linux-old/arch/sh64/Makefile
<<
>>
Prefs
   1#
   2# This file is subject to the terms and conditions of the GNU General Public
   3# License.  See the file "COPYING" in the main directory of this archive
   4# for more details.
   5#
   6# Copyright (C) 2000, 2001  Paolo Alberelli
   7# Copyright (C) 2003  Paul Mundt
   8#
   9# This file is included by the global makefile so that you can add your own
  10# architecture-specific flags and dependencies. Remember to do have actions
  11# for "archclean" and "archdep" for cleaning up and making dependencies for
  12# this architecture
  13#
  14# Note that top level Makefile automagically builds dependencies for SUBDIRS
  15# but does not automagically clean SUBDIRS. Therefore "archclean" should clean
  16# up all, "archdep" does nothing on added SUBDIRS.
  17#
  18
  19cpu-y                           := -mb
  20cpu-$(CONFIG_LITTLE_ENDIAN)     := -ml
  21
  22cpu-$(CONFIG_CPU_SH5)           += -m5-32media-nofpu
  23
  24ifdef CONFIG_LITTLE_ENDIAN
  25LDFLAGS         += -EL  -mshlelf32_linux
  26else
  27LDFLAGS         += -EB  -mshelf32_linux
  28endif
  29
  30# No requirements for endianess support from AFLAGS, 'as' always run through gcc
  31AFLAGS          += -m5 -isa=sh64 -traditional
  32CFLAGS          += $(cpu-y)
  33
  34ENTRY_POINT     = --defsym phys_stext=_stext-0x$(CONFIG_CACHED_MEMORY_OFFSET) \
  35                  -e phys_stext
  36OBJCOPY         = $(CROSS_COMPILE)objcopy -O binary -R .note -R .comment \
  37                  -R .stab -R .stabstr -S
  38LD              = $(CROSS_COMPILE)ld $(LDFLAGS)
  39
  40LINKFLAGS     += -T arch/$(ARCH)/vmlinux.lds  $(ENTRY_POINT)
  41
  42ifdef LOADADDR
  43LINKFLAGS     += -Ttext $(word 1,$(LOADADDR))
  44endif
  45
  46machine-$(CONFIG_SH_CAYMAN)     := cayman
  47machine-$(CONFIG_SH_SIMULATOR)  := sim
  48machine-$(CONFIG_SH_HARP)       := harp
  49
  50HEAD := arch/$(ARCH)/kernel/head.o arch/$(ARCH)/kernel/init_task.o
  51MAKEROOTFS =
  52
  53SUBDIRS += $(addprefix arch/$(ARCH)/, kernel mm lib mach-$(machine-y))
  54CORE_FILES := arch/$(ARCH)/kernel/kernel.o arch/$(ARCH)/mm/mm.o \
  55              arch/$(ARCH)/mach-$(machine-y)/$(machine-y).o \
  56              $(CORE_FILES) 
  57
  58LIBGCC := $(shell $(CC) $(CFLAGS) -print-libgcc-file-name)
  59LIBS := $(TOPDIR)/arch/$(ARCH)/lib/lib.a $(LIBS) $(LIBGCC)
  60
  61MAKEBOOT = $(MAKE) -C arch/$(ARCH)/boot
  62
  63#
  64# override the assembly rules
  65#
  66#.S.o:
  67#       $(CC) $(CFLAGS) $(AFLAGS) -c $< -o $*.o
  68
  69vmlinux: arch/$(ARCH)/vmlinux.lds
  70
  71arch/$(ARCH)/vmlinux.lds: arch/$(ARCH)/vmlinux.lds.S FORCE
  72        $(CPP) $(TOOLCHAIN) $(AFLAGS) -C -P -I$(HPATH) -U$(ARCH) arch/$(ARCH)/vmlinux.lds.S >arch/$(ARCH)/vmlinux.lds
  73
  74FORCE: ;
  75
  76zImage: vmlinux
  77        @$(MAKEBOOT) zImage
  78
  79compressed: zImage
  80
  81zdisk: vmlinux
  82        @$(MAKEBOOT) zdisk
  83
  84archclean:
  85#       @$(MAKEBOOT) clean
  86
  87archmrproper:
  88        rm -f arch/$(ARCH)/vmlinux.lds
  89
  90archdep:
  91#       @$(MAKEBOOT) dep
  92
lxr.linux.no kindly hosted by Redpill Linpro AS, provider of Linux consulting and operations services since 1995.