[PATCH] biarch compiler support for i386

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



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.

	-hpa

Signed-Off-By: H. Peter Anvin <[email protected]>
Index: linux-2.5/arch/i386/Makefile
===================================================================
RCS file: /home/hpa/kernel/bkcvs/linux-2.5/arch/i386/Makefile,v
retrieving revision 1.75
diff -u -r1.75 Makefile
--- linux-2.5/arch/i386/Makefile	12 Mar 2005 22:03:27 -0000	1.75
+++ linux-2.5/arch/i386/Makefile	5 Apr 2005 05:29:20 -0000
@@ -17,6 +17,13 @@
 #           Kianusch Sayah Karadji <[email protected]>
 #           Added support for GEODE CPU
 
+HAS_BIARCH      := $(call cc-option-yn, -m32)
+ifeq ($(HAS_BIARCH),y)
+AS              := $(AS) --32
+LD              := $(LD) -m elf_i386
+CC              := $(CC) -m32
+endif
+
 LDFLAGS		:= -m elf_i386
 OBJCOPYFLAGS	:= -O binary -R .note -R .comment -S
 LDFLAGS_vmlinux :=

[Index of Archives]     [Kernel Newbies]     [Netfilter]     [Bugtraq]     [Photo]     [Stuff]     [Gimp]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Video 4 Linux]     [Linux for the blind]     [Linux Resources]
  Powered by Linux