]> Savannah Git Hosting - gnulib.git/commitdiff
gnulib-tool.py: Follow gnulib-tool changes, part 22.
authorBruno Haible <bruno@clisp.org>
Wed, 3 Aug 2022 12:51:20 +0000 (14:51 +0200)
committerBruno Haible <bruno@clisp.org>
Wed, 3 Aug 2022 12:51:50 +0000 (14:51 +0200)
Follow gnulib-tool change
2016-10-15  Bruno Haible  <bruno@clisp.org>
Avoid gnulib-tool warnings about the dependencies of 'parse-datetime'.

* pygnulib/GLModuleSystem.py (GLModule.getLicense): Special-case the
'parse-datetime' module.

ChangeLog
gnulib-tool.py.TODO
pygnulib/GLModuleSystem.py

index e2f3e0f127a0ba6f5fa2d6ab57ecfc1f4f481289..2f88a72f901734f81690cee20160abb2175d0260 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,12 @@
 2022-08-03  Bruno Haible  <bruno@clisp.org>
 
+       gnulib-tool.py: Follow gnulib-tool changes, part 22.
+       Follow gnulib-tool change
+       2016-10-15  Bruno Haible  <bruno@clisp.org>
+       Avoid gnulib-tool warnings about the dependencies of 'parse-datetime'.
+       * pygnulib/GLModuleSystem.py (GLModule.getLicense): Special-case the
+       'parse-datetime' module.
+
        gnulib-tool.py: Follow gnulib-tool changes, part 21.
        Follow gnulib-tool change
        2016-10-16  Bruno Haible  <bruno@clisp.org>
index b71b7200ab11b5006e6aacc0de25f18c411d3f13..d5030c8231ba09d5a4ff2005c4d5c4120e4bd19d 100644 (file)
@@ -1056,17 +1056,6 @@ Date:   Sun Nov 13 04:12:26 2016 +0100
 
 --------------------------------------------------------------------------------
 
-commit ff9debcf75301805b1db925cdcdfb248541c576d
-Author: Bruno Haible <bruno@clisp.org>
-Date:   Sat Oct 15 15:51:20 2016 +0200
-
-    Avoid gnulib-tool warnings about the dependencies of 'parse-datetime'.
-
-    * gnulib-tool (func_get_license): Special-case the 'parse-datetime'
-    module.
-
---------------------------------------------------------------------------------
-
 commit 9bdf6c8a0cdeb13c12e4b65dee9538c5468dbe1d
 Author: Bruno Haible <bruno@clisp.org>
 Date:   Sun Aug 19 14:06:50 2012 +0200
index 319175dee8b97a27e55e2403cc76d47935735595..25c34f8756b3c43f7e37793895d1e2b2edbeb6f2 100644 (file)
@@ -796,16 +796,22 @@ Include:|Link:|License:|Maintainer:)'
         '''GLModule.getLicense(self) -> str
 
         Get license and warn user if module lacks a license.'''
-        license = self.getLicense_Raw()
-        if not self.isTests():
+        if str(self) == 'parse-datetime':
+            # This module is under a weaker license only for the purpose of some
+            # users who hand-edit it and don't use gnulib-tool. For the regular
+            # gnulib users they are under a stricter license.
+            return 'GPL'
+        else:
+            license = self.getLicense_Raw()
+            if not self.isTests():
+                if not license:
+                    if self.config['errors']:
+                        raise GLError(18, str(self))
+                    else:  # if not self.config['errors']
+                        sys.stderr.write('gnulib-tool: warning: module %s lacks a license\n' % str(self))
             if not license:
-                if self.config['errors']:
-                    raise GLError(18, str(self))
-                else:  # if not self.config['errors']
-                    sys.stderr.write('gnulib-tool: warning: module %s lacks a license\n' % str(self))
-        if not license:
-            license = 'GPL'
-        return license
+                license = 'GPL'
+            return license
 
     def getLicense_Raw(self):
         '''GLModule.getLicense_Raw() -> str