move x86 CAR related stuff to arch/i386/Config.lb

git-svn-id: svn://svn.coreboot.org/coreboot/trunk@1987 2b7e53f0-3cfb-0310-b3e9-8179ed1497e1
This commit is contained in:
Li-Ta Lo 2005-07-26 18:27:13 +00:00
parent 1748bf28a7
commit 09952c1970
2 changed files with 16 additions and 18 deletions

View File

@ -1,4 +1,5 @@
uses CONFIG_SMP uses CONFIG_SMP
uses CONFIG_USE_INIT
init init/crt0.S.lb init init/crt0.S.lb
ldscript init/ldscript.lb ldscript init/ldscript.lb
@ -29,6 +30,21 @@ end
addaction clean "rm -f romimage payload.*" addaction clean "rm -f romimage payload.*"
if CONFIG_USE_INIT
makerule init.o
depends "$(INIT-OBJECTS)"
action "$(LD) -melf_i386 -r -o init.pre.o $(INIT-OBJECTS)"
action "$(OBJCOPY) --rename-section .text=.init.text --rename-section .data=.init.data --rename-section .rodata=.init.rodata --rename-section .rodata.str1.1=.init.rodata.str1.1 init.pre.o init.o"
end
makerule linuxbios
depends "crt0.o init.o linuxbios_ram.rom ldscript.ld"
action "$(CC) -nostdlib -nostartfiles -static -o $@ -T ldscript.ld crt0.o init.o"
action "$(CROSS_COMPILE)nm -n linuxbios | sort > linuxbios.map"
end
end
dir lib dir lib
dir boot dir boot
if CONFIG_SMP if CONFIG_SMP

View File

@ -1,7 +1,6 @@
## This is Architecture independant part of the makefile ## This is Architecture independant part of the makefile
uses HAVE_OPTION_TABLE uses HAVE_OPTION_TABLE
uses CONFIG_USE_INIT
makedefine CPP:= $(CC) -x assembler-with-cpp -DASSEMBLY -E makedefine CPP:= $(CC) -x assembler-with-cpp -DASSEMBLY -E
makedefine LIBGCC_FILE_NAME := $(shell $(CC) -print-libgcc-file-name) makedefine LIBGCC_FILE_NAME := $(shell $(CC) -print-libgcc-file-name)
@ -64,29 +63,12 @@ makerule linuxbios_ram.rom
action "cp $(LINUXBIOS_RAM-1) linuxbios_ram.rom" action "cp $(LINUXBIOS_RAM-1) linuxbios_ram.rom"
end end
if CONFIG_USE_INIT
makerule init.o
depends "$(INIT-OBJECTS)"
action "$(LD) -melf_i386 -r -o init.pre.o $(INIT-OBJECTS)"
action "$(OBJCOPY) --rename-section .text=.init.text --rename-section .data=.init.data --rename-section .rodata=.init.rodata --rename-section .rodata.str1.1=.init.rodata.str1.1 init.pre.o init.o"
end
makerule linuxbios
depends "crt0.o init.o linuxbios_ram.rom ldscript.ld"
action "$(CC) -nostdlib -nostartfiles -static -o $@ -T ldscript.ld crt0.o init.o"
action "$(CROSS_COMPILE)nm -n linuxbios | sort > linuxbios.map"
end
else
makerule linuxbios makerule linuxbios
depends "crt0.o $(INIT-OBJECTS) linuxbios_ram.rom ldscript.ld" depends "crt0.o $(INIT-OBJECTS) linuxbios_ram.rom ldscript.ld"
action "$(CC) -nostdlib -nostartfiles -static -o $@ -T ldscript.ld crt0.o $(INIT-OBJECTS)" action "$(CC) -nostdlib -nostartfiles -static -o $@ -T ldscript.ld crt0.o $(INIT-OBJECTS)"
action "$(CROSS_COMPILE)nm -n linuxbios | sort > linuxbios.map" action "$(CROSS_COMPILE)nm -n linuxbios | sort > linuxbios.map"
end end
end
makerule linuxbios.a makerule linuxbios.a
depends "$(OBJECTS)" depends "$(OBJECTS)"
action "rm -f linuxbios.a" action "rm -f linuxbios.a"