[SCM] libav/ubuntu: build the libav-source tarball iff there is a libav-source package

siretart at users.alioth.debian.org siretart at users.alioth.debian.org
Sat Aug 11 09:29:47 UTC 2012


The following commit has been merged in the ubuntu branch:
commit c91d6dbdd457d65acb3100ab7eba6f078ab366b0
Author: Reinhard Tartler <siretart at tauware.de>
Date:   Sat Aug 11 09:53:24 2012 +0200

    build the libav-source tarball iff there is a libav-source package

diff --git a/debian/rules b/debian/rules
index f6fcccf..956917f 100755
--- a/debian/rules
+++ b/debian/rules
@@ -120,10 +120,13 @@ install-common: build $(DH_INSTALL_FILES)
 	dh_testdir
 	dh_testroot
 	dh_prep
-	dh_installdirs -ptmp usr/src
-	tar czvf debian/tmp/usr/src/libav-source.tar.gz . \
-		 --exclude 'debian*' --exclude .git  --exclude .pc --exclude '*-stamp' \
-		 --transform 's,^./,libav/,'
+	# the libav-source package does exist in some derivatives such as ubuntu, etc.
+	if grep -q 'Package: libav-source' debian/control; then \
+	  dh_installdirs -ptmp usr/src;  \
+	  tar czvf debian/tmp/usr/src/libav-source.tar.gz . \
+	  	 --exclude 'debian*' --exclude .git  --exclude .pc --exclude '*-stamp' \
+	  	 --transform 's,^./,libav/,' ; \
+	fi
 	dh_installdirs -ptmp usr/share/doc/libav/html etc
 	dh_installdirs -ptmp usr/share/doc/libav-doc/html
 	$(foreach flavor,$(FLAVORS),$(call install_flavor,$(flavor)))

-- 
Libav/FFmpeg packaging



More information about the pkg-multimedia-commits mailing list