mariadb: update libdir for libtool
authorHongxu Jia <hongxu.jia@windriver.com>
Wed, 9 Oct 2013 07:30:34 +0000 (07:30 +0000)
committerPatrick Ohly <patrick.ohly@intel.com>
Fri, 9 Jan 2015 16:33:50 +0000 (08:33 -0800)
In mariadb recipe,do_install move all the lib files from usr/lib/mysql
to usr/lib,but didn't change libdir value in *.la libtool file. This
will cause libtool can't get correct lib path of mysql when other
package need mysql lib.So update them to correct value.

Here is a exapmle:
In libmysqlclient.la file: libdir = "/usr/lib/mysq/", but in fact
libmysqclient.so is installed into  "/usr/lib", this will cause
libtool can not find correct lib file with libmysqlclient.la, then
libtool will use rpath option to reference a absolute path, and
this will cause rpath WARING and rpm error.

(From meta-openembedded rev: 8a5dc53b66b4ab1b71e96e80dfe7912675fbfb76)

Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
Signed-off-by: Patrick Ohly <patrick.ohly@intel.com>
meta-openembedded/meta-oe/recipes-support/mysql/mariadb_5.1.67.inc

index c535a41..fd9264f 100644 (file)
@@ -80,6 +80,7 @@ do_install() {
     oe_runmake 'DESTDIR=${D}' install
     mv -f ${D}${libdir}/mysql/* ${D}${libdir}
     rmdir ${D}${libdir}/mysql
+    find ${D}${libdir} -name '*.la'|xargs sed -i 's#${libdir}/mysql#${libdir}#'
 
     install -d ${D}/etc/init.d
     install -m 0644 ${WORKDIR}/my.cnf ${D}/etc/