From 5280293d6b16bbe24dfda76e37f32322fa2874ca Mon Sep 17 00:00:00 2001 From: grischka Date: Thu, 14 Jul 2011 18:45:37 +0200 Subject: 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. --- arm-gen.c | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) (limited to 'arm-gen.c') diff --git a/arm-gen.c b/arm-gen.c index 9feae1b..5cb5c2e 100644 --- a/arm-gen.c +++ b/arm-gen.c @@ -102,10 +102,8 @@ enum { //#define FUNC_STRUCT_PARAM_AS_PTR #if defined(TCC_ARM_EABI) && defined(TCC_ARM_VFP) -#ifdef NEED_FLOAT_TYPES -static CType float_type, double_type, func_float_type, func_double_type; +ST_DATA CType float_type, double_type, func_float_type, func_double_type; #define func_ldouble_type func_double_type -#endif #else #define func_float_type func_old_type #define func_double_type func_old_type @@ -172,6 +170,11 @@ ST_DATA const int reg_classes[NB_REGS] = { #endif }; +/* keep in sync with line 104 above */ +#if defined(TCC_ARM_EABI) && defined(TCC_ARM_VFP) +ST_DATA CType float_type, double_type, func_float_type, func_double_type; +#endif + static int func_sub_sp_offset, last_itod_magic; static int leaffunc; -- cgit v1.3.1