Makefile 1.1 KB

1234567891011121314151617181920212223242526272829303132333435363738394041
  1. #
  2. # Copyright (C) 2006-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:=squashfs
  9. PKG_CPE_ID:=cpe:/a:phillip_lougher:squashfs
  10. PKG_VERSION:=3.0
  11. PKG_SOURCE:=$(PKG_NAME)$(PKG_VERSION).tar.gz
  12. PKG_SOURCE_URL:=@SF/squashfs
  13. PKG_HASH:=39dbda43cf118536deb746c7730b468702d514a19f4cfab73b710e32908ddf20
  14. PKG_CAT:=zcat
  15. HOST_BUILD_DIR:=$(BUILD_DIR_HOST)/$(PKG_NAME)$(PKG_VERSION)
  16. include $(INCLUDE_DIR)/host-build.mk
  17. define Host/Compile
  18. $(MAKE) -C $(HOST_BUILD_DIR)/squashfs-tools \
  19. CC="$(HOSTCC)" \
  20. CFLAGS="$(HOST_CFLAGS) -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -I." \
  21. CXX="$(CXX)" \
  22. LZMAPATH=$(STAGING_DIR_HOST)/lib \
  23. mksquashfs-lzma unsquashfs-lzma
  24. endef
  25. define Host/Install
  26. $(INSTALL_BIN) $(HOST_BUILD_DIR)/squashfs-tools/mksquashfs-lzma $(STAGING_DIR_HOST)/bin/
  27. $(INSTALL_BIN) $(HOST_BUILD_DIR)/squashfs-tools/unsquashfs-lzma $(STAGING_DIR_HOST)/bin/
  28. endef
  29. define Host/Clean
  30. rm -f $(STAGING_DIR_HOST)/bin/mksquashfs-lzma
  31. rm -f $(STAGING_DIR_HOST)/bin/unsquashfs-lzma
  32. endef
  33. $(eval $(call HostBuild))