From bd8e468fb01e64bd0ede49094c4c5d3e528a591b Mon Sep 17 00:00:00 2001 From: Will Estes Date: Tue, 9 Apr 2002 13:33:05 +0000 Subject: [PATCH] test-include-by-buffer now under automake control --- tests/test-include-by-buffer/Makefile.am | 28 ++++++++++ tests/test-include-by-buffer/Makefile.in | 71 ------------------------ 2 files changed, 28 insertions(+), 71 deletions(-) create mode 100644 tests/test-include-by-buffer/Makefile.am delete mode 100644 tests/test-include-by-buffer/Makefile.in diff --git a/tests/test-include-by-buffer/Makefile.am b/tests/test-include-by-buffer/Makefile.am new file mode 100644 index 0000000..9538d34 --- /dev/null +++ b/tests/test-include-by-buffer/Makefile.am @@ -0,0 +1,28 @@ +BISON = @BISON@ +FLEX = $(top_builddir)/flex + +EXTRA_DIST = scanner.l test-1.input test-2.input test-3.input +CLEANFILES = scanner.c scanner.h parser.c parser.h test-include-by-buffer OUTPUT $(OBJS) +OBJS = scanner.o # parser.o + +INCLUDES = -I $(srcdir) -I $(top_srcdir) +#LDFLAGS = $(top_srcdir)/libfl.a +#LFLAGS = --header="scanner.h" +#YFLAGS = --defines --output=parser.c + +testname = test-include-by-buffer + +scanner.c: $(srcdir)/scanner.l + $(FLEX) $< + +parser.c: $(srcdir)/parser.y + $(BISON) $(YFLAGS) $< + +$(testname)$(EXEEXT): $(OBJS) + $(CC) -o $@ $(OBJS) $(LDFLAGS) + +test: $(testname)$(EXEEXT) + $(srcdir)/$(testname)$(EXEEXT) $(srcdir)/test-1.input + +.c.o: + $(CC) -c -o $@ $(INCLUDES) $< diff --git a/tests/test-include-by-buffer/Makefile.in b/tests/test-include-by-buffer/Makefile.in deleted file mode 100644 index 460d308..0000000 --- a/tests/test-include-by-buffer/Makefile.in +++ /dev/null @@ -1,71 +0,0 @@ -# Makefile.in for a single TEST. -# -# By default this Makefile will build the target "$(TESTNAME)" -# from the sources "scanner.l" and "parser.y". -# -# $(TESTNAME) is supplied by the calling Makefile. -# "parser.y" is not necessary. You may delete this file -# if you do not require a parser. -# "scanner.l" is necessary. It should build "scanner.c". -# - -@SET_MAKE@ - -CFLAGS = @CFLAGS@ -CPPFLAGS = @CPPFLAGS@ -I. -I"@srcdir@" -I.. -DEFS = @DEFS@ -LDFLAGS = @LDFLAGS@ -LIBS = @LIBS@ -SHELL = /bin/sh -srcdir = @srcdir@ -VPATH = @srcdir@ -LN_S = @LN_S@ -YACC = @YACC@ -CC = @CC@ -AR = ar -RANLIB = @RANLIB@ -YACC = @YACC@ - -# Edit these if necessary for your specific test. -FLEX = ../../flex -YFLAGS = --defines --output-file="parser.c" --name-prefix="test" -OBJS = scanner.o # parser.o - -# Force YACC to be bison (autoconf generates 'bison -y') -YACC = @BISON@ - -TESTNAME = test-include-by-buffer -all: $(TESTNAME) - -$(TESTNAME): $(OBJS) - $(CC) $(CFLAGS) -o $(TESTNAME) $(OBJS) $(LDFLAGS) $(LIBS) - -scanner.c: $(srcdir)/scanner.l - $(FLEX) $(srcdir)/scanner.l - -scanner.o: scanner.c - $(CC) $(CPPFLAGS) $(CFLAGS) -c scanner.c - -parser.c: $(srcdir)/parser.y - $(YACC) $(YFLAGS) $(srcdir)/parser.y - -parser.o: parser.c - $(CC) $(CPPFLAGS) $(CFLAGS) -c parser.c - -test: check - -check: $(TESTNAME) - for f in test-1.input test-2.input test-3.input ; do \ - if test ! -f $$f ; then \ - cp -f $(srcdir)/$$f . ; \ - fi \ - done - ./$(TESTNAME) test-1.input - -clean: - rm -f scanner.o scanner.c parser.o parser.c parser.h $(TESTNAME) - - -distclean: clean - rm -f Makefile - -- 2.40.0