[pkg-bacula-commits] [bacula] 01/01: Fix MySQL database creation via dbconfig-common (Closes: #830999)

Sven Hartge hartge-guest at moszumanska.debian.org
Thu Jul 14 09:31:09 UTC 2016


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

hartge-guest pushed a commit to branch master-systemd
in repository bacula.

commit 8d89c9e08f78cea07c98406c32bce977eb9c017c
Author: Carsten Leonhardt <leo at debian.org>
Date:   Thu Jul 14 01:13:09 2016 +0200

    Fix MySQL database creation via dbconfig-common (Closes: #830999)
---
 debian/changelog                                   |  8 +++++++-
 .../remove-use-statement-in-make-mysql-tables      | 22 ++++++++++++++++++++++
 debian/patches/series                              |  1 +
 3 files changed, 30 insertions(+), 1 deletion(-)

diff --git a/debian/changelog b/debian/changelog
index 6c09792..139ab57 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,4 +1,4 @@
-bacula (7.4.2+dfsg-2) experimental; urgency=medium
+bacula (7.4.2+dfsg-3) experimental; urgency=medium
 
   [ Sven Hartge ] 
   * Enable systemd integration
@@ -6,6 +6,12 @@ bacula (7.4.2+dfsg-2) experimental; urgency=medium
 
  -- Sven Hartge <sven at svenhartge.de>  Tue, 12 Jul 2016 21:35:28 +0200
 
+bacula (7.4.2+dfsg-2) unstable; urgency=medium
+
+  * Fix MySQL database creation via dbconfig-common (Closes: #830999)
+
+ --
+
 bacula (7.4.2+dfsg-1) unstable; urgency=low
 
   * New upstream release
diff --git a/debian/patches/remove-use-statement-in-make-mysql-tables b/debian/patches/remove-use-statement-in-make-mysql-tables
new file mode 100644
index 0000000..dfa3c71
--- /dev/null
+++ b/debian/patches/remove-use-statement-in-make-mysql-tables
@@ -0,0 +1,22 @@
+Description: Fix MySQL database creation via dbconfig-common
+ dbconfig-common uses its own scheme for telling MySQL which database
+ name is to be used, so we switch from using "USE" to passing -D to
+ the call to mysql. This way the USE statement does not end up in the
+ data for dbconfig-common.
+ This fix is specific to Debian packaging and could also be solved by
+ improving/replacing debian/scripts/install-dbconfig
+Author: Carsten Leonhardt <leo at debian.org>
+Bug-Debian: 830999
+Last-Update: 2016-07-14
+--- a/src/cats/make_mysql_tables.in
++++ b/src/cats/make_mysql_tables.in
+@@ -13,8 +13,7 @@
+ PATH="$bindir:$PATH"
+ db_name=${db_name:- at db_name@}
+ 
+-if mysql $* -f <<END-OF-DATA
+-USE ${db_name};
++if mysql -D ${db_name} $* -f <<END-OF-DATA
+ --
+ -- Note, we use BLOB rather than TEXT because in MySQL,
+ --  BLOBs are identical to TEXT except that BLOB is case
diff --git a/debian/patches/series b/debian/patches/series
index a58866a..9d57234 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -8,3 +8,4 @@ fix-libbaccats-rpath.patch
 fix-scriptdir-examples-devices.patch
 enable-hardening-for-bat.patch
 non-forking-systemd-units.patch
+remove-use-statement-in-make-mysql-tables

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-bacula/bacula.git



More information about the pkg-bacula-commits mailing list