GIBBON icon indicating copy to clipboard operation
GIBBON copied to clipboard

Linux: Compiling geogram and tetgen for `ggremesh` and `runTetGen`

Open shermanlo77 opened this issue 3 years ago • 2 comments

Linux users may have problems using the MATLAB functions ggremesh and runTetGen. One of which is discussed in issue #81.

The functions ggremesh and runTetGen will call externally lib_ext/lin64/bin/vorpalite and lib_ext/tetGen/lin64/tetgen which are pre-compiled binaries. A disadvantage of using these binaries is that they may not be compatible with some Linux computers.

For example, for myself, calling ./lib_ext/tetGen/lin64/tetgen caused the error

/lib64/libm.so.6: version `GLIBC_2.29' not found

I would recommend Linux users compile the binaries themselves. Perhaps this could be done automatically when calling installGibbon.m as a feature or option.

vorpalite

Download the source from the GitHub repo. Follow the compilation instructions. This requires cmake and many prerequisites (read the error messages for hints). Replace the GIBBON's version of vorpalite.

git clone https://github.com/alicevision/geogram.git
cd geogram
sh -f configure.sh
cd build/Linux64-gcc-dynamic-Release
make
cp bin/vorpalite <path to GIBBON>/lib_ext/geogram/lin64/bin/vorpalite

tetgen

Download the source from the GitHub repo. Compile and replace the GIBBON's version of tetgen.

git clone https://github.com/libigl/tetgen.git
cd tetgen
make
cp tetgen <path to GIBBON>/lib_ext/tetGen/lin64/tetgen

shermanlo77 avatar Aug 26 '22 14:08 shermanlo77

Thank you so much for posting these instructions @shermanlo77 I used them (the geogram based instructions) just now as well on a new linux computer.

I'll have to see if the same can be achieved to the latest geomgram developments over at: https://github.com/BrunoLevy/geogram.

Kevin-Mattheus-Moerman avatar Apr 24 '23 15:04 Kevin-Mattheus-Moerman

I can confirm this now also works for the latest geogram (which seems faster) from: https://github.com/BrunoLevy/geogram/wiki/compiling_Linux. Similar instructions:

git clone --recurse-submodules https://github.com/BrunoLevy/geogram.git
cd geogram
./configure.sh
cd build/Linux64-gcc-dynamic-Release
make -j 8
cp bin/vorpalite <path to GIBBON>/lib_ext/geogram/lin64/bin/vorpalite

Kevin-Mattheus-Moerman avatar Apr 24 '23 16:04 Kevin-Mattheus-Moerman