瀏覽代碼

tile: add uclibc-ng support

Waldemar Brodkorb 6 年之前
父節點
當前提交
cecc2b2e51
共有 2 個文件被更改,包括 37 次插入0 次删除
  1. 1 0
      target/config/Config.in.libc
  2. 36 0
      target/tile/Makefile

+ 1 - 0
target/config/Config.in.libc

@@ -35,6 +35,7 @@ config ADK_TARGET_LIB_UCLIBC_NG
 		ADK_TARGET_ARCH_SH || \
 		ADK_TARGET_ARCH_SPARC || \
 		ADK_TARGET_ARCH_SPARC64 || \
+		ADK_TARGET_ARCH_TILE || \
 		ADK_TARGET_ARCH_X86 || \
 		ADK_TARGET_ARCH_X86_64 || \
 		ADK_TARGET_ARCH_XTENSA) && ADK_TARGET_OS_LINUX || ADK_TARGET_OS_WALDUX

+ 36 - 0
target/tile/Makefile

@@ -5,3 +5,39 @@ include $(ADK_TOPDIR)/rules.mk
 include $(ADK_TOPDIR)/mk/kernel-build.mk
 include $(ADK_TOPDIR)/mk/image.mk
 
+KERNEL:=$(LINUX_DIR)/vmlinux
+OSTRIP:=-R .reginfo -R .notes -R .note -R .comment -R .mdebug -R .note.gnu.build-id
+
+# target helper text
+ifeq ($(ADK_TARGET_FS),initramfs)
+targethelp:
+	@echo 'The kernel file is: $(FW_DIR)/${TARGET_KERNEL}'
+	@echo 'The initramfs image is: ${FW_DIR}/${INITRAMFS}'
+endif
+ifeq ($(ADK_TARGET_FS),initramfsarchive)
+targethelp:
+	@echo 'The kernel file is: $(FW_DIR)/${TARGET_KERNEL}'
+	@echo "The RootFS tarball is: $(FW_DIR)/$(ROOTFSUSERTARBALL)"
+endif
+ifeq ($(ADK_TARGET_FS),initramfspiggyback)
+targethelp:
+	@echo 'The kernel+initramfs file is: $(FW_DIR)/${TARGET_KERNEL}'
+endif
+
+kernel-strip:
+	$(TARGET_CROSS)objcopy $(OSTRIP) -S $(KERNEL) $(BUILD_DIR)/$(TARGET_KERNEL)
+
+kernel-install: kernel-strip
+	@cp $(BUILD_DIR)/$(TARGET_KERNEL) $(FW_DIR)/$(TARGET_KERNEL)
+
+# filesystem specific targets
+ifeq ($(ADK_TARGET_FS),initramfs)
+imageinstall: kernel-install $(FW_DIR)/$(INITRAMFS) targethelp
+endif
+ifeq ($(ADK_TARGET_FS),initramfsarchive)
+imageinstall: kernel-install $(FW_DIR)/$(ROOTFSUSERTARBALL) targethelp
+endif
+ifeq ($(ADK_TARGET_FS),initramfspiggyback)
+imageinstall: createinitramfs targethelp
+endif
+