Changeset 6e259d5 in mainline for Makefile


Ignore:
Timestamp:
2005-11-08T13:01:58Z (19 years ago)
Author:
Martin Decky <martin@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
ba22dcb
Parents:
789b5cc
Message:

link kernel in ARCH's native format first, then use objcopy to create output format

File:
1 edited

Legend:

Unmodified
Added
Removed
  • Makefile

    r789b5cc r6e259d5  
    142142
    143143clean:
    144         -rm -f kernel.bin kernel.map kernel.map.pre kernel.objdump generic/src/debug/real_map.bin Makefile.depend generic/include/arch generic/include/genarch arch/$(ARCH)/_link.ld
     144        -rm -f kernel.bin kernel.raw kernel.map kernel.map.pre kernel.objdump generic/src/debug/real_map.bin Makefile.depend generic/include/arch generic/include/genarch arch/$(ARCH)/_link.ld
    145145        find generic/src/ arch/$(ARCH)/src/ genarch/src/ -name '*.o' -exec rm \{\} \;
    146146        $(MAKE) -C arch/$(ARCH)/boot clean
     
    154154
    155155arch/$(ARCH)/_link.ld: arch/$(ARCH)/_link.ld.in
    156         $(CC) $(DEFS) -DBFD=\"$(BFD)\" $(CFLAGS) -E -x c $< | grep -v "^\#" > $@
     156        $(CC) $(DEFS) $(CFLAGS) -E -x c $< | grep -v "^\#" > $@
    157157
    158158generic/src/debug/real_map.bin: depend arch/$(ARCH)/_link.ld $(ARCH_OBJECTS) $(GENARCH_OBJECTS) $(GENERIC_OBJECTS)
     
    165165        $(OBJCOPY) -I binary -O $(BFD_NAME) -B $(BFD_ARCH) --prefix-sections=symtab $< $@
    166166
    167 kernel.bin: depend arch/$(ARCH)/_link.ld $(ARCH_OBJECTS) $(GENARCH_OBJECTS) $(GENERIC_OBJECTS) generic/src/debug/real_map.o
     167kernel.raw: depend arch/$(ARCH)/_link.ld $(ARCH_OBJECTS) $(GENARCH_OBJECTS) $(GENERIC_OBJECTS) generic/src/debug/real_map.o
    168168        $(LD) -T arch/$(ARCH)/_link.ld $(LFLAGS) $(ARCH_OBJECTS) $(GENARCH_OBJECTS) $(GENERIC_OBJECTS) generic/src/debug/real_map.o -o $@ -Map kernel.map
     169
     170kernel.bin: kernel.raw
     171        $(OBJCOPY) -O $(BFD) kernel.raw kernel.bin
    169172
    170173boot: kernel.bin
Note: See TracChangeset for help on using the changeset viewer.