From 1c4583f7575b855f56097eb155445ea0cff001e93d477ea55065c85eda446f56 Mon Sep 17 00:00:00 2001 From: Martin Pluskal Date: Tue, 13 Nov 2018 15:21:30 +0000 Subject: [PATCH] Accepting request 648474 from home:sbrabec:branches:devel:tools - Fix glibc license (savannah#54996). - Add makeinfo to BuildRequires. OBS-URL: https://build.opensuse.org/request/show/648474 OBS-URL: https://build.opensuse.org/package/show/devel:tools/gengetopt?expand=0&rev=25 --- gengetopt-glibc-license.patch | 84 +++++++++++++++++++++++++++++++++++ gengetopt.changes | 6 +++ gengetopt.spec | 6 ++- 3 files changed, 95 insertions(+), 1 deletion(-) create mode 100644 gengetopt-glibc-license.patch diff --git a/gengetopt-glibc-license.patch b/gengetopt-glibc-license.patch new file mode 100644 index 0000000..73c3050 --- /dev/null +++ b/gengetopt-glibc-license.patch @@ -0,0 +1,84 @@ +From ebe3207f870ca379c32c61edcb75466a86ba6e93 Mon Sep 17 00:00:00 2001 +From: Stanislav Brabec +Date: Fri, 9 Nov 2018 19:11:17 +0100 +Subject: [PATCH] Fix licensing clash + +The glibc code is LGPL 2.1 or later. Fix it in the generated files and +mention this fact in the documentation. Fixes bug #54996. +--- + doc/gengetopt.texinfo | 3 +++ + src/skels/custom_getopt_gen.cc | 2 +- + src/skels/custom_getopt_gen.h_skel | 2 +- + tests/test_first_cmdline_cmd.c.test | 2 +- + tests/test_second_cmdline_cmd.c.test | 2 +- + 5 files changed, 7 insertions(+), 4 deletions(-) + +diff --git a/doc/gengetopt.texinfo b/doc/gengetopt.texinfo +index c0d9c39..a5c1d80 100644 +--- a/doc/gengetopt.texinfo ++++ b/doc/gengetopt.texinfo +@@ -168,6 +168,9 @@ licensed with a simple all-permissive license instead of the GPL or + LGPL. You are free to do anything you like with the generated code, + including incorporating it into or linking it with proprietary software. + ++If you use @code{--include-getopt}, then Gengetopt adds a getopt code ++that is licensed under LGPL 2.1 or later. ++ + Gengetopt was originally written by Roberto Arturo Tena Sanchez. It is + currently maintained by Lorenzo Bettini @value{myhomepage}. + +diff --git a/src/skels/custom_getopt_gen.cc b/src/skels/custom_getopt_gen.cc +index abab5f6..40dfa6b 100644 +--- a/src/skels/custom_getopt_gen.cc ++++ b/src/skels/custom_getopt_gen.cc +@@ -21,7 +21,7 @@ custom_getopt_gen_gen_class::generate_custom_getopt_gen(ostream &stream, unsigne + stream << " *"; + stream << "\n"; + stream << indent_str; +- stream << " * Licensed under the GPL as per the whole glibc source tree."; ++ stream << " * Licensed under the LGPL 2.1 or later as per the whole glibc source tree."; + stream << "\n"; + stream << indent_str; + stream << " *"; +diff --git a/src/skels/custom_getopt_gen.h_skel b/src/skels/custom_getopt_gen.h_skel +index 36a4bf6..9a245ed 100644 +--- a/src/skels/custom_getopt_gen.h_skel ++++ b/src/skels/custom_getopt_gen.h_skel +@@ -1,7 +1,7 @@ + /* + * Extracted from the glibc source tree, version 2.3.6 + * +- * Licensed under the GPL as per the whole glibc source tree. ++ * Licensed under the LGPL 2.1 or later as per the whole glibc source tree. + * + * This file was modified so that getopt_long can be called + * many times without risking previous memory to be spoiled. +diff --git a/tests/test_first_cmdline_cmd.c.test b/tests/test_first_cmdline_cmd.c.test +index 5dd6224..8e6537f 100644 +--- a/tests/test_first_cmdline_cmd.c.test ++++ b/tests/test_first_cmdline_cmd.c.test +@@ -560,7 +560,7 @@ test_first_cmdline_cmd_parser_required2 (struct test_first_cmdline_cmd_struct *a + /* + * Extracted from the glibc source tree, version 2.3.6 + * +- * Licensed under the GPL as per the whole glibc source tree. ++ * Licensed under the LGPL 2.1 or later as per the whole glibc source tree. + * + * This file was modified so that getopt_long can be called + * many times without risking previous memory to be spoiled. +diff --git a/tests/test_second_cmdline_cmd.c.test b/tests/test_second_cmdline_cmd.c.test +index f6720d2..3edfd3d 100644 +--- a/tests/test_second_cmdline_cmd.c.test ++++ b/tests/test_second_cmdline_cmd.c.test +@@ -569,7 +569,7 @@ test_second_cmdline_cmd_parser_required2 (struct test_second_cmdline_cmd_struct + /* + * Extracted from the glibc source tree, version 2.3.6 + * +- * Licensed under the GPL as per the whole glibc source tree. ++ * Licensed under the LGPL 2.1 or later as per the whole glibc source tree. + * + * This file was modified so that getopt_long can be called + * many times without risking previous memory to be spoiled. +-- +2.19.1 + diff --git a/gengetopt.changes b/gengetopt.changes index 0721ef1..e9bba4b 100644 --- a/gengetopt.changes +++ b/gengetopt.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Mon Nov 12 13:54:22 CET 2018 - sbrabec@suse.com + +- Fix glibc license (savannah#54996). +- Add makeinfo to BuildRequires. + ------------------------------------------------------------------- Fri Apr 13 12:02:12 UTC 2018 - mpluskal@suse.com diff --git a/gengetopt.spec b/gengetopt.spec index 23353fa..c40e258 100644 --- a/gengetopt.spec +++ b/gengetopt.spec @@ -12,7 +12,7 @@ # license that conforms to the Open Source Definition (Version 1.9) # published by the Open Source Initiative. -# Please submit bugfixes or comments via http://bugs.opensuse.org/ +# Please submit bugfixes or comments via https://bugs.opensuse.org/ # @@ -26,10 +26,13 @@ URL: https://www.gnu.org/software/gengetopt/ Source0: https://ftp.gnu.org/gnu/gengetopt/%{name}-%{version}.tar.gz Source1: https://ftp.gnu.org/gnu/gengetopt/%{name}-%{version}.tar.gz.sig Source2: %{name}.keyring +# PATCH-FIX-UPSTREAM sbrabec@suse.cz savannah54996 -- Fix glibc license. https://savannah.gnu.org/bugs/?54996 +Patch1: gengetopt-glibc-license.patch BuildRequires: bison BuildRequires: flex BuildRequires: gcc-c++ BuildRequires: help2man +BuildRequires: makeinfo Requires(post): %{install_info_prereq} Requires(preun): %{install_info_prereq} @@ -42,6 +45,7 @@ reading/writing the options from/to config files is also supported. %prep %setup -q +%patch1 -p1 %build %configure