Hi Kimon,
I have had similar issues installing graph-tool on the mac. Currently I have
it up and running (with a slight gtk+ problem when trying to export animated
graphs), but this might be an individual success. However, below I send you
the step by step solution that I came up with. At my end this worked at
least. Please let me know if it works for you as well.
Best,
m
Step by step instructions on how to install a working copy of graph-tool on
OS X (tested with High Sierra) with Python 3.X and OpenMP support.
1) Remove all already installed dependencies (Check with brew info
graph-tool)
2) Install llvm, Automarke und libtool:
brew install llvm
brew install automake
brew install libtool
3) Add llvm to environment variables:
echo 'export PATH="/usr/local/opt/llvm/bin:$PATH"' >> ~/.bash_profile
4) Reinitialize ENV:
source ~/.bash_profile
5) Check if the correct clang is called (not Apple clang):
clang --version
6) Install all python3 and all dependencies
brew install python3
brew install pkg-config
brew install boost
brew install boost-python --with-python3 --without-python
brew install cairomm
brew install cgal
brew install py3cairo
brew install gnome-icon-theme
brew install gtk+3
brew install --force librsvg --with-gtk+3
brew install pygobject3 --with-python3 --without-python
brew install google-sparsehash
7) Install python packages with pip3: numpy, scipy, matplotlib
pip3 install numpy
pip3 install scipy
pip3 install matplotlib
7) Clone graph-tool repository:
git clone https://git.skewed.de/count0/graph-tool.git
8) Go to the cloned git folder
9) Set correct Python version in file configure.ac:
AM_PATH_PYTHON([3.6]) ## Replace 2.7 by the correct version you are
using
10) Run
./autogen.sh
11) Modify generated configure file in order to solve a nasty ldflags issue:
Replace:
if test -z "$PYTHON_EXTRA_LDFLAGS"; then
PYTHON_EXTRA_LDFLAGS=`$PYTHON -c "import
distutils.sysconfig; \
conf = distutils.sysconfig.get_config_var; \
print (conf('LINKFORSHARED'))"`
With:
if test -z "$PYTHON_EXTRA_LDFLAGS"; then
PYTHON_EXTRA_LIBS=`$PYTHON-config --ldflags`
12) Run
./configure CC=clang CXX=clang++ LDFLAGS="-L/usr/local/opt/llvm/lib
-Wl,-rpath,/usr/local/opt/llvm/lib" CPPFLAGS="-I/usr/local/opt/llvm/include
-fopenmp"
13) Run
make install
--
Sent from:
http://main-discussion-list-for-the-graph-tool-project.982480.n3.nabble.com/
_______________________________________________
graph-tool mailing list
[email protected]
https://lists.skewed.de/mailman/listinfo/graph-tool