]> err.no Git - linux-2.6/blobdiff - arch/sh/Makefile
sh: Remove duplicate SUPERH64 symbol.
[linux-2.6] / arch / sh / Makefile
index 897f1c590facfd2095a570c2eb452a0d73107732..e08d4d27d8d6c9e8803f0028d04e2dc5c5169ec8 100644 (file)
@@ -74,15 +74,21 @@ OBJCOPYFLAGS        := -O binary -R .note -R .note.gnu.build-id -R .comment -R .stab -R
 # never be used by anyone. Use a board-specific defconfig that has a
 # reasonable chance of being current instead.
 #
-KBUILD_DEFCONFIG := r7780rp_defconfig
+KBUILD_DEFCONFIG       := r7780rp_defconfig
 
-KBUILD_IMAGE   := arch/sh/boot/zImage
+KBUILD_IMAGE           := arch/sh/boot/zImage
 
 #
 # Choosing incompatible machines durings configuration will result in
 # error messages during linking.
 #
-LDFLAGS_vmlinux     += -e _stext
+ifdef CONFIG_SUPERH32
+LDFLAGS_vmlinux        += -e _stext
+else
+LDFLAGS_vmlinux        += --defsym phys_stext=_stext-$(CONFIG_PAGE_OFFSET) \
+                  --defsym phys_stext_shmedia=phys_stext+1 \
+                  -e phys_stext_shmedia
+endif
 
 ifdef CONFIG_CPU_LITTLE_ENDIAN
 LDFLAGS_vmlinux                += --defsym 'jiffies=jiffies_64'
@@ -95,7 +101,9 @@ endif
 KBUILD_CFLAGS          += -pipe $(cflags-y)
 KBUILD_AFLAGS          += $(cflags-y)
 
-head-y := arch/sh/kernel/head.o arch/sh/kernel/init_task.o
+head-y                 := arch/sh/kernel/init_task.o
+head-$(CONFIG_SUPERH32)        += arch/sh/kernel/head_32.o
+head-$(CONFIG_SUPERH64)        += arch/sh/kernel/head_64.o
 
 LIBGCC := $(shell $(CC) $(KBUILD_CFLAGS) -print-libgcc-file-name)