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

Trouble installing on Windows #89

Closed
montallban opened this issue May 3, 2020 · 5 comments
Closed

Trouble installing on Windows #89

montallban opened this issue May 3, 2020 · 5 comments

Comments

@montallban
Copy link

montallban commented May 3, 2020

Hi, thanks to the contributors to this repository, I have cleared some hurdles in my installation of pygalmesh. However, more remain.

So far, the process has been simply a process of finding things to download to get one step further in the installation. Currently, I'm hung up on

  /Users/User/usr/vcpkg/installed/x86-windows/include/CGAL/Mesh_3/Is_mesh_domain_field_3.h(25): fatal error C1083: Cannot open include file: 'boost/callable_traits/is_invocable.hpp': No such file or directory
    error: command 'C:\\Program Files (x86)\\Microsoft Visual Studio\\2019\\Community\\VC\\Tools\\MSVC\\14.22.27905\\bin\\HostX86\\x64\\cl.exe' failed with exit status 2

I wasn't aware that boost was a dependency for pygalmesh. A simple google search turns up: https://www.boost.org/doc/libs/?view=category_metaprogramming&sort=boost-version

I'm new to this, so sorry if the steps are blindingly easy to you.

@flothesof
Copy link

Hi,
I have been able to install pygalmesh on windows, doing a little bit of hacking to get it to work.

My instructions rely on the use of conda and the conda-forge channel (related to my work on #81).

It consists of installing the dependencies using conda-forge and then of a little patching to get the paths right. I've done this in a clean conda environment so as to try to make it as reproducible as possible.

installing dependencies

conda create -n pygalmesh_test python=3.7
conda activate pygalmesh_test
conda install -c conda-forge pybind11 mpir mpfr eigen cgal-cpp

cloning the source and hacking it a little bit

git clone https://github.com/nschloe/pygalmesh.git
cd pygalmesh
set EIGEN_INCLUDE_DIR=c:\Anaconda3\envs\pygalmesh_test\Library\include\eigen3
#in setup.py add the last line to include_dirs
	include_dirs=[
				os.environ.get("EIGEN_INCLUDE_DIR", "/usr/include/eigen3/"),
				# Path to pybind11 headers
				get_pybind_include(),
				get_pybind_include(user=True),
	--> this		r"C:\Anaconda3\envs\pygalmesh_test\Library\include",
			],
#and also after the last comma at the same level than include_dirs			
	extra_link_args = ["/LIBPATH:C:\Anaconda3\envs\pygalmesh_test\Library\lib"],		
# finally on the command line
pip install .

Of course, if your path to the conda environment is different, you have to adapt this "recipe" to your own case.

Regards,
Florian

@nschloe
Copy link
Collaborator

nschloe commented May 4, 2020

Let me point everyone to https://anaconda.org/conda-forge/pygalmesh. (Thanks @flothesof!)

@nschloe nschloe closed this as completed May 4, 2020
@sama2689
Copy link

sama2689 commented Jun 7, 2021

Will using the conda-forge method still require installation of CGAL and Eigen separately? Or are these installed by conda?

@nschloe
Copy link
Collaborator

nschloe commented Jun 7, 2021

I think it's pulled in automatically.

@flothesof
Copy link

To elaborate a little more on that answer: the conda-forge version of pygalmesh knows about its dependencies (such as CGAL and Eigen) which are installed as binary packages (no compilation needed).

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

No branches or pull requests

4 participants