Commit Graph

120 Commits

Author SHA1 Message Date
df9cce24a8 Accept colon separated paths with -L and -I
This allows passing colon separated paths to
  tcc_add_library_path
  tcc_add_sysinclude_path
  tcc_add_include_path

Also there are new configure variables
  CONFIG_TCC_LIBPATH
  CONFIG_TCC_SYSINCLUDE_PATHS
which define the lib/sysinclude paths all in one and can
be overridden from configure/make

For TCC_TARGET_PE semicolons (;) are used as separators

Also, \b in the path string is replaced by s->tcc_lib_path
(CONFIG_TCCDIR rsp. -B option)
2011-08-01 01:10:36 +02:00
5280293d6b make: create native tcc from separate objects
This was already possible using
    make NOTALLINONE=1
and is now the default.

To build as previously from one big source, use
    make ONE_SOURCE=1

Cross compilers are still build from one source because using
separate objects requires separate build directories one per
platform which currently is not (yet) supported by the makefile.

We could probably use gnu-makeish target variables like
    $(I386_CROSS): OUTDIR=build/i386
    $(X64_CROSS): OUTDIR=build/x86-64
and so on ...

Also NEED_FLOAT_TYPES for arm-gen is removed.  It was about
variables that are referenced from outside (libtcc, tccgen).
We could declare them in tcc.h (as with reg_classes) or have
them twice in arm-gen.c.  I chose option 2.
2011-07-14 18:45:37 +02:00
571465d32b Revert "Make examples' shebang use target tcc bindir path"
This reverts commit cb2138f8b0.
2011-07-07 12:14:08 +02:00
cb2138f8b0 Make examples' shebang use target tcc bindir path
Use @BINDIR@ in shebang of examples to put the right path on the target
system. That is, use #!/usr/local/bin/tcc if tcc is installed in /usr/local/bin
and #!/usr/bin/tcc if tcc is installed in /usr/bin/tcc.
2011-06-18 00:45:20 +02:00
3511e6e2a8 Default to create progs with symbols (incl. debug)
* Set CFLAGS entirely in configure if not already set.
* Compile bcheck.c with the same flags as the other source files
* Don't strip binaries by default (GB are cheap now) but provide a
  --strip-binaries option in configure script.
2011-06-17 22:22:04 +02:00
eb152022a0 make test work when LIBTCC1 not defined
Make libtest depends on LIBTCC1 instead of ../libtcc1.a and define
LIBTCC1 to $(TOP)/$(LIBTCC1) if LIBTCC1 is defined
2011-05-17 23:30:32 +02:00
921f002a6d make clean work when LIBTCC1 not defined
Don't call make -C lib clean if LIBTCC1 is not defined, else make clean
fails (for example of arm).
2011-05-14 16:21:45 +02:00
288831854b Makefile: respect LDFLAGS (set via --extra-ldflags=)
Signed-off-by: Sergei Trofimovich <st@anti-virus.by>
2011-01-04 10:22:02 +02:00
44f7055a04 make: fix cannot find -ltcc with --disable-rpath 2010-12-21 09:47:17 -08:00
73cb4392ab make: fix install with CC=tcc and potential link problem 2010-12-20 06:20:08 -08:00
90355c78ed configure: add --disable-rpath option (Fedora) 2010-12-20 05:55:54 -08:00
33f86ada92 trim unnecessary bits from my previous 3 commits 2010-12-05 12:47:50 -08:00
1c821373ad make: i386/libtcc1.a for i386-tcc (x86_64 to i386 cross) 2010-12-05 01:04:28 -08:00
50ff5ed790 make: cross compilers exist before using them (fixes parallel make) 2010-12-04 20:15:37 -08:00
86ffc48129 make: new lib/Makefile for libtcc1.a on more platforms
win32/64 cross-compilers now build libtcc1.a and install it
together with the windows headers in a 'win32' sub-directory
of TCCDIR.
2010-12-04 16:47:08 +01:00
2ce9a0e2fe needs lib path on bcheck.o fixes undefined symbol '__try__' 2010-12-02 21:43:46 -08:00
2215567d7a Makefile: fix clean target, bcheck, add comments 2010-12-02 14:39:34 -08:00
a2779556b4 split cross libtcc1.a to separate directories 2010-12-02 03:08:57 -08:00
165d136614 Makefile: cleanup leftovers on cross build. really works now 2010-11-30 16:17:37 -08:00
93ef24e6fe Makefile: fix typo and resulting workaround 2010-11-30 16:08:33 -08:00
b7d89ff822 Makefile: fix Linux cross install, cleanup 2010-11-30 15:35:32 -08:00
c1a437add7 tccpe.c: Makefile: --enable-cross win64 cross library build 2010-11-30 15:15:55 -08:00
0d38e3b663 make CC=tcc install: fixes strip:tcc: File format not recognized 2010-11-30 13:34:09 -08:00
8185070841 Makefile: Add .PHONY targets 2010-11-30 13:09:16 -08:00
52b75c5fa0 Makefile: Put i386-win32-tcc back into --enable-cross install 2010-11-30 02:42:38 -08:00
7b18df138d Makefile: build --config-cross libtcc1.a directly to win32/lib 2010-11-30 01:49:34 -08:00
48a2a8dabd Remove unnecessary $(PROGS_CROSS) from non-cross builds. 2010-11-29 21:09:20 -08:00
ddea94daea Makefile: TCC=tcc 2010-11-28 16:11:40 -08:00
3d35b6b36d Makefile: --enable-cross on x86_64 simplified 2010-11-28 15:51:03 -08:00
f0afec709e Makefile: x86_64 win32-cross add clean: target 2010-11-06 02:39:28 -07:00
e250ffb319 Makefile: edit comments 2010-10-29 00:40:16 -07:00
24d6a93f44 Makefile: cross-copiler tcc1.def is now libtcc1.a, ignore mv errors 2010-10-29 00:40:06 -07:00
c635976cd7 Force gcc for x86_64 --enable-cross 2010-10-28 22:08:44 -07:00
3f829d11ff Add info file creation into tcc build process
Add info file creation in tcc Makefile
2010-09-10 21:19:01 +02:00
2220467fcf Don't load libtcc1 on arch where it doesn't exist
ARM architecture doesn't have any libtcc1 implementation but tcc load
libtcc1.a in all case. This patch add a conditional preprocessor
instruction to load libtcc1.a only when there is an implementation for
the target architecture.
2010-05-01 17:20:28 +02:00
036ff17916 reverse another unnecessary change
-m32 is set elsewhere now.
2010-04-29 23:52:20 -07:00
1f62f2253c recursive Makefiles should use $(MAKE), not "make"
add clean: target for lib/tcc1.def
2010-04-29 23:06:23 -07:00
c7a4e11bf1 remove superfluous LIBS=. (leftover from work on --disable-statc) 2010-04-28 16:15:19 -07:00
209caeedee Summary of commits + added some brief comments to Makefile
Summary of what was changed or added so far:
    These won't work on Win32

