[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#832099: marked as done (lintian: please check for unnecessary SOURCE_DATE_EPOCH assignments)



Your message dated Wed, 21 Feb 2018 19:35:03 +0000
with message-id <E1eoaAR-0000Rm-R8@fasolo.debian.org>
and subject line Bug#832099: fixed in lintian 2.5.76
has caused the Debian Bug report #832099,
regarding lintian: please check for unnecessary SOURCE_DATE_EPOCH assignments
to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact owner@bugs.debian.org
immediately.)


-- 
832099: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=832099
Debian Bug Tracking System
Contact owner@bugs.debian.org with problems
--- Begin Message ---
Source: lintian
Version: 2.5.45
Severity: wishlist
Tags: patch
X-Debbugs-Cc: reproducible-builds@lists.alioth.debian.org

Hi,

Attached is the following:

  commit 3b10f7dbaecedb0a458c25cc0b8615b489d424af
  Author: Chris Lamb <lamby@debian.org>
  Date:   Fri Jul 22 10:54:02 2016 +0100
  
      c/rules: Check for unnecessary SOURCE_DATE_EPOCH assignments
      
      As of dpkg 1.18.8, this is no longer necessary as dpkg exports this
      variable if it is not already set (#759999). This should encourage
      removing some duplicated code from a lot of our rules files.
      
      Signed-off-by: Chris Lamb <lamby@debian.org>
  
   checks/rules.desc                         | 8 ++++++++
   checks/rules.pm                           | 2 ++
   t/tests/rules-general/debian/debian/rules | 2 ++
   t/tests/rules-general/desc                | 3 ++-
   t/tests/rules-general/tags                | 7 ++++---
   5 files changed, 18 insertions(+), 4 deletions(-)



Regards,

-- 
      ,''`.
     : :'  :     Chris Lamb
     `. `'`      lamby@debian.org / chris-lamb.co.uk
       `-
From 3b10f7dbaecedb0a458c25cc0b8615b489d424af Mon Sep 17 00:00:00 2001
From: Chris Lamb <lamby@debian.org>
Date: Fri, 22 Jul 2016 10:54:02 +0100
Subject: [PATCH] c/rules: Check for unnecessary SOURCE_DATE_EPOCH assignments

As of dpkg 1.18.8, this is no longer necessary as dpkg exports this
variable if it is not already set (#759999). This should encourage
removing some duplicated code from a lot of our rules files.

Signed-off-by: Chris Lamb <lamby@debian.org>
---
 checks/rules.desc                         | 8 ++++++++
 checks/rules.pm                           | 2 ++
 t/tests/rules-general/debian/debian/rules | 2 ++
 t/tests/rules-general/desc                | 3 ++-
 t/tests/rules-general/tags                | 7 ++++---
 5 files changed, 18 insertions(+), 4 deletions(-)

diff --git a/checks/rules.desc b/checks/rules.desc
index 25c565b..13bf4c2 100644
--- a/checks/rules.desc
+++ b/checks/rules.desc
@@ -248,3 +248,11 @@ Info: The source package does not have both a build-arch and a build-indep
  .
  Please consider adding both the build-arch and build-indep targets.
 
+Tag: unnecessary-source-date-epoch-assignment
+Severity: normal
+Certainty: certain
+Info: There is an assignment to a <tt>SOURCE_DATE_EPOCH</tt> variable in the
+  <tt>debian/rules</tt> file.  As of dpkg 1.18.8, this is no longer necessary
+  as dpkg exports this variable if it is not already set.
+  .
+  Consider removing this assignment.
diff --git a/checks/rules.pm b/checks/rules.pm
index bd3a141..ce77909 100644
--- a/checks/rules.pm
+++ b/checks/rules.pm
@@ -226,6 +226,8 @@ sub run {
             # rather well.
             my ($var, $value) = ($1, $2);
             $variables{$var} = $value;
+            tag 'unnecessary-source-date-epoch-assignment', "line $."
+                if $var eq "SOURCE_DATE_EPOCH";
         }
 
         # Keep track of whether this portion of debian/rules may be optional
diff --git a/t/tests/rules-general/debian/debian/rules b/t/tests/rules-general/debian/debian/rules
index cddbc03..121305a 100755
--- a/t/tests/rules-general/debian/debian/rules
+++ b/t/tests/rules-general/debian/debian/rules
@@ -2,6 +2,8 @@
 
 DEB_AUTO_UPDATE_DEBIAN_CONTROL = yes
 
+export SOURCE_DATE_EPOCH = $(shell date -d "$$(dpkg-parsechangelog -SDate)" +%s)
+
 %:
 	dh $@
 
diff --git a/t/tests/rules-general/desc b/t/tests/rules-general/desc
index 1f41c20..cab329e 100644
--- a/t/tests/rules-general/desc
+++ b/t/tests/rules-general/desc
@@ -7,4 +7,5 @@ Test-For:
  debian-rules-should-not-automatically-update-control
  debian-rules-should-not-use-DEB_BUILD_OPTS
  debian-rules-should-not-use-pwd
- debian-rules-should-not-use-underscore-variable
\ No newline at end of file
+ debian-rules-should-not-use-underscore-variable
+ unnecessary-source-date-epoch-assignment
diff --git a/t/tests/rules-general/tags b/t/tests/rules-general/tags
index 3e7351b..6675064 100644
--- a/t/tests/rules-general/tags
+++ b/t/tests/rules-general/tags
@@ -1,5 +1,6 @@
 E: rules-general source: clean-should-be-satisfied-by-build-depends debhelper
 E: rules-general source: debian-rules-should-not-automatically-update-control line 3
-W: rules-general source: debian-rules-should-not-use-DEB_BUILD_OPTS line 10
-W: rules-general source: debian-rules-should-not-use-pwd line 10
-W: rules-general source: debian-rules-should-not-use-underscore-variable line 11
+W: rules-general source: debian-rules-should-not-use-DEB_BUILD_OPTS line 12
+W: rules-general source: debian-rules-should-not-use-pwd line 12
+W: rules-general source: debian-rules-should-not-use-underscore-variable line 13
+W: rules-general source: unnecessary-source-date-epoch-assignment line 5
-- 
2.8.1


--- End Message ---
--- Begin Message ---
Source: lintian
Source-Version: 2.5.76

We believe that the bug you reported is fixed in the latest version of
lintian, which is due to be installed in the Debian FTP archive.

A summary of the changes between this version and the previous one is
attached.

Thank you for reporting the bug, which will now be closed.  If you
have further comments please address them to 832099@bugs.debian.org,
and the maintainer will reopen the bug report if appropriate.

Debian distribution maintenance software
pp.
Chris Lamb <lamby@debian.org> (supplier of updated lintian package)

(This message was generated automatically at their request; if you
believe that there is a problem with it please contact the archive
administrators by mailing ftpmaster@ftp-master.debian.org)


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

Format: 1.8
Date: Wed, 21 Feb 2018 18:42:26 +0000
Source: lintian
Binary: lintian
Architecture: source all
Version: 2.5.76
Distribution: unstable
Urgency: medium
Maintainer: Debian Lintian Maintainers <lintian-maint@debian.org>
Changed-By: Chris Lamb <lamby@debian.org>
Description:
 lintian    - Debian package checker
Closes: 832099 833007 890530 890537 890660 890667 890916 890920 890943 890959 891027
Changes:
 lintian (2.5.76) unstable; urgency=medium
 .
   * Summary of tag changes:
     + Added:
       - debhelper-compat-file-contains-multiple-levels
       - debian-changelog-line-too-short
       - unnecessary-source-date-epoch-assignment
       - upstream-metadata-file-is-missing
     + Renamed:
       - co-maintained-package-with-no-vcs-headers ->
         co-maintained-package-with-no-vcs-fields.
       - desktop-contains-deprecated-header ->
         desktop-contains-deprecated-key.
       - xs-testsuite-header-in-debian-control ->
         xs-testsuite-field-in-debian-control.
       - unnecessary-testsuite-autopkgtest-header ->
         unnecessary-testsuite-autopkgtest-field.
       - xs-vcs-header-in-debian-control ->
         xs-vcs-field-in-debian-control.
 .
   * General:
     + [CL] Apply a patch series from Ben Finney to correct inconsistent use
       of "header" terminology (versus "field", etc.) in descriptions and
       tag names.  Thanks!  (Closes: #890959)
 .
   * checks/changelog-file.{desc,pm}:
     + [CL] Warn about changelog files that are too short.  Thanks to Adrian
       Bunk for the suggestion.  (Closes: #890920)
   * checks/cruft.pm:
     + [CL] Avoid false-positives in Jush's syntax highlighting definition
       files.
     + [CL] Avoid a false-positive when matching the fake Lena Söderberg
       image in libplacebo.  Thanks to Thorsten Alteholz for the report.
       (Closes: #890943)
   * checks/debhelper.{desc,pm}:
     + [CL] Warn if packages define multiple compatibility levels in the
       "compat" file, typically via "echo 11 >> debian/compat" (instead of
       ">").
   * checks/fields.desc:
     + [CL] Correct a grammatical error and tighten up the language of the
       "binary-package-depends-on-toolchain-package" tag's description.
       Thanks to Gregor Herrmann for the report.  (Closes: #890530)
   * checks/init.d.pm:
     + [CL] Also check for "RUN=" and "DAEMONRUN=" when evalating lines in
       /etc/default for "init.d-script-should-always-start-service"
       violations. Thanks to Laurent Bigonville.  (Closes: #890916)
   * checks/rules.{desc,pm}:
     + [CL] Update override_dh_auto_test-does-not-check-DEB_BUILD_OPTIONS
       to fix a number of false positives. Thanks to Gregor Herrmann for
       the report.  (Closes: #890537)
     + [CL] Also check, for example, "override_dh_fixperms-indep" and
       "override_dh_fixperms-arch" targets for
       "override_dh_fixperms-does-not-call-dh_fixperms", etc.
     + [CL] Prevent a large number of false-positives when checking the
       debian-rules-is-dh_make-template tag.  Thanks to Evgeni Golov for
       the report.  (Closes: #890660)
     + [CL] Check for unnecessary SOURCE_DATE_EPOCH assignments; it is
       either exported by dpkg >= 1.18.8 or one can include pkg-info.pk,
       etc.  (Closes: #832099)
   * checks/scripts.pm:
     + [CL] Prevent some false-positives in udevadm-called-without-guard.
   * checks/upstream-metadata.{desc,pm}:
     + [CL] Apply patch from Dylan Aïssi to suggest maintainers add a
       debian/upstream/metadata file, although downgrade the check to
       "experimental" level for the time being.  (Closes: #833007)
   * checks/watch-file.pm:
     + [CL] Use our new $PKGREPACK_REGEX to match and capture the suffix
       when looking at potential debian/watch mangling issues.
 .
   * commands/reporting-html-reports.pm:
     + [NT] Stop including the uncompressed lintian log in the website
       as it consumes considerable space for no reason.  Consumers
       should migrate to the compressed variant, which has been around
       for years and only consumes ~1/20th of the space.
 .
   * data/files/python-generic-modules:
     + [CL] Detect "core" as an overly-generic module name.  Thanks to
       Andreas Beckmann for the report.  (Closes: #891027)
   * data/scripts/interpreters:
     + [CL] Add cwl-runner (to cwltool) as an interpreter for CWL scripts.
       Thanks to Michael Crusoe for the report.  (Closes: #890667)
   * data/spelling/corrections:
     + [PW] Add a number of corrections.
 .
   * debian/source/lintian-overrides:
     + [CL] Drop all the overrides for Lintian itself now that we use the
       <!nocheck> build profile for the previously-spurious warnings.
 .
   * lib/Lintian/Util.pm:
     + [CL] Factor out the regex that matches "repacked" tarballs based on
       their filename.
   * lib/Lintian/Collect/{Changes,Sources}.pm:
     + [CL] Add repacked subroutines to check whether a package has been
       repacked or not.
 .
   * reporting/templates/maintainer.tmpl:
     + [CL] Link package entries directly to sources.debian.org.
 .
   * t/scripts/changelog-format.t:
     + [CL] Provide some possibly-helpful advice when violating the "entry
       header" changelog test.
   * t/tests/cruft-upstream-binaries:
     + [CL] Add a testcase to check that symlinked missing-sources do the
       right thing (re. #890468).
Checksums-Sha1:
 bf9b3395b6467ffd1ce123a378071ccda28e997c 3505 lintian_2.5.76.dsc
 f039c2e8bf5acd73aea2f968e39c7d6e01f52326 1537236 lintian_2.5.76.tar.xz
 36cf5700e371114c9a5cf1cb1247a3f77f5b7dab 1105364 lintian_2.5.76_all.deb
 2c94f54be740fbb16a8bafb18657fdfb2b43777f 16053 lintian_2.5.76_amd64.buildinfo
Checksums-Sha256:
 660b3a52d696a33ff95ecd43b58e57681b70afe44a53e2984d1b616c9d662337 3505 lintian_2.5.76.dsc
 e7a12767b811c6072035691c940c7d0eaf64a986d6f074fe1ccd2caecb434f8b 1537236 lintian_2.5.76.tar.xz
 efbe81a0b506848b04404a0dad6009c85408a022b804d4f106613e0940d2f5ec 1105364 lintian_2.5.76_all.deb
 08029d7f2c9220f6df8131601a2c85bfc0768d7769cfceb86a138783e9f78eb0 16053 lintian_2.5.76_amd64.buildinfo
Files:
 a11ca1e7a6fa5e888243bc9757965f15 3505 devel optional lintian_2.5.76.dsc
 01e36a73587f63dcdfdd2fe13e7efebf 1537236 devel optional lintian_2.5.76.tar.xz
 11992858684eb467fc87e2495d564070 1105364 devel optional lintian_2.5.76_all.deb
 878f56d59e53196834e766a2cab95de4 16053 devel optional lintian_2.5.76_amd64.buildinfo

-----BEGIN PGP SIGNATURE-----

iQIzBAEBCAAdFiEEwv5L0nHBObhsUz5GHpU+J9QxHlgFAlqNx+0ACgkQHpU+J9Qx
HljNjg//V1lPPIM9mEP49hE5f5UvGbj2VpJChWbQOGRmtwIqrdoZ/nu3kb4Ecl7+
J/qvcX5KZVl0DjboUluQf6OP9akSby01HudrObxFbMMMYG5VoAEGypgWnbiiJLqx
UfvgLr4Zo5w407ziEHLWyX60ONzcz0PwGwZox727PFByKNMvRL0lUkbRXykbOoGx
QgTfH0c74DCMt31j73mzDP9ZZ2UPDWoGYH5pOMS9QrDRtbKcZi08765xRS08Xnwr
ddkVa2xYwsNRwPd6Z1TGyQKYx6JP9u6SuepWA2c1ddHjusKSTVBCwfquygvTrBs6
C7HAVv1V2349YOczoA7nRrjUyKOkBT/d6O4h2AN2vGSD9I7GUgwTiStJqHZgv6sa
vqrVXO+L+o8LAaUi/GgYTJOSgUjwOC2U2GNIrh1sZ55n7DrVYmrf4DJjU2o4wfMl
vN9iBjpN3N2ij//V5KJfuylD9e760zYvL93RTeTuTqAcaxjEoxI1bCZqYgQTa29S
rYw/v8SGjo9hjeLaeemr7qmQgZm/HFF3MEpn0xzcal2T0CMC6OL3EoPnHbBf/RJZ
woatfZ7vK54ZSsZdVNWMtGinuLIBxxUOFCCfjzUZotr2xGcU7+ON0KtBUDp+zWJT
cClBUE77LOLRKiFYgnGMnBWUw1lKPg+zYl49nZ+OWagto+770wY=
=H+Ck
-----END PGP SIGNATURE-----

--- End Message ---

Reply to: