[petsc-dev] fix conflict between triangle and spai
Satish Balay
balay at mcs.anl.gov
Tue Apr 28 09:15:15 CDT 2020
I get the following error with triangle+spai build with gcc-10 [this is on linux though - ignore osx in PETSC_ARCH]
CLINKER arch-ci-osx-cxx-pkgs-opt/lib/libpetsc.so.3.13.0
/usr/bin/ld: /home/balay/petsc/arch-ci-osx-cxx-pkgs-opt/lib/libtriangle.a(triangle.o):/home/balay/petsc/arch-ci-osx-cxx-pkgs-opt/externalpackages/Triangle/src/triangle.c:667: multiple definition of `epsilon'; /home/balay/petsc/arch-ci-osx-cxx-pkgs-opt/lib/libspai.a(spai.o):(.bss+0x188): first defined here
Matt,
Any objection to this change to triangle?
diff --git a/src/triangle.c b/src/triangle.c
index 8e915a1..76f6d84 100644
--- a/src/triangle.c
+++ b/src/triangle.c
@@ -664,7 +664,7 @@ long samples; /* Number of random samples for point location. */
unsigned long randomseed; /* Current random number seed. */
REAL splitter; /* Used to split REAL factors for exact multiplication. */
-REAL epsilon; /* Floating-point machine epsilon. */
+static REAL epsilon; /* Floating-point machine epsilon. */
REAL resulterrbound;
REAL ccwerrboundA, ccwerrboundB, ccwerrboundC;
REAL iccerrboundA, iccerrboundB, iccerrboundC;
Satish
More information about the petsc-dev
mailing list