Makefile 1.6 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849
  1. # This file is part of the OpenADK project. OpenADK is copyrighted
  2. # material, please see the LICENCE file in the top-level directory.
  3. include $(TOPDIR)/rules.mk
  4. include ../rules.mk
  5. include $(TOPDIR)/mk/linux.mk
  6. include ${TOPDIR}/mk/buildhlp.mk
  7. $(WRKBUILD)/.headers:
  8. $(MAKE) -C $(WRKBUILD) HOSTCC=$(CC_FOR_BUILD) ARCH=$(ARCH) V=1 \
  9. INSTALL_HDR_PATH=$(STAGING_DIR)/usr \
  10. headers_install
  11. ifeq ($(ADK_TARGET_WITH_MULTILIB),y)
  12. ifeq ($(ADK_LINUX_MIPS),y)
  13. $(MAKE) -C $(WRKBUILD) HOSTCC=$(CC_FOR_BUILD) ARCH=mips V=1 \
  14. INSTALL_HDR_PATH=$(STAGING_TARGET_DIR)-n32/usr \
  15. headers_install
  16. $(MAKE) -C $(WRKBUILD) HOSTCC=$(CC_FOR_BUILD) ARCH=mips V=1 \
  17. INSTALL_HDR_PATH=$(STAGING_TARGET_DIR)-64/usr \
  18. headers_install
  19. $(MAKE) -C $(WRKBUILD) HOSTCC=$(CC_FOR_BUILD) ARCH=mips V=1 \
  20. INSTALL_HDR_PATH=$(STAGING_TARGET_DIR)-o32/usr \
  21. headers_install
  22. endif
  23. ifeq ($(ADK_LINUX_X86_64),y)
  24. $(MAKE) -C $(WRKBUILD) HOSTCC=$(CC_FOR_BUILD) ARCH=x86 V=1 \
  25. INSTALL_HDR_PATH=$(STAGING_TARGET_DIR)-32/usr \
  26. headers_install
  27. $(MAKE) -C $(WRKBUILD) HOSTCC=$(CC_FOR_BUILD) ARCH=x86 V=1 \
  28. INSTALL_HDR_PATH=$(STAGING_TARGET_DIR)-x32/usr \
  29. headers_install
  30. $(MAKE) -C $(WRKBUILD) HOSTCC=$(CC_FOR_BUILD) ARCH=x86 V=1 \
  31. INSTALL_HDR_PATH=$(STAGING_TARGET_DIR)-64/usr \
  32. headers_install
  33. endif
  34. endif
  35. $(MAKE) -C $(WRKBUILD) HOSTCC=$(CC_FOR_BUILD) ARCH=$(ARCH) V=1 \
  36. INSTALL_HDR_PATH=$(LINUX_HEADER_DIR) \
  37. headers_install
  38. ifeq ($(ARCH),cris)
  39. ifeq ($(CPU_ARCH),crisv32)
  40. cd $(STAGING_DIR)/usr/include && ln -sf arch-v32/arch arch
  41. else
  42. cd $(STAGING_DIR)/usr/include && ln -sf arch-v10/arch arch
  43. endif
  44. endif
  45. touch $@
  46. include ${TOPDIR}/mk/toolchain.mk