summaryrefslogtreecommitdiff
path: root/support-files/mysql.spec.sh
diff options
context:
space:
mode:
Diffstat (limited to 'support-files/mysql.spec.sh')
-rw-r--r--support-files/mysql.spec.sh14
1 files changed, 11 insertions, 3 deletions
diff --git a/support-files/mysql.spec.sh b/support-files/mysql.spec.sh
index 81ee0c52eea..1409b8905b4 100644
--- a/support-files/mysql.spec.sh
+++ b/support-files/mysql.spec.sh
@@ -188,9 +188,17 @@ sh -c "PATH=\"${MYSQL_BUILD_PATH:-/bin:/usr/bin}\" \
make benchdir_root=$RPM_BUILD_ROOT/usr/share/
}
-# Use the build root for temporary storage of the shared libraries.
+# Use our own copy of glibc
OTHER_LIBC_DIR=/usr/local/mysql-glibc
+USE_OTHER_LIBC_DIR=""
+if test -d "OTHER_LIBC_DIR"
+then
+ USE_OTHER_LIBC_DIR="--with-other-libc=$OTHER_LIBC_DIR"
+fi
+
+# Use the build root for temporary storage of the shared libraries.
+
RBR=$RPM_BUILD_ROOT
MBD=$RPM_BUILD_DIR/mysql-%{mysql_version}
if test -z "$RBR" -o "$RBR" = "/"
@@ -204,7 +212,7 @@ mkdir -p $RBR
# We need to build shared libraries separate from mysqld-max because we
# are using --with-other-libc
-BuildMySQL "--disable-shared --with-other-libc=$OTHER_LIBC_DIR --with-berkeley-db --with-innodb --with-mysqld-ldflags='-all-static' --with-server-suffix='-Max'"
+BuildMySQL "--disable-shared $USE_OTHER_LIBC_DIR --with-berkeley-db --with-innodb --with-mysqld-ldflags='-all-static' --with-server-suffix='-Max'"
# Save everything for debug
# tar cf $RBR/all.tar .
@@ -234,7 +242,7 @@ automake
BuildMySQL "--disable-shared" \
"--with-mysqld-ldflags='-all-static'" \
"--with-client-ldflags='-all-static'" \
- "--with-other-libc=$OTHER_LIBC_DIR" \
+ "$USE_OTHER_LIBC_DIR" \
"--without-berkeley-db --without-innodb"
nm --numeric-sort sql/mysqld > sql/mysqld.sym