[vlc-commits] contrib: add libarchive

Thomas Guillem git at videolan.org
Fri May 22 15:15:03 CEST 2015


vlc | branch: master | Thomas Guillem <thomas at gllm.fr> | Fri May 22 15:01:45 2015 +0200| [ad5f817ce98ab227e963e112f6d55f264a95bade] | committer: Thomas Guillem

contrib: add libarchive

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=ad5f817ce98ab227e963e112f6d55f264a95bade
---

 .../0001-Fix-build-failure-without-STATVFS.patch   |   27 ++++++++++++++++++++
 contrib/src/libarchive/SHA512SUMS                  |    1 +
 contrib/src/libarchive/rules.mak                   |   24 +++++++++++++++++
 3 files changed, 52 insertions(+)

diff --git a/contrib/src/libarchive/0001-Fix-build-failure-without-STATVFS.patch b/contrib/src/libarchive/0001-Fix-build-failure-without-STATVFS.patch
new file mode 100644
index 0000000..6cfaef1
--- /dev/null
+++ b/contrib/src/libarchive/0001-Fix-build-failure-without-STATVFS.patch
@@ -0,0 +1,27 @@
+From a189efa30ad57c874997dc3ea2a3cef402b6a4ea Mon Sep 17 00:00:00 2001
+From: Thomas Guillem <thomas at gllm.fr>
+Date: Fri, 22 May 2015 14:44:28 +0200
+Subject: [PATCH] Fix build failure without STATVFS
+
+---
+ libarchive/archive_read_disk_posix.c | 4 +++-
+ 1 file changed, 3 insertions(+), 1 deletion(-)
+
+diff --git a/libarchive/archive_read_disk_posix.c b/libarchive/archive_read_disk_posix.c
+index a13dbbf..b93c198 100644
+--- a/libarchive/archive_read_disk_posix.c
++++ b/libarchive/archive_read_disk_posix.c
+@@ -1640,7 +1640,9 @@ setup_current_filesystem(struct archive_read_disk *a)
+ }
+ 
+ #elif defined(HAVE_SYS_STATFS_H) && defined(HAVE_LINUX_MAGIC_H) &&\
+-	defined(HAVE_STATFS) && defined(HAVE_FSTATFS)
++	defined(HAVE_STATFS) && defined(HAVE_FSTATFS) &&\
++	defined(HAVE_SYS_STATVFS_H) &&\
++	(defined(HAVE_STATVFS) || defined(HAVE_FSTATVFS))
+ /*
+  * Note: statfs is deprecated since LSB 3.2
+  */
+-- 
+2.1.4
+
diff --git a/contrib/src/libarchive/SHA512SUMS b/contrib/src/libarchive/SHA512SUMS
new file mode 100644
index 0000000..1f8af0c
--- /dev/null
+++ b/contrib/src/libarchive/SHA512SUMS
@@ -0,0 +1 @@
+1f3c2a675031f93c7d42ae2ed06742b0b1e2236ff57d9117791d62fb8ae77d6cafffbcb5d45b5bd98daa908bd18c576cf82e01a9b1eba699705e23eff3688114  libarchive-3.1.2.tar.gz
diff --git a/contrib/src/libarchive/rules.mak b/contrib/src/libarchive/rules.mak
new file mode 100644
index 0000000..326cab9
--- /dev/null
+++ b/contrib/src/libarchive/rules.mak
@@ -0,0 +1,24 @@
+# LIBARCHIVE
+LIBARCHIVE_VERSION := 3.1.2
+LIBARCHIVE_URL := http://www.libarchive.org/downloads/libarchive-$(LIBARCHIVE_VERSION).tar.gz
+
+PKGS += libarchive
+ifeq ($(call need_pkg,"libarchive >= 3.1.0"),)
+PKGS_FOUND += libarchive
+endif
+
+$(TARBALLS)/libarchive-$(LIBARCHIVE_VERSION).tar.gz:
+	$(call download,$(LIBARCHIVE_URL))
+
+.sum-libarchive: libarchive-$(LIBARCHIVE_VERSION).tar.gz
+
+libarchive: libarchive-$(LIBARCHIVE_VERSION).tar.gz .sum-libarchive
+	$(UNPACK)
+	$(APPLY) $(SRC)/libarchive/0001-Fix-build-failure-without-STATVFS.patch
+	$(MOVE)
+
+.libarchive: libarchive
+	cd $< && $(HOSTVARS) ./configure $(HOSTCONF) \
+		--disable-bsdcpio --disable-bsdtar --without-nettle
+	cd $< && $(MAKE) install
+	touch $@



More information about the vlc-commits mailing list