]> granicus.if.org Git - graphviz/commitdiff
additional check for ruby.h
authorellson <devnull@localhost>
Tue, 18 Oct 2005 21:09:35 +0000 (21:09 +0000)
committerellson <devnull@localhost>
Tue, 18 Oct 2005 21:09:35 +0000 (21:09 +0000)
configure.ac

index 966cab49836d9ebb0b10a3b4b3de6a73e8545c8b..88a723566aada6cc67ad8156a75133bc979a0bec 100644 (file)
@@ -445,6 +445,13 @@ AC_CHECK_PROG(RUBY,ruby,ruby)
 if test "x$RUBY" != "x"; then
   RUBY_INCLUDES="-I`ruby $TOP_DIR/config/config_ruby.rb INCLUDES`"
   RUBY_LIBS="-L`ruby $TOP_DIR/config/config_ruby.rb lib` -lruby"
+  save_CPPFLAGS=$CPPFLAGS
+  CPPFLAGS="$CPPFLAGS $RUBY_INCLUDES"
+  AC_CHECK_HEADER(ruby.h,,[
+    AC_MSG_WARN([Unable to find header ruby.h. The Ruby packages will not be built])
+    RUBY=
+    ])
+  CPPFLAGS=$save_CPPFLAGS
 fi
 AC_SUBST(RUBY_INCLUDES)
 AC_SUBST(RUBY_LIBS)