diff options
| -rw-r--r-- | meta-oe/recipes-support/mysql/mariadb/zlib-let-libdir-configurable.patch | 63 | ||||
| -rw-r--r-- | meta-oe/recipes-support/mysql/mariadb_5.1.67.inc | 2 |
2 files changed, 65 insertions, 0 deletions
diff --git a/meta-oe/recipes-support/mysql/mariadb/zlib-let-libdir-configurable.patch b/meta-oe/recipes-support/mysql/mariadb/zlib-let-libdir-configurable.patch new file mode 100644 index 0000000000..880c2a717a --- /dev/null +++ b/meta-oe/recipes-support/mysql/mariadb/zlib-let-libdir-configurable.patch | |||
| @@ -0,0 +1,63 @@ | |||
| 1 | zlib: let lib dir configurable | ||
| 2 | |||
| 3 | The zlib were found in $mysql_zlib_dir/lib, and the | ||
| 4 | search will fail if zlib in $mysql_zlib_dir/lib64. | ||
| 5 | |||
| 6 | Let lib dir configurable rather than hardcode. | ||
| 7 | |||
| 8 | Upstream-Status: Pending | ||
| 9 | Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com> | ||
| 10 | --- | ||
| 11 | config/ac-macros/zlib.m4 | 12 ++++++------ | ||
| 12 | configure.in | 8 ++++++++ | ||
| 13 | 2 files changed, 14 insertions(+), 6 deletions(-) | ||
| 14 | |||
| 15 | diff --git a/config/ac-macros/zlib.m4 b/config/ac-macros/zlib.m4 | ||
| 16 | --- a/config/ac-macros/zlib.m4 | ||
| 17 | +++ b/config/ac-macros/zlib.m4 | ||
| 18 | @@ -106,17 +106,17 @@ case $SYSTEM_TYPE in | ||
| 19 | ;; | ||
| 20 | *) | ||
| 21 | # Test for libz using all known library file endings | ||
| 22 | - if test \( -f "$mysql_zlib_dir/lib/libz.a" -o \ | ||
| 23 | - -f "$mysql_zlib_dir/lib/libz.so" -o \ | ||
| 24 | - -f "$mysql_zlib_dir/lib/libz.sl" -o \ | ||
| 25 | - -f "$mysql_zlib_dir/lib/libz.dylib" \) \ | ||
| 26 | + if test \( -f "$mysql_zlib_dir/$base_libdir/libz.a" -o \ | ||
| 27 | + -f "$mysql_zlib_dir/$base_libdir/libz.so" -o \ | ||
| 28 | + -f "$mysql_zlib_dir/$base_libdir/libz.sl" -o \ | ||
| 29 | + -f "$mysql_zlib_dir/$base_libdir/libz.dylib" \) \ | ||
| 30 | -a -f "$mysql_zlib_dir/include/zlib.h"; then | ||
| 31 | ZLIB_INCLUDES="-I$mysql_zlib_dir/include" | ||
| 32 | - ZLIB_LIBS="-L$mysql_zlib_dir/lib -lz" | ||
| 33 | + ZLIB_LIBS="-L$mysql_zlib_dir/$base_libdir -lz" | ||
| 34 | MYSQL_CHECK_ZLIB_DIR | ||
| 35 | fi | ||
| 36 | if test "x$mysql_cv_compress" != "xyes"; then | ||
| 37 | - AC_MSG_ERROR([headers or binaries were not found in $mysql_zlib_dir/{include,lib}]) | ||
| 38 | + AC_MSG_ERROR([headers or binaries were not found in $mysql_zlib_dir/{include,$base_libdir}]) | ||
| 39 | fi | ||
| 40 | ;; | ||
| 41 | esac | ||
| 42 | diff --git a/configure.in b/configure.in | ||
| 43 | index 2c6c08e..193b59a 100644 | ||
| 44 | --- a/configure.in | ||
| 45 | +++ b/configure.in | ||
| 46 | @@ -104,6 +104,14 @@ AC_SUBST(SHARED_LIB_MAJOR_VERSION) | ||
| 47 | AC_SUBST(SHARED_LIB_VERSION) | ||
| 48 | AC_SUBST(AVAILABLE_LANGUAGES) | ||
| 49 | |||
| 50 | +AC_ARG_WITH([baselib-dir], | ||
| 51 | + AC_HELP_STRING([--baselib-dir=DIR], | ||
| 52 | + [Provide MySQL with a custom location of | ||
| 53 | + baselib dir. Given DIR, such as zlib binary is | ||
| 54 | + assumed to be in $zlib-dir/$DIR.]), | ||
| 55 | + [base_libdir=${withval}], | ||
| 56 | + [base_libdir="lib"]) | ||
| 57 | + | ||
| 58 | # Check whether a debug mode should be enabled. | ||
| 59 | AC_ARG_WITH([debug], | ||
| 60 | AS_HELP_STRING([--with-debug@<:@=full@:>@], | ||
| 61 | -- | ||
| 62 | 1.8.1.2 | ||
| 63 | |||
diff --git a/meta-oe/recipes-support/mysql/mariadb_5.1.67.inc b/meta-oe/recipes-support/mysql/mariadb_5.1.67.inc index fd9264fd05..98d135f5f6 100644 --- a/meta-oe/recipes-support/mysql/mariadb_5.1.67.inc +++ b/meta-oe/recipes-support/mysql/mariadb_5.1.67.inc | |||
| @@ -15,6 +15,7 @@ SRC_URI = "http://mirrors.coreix.net/mariadb/mariadb-${PV}/kvm-tarbake-jaunty-x8 | |||
| 15 | file://configure-ps-cache-check.patch \ | 15 | file://configure-ps-cache-check.patch \ |
| 16 | file://fix-cve-2013-1861-1.patch \ | 16 | file://fix-cve-2013-1861-1.patch \ |
| 17 | file://fix-cve-2013-1861-2.patch \ | 17 | file://fix-cve-2013-1861-2.patch \ |
| 18 | file://zlib-let-libdir-configurable.patch \ | ||
| 18 | file://my.cnf \ | 19 | file://my.cnf \ |
| 19 | file://mysqld.sh" | 20 | file://mysqld.sh" |
| 20 | 21 | ||
| @@ -51,6 +52,7 @@ EXTRA_OECONF = "--with-atomic-ops=up \ | |||
| 51 | --without-man \ | 52 | --without-man \ |
| 52 | --without-docs \ | 53 | --without-docs \ |
| 53 | --with-zlib-dir=${STAGING_EXECPREFIXDIR} \ | 54 | --with-zlib-dir=${STAGING_EXECPREFIXDIR} \ |
| 55 | --with-baselib-dir=${base_libdir} \ | ||
| 54 | --with-pic \ | 56 | --with-pic \ |
| 55 | " | 57 | " |
| 56 | 58 | ||
