Don't install in mysql directory
Installing libraries in a subdirectory of /usr/lib leads to no end of
trouble. It requires either setting a RUN_PATH in the ELF files linked
with it or adding the path to ld.so.conf and calling ldconfig on the
So to simplify things, put everything in /usr/lib instead of
Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
diff -Nrup mysql-5.1.73.orig/dbug/Makefile.am mysql-5.1.73/dbug/Makefile.am
--- mysql-5.1.73.orig/dbug/Makefile.am 2013-11-04 19:52:27.000000000 +0100
+++ mysql-5.1.73/dbug/Makefile.am 2015-12-14 00:34:58.567937603 +0100
INCLUDES = -I$(top_builddir)/include -I$(top_srcdir)/include
LDADD = libdbug.a ../mysys/libmysys.a ../strings/libmystrings.a
-pkglib_LIBRARIES = libdbug.a
+lib_LIBRARIES = libdbug.a
noinst_HEADERS = dbug_long.h
libdbug_a_SOURCES = dbug.c sanity.c
EXTRA_DIST = CMakeLists.txt example1.c example2.c example3.c \
diff -Nrup mysql-5.1.73.orig/libmysql/Makefile.shared mysql-5.1.73/libmysql/Makefile.shared
--- mysql-5.1.73.orig/libmysql/Makefile.shared 2013-11-04 19:52:27.000000000 +0100
+++ mysql-5.1.73/libmysql/Makefile.shared 2015-12-14 00:34:58.567937603 +0100
@@ -25,7 +25,7 @@ MYSQLBASEdir= $(prefix)
## We'll use CLIENT_EXTRA_LDFLAGS for threaded and non-threaded
## until someone complains that they need separate options.
LDADD = @CLIENT_EXTRA_LDFLAGS@ $(target)
-pkglib_LTLIBRARIES = $(target)
+lib_LTLIBRARIES = $(target)
noinst_PROGRAMS = conf_to_src
diff -Nrup mysql-5.1.73.orig/libmysqld/Makefile.am mysql-5.1.73/libmysqld/Makefile.am
--- mysql-5.1.73.orig/libmysqld/Makefile.am 2013-11-04 19:52:27.000000000 +0100
+++ mysql-5.1.73/libmysqld/Makefile.am 2015-12-14 00:34:58.567937603 +0100
@@ -38,7 +38,7 @@ INCLUDES= -I$(top_builddir)/include -I$
@condition_dependent_plugin_includes@
noinst_LIBRARIES = libmysqld_int.a
-pkglib_LIBRARIES = libmysqld.a
+lib_LIBRARIES = libmysqld.a
libmysqld_sources= libmysqld.c lib_sql.cc emb_qcache.cc
libmysqlsources = errmsg.c get_password.c libmysql.c client.c pack.c \
diff -Nrup mysql-5.1.73.orig/mysys/Makefile.am mysql-5.1.73/mysys/Makefile.am
--- mysql-5.1.73.orig/mysys/Makefile.am 2013-11-04 19:52:27.000000000 +0100
+++ mysql-5.1.73/mysys/Makefile.am 2015-12-14 00:34:58.567937603 +0100
@@ -18,7 +18,7 @@ MYSQLSHAREdir = $(pkgdatadir)
INCLUDES = @ZLIB_INCLUDES@ -I$(top_builddir)/include \
-I$(top_srcdir)/include -I$(srcdir)
-pkglib_LIBRARIES = libmysys.a
+lib_LIBRARIES = libmysys.a
LDADD = libmysys.a $(top_builddir)/strings/libmystrings.a $(top_builddir)/dbug/libdbug.a
noinst_HEADERS = mysys_priv.h my_static.h my_handler_errors.h
libmysys_a_SOURCES = my_init.c my_getwd.c mf_getdate.c my_mmap.c \
diff -Nrup mysql-5.1.73.orig/storage/csv/Makefile.am mysql-5.1.73/storage/csv/Makefile.am
--- mysql-5.1.73.orig/storage/csv/Makefile.am 2013-11-04 19:52:27.000000000 +0100
+++ mysql-5.1.73/storage/csv/Makefile.am 2015-12-14 00:34:58.563937596 +0100