[firmware-nonfree] 08/24: check_upstream.py: Report possibly undistributable files that are not excluded

debian-kernel at lists.debian.org debian-kernel at lists.debian.org
Sun Oct 18 13:49:57 UTC 2015


This is an automated email from the git hooks/post-receive script.

benh pushed a commit to branch master
in repository firmware-nonfree.

commit 6ba0ce53f284371c609d6497451562a4e69dfa26
Author: Ben Hutchings <ben at decadent.org.uk>
Date:   Sun Oct 18 03:41:37 2015 +0100

    check_upstream.py: Report possibly undistributable files that are not excluded
---
 debian/bin/check_upstream.py | 13 +++++++++----
 debian/changelog             |  2 ++
 2 files changed, 11 insertions(+), 4 deletions(-)

diff --git a/debian/bin/check_upstream.py b/debian/bin/check_upstream.py
index 65a4341..1879f11 100755
--- a/debian/bin/check_upstream.py
+++ b/debian/bin/check_upstream.py
@@ -54,11 +54,16 @@ def main(source_dir='.'):
     exclusions = config['upstream',]['exclude']
 
     for section in FirmwareWhence(open(os.path.join(source_dir, 'WHENCE'))):
-        if check_section(section) == DistState.non_free:
-            for file_info in section.files.values():
+        dist_state = check_section(section)
+        for file_info in section.files.values():
+            if dist_state == DistState.non_free:
                 if not any(fnmatch.fnmatch(file_info.binary, exclusion)
                            for exclusion in exclusions):
                     update_file(source_dir, over_dirs, file_info.binary)
+            elif dist_state == DistState.undistributable:
+                if os.path.isfile(file_info.binary):
+                    print('W: %s appears to be undistributable' %
+                          file_info.binary)
 
 def update_file(source_dir, over_dirs, filename):
     source_file = os.path.join(source_dir, filename)
@@ -67,10 +72,10 @@ def update_file(source_dir, over_dirs, filename):
                           glob.glob(os.path.join(over_dir, filename + '-*'))):
             if os.path.isfile(over_file):
                 if not filecmp.cmp(source_file, over_file, True):
-                    print('%s: changed' % filename)
+                    print('I: %s: changed' % filename)
                 return
     if not os.path.isfile(filename):
-        print('%s: could be added' % filename)
+        print('I: %s: could be added' % filename)
         return
 
 if __name__ == '__main__':
diff --git a/debian/changelog b/debian/changelog
index 2a63997..d5a9f14 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -13,6 +13,8 @@ firmware-nonfree (20151018-1) UNRELEASED; urgency=medium
   * Update to linux-support 4.1.0-2
   * debian/control: Drop Frederik Schüler and dann frazier from Uploaders
   * debian/bin: Use Python 3 (as assumed by linux-support-4.2.0-1)
+  * check_upstream.py: Report possibly undistributable files that are not
+    excluded
 
   [ maximilian attems ]
   * iwlwifi: Update Intel Wireless 3160, 7260, 7265 and 7265D firmware version

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/kernel/firmware-nonfree.git



More information about the Kernel-svn-changes mailing list