2011-10-04 18:54:51 +04:00
#
# linux/arch/c6x/Makefile
#
# This file is subject to the terms and conditions of the GNU General Public
# License. See the file "COPYING" in the main directory of this archive
# for more details.
#
2012-10-04 01:39:12 +04:00
KBUILD_DEFCONFIG := dsk6455_defconfig
2015-03-03 01:33:42 +03:00
cflags-y += -mno-dsbt -msdata= none -D__linux__
2011-10-04 18:54:51 +04:00
cflags-$(CONFIG_C6X_BIG_KERNEL) += -mlong-calls
CFLAGS_MODULE += -mlong-calls -mno-dsbt -msdata= none
CHECKFLAGS +=
KBUILD_CFLAGS += $( cflags-y)
KBUILD_AFLAGS += $( cflags-y)
i f d e f C O N F I G _ C P U _ B I G _ E N D I A N
KBUILD_CFLAGS += -mbig-endian
KBUILD_AFLAGS += -mbig-endian
LINKFLAGS += -mbig-endian
KBUILD_LDFLAGS += -mbig-endian
LDFLAGS += -EB
e n d i f
head-y := arch/c6x/kernel/head.o
core-y += arch/c6x/kernel/ arch/c6x/mm/ arch/c6x/platforms/
libs-y += arch/c6x/lib/
# Default to vmlinux.bin, override when needed
all : vmlinux .bin
boot := arch/$( ARCH) /boot
# Are we making a dtbImage.<boardname> target? If so, crack out the boardname
DTB := $( subst dtbImage.,,$( filter dtbImage.%, $( MAKECMDGOALS) ) )
export DTB
i f n e q ( $( DTB ) , )
2012-11-28 03:29:14 +04:00
core-y += $( boot) /dts/
2011-10-04 18:54:51 +04:00
e n d i f
# With make 3.82 we cannot mix normal and wildcard targets
vmlinux.bin : vmlinux
$( Q) $( MAKE) $( build) = $( boot) $( patsubst %,$( boot) /%,$@ )
dtbImage.% : vmlinux
$( Q) $( MAKE) $( build) = $( boot) $( patsubst %,$( boot) /%,$@ )
archclean :
$( Q) $( MAKE) $( clean) = $( boot)
d e f i n e a r c h h e l p
@echo ' vmlinux.bin - Binary kernel image (arch/$(ARCH)/boot/vmlinux.bin)'
@echo ' dtbImage.<dt> - ELF image with $(arch)/boot/dts/<dt>.dts linked in'
@echo ' - stripped elf with fdt blob'
e n d e f