aboutsummaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authorbellard <bellard>2001-10-28 15:20:24 +0000
committerbellard <bellard>2001-10-28 15:20:24 +0000
commit927c4afc0cd9a66b58c44475b2650d9fe9c9fc2a (patch)
tree590d900cc1da703113fbdc35dd9005b95ad4b94e /Makefile
parent9a8dfaac3508c594559b3bb063212e75fffe4d07 (diff)
downloadtinycc-927c4afc0cd9a66b58c44475b2650d9fe9c9fc2a.tar.gz
tinycc-927c4afc0cd9a66b58c44475b2650d9fe9c9fc2a.tar.bz2
update for name change
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile63
1 files changed, 36 insertions, 27 deletions
diff --git a/Makefile b/Makefile
index fb4ada4..3420331 100644
--- a/Makefile
+++ b/Makefile
@@ -3,50 +3,59 @@ all: test cvt
test: prog.bin
cmp -l prog.bin prog.bin.ref
-run: tc prog.c
- ./tc prog.c
+run: tcc prog.c
+ ./tcc prog.c
-run2: tc tc1.c prog.c
- ./tc tc1.c prog.c
+run2: tcc tcc1.c prog.c
+ ./tcc tcc1.c prog.c
-run3: tc tc1.c prog.c
- ./tc tc1.c tc1.c prog.c
+run3: tcc tcc1.c prog.c
+ ./tcc tcc1.c tcc1.c prog.c
-prog.bin: prog.c tct
- ./tct prog.c $@
+prog.bin: prog.c tcc
+ ./tc prog.c $@
ndisasm -b 32 $@
-p2.bin: p2.c tct
- ./tct $< $@
+p2.bin: p2.c tcc
+ ./tcc $< $@
ndisasm -b 32 $@
-tct: tc.c
- gcc -DTEST -O2 -g -o $@ $< -ldl
+# Tiny C Compiler
-tc: tc.c Makefile
+tcc: tcc.c
gcc -O2 -Wall -g -o $@ $< -ldl
-tc1: tc1.c
+tcc1: tcc1.c
gcc -O2 -Wall -g -o $@ $<
-cvt: cvt.c
- gcc -O2 -Wall -g -o $@ $<
+tcc1.i: tcc.c Makefile
+ gcc -E -P -o $@ $<
-instr.o: instr.S
- gcc -O2 -Wall -g -c -o $@ $<
+tcc1.c: tcc1.i cvt Makefile
+ ./cvt -d $< $@
+ @ls -l $@
+
+# obfuscated C compiler
+otcc: otcc.c
+ gcc -O2 -Wall -g -o $@ $< -ldl
-tc.i: tc.c Makefile
- gcc -E -P -DTINY -o $@ tc.c
+otcc.i: otcc.c Makefile
+ gcc -E -P -DTINY -o $@ $<
-tc1.c: tc.i cvt Makefile
+otcc1.c: otcc.i cvt Makefile
./cvt $< $@
@ls -l $@
-test2: tct tc1.c
- ./tct tc1.c tc2
- ndisasm -b 32 tc2
+orun: otcc otcc1.c
+ ./otcc otcc1.c ex1.c
-tc2: tc
- ./tct < tc1.c > tc2
- ndisasm -b 32 tc2
+# misc
+
+cvt: cvt.c
+ gcc -O2 -Wall -g -o $@ $<
+
+instr.o: instr.S
+ gcc -O2 -Wall -g -c -o $@ $<
+clean:
+ rm -f *~ *.o tcc tcc1 cvt