Commit ff1a7e88 authored by David Mosberger's avatar David Mosberger

ia64: Manual Makefile cleanup merge.

parent f1731ed8
......@@ -5,23 +5,21 @@
# License. See the file "COPYING" in the main directory of this archive
# for more details.
#
# Copyright (C) 1998-2001 by David Mosberger-Tang <davidm@hpl.hp.com>
# Copyright (C) 1998-2002 by David Mosberger-Tang <davidm@hpl.hp.com>
#
NM := $(CROSS_COMPILE)nm -B
AWK := awk
export AWK
OBJCOPYFLAGS := --strip-all
LDFLAGS_vmlinux := -static
AFLAGS_KERNEL := -mconstant-gp
EXTRA =
OBJCOPYFLAGS := --strip-all
LDFLAGS_vmlinux := -static
AFLAGS_KERNEL := -mconstant-gp
EXTRA :=
CFLAGS := $(CFLAGS) -pipe $(EXTRA) -ffixed-r13 -mfixed-range=f10-f15,f32-f127 \
-falign-functions=32
# -ffunction-sections
CFLAGS_KERNEL := -mconstant-gp
cflags-y := -pipe $(EXTRA) -ffixed-r13 -mfixed-range=f10-f15,f32-f127 \
-falign-functions=32
CFLAGS_KERNEL := -mconstant-gp
GCC_VERSION=$(shell $(CC) -v 2>&1 | fgrep 'gcc version' | cut -f3 -d' ' | cut -f1 -d'.')
......@@ -29,55 +27,46 @@ ifneq ($(GCC_VERSION),2)
CFLAGS += -frename-registers --param max-inline-insns=5000
endif
ifeq ($(CONFIG_ITANIUM_BSTEP_SPECIFIC),y)
CFLAGS += -mb-step
endif
cflags-$(CONFIG_ITANIUM_BSTEP_SPECIFIC) += -mb-step
cflags-$(CONFIG_IA64_SGI_SN) += -DBRINGUP
HEAD := arch/$(ARCH)/kernel/head.o arch/$(ARCH)/kernel/init_task.o
libs-y += arch/$(ARCH)/lib/
core-y += arch/$(ARCH)/kernel/ arch/$(ARCH)/mm/
core-$(CONFIG_IA32_SUPPORT) += arch/$(ARCH)/ia32/
core-$(CONFIG_IA64_DIG) += arch/$(ARCH)/dig/
core-$(CONFIG_IA64_GENERIC) += arch/$(ARCH)/dig/ arch/$(ARCH)/hp/common/ arch/$(ARCH)/hp/zx1/ \
arch/$(ARCH)/hp/sim/
core-$(CONFIG_IA64_HP_ZX1) += arch/$(ARCH)/dig/
core-$(CONFIG_IA64_SGI_SN) += arch/$(ARCH)/sn/kernel/ \
arch/$(ARCH)/sn/io/ \
arch/$(ARCH)/sn/io/sn2/ \
arch/$(ARCH)/sn/io/sn2/pcibr/ \
arch/$(ARCH)/sn/kernel/sn2/
drivers-$(CONFIG_PCI) += arch/$(ARCH)/pci/
drivers-$(CONFIG_IA64_HP_SIM) += arch/$(ARCH)/hp/sim/
drivers-$(CONFIG_IA64_HP_ZX1) += arch/$(ARCH)/hp/common/ arch/$(ARCH)/hp/zx1/
ifdef CONFIG_IA64_SGI_SN
CFLAGS += -DBRINGUP
SUBDIRS += arch/$(ARCH)/sn/fakeprom
endif
HEAD := arch/ia64/kernel/head.o arch/ia64/kernel/init_task.o
makeboot = $(call descend,arch/ia64/boot,$(1))
maketool = $(call descend,arch/ia64/tools,$(1))
libs-y += arch/ia64/lib/
core-y += arch/ia64/kernel/ arch/ia64/mm/
core-$(CONFIG_IA32_SUPPORT) += arch/ia64/ia32/
core-$(CONFIG_IA64_DIG) += arch/ia64/dig/
core-$(CONFIG_IA64_GENERIC) += arch/ia64/dig/ arch/ia64/hp/common/ arch/ia64/hp/zx1/ \
arch/ia64/hp/sim/
core-$(CONFIG_IA64_HP_ZX1) += arch/ia64/dig/
core-$(CONFIG_IA64_SGI_SN) += arch/ia64/sn/kernel/ \
arch/ia64/sn/io/ \
arch/ia64/sn/io/sn2/ \
arch/ia64/sn/io/sn2/pcibr/ \
arch/ia64/sn/kernel/sn2/
drivers-$(CONFIG_PCI) += arch/ia64/pci/
drivers-$(CONFIG_IA64_HP_SIM) += arch/ia64/hp/sim/
drivers-$(CONFIG_IA64_HP_ZX1) += arch/ia64/hp/common/ arch/ia64/hp/zx1/
drivers-$(CONFIG_IA64_SGI_SN) += arch/ia64/sn/fakeprom/
.PHONY: compressed archclean archmrproper $(TOPDIR)/include/asm-ia64/offsets.h
makeboot =$(Q)$(MAKE) -f scripts/Makefile.build obj=arch/ia64/boot $(1)
maketool =$(Q)$(MAKE) -f scripts/Makefile.build obj=arch/ia64/tools $(1)
all: compressed boot
.PHONY: compressed archclean archmrproper include/asm-ia64/offsets.h
boot: vmlinux
+@$(call makeboot,all)
all compressed: vmlinux.gz
compressed: vmlinux
$(OBJCOPY) $(OBJCOPYFLAGS) vmlinux vmlinux-tmp
gzip vmlinux-tmp
mv vmlinux-tmp.gz vmlinux.gz
vmlinux.gz: vmlinux
$(call makeboot,vmlinux.gz)
archmrproper:
archclean:
$(MAKE) -rR -f scripts/Makefile.clean obj=arch/$(ARCH)/boot
$(Q)$(MAKE) -f scripts/Makefile.clean obj=arch/ia64/boot
archmrproper:
CLEAN_FILES += include/asm-ia64/offsets.h vmlinux.gz bootloader
prepare: $(TOPDIR)/include/asm-ia64/offsets.h
prepare: include/asm-ia64/offsets.h
$(TOPDIR)/include/asm-ia64/offsets.h: include/asm include/linux/version.h \
include/config/MARKER
+@$(call maketool,$@)
include/asm-ia64/offsets.h: include/asm include/linux/version.h \
include/config/MARKER
$(call maketool,$@)
......@@ -14,8 +14,8 @@ targets-$(CONFIG_IA64_HP_SIM) += bootloader
targets-$(CONFIG_IA64_GENERIC) += bootloader
EXTRA_TARGETS += $(sort $(targets-y))
quiet_cmd_cptotop = CP $@
cmd_cptotop = cp $< $@
quiet_cmd_cptotop = LN $@
cmd_cptotop = ln $< $@
vmlinux.gz: $(obj)/vmlinux.gz $(targets-y)
$(call cmd,cptotop)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment