Makefile 673 B

123456789101112131415161718192021222324252627
  1. PATH_PREFIX:=..
  2. VARIANT:=headers
  3. include ../common.mk
  4. define Host/Compile
  5. endef
  6. define Host/Install
  7. $(call Host/SetToolchainInfo)
  8. mkdir -p $(BUILD_DIR_TOOLCHAIN)/$(LIBC)-dev/{include,lib}
  9. $(MAKE) -C $(CUR_BUILD_DIR) \
  10. BUILD_CFLAGS="$(HOST_CFLAGS)" \
  11. install_root="$(BUILD_DIR_TOOLCHAIN)/$(LIBC)-dev" \
  12. install-bootstrap-headers=yes \
  13. install-headers
  14. $(MAKE) -C $(CUR_BUILD_DIR) \
  15. csu/subdir_lib
  16. ( cd $(CUR_BUILD_DIR); \
  17. $(CP) csu/crt1.o csu/crti.o csu/crtn.o $(BUILD_DIR_TOOLCHAIN)/$(LIBC)-dev/lib/ \
  18. )
  19. $(TARGET_CC) -nostdlib -nostartfiles -shared -x c /dev/null \
  20. -o $(BUILD_DIR_TOOLCHAIN)/$(LIBC)-dev/lib/libc.so
  21. endef
  22. $(eval $(call HostBuild))