]> granicus.if.org Git - graphviz/commitdiff
Some flex insert an explicit declaration for isatty(), so the previous
authorEmden Gansner <erg@research.att.com>
Fri, 4 Jan 2013 18:42:44 +0000 (13:42 -0500)
committerEmden Gansner <erg@research.att.com>
Fri, 4 Jan 2013 18:42:44 +0000 (13:42 -0500)
fix of
#define isatty(x) 0
fails. Add action to strip out the declaration when generating scan.c.

lib/cgraph/Makefile.am

index 241ef97a592ea923012b5f659b0d570e4f5d12d4..c42d947c17c706c3019e9e407271fa02147a5915 100644 (file)
@@ -33,7 +33,7 @@ scan.o scan.lo: scan.c grammar.h
 
 scan.c: $(top_srcdir)/lib/cgraph/scan.l
        @LEX@ -i $(top_srcdir)/lib/cgraph/scan.l
-       @SED@ "s/yy/aag/g" < @LEX_OUTPUT_ROOT@.c > scan.c
+       @SED@ "s/yy/aag/g" < @LEX_OUTPUT_ROOT@.c | @SED@ '/extern.*isatty/d' > scan.c
        rm @LEX_OUTPUT_ROOT@.c
 
 grammar.c: y.tab.c