summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEric Andersen <andersen@codepoet.org>2003-10-03 01:27:09 +0000
committerEric Andersen <andersen@codepoet.org>2003-10-03 01:27:09 +0000
commit1d669278d8aa2a78e372a914277e27754e4cca79 (patch)
tree31b19f791b20f88ac537117da60c08e8a08a8e5a
parent3f43ecc42800401ed2dec0c62db812f329bad875 (diff)
Update file
-rw-r--r--make/file.mk19
-rw-r--r--sources/file.patch30
2 files changed, 38 insertions, 11 deletions
diff --git a/make/file.mk b/make/file.mk
index eea380ae2..3eb4829d3 100644
--- a/make/file.mk
+++ b/make/file.mk
@@ -3,11 +3,11 @@
# file
#
#############################################################
-FILE_SOURCE:=file-3.41.tar.gz
+FILE_SOURCE:=file-4.04.tar.gz
FILE_SITE:=ftp://ftp.astron.com/pub/file
-FILE_DIR:=$(BUILD_DIR)/file-3.41
+FILE_DIR:=$(BUILD_DIR)/file-4.04
FILE_CAT:=zcat
-FILE_BINARY:=file
+FILE_BINARY:=src/file
FILE_TARGET_BINARY:=usr/bin/file
$(DL_DIR)/$(FILE_SOURCE):
@@ -17,11 +17,8 @@ file-source: $(DL_DIR)/$(FILE_SOURCE)
$(FILE_DIR)/.unpacked: $(DL_DIR)/$(FILE_SOURCE)
$(FILE_CAT) $(DL_DIR)/$(FILE_SOURCE) | tar -C $(BUILD_DIR) -xvf -
- # Use the system file utility, not the one we just built
- perl -pi -e "s,\./file,file,g" $(FILE_DIR)/Makefile.in $(FILE_DIR)/Makefile.am
- touch $(FILE_DIR)/config.guess
- touch $(FILE_DIR)/config.sub
- touch $(FILE_DIR)/.unpacked
+ cat $(SOURCE_DIR)/file.patch | patch -p1 -d $(FILE_DIR)
+ touch $(FILE_DIR)/.unpacked
$(FILE_DIR)/.configured: $(FILE_DIR)/.unpacked
(cd $(FILE_DIR); rm -rf config.cache; \
@@ -41,15 +38,15 @@ $(FILE_DIR)/.configured: $(FILE_DIR)/.unpacked
--mandir=/usr/man \
--infodir=/usr/info \
$(DISABLE_NLS) \
- --enable-fsect-man5 \
+ --disable-fsect-man5 \
);
touch $(FILE_DIR)/.configured
$(FILE_DIR)/$(FILE_BINARY): $(FILE_DIR)/.configured
- $(MAKE) CC=$(TARGET_CC) -C $(FILE_DIR)
+ $(MAKE) $(TARGET_CONFIGURE_OPTS) -C $(FILE_DIR)
$(TARGET_DIR)/$(FILE_TARGET_BINARY): $(FILE_DIR)/$(FILE_BINARY)
- $(MAKE) DESTDIR=$(TARGET_DIR) CC=$(TARGET_CC) -C $(FILE_DIR) install
+ $(MAKE) $(TARGET_CONFIGURE_OPTS) DESTDIR=$(TARGET_DIR) -C $(FILE_DIR) install
rm -rf $(TARGET_DIR)/share/locale $(TARGET_DIR)/usr/info \
$(TARGET_DIR)/usr/man $(TARGET_DIR)/usr/share/doc
diff --git a/sources/file.patch b/sources/file.patch
new file mode 100644
index 000000000..4b7775137
--- /dev/null
+++ b/sources/file.patch
@@ -0,0 +1,30 @@
+--- file-4.04/magic/Makefile.am.orig 2003-10-02 13:46:41.000000000 -0600
++++ file-4.04/magic/Makefile.am 2003-10-02 13:47:38.000000000 -0600
+@@ -16,10 +16,10 @@
+ done >> $@
+
+ magic.mgc: magic
+- $(top_builddir)/src/file -C -m magic
++ /usr/bin/file -C -m magic
+
+ magic.mime.mgc: magic.mime
+- $(top_builddir)/src/file -C -m magic.mime
++ /usr/bin/file -C -m magic.mime
+
+ magic_FRAGMENTS = \
+ Magdir/acorn \
+--- file-4.04/magic/Makefile.in.orig 2003-10-02 13:52:23.000000000 -0600
++++ file-4.04/magic/Makefile.in 2003-10-02 13:52:53.000000000 -0600
+@@ -477,10 +477,10 @@
+ done >> $@
+
+ magic.mgc: magic
+- $(top_builddir)/src/file -C -m magic
++ /usr/bin/file -C -m magic
+
+ magic.mime.mgc: magic.mime
+- $(top_builddir)/src/file -C -m magic.mime
++ /usr/bin/file -C -m magic.mime
+ # Tell versions [3.59,3.63) of GNU make to not export all variables.
+ # Otherwise a system limit (for SysV at least) may be exceeded.
+ .NOEXPORT: