Check-in [a319c993d9]
Overview
Comment:Updated to build Tcc naively
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1: a319c993d903aaf56c78dfaeb18746553a61b206
User & Date: rkeene on 2014-05-01 23:32:44
Other Links: manifest | tags
Context
2014-05-01
23:35
Corrected call to tcc configure check-in: 013ffc32d5 user: rkeene tags: trunk
23:32
Updated to build Tcc naively check-in: a319c993d9 user: rkeene tags: trunk
23:13
Updated to download TCC check-in: 2631d4cf7d user: rkeene tags: trunk
Changes

Modified Makefile.in from [0567345519] to [87dfad392f].

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18











19
20
21
22
23
24
25

26
27

28
29
30
31
32
33
34
35
36
37

38
39
40
41
42
43

44
45
46
47
48
49
50
CC = @CC@
AR = @AR@
RANLIB = @RANLIB@
CFLAGS = @CFLAGS@ @SHOBJFLAGS@
CPPFLAGS = @CPPFLAGS@ -I@srcdir@ @DEFS@
LDFLAGS =
SHOBJLDFLAGS = @SHOBJLDFLAGS@
LIBS = @LIBS@
INSTALL = @INSTALL@
PACKAGE_NAME = @PACKAGE_NAME@
PACKAGE_VERSION = @PACKAGE_VERSION@
TCL_PACKAGE_PATH = @TCL_PACKAGE_PATH@
PACKAGE_INSTALL_DIR = $(TCL_PACKAGE_PATH)/$(PACKAGE_NAME)-$(PACKAGE_VERSION)
TARGETS = @TARGETS@
srcdir = @srcdir@

all: $(TARGETS)












tcltcc.o: $(srcdir)/tcltcc.c
	$(CC) $(CPPFLAGS) $(CFLAGS) -o tcltcc.o -c $(srcdir)/tcltcc.c

tcltcc-shared.@SHOBJEXT@: tcltcc.o
	$(CC) $(CPPFLAGS) $(CFLAGS) $(LDFLAGS) $(SHOBJLDFLAGS) -o tcltcc-shared.@SHOBJEXT@ tcltcc.o $(LIBS)

tcltcc-static.a: tcltcc.o

	$(AR) rcu tcltcc-static.a tcltcc.o
	-$(RANLIB) tcltcc-static.a


install: $(TARGETS) pkgIndex.tcl
	$(INSTALL) -d "$(DESTDIR)$(PACKAGE_INSTALL_DIR)"
	$(INSTALL) -m 0644 pkgIndex.tcl "$(DESTDIR)$(PACKAGE_INSTALL_DIR)"
	$(INSTALL) -m 0755 $(TARGETS) "$(DESTDIR)$(PACKAGE_INSTALL_DIR)"

clean:
	rm -f tcltcc.o
	rm -f tcltcc-shared.@SHOBJEXT@ tcltcc-static.a
	rm -f tcltcc-shared.@SHOBJEXT@.a tcltcc-shared.@SHOBJEXT@.def


distclean: clean
	rm -rf autom4te.cache
	rm -f config.log config.status
	rm -f pkgIndex.tcl
	rm -f Makefile


mrproper: distclean
	rm -rf __TMP__
	rm -rf tcc
	rm -f configure aclocal.m4
	rm -f config.guess config.sub install-sh





|













>
>
>
>
>
>
>
>
>
>
>
|


|


|
>
|
|
>










>






>







1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
CC = @CC@
AR = @AR@
RANLIB = @RANLIB@
CFLAGS = @CFLAGS@ @SHOBJFLAGS@
CPPFLAGS = @CPPFLAGS@ -I@srcdir@ -I@srcdir@/tcc -Itcc @DEFS@
LDFLAGS =
SHOBJLDFLAGS = @SHOBJLDFLAGS@
LIBS = @LIBS@
INSTALL = @INSTALL@
PACKAGE_NAME = @PACKAGE_NAME@
PACKAGE_VERSION = @PACKAGE_VERSION@
TCL_PACKAGE_PATH = @TCL_PACKAGE_PATH@
PACKAGE_INSTALL_DIR = $(TCL_PACKAGE_PATH)/$(PACKAGE_NAME)-$(PACKAGE_VERSION)
TARGETS = @TARGETS@
srcdir = @srcdir@

all: $(TARGETS)

tcc/config.h:
	if [ "$(srcdir)" = "." ]; then
		cd tcc && ./configure
	else
		mkdir tcc >/dev/null 2>/dev/null || true
		cd tcc && $(shell cd $(srcdir) && pwd)/tcc/configure
	fi

tcc/libtcc.a: tcc/config.h
	$(MAKE) -C tcc libtcc.a

tcltcc.o: $(srcdir)/tcltcc.c $(srcdir)/tcc/tcc.h $(srcdir)/tcc/libtcc.h tcc/config.h
	$(CC) $(CPPFLAGS) $(CFLAGS) -o tcltcc.o -c $(srcdir)/tcltcc.c

tcltcc-shared.@SHOBJEXT@: tcltcc.o tcc/libtcc.a
	$(CC) $(CPPFLAGS) $(CFLAGS) $(LDFLAGS) $(SHOBJLDFLAGS) -o tcltcc-shared.@SHOBJEXT@ tcltcc.o $(LIBS)

tcltcc-static.a: tcltcc.o tcc/libtcc.a
	cp tcc/libtcc.a tcltcc-static.new.a
	$(AR) rcu tcltcc-static.new.a tcltcc.o
	-$(RANLIB) tcltcc-static.new.a
	mv tcltcc-static.new.a tcltcc-static.a

install: $(TARGETS) pkgIndex.tcl
	$(INSTALL) -d "$(DESTDIR)$(PACKAGE_INSTALL_DIR)"
	$(INSTALL) -m 0644 pkgIndex.tcl "$(DESTDIR)$(PACKAGE_INSTALL_DIR)"
	$(INSTALL) -m 0755 $(TARGETS) "$(DESTDIR)$(PACKAGE_INSTALL_DIR)"

clean:
	rm -f tcltcc.o
	rm -f tcltcc-shared.@SHOBJEXT@ tcltcc-static.a
	rm -f tcltcc-shared.@SHOBJEXT@.a tcltcc-shared.@SHOBJEXT@.def
	-$(MAKE) -C tcc clean

distclean: clean
	rm -rf autom4te.cache
	rm -f config.log config.status
	rm -f pkgIndex.tcl
	rm -f Makefile
	-$(MAKE) -C tcc distclean

mrproper: distclean
	rm -rf __TMP__
	rm -rf tcc
	rm -f configure aclocal.m4
	rm -f config.guess config.sub install-sh

Modified tcltcc.c from [f5d4fd88e2] to [07a867c26b].

13
14
15
16
17
18
19



20
21
22
23
24
25
26
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
 * Lesser General Public License for more details.
 *
 * You should have received a copy of the GNU Lesser General Public
 * License along with this library; if not, write to the Free Software
 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
 */




static void TccErrorFunc(Tcl_Interp * interp, char * msg) {
    Tcl_AppendResult(interp, msg, "\n", NULL);
}


static void TccCCommandDeleteProc (ClientData cdata) {







>
>
>







13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
 * Lesser General Public License for more details.
 *
 * You should have received a copy of the GNU Lesser General Public
 * License along with this library; if not, write to the Free Software
 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
 */

#include <tcl.h>
#include "tcc.h"

static void TccErrorFunc(Tcl_Interp * interp, char * msg) {
    Tcl_AppendResult(interp, msg, "\n", NULL);
}


static void TccCCommandDeleteProc (ClientData cdata) {