summaryrefslogtreecommitdiff
path: root/package/file
diff options
context:
space:
mode:
Diffstat (limited to 'package/file')
-rw-r--r--package/file/file.mk20
1 files changed, 13 insertions, 7 deletions
diff --git a/package/file/file.mk b/package/file/file.mk
index 5a5058dc5..2b860c7ef 100644
--- a/package/file/file.mk
+++ b/package/file/file.mk
@@ -31,7 +31,7 @@ $(FILE_DIR1)/.configured: $(FILE_SOURCE_DIR)/.unpacked
$(FILE_SOURCE_DIR)/configure \
--prefix=$(FILE_DIR1)/install \
)
- touch $(FILE_DIR1)/.configured
+ touch $@
$(TOOL_BUILD_DIR)/bin/file: $(FILE_DIR1)/.configured
$(MAKE) -C $(FILE_DIR1) install
@@ -55,7 +55,7 @@ $(FILE_SOURCE_DIR)/.unpacked: $(DL_DIR)/$(FILE_SOURCE)
$(FILE_CAT) $(DL_DIR)/$(FILE_SOURCE) | tar -C $(BUILD_DIR) $(TAR_OPTIONS) -
toolchain/patch-kernel.sh $(FILE_SOURCE_DIR) package/file/ file\*.patch
$(CONFIG_UPDATE) $(FILE_SOURCE_DIR)
- touch $(FILE_SOURCE_DIR)/.unpacked
+ touch $@
$(FILE_DIR2)/.configured: $(FILE_SOURCE_DIR)/.unpacked
mkdir -p $(FILE_DIR2)
@@ -75,14 +75,14 @@ $(FILE_DIR2)/.configured: $(FILE_SOURCE_DIR)/.unpacked
--sysconfdir=/etc \
--datadir=/usr/share/misc \
--localstatedir=/var \
- --mandir=/usr/man \
- --infodir=/usr/info \
+ --mandir=/usr/share/man \
+ --infodir=/usr/share/info \
$(DISABLE_NLS) \
$(DISABLE_LARGEFILE) \
--enable-static \
--disable-fsect-man5 \
)
- touch $(FILE_DIR2)/.configured
+ touch $@
$(FILE_DIR2)/$(FILE_BINARY): $(FILE_DIR2)/.configured $(TOOL_BUILD_DIR)/bin/file
$(MAKE) $(TARGET_CONFIGURE_OPTS) LDFLAGS="-static" -C $(FILE_DIR2)
@@ -90,8 +90,14 @@ $(FILE_DIR2)/$(FILE_BINARY): $(FILE_DIR2)/.configured $(TOOL_BUILD_DIR)/bin/file
$(TARGET_DIR)/$(FILE_TARGET_BINARY): $(FILE_DIR2)/$(FILE_BINARY)
$(MAKE) $(TARGET_CONFIGURE_OPTS) DESTDIR=$(TARGET_DIR) -C $(FILE_DIR2) install
-($(STRIP) $(TARGET_DIR)/usr/lib/libmagic.so.*.* > /dev/null 2>&1)
- rm -rf $(TARGET_DIR)/share/locale $(TARGET_DIR)/usr/info \
- $(TARGET_DIR)/usr/man $(TARGET_DIR)/usr/share/doc
+ifneq ($(BR2_HAVE_INFOPAGES),y)
+ rm -rf $(TARGET_DIR)/usr/share/info
+endif
+ifneq ($(BR2_HAVE_MANPAGES),y)
+ rm -rf $(TARGET_DIR)/usr/share/man
+endif
+ rm -rf $(TARGET_DIR)/share/locale
+ rm -rf $(TARGET_DIR)/usr/share/doc
mv $(TARGET_DIR)/lib/libmagic.a $(STAGING_DIR)/lib
rm -f $(TARGET_DIR)/lib/libmagic.la
mv $(TARGET_DIR)/usr/include/magic.h $(STAGING_DIR)/usr/include