Makefile 1.1 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243
  1. #
  2. # Copyright (C) 2009-2012 OpenWrt.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:=squashfs4
  9. PKG_VERSION:=4.2
  10. PKG_SOURCE:=squashfs$(PKG_VERSION).tar.gz
  11. PKG_SOURCE_URL:=@SF/squashfs
  12. PKG_MD5SUM:=1b7a781fb4cf8938842279bd3e8ee852
  13. PKG_CAT:=zcat
  14. HOST_BUILD_DIR:=$(BUILD_DIR_HOST)/squashfs$(PKG_VERSION)
  15. include $(INCLUDE_DIR)/host-build.mk
  16. define Host/Compile
  17. $(MAKE) -C $(HOST_BUILD_DIR)/squashfs-tools \
  18. CC="$(HOSTCC)" \
  19. XZ_SUPPORT=1 \
  20. LZMA_XZ_SUPPORT=1 \
  21. XATTR_SUPPORT= \
  22. LZMA_LIB="$(STAGING_DIR_HOST)/lib/liblzma.a" \
  23. EXTRA_CFLAGS="-I$(STAGING_DIR_HOST)/include" \
  24. EXTRA_LDFLAGS="$(HOST_STATIC_LINKING)" \
  25. mksquashfs unsquashfs
  26. endef
  27. define Host/Install
  28. $(INSTALL_BIN) $(HOST_BUILD_DIR)/squashfs-tools/mksquashfs $(STAGING_DIR_HOST)/bin/mksquashfs4
  29. $(INSTALL_BIN) $(HOST_BUILD_DIR)/squashfs-tools/unsquashfs $(STAGING_DIR_HOST)/bin/unsquashfs4
  30. endef
  31. define Host/Clean
  32. rm -f $(STAGING_DIR_HOST)/bin/mksquashfs4
  33. rm -f $(STAGING_DIR_HOST)/bin/unsquashfs4
  34. endef
  35. $(eval $(call HostBuild))