History

tccelf.c

bellard committed 24 years ago

Commit 2eddd131 parent cdf51a71 file · +26 −5Browse files

Unified · Split

Makefile+26−5
@@ -12,7 +12,7 @@ CFLAGS+=-m386 -malign-functions=0 · 11 unmodified lines
1212 CFLAGS+=-DCONFIG_TCC_PREFIX=\"$(prefix)\"
1313 DISAS=objdump -d
1414 INSTALL=install
15−VERSION=0.9.8
15+VERSION=0.9.10
1616
1717 # run local version of tcc with local libraries and includes
1818 TCC=./tcc -B. -I.
@@ -46,6 +46,26 @@ test3: tcc tcc.c tcctest.c test.ref · 27 unmodified lines
4646 $(TCC) tcc.c -B. -I. tcc.c -B. -I. tcctest.c > test.out3
4747 @if diff -u test.ref test.out3 ; then echo "Auto Test3 OK"; fi
4848
49+# binary output test
50+test4: tcc test.ref
51+# dynamic output
52+ $(TCC) -o tcctest1 tcctest.c
53+ ./tcctest1 > test1.out
54+ @if diff -u test.ref test1.out ; then echo "Dynamic Auto Test OK"; fi
55+# static output
56+ $(TCC) -static -o tcctest2 tcctest.c
57+ ./tcctest2 > test2.out
58+ @if diff -u test.ref test2.out ; then echo "Static Auto Test OK"; fi
59+# object + link output
60+ $(TCC) -c -o tcctest3.o tcctest.c
61+ $(TCC) -o tcctest3 tcctest3.o
62+ ./tcctest3 > test3.out
63+ @if diff -u test.ref test3.out ; then echo "Object Auto Test OK"; fi
64+# dynamic output + bound check
65+ $(TCC) -b -o tcctest4 tcctest.c
66+ ./tcctest4 > test4.out
67+ @if diff -u test.ref test4.out ; then echo "BCheck Auto Test OK"; fi
68+
4969 # memory and bound check auto test
5070 BOUNDS_OK = 1 4 8 10
5171 BOUNDS_FAIL= 2 5 7 9 11 12 13
@@ -82,7 +102,7 @@ ex3: ex3.c · 30 unmodified lines
82102
83103 # Native Tiny C Compiler
84104
85−tcc_g: tcc.c i386-gen.c bcheck.c tcctok.h libtcc.h Makefile
105+tcc_g: tcc.c i386-gen.c tccelf.c tcctok.h libtcc.h Makefile
86106 gcc $(CFLAGS) -o $@ $< $(LIBS)
87107
88108 tcc: tcc_g
@@ -97,7 +117,7 @@ bcheck.o: bcheck.c · 8 unmodified lines
97117
98118 install: tcc libtcc1.o bcheck.o
99119 $(INSTALL) -m755 tcc $(prefix)/bin
100− $(INSTALL) tcc.1 $(prefix)/man/man1
120+ $(INSTALL) tcc.1 $(prefix)/share/man/man1
101121 mkdir -p $(prefix)/lib/tcc
102122 mkdir -p $(prefix)/lib/tcc/include
103123 $(INSTALL) -m644 libtcc1.o bcheck.o $(prefix)/lib/tcc
@@ -107,7 +127,8 @@ install: tcc libtcc1.o bcheck.o · 3 unmodified lines
107127 clean:
108128 rm -f *~ *.o tcc tcc1 tcct tcc_g tcctest.ref *.bin *.i ex2 \
109129 core gmon.out test.out test.ref a.out tcc_p \
110− *.exe iltcc iltcc_g
130+ *.exe iltcc iltcc_g tcc-doc.html \
131+ tcctest[1234] test[1234].out
111132
112133 # IL TCC
113134
@@ -168,7 +189,7 @@ tar: · 54 unmodified lines
168189 $(FILE)/README $(FILE)/TODO $(FILE)/COPYING \
169190 $(FILE)/Changelog $(FILE)/tcc-doc.texi $(FILE)/tcc-doc.html \
170191 $(FILE)/tcc.1 \
171− $(FILE)/tcc.c $(FILE)/i386-gen.c $(FILE)/tcctok.h \
192+ $(FILE)/tcc.c $(FILE)/i386-gen.c $(FILE)/tccelf.c $(FILE)/tcctok.h \
172193 $(FILE)/bcheck.c $(FILE)/libtcc1.c \
173194 $(FILE)/il-opcodes.h $(FILE)/il-gen.c \
174195 $(FILE)/elf.h $(FILE)/stab.h $(FILE)/stab.def \

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t