- Builds all four possible ARM targets when cross compiling - Adds some auto detection to select the target for native ARM builds The auto detection will select EABI if it finds /lib/ld-linux.so.3. It will select VFP floating point support when /proc/cpuinfo lists a VFP or iWMMXt coprocessor. Intel Wireless MMX does not imply VFP, but it conflicts with FPA, so VFP is the only choice (apart from yet unsupported soft-float). Daniel
Unified · Split
| @@ -30,14 +30,14 @@ INSTALL=install · 29 unmodified lines | ||
| 30 | 30 | ifdef CONFIG_WIN32 |
| 31 | 31 | PROGS=tcc$(EXESUF) |
| 32 | 32 | ifdef CONFIG_CROSS |
| 33 | −PROGS+=c67-tcc$(EXESUF) arm-tcc$(EXESUF) | |
| 33 | +PROGS+=c67-tcc$(EXESUF) arm-tcc-fpa$(EXESUF) arm-tcc-fpa-ld$(EXESUF) arm-tcc-vfp$(EXESUF) arm-tcc-vfp-eabi$(EXESUF) | |
| 34 | 34 | endif |
| 35 | 35 | PROGS+=tiny_impdef$(EXESUF) tiny_libmaker$(EXESUF) |
| 36 | 36 | else |
| 37 | 37 | ifeq ($(ARCH),i386) |
| 38 | 38 | PROGS=tcc$(EXESUF) |
| 39 | 39 | ifdef CONFIG_CROSS |
| 40 | −PROGS+=arm-tcc$(EXESUF) | |
| 40 | +PROGS+=arm-tcc-fpa$(EXESUF) arm-tcc-fpa-ld$(EXESUF) arm-tcc-vfp$(EXESUF) arm-tcc-vfp-eabi$(EXESUF) | |
| 41 | 41 | endif |
| 42 | 42 | endif |
| 43 | 43 | ifeq ($(ARCH),arm) |
| @@ -151,8 +151,11 @@ tcc$(EXESUF): tcc.c i386-gen.c tccelf.c tccasm.c i386-asm.c tcctok.h libtcc.h i3 · 107 unmodified lines | ||
| 151 | 151 | $(CC) $(CFLAGS) -o $@ $< $(LIBS) |
| 152 | 152 | endif |
| 153 | 153 | ifeq ($(ARCH),arm) |
| 154 | +ARMFLAGS = $(if $(wildcard /lib/ld-linux.so.3),-DTCC_ARM_EABI) | |
| 155 | +ARMFLAGS += $(if $(shell grep -l "^Features.* \(vfp\|iwmmxt\) " /proc/cpuinfo),-DTCC_ARM_VFP) | |
| 156 | + | |
| 154 | 157 | tcc$(EXESUF): tcc.c arm-gen.c tccelf.c tccasm.c tcctok.h libtcc.h |
| 155 | − $(CC) $(CFLAGS) -DTCC_TARGET_ARM -o $@ $< $(LIBS) | |
| 158 | + $(CC) $(CFLAGS) -DTCC_TARGET_ARM $(ARMFLAGS) -o $@ $< $(LIBS) | |
| 156 | 159 | endif |
| 157 | 160 | endif |
| 158 | 161 | |
| @@ -163,7 +166,16 @@ i386-tcc$(EXESUF): tcc.c i386-gen.c tccelf.c tccasm.c i386-asm.c tcctok.h libtcc · 4 unmodified lines | ||
| 163 | 166 | c67-tcc$(EXESUF): tcc.c c67-gen.c tccelf.c tccasm.c tcctok.h libtcc.h tcccoff.c |
| 164 | 167 | $(CC) $(CFLAGS) -DTCC_TARGET_C67 -o $@ $< $(LIBS) |
| 165 | 168 | |
| 166 | −arm-tcc$(EXESUF): tcc.c arm-gen.c tccelf.c tccasm.c tcctok.h libtcc.h | |
| 169 | +arm-tcc-fpa$(EXESUF): tcc.c arm-gen.c tccelf.c tccasm.c tcctok.h libtcc.h | |
| 170 | + $(CC) $(CFLAGS) -DTCC_TARGET_ARM -o $@ $< $(LIBS) | |
| 171 | + | |
| 172 | +arm-tcc-fpa-ld$(EXESUF): tcc.c arm-gen.c tccelf.c tccasm.c tcctok.h libtcc.h | |
| 173 | + $(CC) $(CFLAGS) -DTCC_TARGET_ARM -DLDOUBLE_SIZE=12 -o $@ $< $(LIBS) | |
| 174 | + | |
| 175 | +arm-tcc-vfp$(EXESUF): tcc.c arm-gen.c tccelf.c tccasm.c tcctok.h libtcc.h | |
| 176 | + $(CC) $(CFLAGS) -DTCC_TARGET_ARM -DTCC_ARM_VFP -o $@ $< $(LIBS) | |
| 177 | + | |
| 178 | +arm-tcc-vfp-eabi$(EXESUF): tcc.c arm-gen.c tccelf.c tccasm.c tcctok.h libtcc.h | |
| 167 | 179 | $(CC) $(CFLAGS) -DTCC_TARGET_ARM -DTCC_ARM_EABI -o $@ $< $(LIBS) |
| 168 | 180 | |
| 169 | 181 | i386-win32-tcc$(EXESUF): tcc.c i386-gen.c tccelf.c tccasm.c i386-asm.c tcctok.h libtcc.h i386-asm.h tccpe.c |