Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add VTK/9.0.1 - help needed! #3280

Closed
wants to merge 44 commits into from
Closed

Conversation

atrelinski
Copy link

@atrelinski atrelinski commented Oct 20, 2020

Specify library name and version: vtk/9.0.1

  • I've read the guidelines for contributing.
  • I've followed the PEP8 style guides for Python code in the recipes.
  • I've used the latest Conan client version.
  • I've tried at least one configuration locally with the
    conan-center hook activated.

@CLAassistant
Copy link

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.


atrelinski seems not to be a GitHub user. You need a GitHub account to be able to sign the CLA. If you have already a GitHub account, please add the email address used for this commit to your account.
You have signed the CLA already but the status is still pending? Let us recheck it.

@conan-center-bot

This comment has been minimized.

@conan-center-bot

This comment has been minimized.

@atrelinski
Copy link
Author

Not sure why CLA is pending while I've signed it (after fixing commit email address)
Also I can't sign it second time, and recheck it doesn't work for me.
Please help

@conan-center-bot
Copy link
Collaborator

All green in build 21 (9bf7762c3837bff942ecc022ba9613a770d4a028)! 😊

@atrelinski
Copy link
Author

madebr, thank You for analysis!
It definitely move thing forward!,
unfortunately probably it will take a while to address all of that :(

@stale
Copy link

stale bot commented Dec 1, 2020

This pull request has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the stale label Dec 1, 2020
@atrelinski
Copy link
Author

It looks like, I won't find more time to improve recipe :(

For those who would like to improve VTK 9.0.1 recipe or use it here is link to it:
https://github.com/atrelinski/conan-vtk/tree/stable/9.0.1

@stale stale bot removed the stale label Dec 10, 2020
@taoyouh
Copy link
Contributor

taoyouh commented Jan 4, 2021

@madebr

I found that the 3rd-party libraries contained in VTK are modified special versions. The symbols are changed so that it should not conflict with the packages directly used by the user.

Is it still necessary to use the cci version of those packages?

@jgsogo
Copy link
Contributor

jgsogo commented Jan 25, 2021

Hi, @atrelinski

I see the license/cla is pending. I feel like there is nothing we can do on our side if the notification from the license/app doesn't arrive... maybe the easiest way for you is to close this PR and open a new one with these same changes.

Comment on lines +271 to +273
# FIXME: Missing qt recipe. Qt recipe PR: https://github.com/conan-io/conan-center-index/pull/1759
# When qt available, "self.requires("qt/5.15.1")" should replace below line.
raise ConanInvalidConfiguration("qt is not (yet) available on conan-center-index")
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It was merged 🎉

if self.options.group_rendering:
self.requires("opengl/system")
if self.options.module_ioxdmf3:
self.requires("boost/1.74.0")
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
self.requires("boost/1.74.0")
self.requires("boost/1.75.0")

self._cmake = CMake(self)
self._cmake.definitions["BUILD_TESTING"] = "OFF"
self._cmake.definitions["BUILD_EXAMPLES"] = "OFF"
self._cmake.definitions["BUILD_SHARED_LIBS"] = "ON" if self.options.shared else "OFF"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Conan handles the translation

Suggested change
self._cmake.definitions["BUILD_SHARED_LIBS"] = "ON" if self.options.shared else "OFF"
self._cmake.definitions["BUILD_SHARED_LIBS"] = self.options.shared

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I see elsewhere it's very strict... is that the case here?

for module in self._modules:
# Defines shouldn't be left uninitalized, however VTK has so many _modules, that
# it ends up as "The command line is too long." error on Windows.
if self.options.get_safe("module_{}".format(module.lower()), default=False):
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
if self.options.get_safe("module_{}".format(module.lower()), default=False):
# FIXME: remove top level if
if self.options.get_safe("module_{}".format(module.lower()), default=False):

Comment on lines +295 to +301
def build(self):
if self.options.group_qt:
if self.options["qt"].shared == False:
raise ConanInvalidConfiguration("VTK option 'group_qt' requires 'qt:shared=True'")
if self.settings.os == "Linux":
if self.options["qt"].qtx11extras == False:
raise ConanInvalidConfiguration("VTK option 'group_qt' requires 'qt:qtx11extras=True'")
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
def build(self):
if self.options.group_qt:
if self.options["qt"].shared == False:
raise ConanInvalidConfiguration("VTK option 'group_qt' requires 'qt:shared=True'")
if self.settings.os == "Linux":
if self.options["qt"].qtx11extras == False:
raise ConanInvalidConfiguration("VTK option 'group_qt' requires 'qt:qtx11extras=True'")
def validate(self):
if self.options.group_qt:
if self.options["qt"].shared == False:
raise ConanInvalidConfiguration("VTK option 'group_qt' requires 'qt:shared=True'")
if self.settings.os == "Linux":
if self.options["qt"].qtx11extras == False:
raise ConanInvalidConfiguration("VTK option 'group_qt' requires 'qt:qtx11extras=True'")
def build(self):

if self.settings.compiler != "gcc":
return libs
libs_ordered = []
print('VTK libs before sort: ' + (';'.join(libs)))
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There is a self.output.info for the conan-ization of print


if not self.options.shared and self.options.group_qt:
if self.settings.os == 'Windows':
self.cpp_info.system_libs.append('Ws2_32') # 'vtksys-9.0d.lib' require 'gethostbyname', 'gethostname', 'WSAStartup' and 'WSACleanup' which are in 'Ws2_32.lib' library
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
self.cpp_info.system_libs.append('Ws2_32') # 'vtksys-9.0d.lib' require 'gethostbyname', 'gethostname', 'WSAStartup' and 'WSACleanup' which are in 'Ws2_32.lib' library
self.cpp_info.system_libs.append('ws2_32') # 'vtksys-9.0d.lib' require 'gethostbyname', 'gethostname', 'WSAStartup' and 'WSACleanup' which are in 'Ws2_32.lib' library

Comment on lines +360 to +361
version_split = self.version.split('.')
short_version = "{}.{}".format(version_split[0], version_split[1])
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
version_split = self.version.split('.')
short_version = "{}.{}".format(version_split[0], version_split[1])
version = tools.Version(self.version)
short_version = "{}.{}".format(version.major, version.minor)

Comment on lines +362 to +364
# Why "vtknetcdf" and "vtknetcdfcpp" are treated exceptionally from all other _modules?
# There are a lot of other *.h in subfolders, should they be directly exposed too
# or maybe those two should be removed from below?
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this how the CMake targets are exposed? Maybe put a link?

Copy link
Contributor

@prince-chrismc prince-chrismc left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There's at time some fuss about mixing ' and ", being C++ developers there are strong preference for the double quote consistency.

There's a few items I listed above, can you please just make it consistent in your next commit?

@prince-chrismc
Copy link
Contributor

You'll need to edit the commit authorship on all of commits to fix the CLA ( or just squash and force push )

There is no GitHub account associated to the email that the commits are being made against ( it needs to match the account you are using to open the PR )

@conan-center-bot
Copy link
Collaborator

Failure in build 22 (9bf7762c3837bff942ecc022ba9613a770d4a028):

  • vtk/9.0.1@:
    CI failed to create some packages (All logs)

    Logs for packageID efcd8bcea0e221bbd14c0dc9e532611086ae4385:
    [settings]
    arch=x86_64
    arch_build=x86_64
    build_type=Debug
    compiler=clang
    compiler.libcxx=libstdc++
    compiler.version=11
    os=Linux
    os_build=Linux
    [options]
    vtk:shared=False
    
    [ 15%] Building C object source_subfolder/ThirdParty/libproj/vtklibproj/src/CMakeFiles/libproj.dir/pj_strerrno.c.o
    [ 15%] Building C object source_subfolder/ThirdParty/libproj/vtklibproj/src/CMakeFiles/libproj.dir/pj_transform.c.o
    [ 15%] Building C object source_subfolder/ThirdParty/libproj/vtklibproj/src/CMakeFiles/libproj.dir/pj_tsfn.c.o
    [ 15%] Building C object source_subfolder/ThirdParty/libproj/vtklibproj/src/CMakeFiles/libproj.dir/pj_units.c.o
    [ 15%] Building C object source_subfolder/ThirdParty/libproj/vtklibproj/src/CMakeFiles/libproj.dir/pj_utils.c.o
    [ 15%] Building C object source_subfolder/ThirdParty/libproj/vtklibproj/src/CMakeFiles/libproj.dir/pj_zpoly1.c.o
    [ 15%] Building C object source_subfolder/ThirdParty/libproj/vtklibproj/src/CMakeFiles/libproj.dir/proj_mdist.c.o
    [ 15%] Building C object source_subfolder/ThirdParty/libproj/vtklibproj/src/CMakeFiles/libproj.dir/proj_rouss.c.o
    [ 15%] Building C object source_subfolder/ThirdParty/libproj/vtklibproj/src/CMakeFiles/libproj.dir/rtodms.c.o
    [ 15%] Building C object source_subfolder/ThirdParty/libproj/vtklibproj/src/CMakeFiles/libproj.dir/vector1.c.o
    [ 15%] Building C object source_subfolder/ThirdParty/libproj/vtklibproj/src/CMakeFiles/libproj.dir/pj_strtod.c.o
    [ 15%] Linking C static library ../../../../../lib/libvtklibproj-9.0.a
    [ 15%] Built target libproj
    Makefile:148: recipe for target 'all' failed
    vtk/9.0.1: 
    CMake Warning:
      Manually-specified variables were not used by the project:
    
        BUILD_EXAMPLES
        CMAKE_EXPORT_NO_PACKAGE_REGISTRY
    
    
    /home/conan/w/BuildSingleReference/.conan/data/vtk/9.0.1/_/_/build/efcd8bcea0e221bbd14c0dc9e532611086ae4385/source_subfolder/ThirdParty/gl2ps/vtkgl2ps/gl2ps.c:4408:17: warning: implicit conversion from 'unsigned long' to 'double' changes value from 18446744073709551614 to 18446744073709551616 [-Wimplicit-const-int-float-conversion]
      double dmax = ~1UL;
             ~~~~   ^~~~
    /home/conan/w/BuildSingleReference/.conan/data/vtk/9.0.1/_/_/build/efcd8bcea0e221bbd14c0dc9e532611086ae4385/source_subfolder/ThirdParty/gl2ps/vtkgl2ps/gl2ps.c:4451:17: warning: implicit conversion from 'unsigned long' to 'double' changes value from 18446744073709551614 to 18446744073709551616 [-Wimplicit-const-int-float-conversion]
      double dmax = ~1UL;
             ~~~~   ^~~~
    /home/conan/w/BuildSingleReference/.conan/data/vtk/9.0.1/_/_/build/efcd8bcea0e221bbd14c0dc9e532611086ae4385/source_subfolder/ThirdParty/gl2ps/vtkgl2ps/gl2ps.c:4476:17: warning: implicit conversion from 'unsigned long' to 'double' changes value from 18446744073709551614 to 18446744073709551616 [-Wimplicit-const-int-float-conversion]
      double dmax = ~1UL;
             ~~~~   ^~~~
    3 warnings generated.
    ../../../lib/libvtkWrappingTools-9.0.a(vtkParse.tab.c.o):/home/conan/w/BuildSingleReference/.conan/data/vtk/9.0.1/_/_/build/efcd8bcea0e221bbd14c0dc9e532611086ae4385/source_subfolder/Wrapping/Tools/vtkParse.tab.c:224: multiple definition of `currentFunction'
    CMakeFiles/WrapJava.dir/vtkWrapJava.c.o:/home/conan/w/BuildSingleReference/.conan/data/vtk/9.0.1/_/_/build/efcd8bcea0e221bbd14c0dc9e532611086ae4385/source_subfolder/Wrapping/Tools/vtkWrapJava.c:28: first defined here
    clang: error: linker command failed with exit code 1 (use -v to see invocation)
    make[2]: *** [bin/vtkWrapJava-9.0] Error 1
    make[1]: *** [source_subfolder/Wrapping/Tools/CMakeFiles/WrapJava.dir/all] Error 2
    make[1]: *** Waiting for unfinished jobs....
    ../../../lib/libvtkWrappingTools-9.0.a(vtkParse.tab.c.o):/home/conan/w/BuildSingleReference/.conan/data/vtk/9.0.1/_/_/build/efcd8bcea0e221bbd14c0dc9e532611086ae4385/source_subfolder/Wrapping/Tools/vtkParse.tab.c:224: multiple definition of `currentFunction'
    CMakeFiles/ParseJava.dir/vtkParseJava.c.o:/home/conan/w/BuildSingleReference/.conan/data/vtk/9.0.1/_/_/build/efcd8bcea0e221bbd14c0dc9e532611086ae4385/source_subfolder/Wrapping/Tools/vtkParseJava.c:28: first defined here
    clang: error: linker command failed with exit code 1 (use -v to see invocation)
    make[2]: *** [bin/vtkParseJava-9.0] Error 1
    make[1]: *** [source_subfolder/Wrapping/Tools/CMakeFiles/ParseJava.dir/all] Error 2
    make: *** [all] Error 2
    vtk/9.0.1: WARN: Build folder is dirty, removing it: /home/conan/w/BuildSingleReference/.conan/data/vtk/9.0.1/_/_/build/efcd8bcea0e221bbd14c0dc9e532611086ae4385
    vtk/9.0.1: ERROR: Package 'efcd8bcea0e221bbd14c0dc9e532611086ae4385' build failed
    vtk/9.0.1: WARN: Build folder /home/conan/w/BuildSingleReference/.conan/data/vtk/9.0.1/_/_/build/efcd8bcea0e221bbd14c0dc9e532611086ae4385
    ERROR: vtk/9.0.1: Error in build() method, line 307
    	cmake.build()
    	ConanException: Error 2 while executing cmake --build '/home/conan/w/BuildSingleReference/.conan/data/vtk/9.0.1/_/_/build/efcd8bcea0e221bbd14c0dc9e532611086ae4385/build' '--' '-j3'
    

Note: To save resources, CI tries to finish as soon as an error is found. For this reason you might find that not all the references have been launched or not all the configurations for a given reference. Also, take into account that we cannot guarantee the order of execution as it depends on CI workload and workers availability.

@stale
Copy link

stale bot commented Apr 6, 2021

This pull request has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the stale label Apr 6, 2021
@stale
Copy link

stale bot commented May 6, 2021

This pull request has been automatically closed because it has not had recent activity. Thank you for your contributions.

@stale stale bot closed this May 6, 2021
@rockandsalt rockandsalt mentioned this pull request Jun 13, 2021
4 tasks
@poretga99
Copy link

I would like to continue work on VTK recipe.
Should new PR be opened for this?

@prince-chrismc
Copy link
Contributor

Please submit a PR !

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

9 participants