2
0

Makefile 1.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263
  1. #
  2. # Copyright (C) 2016 Daniel Golle <daniel@makrotopia.org>
  3. #
  4. # This is free software, licensed under the GNU General Public License v2.
  5. # See /LICENSE for more information.
  6. #
  7. include $(TOPDIR)/rules.mk
  8. PKG_NAME:=yasm
  9. PKG_VERSION:=1.3.0
  10. PKG_SOURCE_URL:=http://www.tortall.net/projects/yasm/releases/
  11. PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
  12. PKG_HASH:=3dce6601b495f5b3d45b59f7d2492a340ee7e84b5beca17e48f862502bd5603f
  13. HOST_BUILD_PARALLEL:=1
  14. include $(INCLUDE_DIR)/toolchain-build.mk
  15. YASM_CONFIGURE:= \
  16. ./configure \
  17. --prefix=$(TOOLCHAIN_DIR) \
  18. --build=$(GNU_HOST_NAME) \
  19. --host=$(GNU_HOST_NAME) \
  20. --target=$(REAL_GNU_TARGET_NAME) \
  21. --with-sysroot=$(TOOLCHAIN_DIR) \
  22. --disable-multilib \
  23. --disable-werror \
  24. --disable-nls \
  25. --disable-sim \
  26. --disable-gdb \
  27. $(SOFT_FLOAT_CONFIG_OPTION) \
  28. define Host/Prepare
  29. $(call Host/Prepare/Default)
  30. ln -snf $(notdir $(HOST_BUILD_DIR)) $(BUILD_DIR_TOOLCHAIN)/$(PKG_NAME)
  31. $(CP) $(SCRIPT_DIR)/config.{guess,sub} $(HOST_BUILD_DIR)/
  32. endef
  33. define Host/Configure
  34. (cd $(HOST_BUILD_DIR); \
  35. $(YASM_CONFIGURE) \
  36. );
  37. endef
  38. define Host/Compile
  39. +$(MAKE) $(HOST_JOBS) -C $(HOST_BUILD_DIR) all
  40. endef
  41. define Host/Install
  42. $(MAKE) -C $(HOST_BUILD_DIR) \
  43. prefix=$(TOOLCHAIN_DIR) \
  44. install
  45. endef
  46. define Host/Clean
  47. rm -rf \
  48. $(HOST_BUILD_DIR) \
  49. $(BUILD_DIR_TOOLCHAIN)/$(PKG_NAME)
  50. endef
  51. $(eval $(call HostBuild))