From df48d40d3544088338759e8bea2e7f832a564d48 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Rub=C3=A9n=20Rodr=C3=ADguez?= <ruben@trisquel.info>
Date: Sat, 9 Feb 2013 22:40:55 +0100
Subject: [PATCH] Added db helpers, fixes 5954

---
 helpers/DATA/db/007-mt19937db.c_license.patch | 49 +++++++++++++++++++
 .../DATA/db4.7/007-mt19937db.c_license.patch  | 49 +++++++++++++++++++
 .../DATA/db4.8/007-mt19937db.c_license.patch  | 49 +++++++++++++++++++
 helpers/make-db                               | 43 ++++++++++++++++
 helpers/make-db4.7                            |  1 +
 helpers/make-db4.8                            |  1 +
 6 files changed, 192 insertions(+)
 create mode 100644 helpers/DATA/db/007-mt19937db.c_license.patch
 create mode 100644 helpers/DATA/db4.7/007-mt19937db.c_license.patch
 create mode 100644 helpers/DATA/db4.8/007-mt19937db.c_license.patch
 create mode 100644 helpers/make-db
 create mode 120000 helpers/make-db4.7
 create mode 120000 helpers/make-db4.8

diff --git a/helpers/DATA/db/007-mt19937db.c_license.patch b/helpers/DATA/db/007-mt19937db.c_license.patch
new file mode 100644
index 00000000..360ac540
--- /dev/null
+++ b/helpers/DATA/db/007-mt19937db.c_license.patch
@@ -0,0 +1,49 @@
+Description: mt19937db.c license should include the GPL
+ This file is distributed from upstream Berkeley DB under the Artistic
+ License (no version specified), althouth it was later released by the
+ original author under both GPL2+ and BSD.
+ .
+ References:
+ http://web.archive.org/web/20010806225716/http://www.math.keio.ac.jp/matumoto/mt19937int.c
+ http://web.archive.org/web/20130127064020/http://www.math.sci.hiroshima-u.ac.jp/~m-mat/MT/MT2002/CODES/mt19937ar.c
+ https://bugzilla.redhat.com/show_bug.cgi?format=multiple&id=886838
+ https://lists.nongnu.org/archive/html/gnu-linux-libre/2010-05/msg00000.html
+ .
+Author: Ruben Rodriguez <ruben@trisquel.info>
+
+
+--- db-5.1.25.orig/src/crypto/mersenne/mt19937db.c
++++ db-5.1.25/src/crypto/mersenne/mt19937db.c
+@@ -16,16 +16,27 @@
+ /*   Coded by Takuji Nishimura, considering the suggestions by    */
+ /* Topher Cooper and Marc Rieffel in July-Aug. 1997.              */
+ 
+-/* This library is free software under the Artistic license:       */
+-/* see the file COPYING distributed together with this code.       */
+-/* For the verification of the code, its output sequence file      */
+-/* mt19937int.out is attached (2001/4/2)                           */
+-
+ /* Copyright (C) 1997, 1999 Makoto Matsumoto and Takuji Nishimura. */
+ /* Any feedback is very welcome. For any question, comments,       */
+ /* see http://www.math.keio.ac.jp/matumoto/emt.html or email       */
+ /* matumoto@math.keio.ac.jp                                        */
+ 
++/* This library is free software; you can redistribute it and/or   */
++/* modify it under the terms of the GNU Library General Public     */
++/* License as published by the Free Software Foundation; either    */
++/* version 2 of the License, or (at your option) any later         */
++/* version.                                                        */
++/* This library is distributed in the hope that it will be useful, */
++/* but WITHOUT ANY WARRANTY; without even the implied warranty of  */
++/* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.            */
++/* See the GNU Library General Public License for more details.    */
++/* You should have received a copy of the GNU Library General      */
++/* Public License along with this library; if not, write to the    */
++/* Free Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA   */ 
++/* 02111-1307  USA                                                 */
++
++/* This library is free software under the Artistic license:       */
++
+ /* REFERENCE                                                       */
+ /* M. Matsumoto and T. Nishimura,                                  */
+ /* "Mersenne Twister: A 623-Dimensionally Equidistributed Uniform  */
diff --git a/helpers/DATA/db4.7/007-mt19937db.c_license.patch b/helpers/DATA/db4.7/007-mt19937db.c_license.patch
new file mode 100644
index 00000000..1036db4d
--- /dev/null
+++ b/helpers/DATA/db4.7/007-mt19937db.c_license.patch
@@ -0,0 +1,49 @@
+Description: mt19937db.c license should include the GPL
+ This file is distributed from upstream Berkeley DB under the Artistic
+ License (no version specified), althouth it was later released by the
+ original author under both GPL2+ and BSD.
+ .
+ References:
+ http://web.archive.org/web/20010806225716/http://www.math.keio.ac.jp/matumoto/mt19937int.c
+ http://web.archive.org/web/20130127064020/http://www.math.sci.hiroshima-u.ac.jp/~m-mat/MT/MT2002/CODES/mt19937ar.c
+ https://bugzilla.redhat.com/show_bug.cgi?format=multiple&id=886838
+ https://lists.nongnu.org/archive/html/gnu-linux-libre/2010-05/msg00000.html
+ .
+Author: Ruben Rodriguez <ruben@trisquel.info>
+
+
+--- a/crypto/mersenne/mt19937db.c
++++ b/crypto/mersenne/mt19937db.c
+@@ -16,16 +16,27 @@
+ /*   Coded by Takuji Nishimura, considering the suggestions by    */
+ /* Topher Cooper and Marc Rieffel in July-Aug. 1997.              */
+ 
+-/* This library is free software under the Artistic license:       */
+-/* see the file COPYING distributed together with this code.       */
+-/* For the verification of the code, its output sequence file      */
+-/* mt19937int.out is attached (2001/4/2)                           */
+-
+ /* Copyright (C) 1997, 1999 Makoto Matsumoto and Takuji Nishimura. */
+ /* Any feedback is very welcome. For any question, comments,       */
+ /* see http://www.math.keio.ac.jp/matumoto/emt.html or email       */
+ /* matumoto@math.keio.ac.jp                                        */
+ 
++/* This library is free software; you can redistribute it and/or   */
++/* modify it under the terms of the GNU Library General Public     */
++/* License as published by the Free Software Foundation; either    */
++/* version 2 of the License, or (at your option) any later         */
++/* version.                                                        */
++/* This library is distributed in the hope that it will be useful, */
++/* but WITHOUT ANY WARRANTY; without even the implied warranty of  */
++/* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.            */
++/* See the GNU Library General Public License for more details.    */
++/* You should have received a copy of the GNU Library General      */
++/* Public License along with this library; if not, write to the    */
++/* Free Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA   */ 
++/* 02111-1307  USA                                                 */
++
++/* This library is free software under the Artistic license:       */
++
+ /* REFERENCE                                                       */
+ /* M. Matsumoto and T. Nishimura,                                  */
+ /* "Mersenne Twister: A 623-Dimensionally Equidistributed Uniform  */
diff --git a/helpers/DATA/db4.8/007-mt19937db.c_license.patch b/helpers/DATA/db4.8/007-mt19937db.c_license.patch
new file mode 100644
index 00000000..1036db4d
--- /dev/null
+++ b/helpers/DATA/db4.8/007-mt19937db.c_license.patch
@@ -0,0 +1,49 @@
+Description: mt19937db.c license should include the GPL
+ This file is distributed from upstream Berkeley DB under the Artistic
+ License (no version specified), althouth it was later released by the
+ original author under both GPL2+ and BSD.
+ .
+ References:
+ http://web.archive.org/web/20010806225716/http://www.math.keio.ac.jp/matumoto/mt19937int.c
+ http://web.archive.org/web/20130127064020/http://www.math.sci.hiroshima-u.ac.jp/~m-mat/MT/MT2002/CODES/mt19937ar.c
+ https://bugzilla.redhat.com/show_bug.cgi?format=multiple&id=886838
+ https://lists.nongnu.org/archive/html/gnu-linux-libre/2010-05/msg00000.html
+ .
+Author: Ruben Rodriguez <ruben@trisquel.info>
+
+
+--- a/crypto/mersenne/mt19937db.c
++++ b/crypto/mersenne/mt19937db.c
+@@ -16,16 +16,27 @@
+ /*   Coded by Takuji Nishimura, considering the suggestions by    */
+ /* Topher Cooper and Marc Rieffel in July-Aug. 1997.              */
+ 
+-/* This library is free software under the Artistic license:       */
+-/* see the file COPYING distributed together with this code.       */
+-/* For the verification of the code, its output sequence file      */
+-/* mt19937int.out is attached (2001/4/2)                           */
+-
+ /* Copyright (C) 1997, 1999 Makoto Matsumoto and Takuji Nishimura. */
+ /* Any feedback is very welcome. For any question, comments,       */
+ /* see http://www.math.keio.ac.jp/matumoto/emt.html or email       */
+ /* matumoto@math.keio.ac.jp                                        */
+ 
++/* This library is free software; you can redistribute it and/or   */
++/* modify it under the terms of the GNU Library General Public     */
++/* License as published by the Free Software Foundation; either    */
++/* version 2 of the License, or (at your option) any later         */
++/* version.                                                        */
++/* This library is distributed in the hope that it will be useful, */
++/* but WITHOUT ANY WARRANTY; without even the implied warranty of  */
++/* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.            */
++/* See the GNU Library General Public License for more details.    */
++/* You should have received a copy of the GNU Library General      */
++/* Public License along with this library; if not, write to the    */
++/* Free Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA   */ 
++/* 02111-1307  USA                                                 */
++
++/* This library is free software under the Artistic license:       */
++
+ /* REFERENCE                                                       */
+ /* M. Matsumoto and T. Nishimura,                                  */
+ /* "Mersenne Twister: A 623-Dimensionally Equidistributed Uniform  */
diff --git a/helpers/make-db b/helpers/make-db
new file mode 100644
index 00000000..78d446e9
--- /dev/null
+++ b/helpers/make-db
@@ -0,0 +1,43 @@
+#!/bin/sh
+#
+#    Copyright (C) 2013  Rubén Rodríguez <ruben@trisquel.info>
+#
+#    This program is free software; you can redistribute it and/or modify
+#    it under the terms of the GNU General Public License as published by
+#    the Free Software Foundation; either version 2 of the License, or
+#    (at your option) any later version.
+#
+#    This program is distributed in the hope that it will be useful,
+#    but WITHOUT ANY WARRANTY; without even the implied warranty of
+#    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+#    GNU General Public License for more details.
+#
+#    You should have received a copy of the GNU General Public License
+#    along with this program; if not, write to the Free Software
+#    Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301 USA
+#
+
+VERSION=1
+QUILT=skip
+. ./config
+
+# This file is distributed from upstream Berkeley DB under the Artistic
+# License (no version specified), althouth it was later released by the
+# original author under both GPL2+ and BSD.
+# .
+# References:
+# http://web.archive.org/web/20010806225716/http://www.math.keio.ac.jp/matumoto/mt19937int.c
+# http://web.archive.org/web/20130127064020/http://www.math.sci.hiroshima-u.ac.jp/~m-mat/MT/MT2002/CODES/mt19937ar.c
+# https://bugzilla.redhat.com/show_bug.cgi?format=multiple&id=886838
+# https://lists.nongnu.org/archive/html/gnu-linux-libre/2010-05/msg00000.html
+
+cp $DATA/007-mt19937db.c_license.patch debian/patches
+echo 007-mt19937db.c_license.patch >> debian/patches/series
+
+export QUILT_PATCHES=debian/patches
+quilt push -a
+
+changelog "Update license to include GPL, fixes 5954"
+
+compile
+
diff --git a/helpers/make-db4.7 b/helpers/make-db4.7
new file mode 120000
index 00000000..29bb07d1
--- /dev/null
+++ b/helpers/make-db4.7
@@ -0,0 +1 @@
+make-db
\ No newline at end of file
diff --git a/helpers/make-db4.8 b/helpers/make-db4.8
new file mode 120000
index 00000000..29bb07d1
--- /dev/null
+++ b/helpers/make-db4.8
@@ -0,0 +1 @@
+make-db
\ No newline at end of file
-- 
GitLab