diff Bison-Flex/BasicCompiler-StackBase/EUC/Makefile~ @ 0:db40c85cad7a default tip

upload sample source
author nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
date Mon, 09 May 2011 03:11:59 +0900
parents
children
line wrap: on
line diff
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Bison-Flex/BasicCompiler-StackBase/EUC/Makefile~	Mon May 09 03:11:59 2011 +0900
@@ -0,0 +1,85 @@
+SOURCES = script.cpp compiler.cpp node.cpp vm.cpp script-parser.yy script-scanner.ll
+HEADERS = compiler.h node.h vm.h vm_code.h vm_value.h
+OBJ = script.o compiler.o node.o vm.o script-parser.o script-scanner.o
+BISON_OUTPUT = script-parser.cc script-parser.hh location.hh position.hh
+
+CFLAGS = -O2
+
+all: script
+
+convert: $(SOURCES) $(HEADERS)
+
+.SUFFIXES:
+.SUFFIXES: .cpp .cc .ll .yy .o
+
+script: $(OBJ)
+	$(CC) $(LDFLAGS) -o $@ $(OBJ) -lstdc++
+
+.cpp.o:
+	$(CC) -c $(CFLAGS) -o $@ $<
+
+.cc.o:
+	$(CC) -c $(CFLAGS) -o $@ $<
+
+$(BISON_OUTPUT): script-parser.yy
+	bison -d -ra -oscript-parser.cc script-parser.yy
+
+script-scanner.cc: script-scanner.ll
+	flex -8 -oscript-scanner.cc script-scanner.ll
+
+script-parser.o: $(BISON_OUTPUT)
+script-scanner.o: script-scanner.cc
+
+script.cpp: ../script.cpp
+	nkf --unix $< > $@
+
+compiler.cpp: ../compiler.cpp
+	nkf --unix $< > $@
+
+node.cpp: ../node.cpp
+	nkf --unix $< > $@
+
+vm.cpp: ../vm.cpp
+	nkf --unix $< > $@
+
+script-parser.yy: ../script-parser.yy
+	nkf --unix $< > $@
+
+script-scanner.ll: ../script-scanner.ll
+	nkf --unix $< > $@
+
+vm_code.h: ../vm_code.h
+	nkf --unix $< > $@
+
+vm_value.h: ../vm_value.h
+	nkf --unix $< > $@
+
+vm.h: ../vm.h
+	nkf --unix $< > $@
+
+node.h: ../node.h
+	nkf --unix $< > $@
+
+compiler.h: ../compiler.h
+	nkf --unix $< > $@
+
+depend:
+	makedepend -- $(CFLAGS) -- $(SOURCES)
+
+# DO NOT DELETE
+
+script.o: compiler.h vm.h vm_value.h vm_code.h node.h
+compiler.o: compiler.h vm.h vm_value.h vm_code.h node.h
+node.o: node.h vm.h vm_value.h vm_code.h compiler.h
+vm.o: vm.h vm_value.h vm_code.h
+script-parser.o: node.h vm.h vm_value.h vm_code.h compiler.h
+script-scanner.o: /usr/include/errno.h /usr/include/features.h
+script-scanner.o: /usr/include/sys/cdefs.h /usr/include/gnu/stubs.h
+script-scanner.o: /usr/include/bits/errno.h /usr/include/linux/errno.h
+script-scanner.o: /usr/include/asm/errno.h /usr/include/asm-i486/errno.h
+script-scanner.o: /usr/include/asm-generic/errno.h
+script-scanner.o: /usr/include/asm-generic/errno-base.h /usr/include/limits.h
+script-scanner.o: /usr/include/bits/posix1_lim.h
+script-scanner.o: /usr/include/bits/local_lim.h /usr/include/linux/limits.h
+script-scanner.o: /usr/include/bits/posix2_lim.h compiler.h vm.h vm_value.h
+script-scanner.o: vm_code.h node.h