compas-dev / compas_libigl

COMPAS bindings for libigl.
http://compas.dev/compas_libigl/
MIT License
4 stars 8 forks source link

Errors while installing the library #7

Closed ioannaMitropoulou closed 4 years ago

ioannaMitropoulou commented 4 years ago

Hello, I follow the instructions in the README for the installation, but I get an extensive error when I try to use pip install -e . I paste the error here:

Obtaining file:///I:/libraries/compas_libigl
Installing collected packages: compas-libigl
  Running setup.py develop for compas-libigl
    ERROR: Command errored out with exit status 1:
     command: 'C:\ProgramData\Anaconda3\envs\igl\python.exe' -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'I:\\libraries\\compas_libigl\\setup.py'"'"'; __file__='"'"'I:\\libraries\\compas_libigl\\setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' develop --no-deps
         cwd: I:\libraries\compas_libigl\
    Complete output (69 lines):
    running develop
    running egg_info
    writing src\compas_libigl.egg-info\PKG-INFO
    writing dependency_links to src\compas_libigl.egg-info\dependency_links.txt
    writing top-level names to src\compas_libigl.egg-info\top_level.txt
    reading manifest file 'src\compas_libigl.egg-info\SOURCES.txt'
    reading manifest template 'MANIFEST.in'
    no previously-included directories found matching 'data'
    no previously-included directories found matching 'temp'
    warning: no files found matching 'LICENSE'
    warning: no previously-included files found matching 'requirements-dev.txt'
    warning: no previously-included files found matching 'pytest.ini'
    warning: no previously-included files found matching '.bumpversion.cfg'
    warning: no previously-included files found matching '.editorconfig'
    warning: no previously-included files found matching 'tasks.py'
    warning: no previously-included files matching '*.py[cod]' found anywhere in distribution
    warning: no previously-included files matching '__pycache__' found anywhere in distribution
    warning: no previously-included files matching '*.dylib' found anywhere in distribution
    warning: no previously-included files matching '*.nb[ic]' found anywhere in distribution
    warning: no previously-included files matching '.DS_Store' found anywhere in distribution
    writing manifest file 'src\compas_libigl.egg-info\SOURCES.txt'
    running build_ext
    -- Selecting Windows SDK version 10.0.18362.0 to target Windows 10.0.18363.
    CMake Error at CMakeLists.txt:31 (find_package):
      By not providing "Findpybind11.cmake" in CMAKE_MODULE_PATH this project has
      asked CMake to find a package configuration file provided by "pybind11",
      but CMake did not find one.

      Could not find a package configuration file provided by "pybind11" with any
      of the following names:

        pybind11Config.cmake
        pybind11-config.cmake

      Add the installation prefix of "pybind11" to CMAKE_PREFIX_PATH or set
      "pybind11_DIR" to a directory containing one of the above files.  If
      "pybind11" provides a separate development package or SDK, be sure it has
      been installed.

    -- Configuring incomplete, errors occurred!
    See also "I:/libraries/compas_libigl/build/temp.win-amd64-3.7/Release/CMakeFiles/CMakeOutput.log".
    Traceback (most recent call last):
      File "<string>", line 1, in <module>
      File "I:\libraries\compas_libigl\setup.py", line 124, in <module>
        cmdclass=dict(build_ext=CMakeBuild),
      File "C:\ProgramData\Anaconda3\envs\igl\lib\site-packages\setuptools\__init__.py", line 161, in setup
        return distutils.core.setup(**attrs)
      File "C:\ProgramData\Anaconda3\envs\igl\lib\distutils\core.py", line 148, in setup
        dist.run_commands()
      File "C:\ProgramData\Anaconda3\envs\igl\lib\distutils\dist.py", line 966, in run_commands
        self.run_command(cmd)
      File "C:\ProgramData\Anaconda3\envs\igl\lib\distutils\dist.py", line 985, in run_command
        cmd_obj.run()
      File "C:\ProgramData\Anaconda3\envs\igl\lib\site-packages\setuptools\command\develop.py", line 38, in run
        self.install_for_development()
      File "C:\ProgramData\Anaconda3\envs\igl\lib\site-packages\setuptools\command\develop.py", line 140, in install_for_development
        self.run_command('build_ext')
      File "C:\ProgramData\Anaconda3\envs\igl\lib\distutils\cmd.py", line 313, in run_command
        self.distribution.run_command(command)
      File "C:\ProgramData\Anaconda3\envs\igl\lib\distutils\dist.py", line 985, in run_command
        cmd_obj.run()
      File "I:\libraries\compas_libigl\setup.py", line 46, in run
        self.build_extension(ext)
      File "I:\libraries\compas_libigl\setup.py", line 79, in build_extension
        subprocess.check_call(['cmake', ext.sourcedir] + cmake_args, cwd=self.build_temp, env=env)
      File "C:\ProgramData\Anaconda3\envs\igl\lib\subprocess.py", line 363, in check_call
        raise CalledProcessError(retcode, cmd)
    subprocess.CalledProcessError: Command '['cmake', 'I:\\libraries\\compas_libigl', '-DCMAKE_LIBRARY_OUTPUT_DIRECTORY=I:\\libraries\\compas_libigl\\src', '-DPYTHON_EXECUTABLE=C:\\ProgramData\\Anaconda3\\envs\\igl\\python.exe', '-DCMAKE_LIBRARY_OUTPUT_DIRECTORY_RELEASE=I:\\libraries\\compas_libigl\\src', '-A', 'x64']' returned non-zero exit status 1.
    ----------------------------------------
ERROR: Command errored out with exit status 1: 'C:\ProgramData\Anaconda3\envs\igl\python.exe' -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'I:\\libraries\\compas_libigl\\setup.py'"'"'; __file__='"'"'I:\\libraries\\compas_libigl\\setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' develop --no-deps Check the logs for full command output.

I noticed that the pybind11 is missing from the cmake paths and the ext folder. Does it have to be added manually?

Thanks, Ioanna

tomvanmele commented 4 years ago

haven't worked on this in a while. will have a look. are you interested in specific functionality or just exploring?

ioannaMitropoulou commented 4 years ago

Firstly I am interested in the geodesic distances. Then I also want to use this project as a template to expose some more libigl functions which are not available in python yet and would be very useful to me.

I should also mention I am running the installation on Windows 10.

tomvanmele commented 4 years ago

the installation instructions are outdated. we have tried to release this package via conda-forge but the process was a bit slow and i gave up :). however that means you have to install using conda-build. it is not more or less complicated. just different. testing the procedure now on mac and windows and will update the instructions as soon as it works.

if you plan to wrap more of igl's functionality, perhaps you can just contribute to this repo?

the plan for compas_libigl is to remove all the cgal related stuff as this is now handled by compas_cgal and focus on the signature igl things, like the conformal maps and parametrisations...

tomvanmele commented 4 years ago

okay this was a bit more complicated than expected. i updated the repo and the instructions. tested the procedure on windows. everything should be fine with a good old pip install...

let me know if you have problems!

ioannaMitropoulou commented 4 years ago

Thanks now it works well! I installed the Python and build the Cmake for Visual Studio, and all looks good so far. Regarding the igl functions I want to wrap, I was interested in shape deformations, mesh cutting, and remeshing along isolines. I will fork this repository, and if I have something that could be useful for others, I will let you know.