linux/arch/frv/Makefile
<<
>>
Prefs
   1#
   2# frv/Makefile
   3#
   4# This file is included by the global makefile so that you can add your own
   5# architecture-specific flags and dependencies. Remember to do have actions
   6# for "archclean" and "archdep" for cleaning up and making dependencies for
   7# this architecture
   8#
   9# This file is subject to the terms and conditions of the GNU General Public
  10# License.  See the file "COPYING" in the main directory of this archive
  11# for more details.
  12#
  13# Copyright (c) 2003, 2004 Red Hat Inc.
  14# - Written by David Howells <dhowells@redhat.com>
  15# - Derived from arch/m68knommu/Makefile,
  16#       Copyright (c) 1999,2001  D. Jeff Dionne <jeff@lineo.ca>,
  17#       Rt-Control Inc. / Lineo, Inc.
  18#
  19# Copyright (C) 1998,1999  D. Jeff Dionne <jeff@uclinux.org>,
  20#                          Kenneth Albanowski <kjahds@kjahds.com>,
  21#
  22# Based on arch/m68k/Makefile:
  23# Copyright (C) 1994 by Hamish Macdonald
  24#
  25
  26ifdef CONFIG_MMU
  27UTS_SYSNAME = -DUTS_SYSNAME=\"Linux\"
  28else
  29UTS_SYSNAME = -DUTS_SYSNAME=\"uClinux\"
  30endif
  31
  32KBUILD_AFLAGS_MODULE += -G0 -mlong-calls
  33KBUILD_CFLAGS_MODULE += -G0 -mlong-calls
  34
  35ifdef CONFIG_GPREL_DATA_8
  36KBUILD_CFLAGS   += -G8
  37else
  38ifdef CONFIG_GPREL_DATA_4
  39KBUILD_CFLAGS   += -G4
  40else
  41ifdef CONFIG_GPREL_DATA_NONE
  42KBUILD_CFLAGS   += -G0
  43endif
  44endif
  45endif
  46
  47#LDFLAGS_vmlinux        := -Map linkmap.txt
  48
  49ifdef CONFIG_GC_SECTIONS
  50KBUILD_CFLAGS   += -ffunction-sections -fdata-sections
  51endif
  52
  53ifndef CONFIG_FRAME_POINTER
  54KBUILD_CFLAGS   += -mno-linked-fp
  55endif
  56
  57ifdef CONFIG_CPU_FR451_COMPILE
  58KBUILD_CFLAGS   += -mcpu=fr450
  59KBUILD_AFLAGS   += -mcpu=fr450
  60else
  61ifdef CONFIG_CPU_FR551_COMPILE
  62KBUILD_CFLAGS   += -mcpu=fr550
  63KBUILD_AFLAGS   += -mcpu=fr550
  64else
  65KBUILD_CFLAGS   += -mcpu=fr400
  66KBUILD_AFLAGS   += -mcpu=fr400
  67endif
  68endif
  69
  70# pretend the kernel is going to run on an FR400 with no media-fp unit
  71# - reserve CC3 for use with atomic ops
  72# - all the extra registers are dealt with only at context switch time
  73KBUILD_CFLAGS   += -mno-fdpic -mgpr-32 -msoft-float -mno-media
  74KBUILD_CFLAGS   += -ffixed-fcc3 -ffixed-cc3 -ffixed-gr15 -ffixed-icc2
  75KBUILD_AFLAGS   += -mno-fdpic
  76
  77# make sure the .S files get compiled with debug info
  78# and disable optimisations that are unhelpful whilst debugging
  79ifdef CONFIG_DEBUG_INFO
  80#KBUILD_CFLAGS  += -O1
  81KBUILD_AFLAGS   += -Wa,--gdwarf2
  82endif
  83
  84head-y          := arch/frv/kernel/head.o
  85
  86core-y          += arch/frv/kernel/ arch/frv/mm/
  87libs-y          += arch/frv/lib/
  88
  89core-$(CONFIG_MB93090_MB00)     += arch/frv/mb93090-mb00/
  90
  91all: Image
  92
  93Image: vmlinux
  94        $(Q)$(MAKE) $(build)=arch/frv/boot $@
  95
  96archclean:
  97        $(Q)$(MAKE) $(clean)=arch/frv/boot
  98
lxr.linux.no kindly hosted by Redpill Linpro AS, provider of Linux consulting and operations services since 1995.