* --disable-static option builds libtcca.so.1.0 and associated simlinks.
  This replaces libtcca.a, which is a static library with a dynamic one.

* --with-selinux option uses mmap to enable tcc -run to work with Selinux.

* attempt to build tcc1.def on i386 / x86_64 when --enable-cross is used.

  If successful, this gets around the "_start not found" or "_winstart not
  found" messages when i386-win32-tcc is run on these systems. I say "if"
  because it gave me fits of trouble on my system and not all others have
  been tested yet. tcc1.def is not a real .def file by the way, but it works,
  so it's kind of a dancing bear at this point. We're not concerned that
  it's getting the steps wrong. We're just happy it's not eating us for lunch.
2010-04-26 23:20:35 -07:00
ac0b7d82d8 don't build tcc1.def on Windows.
I think the Windows build portion of the Makefile already
provides their own version. If not, we can remove the check.
2010-04-26 01:27:15 -07:00
765992396f Makefile fixup:
* additional make target for lib/tcc1.def on non-win32 builds
  tcc1.def was formerly lib/libtcc1.a but has bee made into its
  own Makefile target, tcc1.def

* use mv instead of cp on config.h
  this fixes a mistake I made which caused Makefile to rebuild
  all targets every time

* make links from libtcc.so.1.0 to libtcc.so.1 and libtcc.so
2010-04-25 13:34:02 -07:00
07eb850608 make --enable-cross work properly on x86_64
merge more changes from Fedora spec file into Makefile
I did a lot of reading on Makefiles. It should be a lot less hacked now that I got rid of my temporary cross-build script. I had to build i386-win32-tcc as 32 bit in order to use it to build the windows version of libtcc1.a and move that into lib directory. Still testing, but it does build windows fib.exe smoothly now and generates shard lib, libtcc.so.1.0 and test links against it.
2010-04-25 00:35:25 -07:00
239fdf0b87 remove make_libtcc1_win32.sh shell script
and merge commands into Makefile
2010-04-24 22:16:39 -07:00
80b4c698c2 make win32 version of libtcc1.a for cross-compiler on x86 / x86_64 2010-04-24 13:27:56 -07:00
a4ed587f61 add --disable-static option to build libtcc.so instead of libtcc.a
for distros that want static libs
2010-04-24 02:35:43 -07:00
4686236091 i386-win32-tcc fails to build a valid win32 executable if built
on x86_64 using --enable-cross. The easiest way to fix this is
to put -m32 in the Makefile.

Committer: Henry Kroll <henry@comptune.com>

Committer: Henry Kroll <henry@comptune.com>
2010-04-23 18:36:12 -07:00
253bad7993 Added patch to detect and use the paths for 64bit libraries as
used by CentOS (affects X86_64 only).
2010-01-28 08:27:38 +01:00
5caf6235cf Makefile: Delete tcc-doc.html during 'make distclean' 2010-01-26 22:53:52 +01:00
903b6001e7 update Makefiles 2009-12-20 20:34:35 +01:00
88a3ccab9f allow tcc be build from separate objects
If you want that, run: make NOTALLINONE=1
2009-12-20 01:53:49 +01:00