]> granicus.if.org Git - graphviz/commitdiff
add configure test for lib/sfdpgen/triangle.[ch] and define HAVE_TRIANGLE is present
authorellson <devnull@localhost>
Wed, 4 Jun 2008 18:57:53 +0000 (18:57 +0000)
committerellson <devnull@localhost>
Wed, 4 Jun 2008 18:57:53 +0000 (18:57 +0000)
change tests to "#if defined", since HAVE_TRIANGLE is not defined if not present.

configure.ac
lib/neatogen/adjust.c

index b349af84ce5845e67a5628b4ce3bd22546eb6d87..614f7fde94258ddbc1589906e0195a2dedc234c2 100644 (file)
@@ -2503,6 +2503,15 @@ fi
 fi
 AC_SUBST(TKINT_INCLUDES)
 
+# ------------------------------------
+# triangle.[ch]
+
+if test -f "lib/sfdpgen/triangle.c"; then
+if test -f "lib/sfdpgen/triangle.h"; then
+    AC_DEFINE_UNQUOTED(HAVE_TRIANGLE,1,[Define if triangle.[ch] are available.])
+fi
+fi
+
 # ----------------------------------
 # tcl/tk pkgIndex.tcl generation
 
index 984d7c32af3e6201b29d5ebb226e5060abe924c0..5f3eab934f0497c97e987fcdc953d4213ca048f0 100644 (file)
@@ -30,7 +30,7 @@
 #include "heap.h"
 #include "hedges.h"
 #include "digcola.h"
-#if ((HAVE_GTS || HAVE_TRIANGLE) && SFDP)
+#if ((defined(HAVE_GTS) || defined(HAVE_TRIANGLE)) && defined(SFDP))
 #include "sfdp.h"
 #endif
 #ifdef IPSEPCOLA