1 # $Id: Makefile,v 1.6 2000/06/10 03:03:52 gniibe Exp $
3 # This file is subject to the terms and conditions of the GNU General Public
4 # License. See the file "COPYING" in the main directory of this archive
7 # Copyright (C) 1999 Kaz Kojima
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
16 # Select the object file format to substitute into the linker script.
18 tool_prefix
= sh-linux-gnu-
20 ifdef CONFIG_CPU_LITTLE_ENDIAN
32 # ifdef CONFIG_CROSSCOMPILE
33 CROSS_COMPILE
= $(tool_prefix
)
36 LD
=$(CROSS_COMPILE
)ld $(LDFLAGS
)
37 OBJCOPY
=$(CROSS_COMPILE
)objcopy
-O binary
-R .note
-R .comment
-R .stab
-R .stabstr
-S
54 # Choosing incompatible machines durings configuration will result in
55 # error messages during linking. Select a default linkscript if
56 # none has been choosen above.
58 LINKSCRIPT
= arch
/sh
/vmlinux.lds
59 LINKFLAGS
+= -T
$(word 1,$(LINKSCRIPT
)) -e _stext
62 LINKFLAGS
+= -Ttext
$(word 1,$(LOADADDR
))
68 HEAD
:= arch
/sh
/kernel
/head.o arch
/sh
/kernel
/init_task.o
70 SUBDIRS
:= $(SUBDIRS
) $(addprefix arch
/sh
/, kernel mm lib
)
71 CORE_FILES
:= arch
/sh
/kernel
/kernel.o arch
/sh
/mm
/mm.o
$(CORE_FILES
)
72 LIBGCC
:= $(shell $(CC
) $(CFLAGS
) -print-libgcc-file-name
)
73 LIBS
:= $(TOPDIR
)/arch
/sh
/lib
/lib.a
$(LIBS
) $(TOPDIR
)/arch
/sh
/lib
/lib.a \
76 MAKEBOOT
= $(MAKE
) -C arch
/$(ARCH
)/boot
78 vmlinux
: arch
/sh
/vmlinux.lds
80 arch
/sh
/vmlinux.lds
: arch
/sh
/vmlinux.lds.S FORCE
81 $(CPP
) -traditional
-C
-P
-I
$(HPATH
) -Ush arch
/sh
/vmlinux.lds.S
>arch
/sh
/vmlinux.lds
95 $(MAKE
) -C arch
/$(ARCH
)/kernel
clean
96 # $(MAKE) -C arch/$(ARCH)/tools clean
99 rm -f arch
/sh
/vmlinux.lds