Accepting request 648761 from devel:tools

- Fix glibc license (savannah#54996):
  * gengetopt-glibc-license.patch
- Add makeinfo to BuildRequires.

OBS-URL: https://build.opensuse.org/request/show/648761
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/gengetopt?expand=0&rev=15
This commit is contained in:
Dominique Leuenberger 2018-11-18 22:22:23 +00:00 committed by Git OBS Bridge
commit c209da193f
3 changed files with 96 additions and 1 deletions

View File

@ -0,0 +1,84 @@
From ebe3207f870ca379c32c61edcb75466a86ba6e93 Mon Sep 17 00:00:00 2001
From: Stanislav Brabec <sbrabec@suse.com>
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

View File

@ -1,3 +1,10 @@
-------------------------------------------------------------------
Mon Nov 12 13:54:22 CET 2018 - sbrabec@suse.com
- Fix glibc license (savannah#54996):
* gengetopt-glibc-license.patch
- Add makeinfo to BuildRequires.
-------------------------------------------------------------------
Fri Apr 13 12:02:12 UTC 2018 - mpluskal@suse.com

View File

@ -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