Makefile 1.4 KB
Newer Older
L
Linus Torvalds 已提交
1 2 3 4 5 6 7 8 9
# sparc64/Makefile
#
# Makefile for the architecture dependent flags and dependencies on the
# 64-bit Sparc.
#
# Copyright (C) 1996,1998 David S. Miller (davem@caip.rutgers.edu)
# Copyright (C) 1998 Jakub Jelinek (jj@ultra.linux.cz)
#

10
CHECKFLAGS	+= -D__sparc__ -D__sparc_v9__ -D__arch64__ -m64
L
Linus Torvalds 已提交
11

12 13 14
# Undefine sparc when processing vmlinux.lds - it is used
# And teach CPP we are doing 64 bit builds (for this case)
CPPFLAGS_vmlinux.lds += -m64 -Usparc
15 16
LDFLAGS              := -m elf64_sparc
export BITS          := 64
L
Linus Torvalds 已提交
17

18 19 20
KBUILD_CFLAGS += -m64 -pipe -mno-fpu -mcpu=ultrasparc -mcmodel=medlow \
	-ffixed-g4 -ffixed-g5 -fcall-used-g7 -Wno-sign-compare \
	-Wa,--undeclared-regs
21
KBUILD_CFLAGS += $(call cc-option,-mtune=ultrasparc3)
22
KBUILD_AFLAGS += -m64 -mcpu=ultrasparc -Wa,--undeclared-regs
L
Linus Torvalds 已提交
23 24

ifeq ($(CONFIG_MCOUNT),y)
25
  KBUILD_CFLAGS += -pg
L
Linus Torvalds 已提交
26 27 28 29
endif

head-y := arch/sparc64/kernel/head.o arch/sparc64/kernel/init_task.o

S
Sam Ravnborg 已提交
30
core-y				+= arch/sparc64/kernel/ arch/sparc/mm/
S
Sam Ravnborg 已提交
31
core-y				+= arch/sparc/math-emu/
L
Linus Torvalds 已提交
32
libs-y				+= arch/sparc64/prom/ arch/sparc64/lib/
33
drivers-$(CONFIG_OPROFILE)	+= arch/sparc/oprofile/
L
Linus Torvalds 已提交
34 35 36 37 38 39 40 41 42 43 44 45 46 47 48

boot := arch/sparc64/boot

image tftpboot.img vmlinux.aout: vmlinux
	$(Q)$(MAKE) $(build)=$(boot) $(boot)/$@

archclean:
	$(Q)$(MAKE) $(clean)=$(boot)

define archhelp
  echo  '* vmlinux       - Standard sparc64 kernel'
  echo  '  vmlinux.aout  - a.out kernel for sparc64'
  echo  '  tftpboot.img  - Image prepared for tftp'
endef