Skip to content

Commit d0e7feb

Browse files
H. Peter AnvinLinus Torvalds
authored andcommitted
[PATCH] biarch compiler support for i386
This allows the i386 architecture to be built on a system with a biarch compiler that defaults to x86-64, merely by specifying ARCH=i386. As previously discussed, this uses the equivalent logic to the ppc port. Signed-Off-By: H. Peter Anvin <hpa@zytor.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
1 parent 6f4e1e5 commit d0e7feb

1 file changed

Lines changed: 7 additions & 0 deletions

File tree

‎arch/i386/Makefile‎

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,13 @@
1717
# 20050320 Kianusch Sayah Karadji <kianusch@sk-tech.net>
1818
# Added support for GEODE CPU
1919

20+
HAS_BIARCH := $(call cc-option-yn, -m32)
21+
ifeq ($(HAS_BIARCH),y)
22+
AS := $(AS) --32
23+
LD := $(LD) -m elf_i386
24+
CC := $(CC) -m32
25+
endif
26+
2027
LDFLAGS := -m elf_i386
2128
OBJCOPYFLAGS := -O binary -R .note -R .comment -S
2229
LDFLAGS_vmlinux :=

0 commit comments

Comments
 (0)