Newer CGAL versions build into lib64, breaking current CGAL make rules.
On 64-bit systems, the system installations of boost, cgal are under lib64/
.
The behaviour for a ThirdParty build is mostly lib/
but this can also be changing.
- Boost 1_62_0 and older build into 'lib/'.
- CGAL-4.9 builds into 'lib64/', older versions into 'lib/'.
Future-proof things by using lib$WM_COMPILER_LIB_ARCH
for boost and cgal build rules, and forcing these as build targets in the ThirdParty makeCGAL as well.
Cross-referenced as ThirdParty issue https://develop.openfoam.com/Development/ThirdParty-plus/issues/8
No child items are currently assigned. Use child items to break down this issue into smaller parts.
Link issues together to show that they're related. Learn more.
Activity
- Mark OLESEN Mentioned in issue Development/ThirdParty-plus#8
Mentioned in issue Development/ThirdParty-plus#8
- Mark OLESEN Mentioned in commit aa16fa54
Mentioned in commit aa16fa54
- Prashant Sonakar Mentioned in issue #300 (closed)
Mentioned in issue #300 (closed)
Compiling with ubuntu 15.10, CGAL-4.9 (latest develop branch) and it did not resolve the links to gmp and mpfr when linking foamy. Probably CGAL is missing the correct loader dependencies.
I've reproduced the same error as @landmann, using:
- CGAL 4.9
- Ubuntu 16.04 x86_64
- using Ubuntu's default GCC stack (version 5.4.0) and binutils
ld.bfd
(version 2.26.1) - OpenFOAM-plus (6d7e27d0) and ThirdParty-plus (852e88b4957)
develop
branches
Looks like
-mpfr
was accidentally dropped. The following patch fixes it:diff --git a/wmake/rules/General/CGAL b/wmake/rules/General/CGAL index 2e7e3d5..ae1df01 100644 --- a/wmake/rules/General/CGAL +++ b/wmake/rules/General/CGAL @@ -12,4 +12,5 @@ CGAL_LIBS = \ -L$(BOOST_ARCH_PATH)/lib$(WM_COMPILER_LIB_ARCH) \ -L$(CGAL_ARCH_PATH)/lib \ -L$(CGAL_ARCH_PATH)/lib$(WM_COMPILER_LIB_ARCH) \ - -lCGAL + -lCGAL \ + -lmpfr
Unfortunately it does not solve a similar linking problem when building
foamList
:/home/ofuser/OpenFOAM/OpenFOAM-plus/platforms/linux64GccDPInt32Opt/lib/libconformalVoronoiMesh.so: undefined reference to `mpfr_get_d' /home/ofuser/OpenFOAM/OpenFOAM-plus/platforms/linux64GccDPInt32Opt/lib/libconformalVoronoiMesh.so: undefined reference to `__gmpq_sub' /home/ofuser/OpenFOAM/OpenFOAM-plus/platforms/linux64GccDPInt32Opt/lib/libconformalVoronoiMesh.so: undefined reference to `__gmpn_com' /home/ofuser/OpenFOAM/OpenFOAM-plus/platforms/linux64GccDPInt32Opt/lib/libconformalVoronoiMesh.so: undefined reference to `__gmpq_init' /home/ofuser/OpenFOAM/OpenFOAM-plus/platforms/linux64GccDPInt32Opt/lib/libconformalVoronoiMesh.so: undefined reference to `mpfr_clear' /home/ofuser/OpenFOAM/OpenFOAM-plus/platforms/linux64GccDPInt32Opt/lib/libconformalVoronoiMesh.so: undefined reference to `__gmpq_clear' /home/ofuser/OpenFOAM/OpenFOAM-plus/platforms/linux64GccDPInt32Opt/lib/libconformalVoronoiMesh.so: undefined reference to `__gmpn_sqr' /home/ofuser/OpenFOAM/OpenFOAM-plus/platforms/linux64GccDPInt32Opt/lib/libconformalVoronoiMesh.so: undefined reference to `__gmpn_copyi' /home/ofuser/OpenFOAM/OpenFOAM-plus/platforms/linux64GccDPInt32Opt/lib/libconformalVoronoiMesh.so: undefined reference to `__gmpn_sub_n' /home/ofuser/OpenFOAM/OpenFOAM-plus/platforms/linux64GccDPInt32Opt/lib/libconformalVoronoiMesh.so: undefined reference to `mpfr_init2' /home/ofuser/OpenFOAM/OpenFOAM-plus/platforms/linux64GccDPInt32Opt/lib/libconformalVoronoiMesh.so: undefined reference to `__gmpq_set_si' /home/ofuser/OpenFOAM/OpenFOAM-plus/platforms/linux64GccDPInt32Opt/lib/libconformalVoronoiMesh.so: undefined reference to `__gmpq_mul' /home/ofuser/OpenFOAM/OpenFOAM-plus/platforms/linux64GccDPInt32Opt/lib/libconformalVoronoiMesh.so: undefined reference to `__gmpq_cmp' /home/ofuser/OpenFOAM/OpenFOAM-plus/platforms/linux64GccDPInt32Opt/lib/libconformalVoronoiMesh.so: undefined reference to `mpfr_set_q' /home/ofuser/OpenFOAM/OpenFOAM-plus/platforms/linux64GccDPInt32Opt/lib/libconformalVoronoiMesh.so: undefined reference to `__gmpq_div' /home/ofuser/OpenFOAM/OpenFOAM-plus/platforms/linux64GccDPInt32Opt/lib/libconformalVoronoiMesh.so: undefined reference to `__gmpn_add_n' /home/ofuser/OpenFOAM/OpenFOAM-plus/platforms/linux64GccDPInt32Opt/lib/libconformalVoronoiMesh.so: undefined reference to `__gmpn_mul' /home/ofuser/OpenFOAM/OpenFOAM-plus/platforms/linux64GccDPInt32Opt/lib/libconformalVoronoiMesh.so: undefined reference to `__gmpq_add' /home/ofuser/OpenFOAM/OpenFOAM-plus/platforms/linux64GccDPInt32Opt/lib/libconformalVoronoiMesh.so: undefined reference to `__gmpq_set_d' collect2: error: ld returned 1 exit status /home/ofuser/OpenFOAM/OpenFOAM-plus/wmake/makefiles/general:132: recipe for target '/home/ofuser/OpenFOAM/OpenFOAM-plus/platforms/linux64GccDPInt32Opt/bin/foamList' failed
Edited by Bruno Santos- Mark OLESEN Mentioned in commit 4f37fb9c
Mentioned in commit 4f37fb9c
- Mark OLESEN Status changed to closed
Status changed to closed