2013-06-21 00:17:14 +02:00
|
|
|
################################################################################
|
|
|
|
#
|
|
|
|
# squashfs
|
|
|
|
#
|
|
|
|
################################################################################
|
|
|
|
|
2013-07-20 08:52:43 +02:00
|
|
|
SQUASHFS_VERSION = 4.2
|
|
|
|
SQUASHFS_SOURCE = squashfs$(SQUASHFS_VERSION).tar.gz
|
|
|
|
SQUASHFS_SITE = http://downloads.sourceforge.net/projct/squashfs/squashfs/squashfs$(SQUASHFS_VERSION)
|
2010-03-02 00:14:33 +01:00
|
|
|
|
2011-03-04 15:10:14 +01:00
|
|
|
# no libattr in BR
|
2010-09-20 22:05:39 +02:00
|
|
|
SQUASHFS_MAKE_ARGS = XATTR_SUPPORT=0
|
2010-09-20 16:19:26 +02:00
|
|
|
|
2010-09-20 22:05:39 +02:00
|
|
|
ifeq ($(BR2_PACKAGE_SQUASHFS_LZMA),y)
|
|
|
|
SQUASHFS_DEPENDENCIES += xz
|
2011-03-04 15:10:14 +01:00
|
|
|
SQUASHFS_MAKE_ARGS += LZMA_XZ_SUPPORT=1 COMP_DEFAULT=lzma
|
|
|
|
else
|
|
|
|
SQUASHFS_MAKE_ARGS += LZMA_XZ_SUPPORT=0
|
|
|
|
endif
|
|
|
|
|
|
|
|
ifeq ($(BR2_PACKAGE_SQUASHFS_XZ),y)
|
|
|
|
SQUASHFS_DEPENDENCIES += xz
|
2011-03-03 11:49:57 +01:00
|
|
|
SQUASHFS_MAKE_ARGS += XZ_SUPPORT=1 COMP_DEFAULT=xz
|
2010-09-20 16:19:26 +02:00
|
|
|
else
|
2010-09-20 22:05:39 +02:00
|
|
|
SQUASHFS_MAKE_ARGS += XZ_SUPPORT=0
|
2010-09-20 16:19:26 +02:00
|
|
|
endif
|
|
|
|
|
|
|
|
ifeq ($(BR2_PACKAGE_SQUASHFS_LZO),y)
|
|
|
|
SQUASHFS_DEPENDENCIES += lzo
|
2010-09-20 22:05:39 +02:00
|
|
|
SQUASHFS_MAKE_ARGS += LZO_SUPPORT=1 COMP_DEFAULT=lzo
|
2010-09-20 16:19:26 +02:00
|
|
|
else
|
|
|
|
SQUASHFS_MAKE_ARGS += LZO_SUPPORT=0
|
|
|
|
endif
|
|
|
|
|
2010-09-20 22:05:39 +02:00
|
|
|
ifeq ($(BR2_PACKAGE_SQUASHFS_GZIP),y)
|
|
|
|
SQUASHFS_DEPENDENCIES += zlib
|
|
|
|
SQUASHFS_MAKE_ARGS += GZIP_SUPPORT=1 COMP_DEFAULT=gzip
|
|
|
|
else
|
|
|
|
SQUASHFS_MAKE_ARGS += GZIP_SUPPORT=0
|
|
|
|
endif
|
|
|
|
|
2010-09-20 16:19:26 +02:00
|
|
|
|
2010-09-20 22:05:39 +02:00
|
|
|
HOST_SQUASHFS_DEPENDENCIES = host-zlib host-lzo host-xz
|
2010-09-20 16:19:26 +02:00
|
|
|
|
|
|
|
# no libattr/xz in BR
|
|
|
|
HOST_SQUASHFS_MAKE_ARGS = \
|
|
|
|
XATTR_SUPPORT=0 \
|
2010-09-20 22:05:39 +02:00
|
|
|
XZ_SUPPORT=1 \
|
2010-09-20 16:19:26 +02:00
|
|
|
GZIP_SUPPORT=1 \
|
2011-03-04 15:10:14 +01:00
|
|
|
LZO_SUPPORT=1 \
|
|
|
|
LZMA_XZ_SUPPORT=1
|
2010-03-02 00:14:33 +01:00
|
|
|
|
|
|
|
define SQUASHFS_BUILD_CMDS
|
|
|
|
$(TARGET_MAKE_ENV) $(MAKE) \
|
|
|
|
CC="$(TARGET_CC)" \
|
2010-09-20 16:19:26 +02:00
|
|
|
EXTRA_CFLAGS="$(TARGET_CFLAGS)" \
|
|
|
|
EXTRA_LDFLAGS="$(TARGET_LDFLAGS)" \
|
|
|
|
$(SQUASHFS_MAKE_ARGS) \
|
2010-03-02 00:14:33 +01:00
|
|
|
-C $(@D)/squashfs-tools/
|
|
|
|
endef
|
|
|
|
|
|
|
|
define SQUASHFS_INSTALL_TARGET_CMDS
|
2010-09-20 16:19:26 +02:00
|
|
|
$(TARGET_MAKE_ENV) $(MAKE) $(SQUASHFS_MAKE_ARGS) \
|
|
|
|
-C $(@D)/squashfs-tools/ INSTALL_DIR=$(TARGET_DIR)/usr/bin install
|
2010-03-02 00:14:33 +01:00
|
|
|
endef
|
|
|
|
|
|
|
|
define HOST_SQUASHFS_BUILD_CMDS
|
2010-09-20 16:19:26 +02:00
|
|
|
$(HOST_MAKE_ENV) $(MAKE) \
|
|
|
|
CC="$(HOSTCC)" \
|
|
|
|
EXTRA_CFLAGS="$(HOST_CFLAGS)" \
|
|
|
|
EXTRA_LDFLAGS="$(HOST_LDFLAGS)" \
|
|
|
|
$(HOST_SQUASHFS_MAKE_ARGS) \
|
|
|
|
-C $(@D)/squashfs-tools/
|
2010-03-02 00:14:33 +01:00
|
|
|
endef
|
|
|
|
|
|
|
|
define HOST_SQUASHFS_INSTALL_CMDS
|
2010-09-20 16:19:26 +02:00
|
|
|
$(HOST_MAKE_ENV) $(MAKE) $(HOST_SQUASHFS_MAKE_ARGS) \
|
|
|
|
-C $(@D)/squashfs-tools/ INSTALL_DIR=$(HOST_DIR)/usr/bin install
|
2010-03-02 00:14:33 +01:00
|
|
|
endef
|
|
|
|
|
2012-07-03 00:07:32 +02:00
|
|
|
$(eval $(generic-package))
|
2012-07-03 00:06:54 +02:00
|
|
|
$(eval $(host-generic-package))
|