From: Bernhard Reutner-Fischer Date: Tue, 31 Jul 2007 16:13:00 +0000 (-0000) Subject: - lzma needs a CXX cross-compiler X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=dd8226a46dcb79079f191e1a88658269e7f6ceb5;p=buildroot.git - lzma needs a CXX cross-compiler - minor cleanups while at it --- diff --git a/package/lzma/Config.in b/package/lzma/Config.in index 774d7711b6..a72616fa9b 100644 --- a/package/lzma/Config.in +++ b/package/lzma/Config.in @@ -1,6 +1,7 @@ config BR2_PACKAGE_LZMA_TARGET bool "Install lzma for the target system" default n + select BR2_GCC_CROSS_CXX help lzma utils on the target diff --git a/package/lzma/lzma.mk b/package/lzma/lzma.mk index 49a426ecdd..ed511c9e03 100644 --- a/package/lzma/lzma.mk +++ b/package/lzma/lzma.mk @@ -24,19 +24,19 @@ $(DL_DIR)/$(LZMA_SOURCE): # ###################################################################### -$(LZMA_HOST_DIR)/.source: $(DL_DIR)/$(LZMA_SOURCE) +$(LZMA_HOST_DIR)/.unpacked: $(DL_DIR)/$(LZMA_SOURCE) $(LZMA_CAT) $(DL_DIR)/$(LZMA_SOURCE) | tar -C $(TOOL_BUILD_DIR) $(TAR_OPTIONS) - toolchain/patch-kernel.sh $(LZMA_HOST_DIR) package/lzma/ lzma\*.patch - touch $(LZMA_HOST_DIR)/.source + touch $@ -$(LZMA_HOST_DIR)/.configured: $(LZMA_HOST_DIR)/.source +$(LZMA_HOST_DIR)/.configured: $(LZMA_HOST_DIR)/.unpacked (cd $(LZMA_HOST_DIR); rm -f config.cache ;\ CC="$(HOSTCC)" \ CXX="$(HOSTCXX)" \ ./configure \ --prefix=/ \ ); - touch $(LZMA_HOST_DIR)/.configured; + touch $@ $(LZMA_HOST_DIR)/src/lzma/lzma: $(LZMA_HOST_DIR)/.configured $(MAKE) -C $(LZMA_HOST_DIR) all @@ -45,20 +45,24 @@ $(LZMA_HOST_DIR)/src/lzma/lzma: $(LZMA_HOST_DIR)/.configured $(STAGING_DIR)/bin/lzma: $(LZMA_HOST_DIR)/src/lzma/lzma $(MAKE) DESTDIR=$(STAGING_DIR) -C $(LZMA_HOST_DIR) install -lzma-host: uclibc $(STAGING_DIR)/bin/lzma - +lzma-host: $(STAGING_DIR)/bin/lzma +lzma-host-clean: + rm -f $(STAGING_DIR)/bin/lzma + -$(MAKE) -C $(LZMA_HOST_DIR) clean +lzma-host-dirclean: + rm -rf $(LZMA_HOST_DIR) ###################################################################### # # lzma target # ###################################################################### -$(LZMA_TARGET_DIR)/.source: $(DL_DIR)/$(LZMA_SOURCE) +$(LZMA_TARGET_DIR)/.unpacked: $(DL_DIR)/$(LZMA_SOURCE) $(LZMA_CAT) $(DL_DIR)/$(LZMA_SOURCE) | tar -C $(BUILD_DIR) $(TAR_OPTIONS) - toolchain/patch-kernel.sh $(LZMA_TARGET_DIR) package/lzma/ lzma\*.patch - touch $(LZMA_TARGET_DIR)/.source + touch $@ -$(LZMA_TARGET_DIR)/.configured: $(LZMA_TARGET_DIR)/.source +$(LZMA_TARGET_DIR)/.configured: $(LZMA_TARGET_DIR)/.unpacked (cd $(LZMA_TARGET_DIR); rm -f config.cache ;\ $(TARGET_CONFIGURE_OPTS) \ $(TARGET_CONFIGURE_ARGS) \ @@ -76,7 +80,7 @@ $(LZMA_TARGET_DIR)/.configured: $(LZMA_TARGET_DIR)/.source $(DISABLE_NLS) \ $(DISABLE_LARGEFILE) \ ); - touch $(LZMA_TARGET_DIR)/.configured; + touch $@ $(LZMA_TARGET_DIR)/src/lzma/lzma: $(LZMA_TARGET_DIR)/.configured $(MAKE) -C $(LZMA_TARGET_DIR) all @@ -107,6 +111,7 @@ lzma-dirclean: ############################################################# ifeq ($(strip $(BR2_PACKAGE_LZMA_HOST)),y) TARGETS+=lzma-host +HOST_SOURCE+=lzma-source endif ifeq ($(strip $(BR2_PACKAGE_LZMA_TARGET)),y)