summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--configure.in15
-rw-r--r--include/global.h13
-rw-r--r--support-files/mysql.spec.sh24
3 files changed, 44 insertions, 8 deletions
diff --git a/configure.in b/configure.in
index 807de749b73..f0c2d30c035 100644
--- a/configure.in
+++ b/configure.in
@@ -359,6 +359,9 @@ else
*darwin*)
FIND_PROC="$PS -uaxww | grep mysqld | grep \" \$\$PID \" > /dev/null"
;;
+ *cygwin*)
+ FIND_PROC="$PS -e | grep mysqld | grep \" \$\$PID \" > /dev/null"
+ ;;
*)
AC_MSG_ERROR([Could not find the right ps switches. Which OS is this ?. See the Installation chapter in the Reference Manual.])
esac
@@ -795,6 +798,15 @@ case $SYSTEM_TYPE in
CFLAGS="$CFLAGS -Wa,-many -DUNDEF_HAVE_INITGROUPS"
CXXFLAGS="$CXXFLAGS -Wa,-many -DUNDEF_HAVE_INITGROUPS"
;;
+dnl Is this the right match for DEC OSF on alpha?
+ *dec-osf*)
+ if test "$ac_cv_prog_gcc" = "yes" && test "$host_cpu" = "alpha"
+ then
+ echo "Adding defines for DEC OSF on alpha"
+ CFLAGS="$CFLAGS -mieee"
+ CXXFLAGS="$CXXFLAGS -mieee"
+ fi
+ ;;
esac
@@ -1605,10 +1617,11 @@ AC_ARG_WITH(bench,
if test "$with_bench" = "yes"
then
- bench_dirs="sql-bench mysql-test"
+ bench_dirs="sql-bench"
else
bench_dirs=""
fi
+bench_dirs="$bench_dirs mysql-test"
AC_SUBST(bench_dirs)
# Don't build readline, i have it already
diff --git a/include/global.h b/include/global.h
index 2ad4a1387a9..2c9157630f4 100644
--- a/include/global.h
+++ b/include/global.h
@@ -28,6 +28,19 @@
#include <os2.h>
#endif /* __EMX__ */
+#ifdef __CYGWIN__
+/* We use a Unix API, so pretend it's not Windows */
+#undef WIN
+#undef WIN32
+#undef _WIN
+#undef _WIN32
+#undef _WIN64
+#undef __WIN__
+#undef __WIN32__
+#define HAVE_ERRNO_AS_DEFINE
+#endif /* __CYGWIN__ */
+
+
#if defined(_WIN32) || defined(_WIN64) || defined(__WIN32__) || defined(WIN32)
#include <config-win.h>
#else
diff --git a/support-files/mysql.spec.sh b/support-files/mysql.spec.sh
index 975c4583a03..f3775779746 100644
--- a/support-files/mysql.spec.sh
+++ b/support-files/mysql.spec.sh
@@ -135,7 +135,7 @@ Obsoletes: mysql-Max
%description Max
Extra MySQL server binary to get support extra features like
-transactional tables. To active these features on only have to install
+transactional tables. To active these features one only has to install
this package after the server package.
%prep
@@ -298,15 +298,25 @@ chmod -R og-rw $mysql_datadir/mysql
# Allow safe_mysqld to start mysqld and print a message before we exit
sleep 2
+%post Max
+# Restart mysqld, to use the new binary.
+# There may be a better way to handle this.
+/etc/rc.d/init.d/mysql stop > /dev/null 2>&1
+echo "Giving mysqld a couple of seconds to restart"
+sleep 5
+/etc/rc.d/init.d/mysql start
+sleep 2
+
%preun
-if test -x /etc/rc.d/init.d/mysql
-then
- /etc/rc.d/init.d/mysql stop > /dev/null
-fi
-# Remove autostart of mysql
if test $1 = 0
then
- /sbin/chkconfig --del mysql
+ if test -x /etc/rc.d/init.d/mysql
+ then
+ /etc/rc.d/init.d/mysql stop > /dev/null
+ fi
+
+ # Remove autostart of mysql
+ /sbin/chkconfig --del mysql
fi
# We do not remove the mysql user since it may still own a lot of
# database files.