ana(conda) windows packaging

Having trouble installing or compiling FreeCAD? Get help here.
Forum rules
Be nice to others! Respect the FreeCAD code of conduct!
User avatar
sgrogan
Veteran
Posts: 6499
Joined: Wed Oct 22, 2014 5:02 pm

Re: ana(conda) windows packaging

Post by sgrogan »

looo wrote:So we have to create a new UseLibPackXX.cmake file to build with conda? or can we use an old one?
Don't know, if the conda directory structure is the same as the libpack then we may be ok. If not we probably don't build with a libpack, but then we would probably need to set a lot of paths manually.
Anyway the error is because a libpack could be found, so we need to set the path

Code: Select all

-DFREECAD_LIBPACK_DIR=$PREFIX
If it doesn't work, then we can try without a libpack

Code: Select all

-DFREECAD_LIBPACK_USE=FALSE
"fight the good fight"
User avatar
looo
Veteran
Posts: 3941
Joined: Mon Nov 11, 2013 5:29 pm

Re: ana(conda) windows packaging

Post by looo »

thanks, -DFREECAD_LIBPACK_USE=FALSE worked. Now I am stuck with vtk.

Code: Select all

CMake Error at CMakeLists.txt:631 (find_package):
  Could not find a configuration file for package "VTK" that is compatible
  with requested version "".

  The following configuration files were considered but not accepted:

    C:/Users/fc_builder/Miniconda3/conda-bld/freecad_1490210124892/_b_env/Library/lib/cmake/vtk-7.1/
VTKConfig.cmake, version: 7.1.0 (64bit)
strange. I thought 7.1 is quite new.
peterl94
Veteran
Posts: 1001
Joined: Thu May 23, 2013 7:31 pm
Location: United States

Re: ana(conda) windows packaging

Post by peterl94 »

Hey guys, sorry for my absence. I haven't read through this thread, but to me that vtk message seems like the version number it is checking is an empty string so it can't find any files that match. Is the requested version specified with a variable?
User avatar
looo
Veteran
Posts: 3941
Joined: Mon Nov 11, 2013 5:29 pm

Re: ana(conda) windows packaging

Post by looo »

ah I missed the line above:

Code: Select all

-- VTK components: not found or used
So the propbem is with this: https://github.com/FreeCAD/FreeCAD/blob ... t#L638L639 . there is no requested version I think.
the libraries are all suffixed with -7.1.

ps.: Thanks for the help and welcome back. :D
peterl94
Veteran
Posts: 1001
Joined: Thu May 23, 2013 7:31 pm
Location: United States

Re: ana(conda) windows packaging

Post by peterl94 »

The check for the components is wrapped in "if(UNIX)". Maybe try changing it to "if(UNIX or windows and not use libpack)"?
User avatar
looo
Veteran
Posts: 3941
Joined: Mon Nov 11, 2013 5:29 pm

Re: ana(conda) windows packaging

Post by looo »

same problem some lines above.

Code: Select all

CMake Error at CMakeLists.txt:615 (find_package):
  Could not find a configuration file for package "VTK" that is compatible
  with requested version "".
If anyone wants to make further experiments: current state of the recipe can be found here:
https://github.com/looooo/FreeCAD_Conda ... ng/FreeCAD

good night :D
User avatar
sgrogan
Veteran
Posts: 6499
Joined: Wed Oct 22, 2014 5:02 pm

Re: ana(conda) windows packaging

Post by sgrogan »

peterl94 wrote:The check for the components is wrapped in "if(UNIX)". Maybe try changing it to "if(UNIX or windows and not use libpack)"?
Is it?
I don't have this problem with VTK7.0, but I'm using CLbundler libpack with the VTK inserted into the libpack. I haven't found where an empty string should be passed.
"fight the good fight"
peterl94
Veteran
Posts: 1001
Joined: Thu May 23, 2013 7:31 pm
Location: United States

Re: ana(conda) windows packaging

Post by peterl94 »

I was talking about the if statement right above the code that looo highlighted: https://github.com/FreeCAD/FreeCAD/blob ... t#L622L631

I looked at the documentation for find_package and it says that when a version is passed to find_package, cmake defines PACKAGE_FIND_VERSION which is used in the config cmake files. Since we are not specifying a version, PACKAGE_FIND_VERSION would not be defined and so that is why no version is displayed in the error message. That is what it seems like anyway. I don't know how it works elsewhere, but I wonder if specifying a version would fix the problem.
peterl94
Veteran
Posts: 1001
Joined: Thu May 23, 2013 7:31 pm
Location: United States

Re: ana(conda) windows packaging

Post by peterl94 »

No, the version is not the issue. I discovered that the actual problem is that CMAKE_SIZEOF_VOID_P is set to 4 (on my system anyway) somehow even though we are clearly building 64bit (which means it is supposed to be 8). There is a check for this in the vtk (and hdf5) version config files to make sure the installed lib is the same architecture as the calling project. I have no idea how CMAKE_SIZEOF_VOID_P is not set to 8.
User avatar
looo
Veteran
Posts: 3941
Joined: Mon Nov 11, 2013 5:29 pm

Re: ana(conda) windows packaging

Post by looo »

Seems there is something wrong on windows? Setting CMAKE_SIZEOF_VOID_P = "" worked for me. After adding the lib-dir and include-dir to coin search path, now pyside makes big problems. In there config they use unix like filepaths with "/" and not "\". Seems we have to write a patch for https://github.com/conda-forge/pyside-feedstock
Post Reply