[Glibc-bsd-commits] r5722 - trunk/kfreebsd-11/debian

stevenc-guest at alioth.debian.org stevenc-guest at alioth.debian.org
Tue Jul 7 20:14:31 UTC 2015


Author: stevenc-guest
Date: 2015-07-07 20:14:31 +0000 (Tue, 07 Jul 2015)
New Revision: 5722

Modified:
   trunk/kfreebsd-11/debian/changelog
   trunk/kfreebsd-11/debian/rules
Log:
Merge changes from kfreebsd-10:
* Create tarballs of upstream source, and of the kfreebsd-source
  binary-indep package, using a reproducible stable file order.
  (Closes: #786615)
* In the kfreebsd-source binary-indep package, clamp timestamps
  to be no later than the last debian/changelog entry.
  (Closes: #788238)
* In the kfreebsd-source binary-indep package, ensure files
  and directories in the tarball are not writable by the src
  group, but readable by all, regardless of the umask setting
  when the package is built. (Closes: #791584)


Modified: trunk/kfreebsd-11/debian/changelog
===================================================================
--- trunk/kfreebsd-11/debian/changelog	2015-07-07 20:08:24 UTC (rev 5721)
+++ trunk/kfreebsd-11/debian/changelog	2015-07-07 20:14:31 UTC (rev 5722)
@@ -12,6 +12,16 @@
     and thereby correctly specify any-arm in debian/control too.
   * Build with clang-3.6 on i386, amd64, arm;  due to clang-3.4
     going away soon. (Closes: #790358)
+  * Create tarballs of upstream source, and of the kfreebsd-source
+    binary-indep package, using a reproducible stable file order.
+    (Closes: #786615)
+  * In the kfreebsd-source binary-indep package, clamp timestamps
+    to be no later than the last debian/changelog entry.
+    (Closes: #788238)
+  * In the kfreebsd-source binary-indep package, ensure files
+    and directories in the tarball are not writable by the src
+    group, but readable by all, regardless of the umask setting
+    when the package is built. (Closes: #791584)
 
  -- Steven Chamberlain <steven at pyro.eu.org>  Tue, 07 Jul 2015 21:00:25 +0100
 

Modified: trunk/kfreebsd-11/debian/rules
===================================================================
--- trunk/kfreebsd-11/debian/rules	2015-07-07 20:08:24 UTC (rev 5721)
+++ trunk/kfreebsd-11/debian/rules	2015-07-07 20:14:31 UTC (rev 5722)
@@ -97,7 +97,12 @@
 		| sed -ne 's/.*\sCLANG_VERSION\s\+//p' \
 		> $(ORIG_DIR)/CLANG_VERSION
 	cd $(ORIG_DIR) && $(CURDIR)/debian/prune.sh
-	tar --numeric-owner --owner 0 --group 0 -cJf ../$(ORIG_TAR) $(ORIG_DIR)
+	# Create tarball with files sorted in a stable order, see
+	# https://wiki.debian.org/ReproducibleBuilds/FileOrderInTarballs
+	find $(ORIG_DIR) -print0 | LC_ALL=C sort -z \
+	 | tar --null --no-recursion --files-from - \
+	    --numeric-owner --owner 0 --group 0 \
+	    -cJf ../$(ORIG_TAR)
 	rm -rf $(ORIG_DIR)
 
 control: clean
@@ -163,7 +168,18 @@
 
 	mkdir -p $(SOURCE_PACKAGE)/usr/src
 	chown -R root.src $(SRC_DIR)
-	tar cfJ $(SOURCE_PACKAGE)/usr/src/$(SRC_TAR) $(SRC_DIR)
+	# Clamp timestamps to be no newer than last changelog entry, see
+	# https://wiki.debian.org/ReproducibleBuilds/TimestampsInTarball
+	find $(SRC_DIR) -newermt "$(BUILD_DATE)" -print0 \
+	 | xargs -0r touch --no-dereference --date="$(BUILD_DATE)"
+	# Create tarball with files sorted in a stable order, see
+	# https://wiki.debian.org/ReproducibleBuilds/FileOrderInTarballs
+	# and normalised file permissions regardless of umask, see
+	# https://wiki.debian.org/ReproducibleBuilds/VaryingPermissionsInTarballs
+	find $(SRC_DIR) -print0 | LC_ALL=C sort -z \
+	 | tar --null --no-recursion --files-from - \
+	    --mode=go=rX,u+rw,a-s \
+	    -cJf $(SOURCE_PACKAGE)/usr/src/$(SRC_TAR)
 
 	touch install-indep-stamp
 




More information about the Glibc-bsd-commits mailing list