7fad07b
Upstream chooses to install INFO_SRC and INFO_BIN into the docs dir, which
7fad07b
breaks at least two packaging commandments, so we put them into $libdir
7fad07b
instead.  That means we have to hack the file_contents regression test
7fad07b
to know about this.
7fad07b
7fad07b
Recommendation they change is at http://bugs.mysql.com/bug.php?id=61425
7fad07b
a4a6473
diff --git a/mysql-test/t/file_contents.test b/mysql-test/t/file_contents.test
a4a6473
index 75f8c93..973291c 100644
a4a6473
--- a/mysql-test/t/file_contents.test
a4a6473
+++ b/mysql-test/t/file_contents.test
a4a6473
@@ -12,7 +12,7 @@
c48a49a
 --perl
c48a49a
 print "\nChecking 'INFO_SRC' and 'INFO_BIN'\n";
c48a49a
 $dir_bin = $ENV{'MYSQL_BINDIR'};
a4a6473
-if ($dir_bin =~ m|^/usr/|) {
c48a49a
+if ($dir_bin =~ m|.*/usr/$|) {
c48a49a
   # RPM package
c48a49a
   $dir_docs = $dir_bin;
c48a49a
   $dir_docs =~ s|/lib|/share/doc|;
a4a6473
@@ -35,7 +35,7 @@ if ($dir_bin =~ m|^/usr/|) {
Jakub Dorňák 891c072
       }
c48a49a
     }
c48a49a
   }
c48a49a
-} elsif ($dir_bin =~ m|/usr$|) {
c48a49a
+} elsif ($dir_bin =~ m|.*/usr$|) {
c48a49a
   # RPM build during development
c48a49a
   $dir_docs = "$dir_bin/share/doc";
c48a49a
   if(-d "$dir_docs/packages") {
a4a6473
@@ -55,6 +55,15 @@ if ($dir_bin =~ m|^/usr/|) {
a4a6473
         $dir_docs = glob "$dir_bin/share/mysql-*/docs";
Jakub Dorňák 891c072
       }
1d21d16
     }
c48a49a
+
7a5573f
+    # All the above is entirely wacko, because these files are not docs;
7a5573f
+    # they should be kept in libdir instead.  mtr does not provide a nice
7a5573f
+    # way to find libdir though, so we have to kluge it like this:
c48a49a
+    if (-d "$dir_bin/lib64/mysql") {
c48a49a
+       $dir_docs = "$dir_bin/lib64/mysql";
7a5573f
+    } else {
c48a49a
+       $dir_docs = "$dir_bin/lib/mysql";
7a5573f
+    }
7a5573f
   }
7a5573f
 } else {
Bjorn Munch 3266fef
   # tar.gz package, Windows, or developer work (in git)