From 48ba5e495666fd5db051c1a1aa9d4d61a85f07c0 Mon Sep 17 00:00:00 2001
From: "joerg@mysql.com" <>
Date: Wed, 20 Apr 2005 20:10:28 +0200
Subject: [PATCH] Step 1 of the switch to support configuration with NPTL:
 Rename 'IS_LINUX' configuration variable to 'TARGET_LINUX'.

---
 acinclude.m4              |  2 +-
 configure.in              | 18 +++++++++---------
 myisam/Makefile.am        |  2 +-
 scripts/Makefile.am       |  2 +-
 scripts/mysqld_safe.sh    |  2 +-
 support-files/Makefile.am |  2 +-
 6 files changed, 14 insertions(+), 14 deletions(-)

diff --git a/acinclude.m4 b/acinclude.m4
index 74426bc206..a81a4fa5c3 100644
--- a/acinclude.m4
+++ b/acinclude.m4
@@ -976,7 +976,7 @@ AC_DEFUN([MYSQL_FIND_OPENSSL], [
  if test -z "$OPENSSL_LIB" -o -z "$OPENSSL_INCLUDE" ; then
    echo "Could not find an installation of OpenSSL"
    if test -n "$OPENSSL_LIB" ; then
-    if test "$IS_LINUX" = "true"; then
+    if test "$TARGET_LINUX" = "true"; then
       echo "Looks like you've forgotten to install OpenSSL development RPM"
     fi
    fi
diff --git a/configure.in b/configure.in
index d191463d0f..6650c0fc64 100644
--- a/configure.in
+++ b/configure.in
@@ -410,15 +410,15 @@ AC_MSG_CHECKING("if we should use 'skip-locking' as default for $target_os")
 if expr "$target_os" : "[[Ll]]inux.*" > /dev/null
 then
   MYSQLD_DEFAULT_SWITCHES="--skip-locking"
-  IS_LINUX="true"
+  TARGET_LINUX="true"
   AC_MSG_RESULT("yes");
 else
   MYSQLD_DEFAULT_SWITCHES=""
-  IS_LINUX="false"
+  TARGET_LINUX="false"
   AC_MSG_RESULT("no");
 fi
 AC_SUBST(MYSQLD_DEFAULT_SWITCHES)
-AC_SUBST(IS_LINUX)
+AC_SUBST(TARGET_LINUX)
 
 dnl Find paths to some shell programs
 AC_PATH_PROG(LN, ln, ln)
@@ -607,7 +607,7 @@ AC_SUBST(NOINST_LDFLAGS)
 # (this is true on the MySQL build machines to avoid NSS problems)
 #
 
-if test "$IS_LINUX" = "true" -a "$static_nss" = ""
+if test "$TARGET_LINUX" = "true" -a "$static_nss" = ""
 then
   tmp=`nm /usr/lib/libc.a  | grep _nss_files_getaliasent_r`
   if test -n "$tmp"
@@ -841,7 +841,7 @@ struct request_info *req;
 ])
 AC_SUBST(WRAPLIBS)
 
-if test "$IS_LINUX" = "true"; then
+if test "$TARGET_LINUX" = "true"; then
   AC_MSG_CHECKING([for atomic operations])
 
   atom_ops=
@@ -885,7 +885,7 @@ int main()
     [ USE_PSTACK=no ])
   pstack_libs=
   pstack_dirs=
-  if test "$USE_PSTACK" = yes -a "$IS_LINUX" = "true" -a "$BASE_MACHINE_TYPE" = "i386" -a "$with_mit_threads" = "no"
+  if test "$USE_PSTACK" = yes -a "$TARGET_LINUX" = "true" -a "$BASE_MACHINE_TYPE" = "i386" -a "$with_mit_threads" = "no"
   then
     have_libiberty= have_libbfd=
     my_save_LIBS="$LIBS"
@@ -1286,7 +1286,7 @@ then
     else
       AC_MSG_RESULT("Not found")
       # If this is a linux machine we should barf
-      if test "$IS_LINUX" = "true"
+      if test "$TARGET_LINUX" = "true"
       then
 	AC_MSG_ERROR([This is a linux system and Linuxthreads was not
 found. On linux Linuxthreads should be used.  Please install Linuxthreads
@@ -1738,7 +1738,7 @@ fi
 AC_SUBST(COMPILATION_COMMENT)
 
 AC_MSG_CHECKING("need of special linking flags")
-if test "$IS_LINUX" = "true" -a "$ac_cv_prog_gcc" = "yes" -a "$all_is_static" != "yes"
+if test "$TARGET_LINUX" = "true" -a "$ac_cv_prog_gcc" = "yes" -a "$all_is_static" != "yes"
 then
   LDFLAGS="$LDFLAGS -rdynamic"
   AC_MSG_RESULT("-rdynamic")
@@ -1955,7 +1955,7 @@ CFLAGS="$ORG_CFLAGS"
 # Sanity check: We chould not have any fseeko symbol unless
 # large_file_support=yes
 AC_CHECK_FUNC(fseeko,
-[if test "$large_file_support" = no -a "$IS_LINUX" = "true";
+[if test "$large_file_support" = no -a "$TARGET_LINUX" = "true";
 then
   AC_MSG_ERROR("Found fseeko symbol but large_file_support is not enabled!");
 fi]
diff --git a/myisam/Makefile.am b/myisam/Makefile.am
index 378e810781..0b8a25e340 100644
--- a/myisam/Makefile.am
+++ b/myisam/Makefile.am
@@ -88,7 +88,7 @@ SUFFIXES = .sh
 	  -e 's!@''FIND_PROC''@!@FIND_PROC@!' \
 	  -e 's!@''MYSQLD_DEFAULT_SWITCHES''@!@MYSQLD_DEFAULT_SWITCHES@!' \
 	  -e 's!@''MYSQL_UNIX_ADDR''@!@MYSQL_UNIX_ADDR@!' \
-	  -e 's!@''IS_LINUX''@!@IS_LINUX@!' \
+	  -e 's!@''TARGET_LINUX''@!@TARGET_LINUX@!' \
 	  -e "s!@""CONF_COMMAND""@!@CONF_COMMAND@!" \
 	  -e 's!@''MYSQLD_USER''@!@MYSQLD_USER@!' \
 	  -e 's!@''sysconfdir''@!@sysconfdir@!' \
diff --git a/scripts/Makefile.am b/scripts/Makefile.am
index b170fa483b..e2ef1bba97 100644
--- a/scripts/Makefile.am
+++ b/scripts/Makefile.am
@@ -135,7 +135,7 @@ SUFFIXES = .sh
 	  -e 's!@''MYSQLD_DEFAULT_SWITCHES''@!@MYSQLD_DEFAULT_SWITCHES@!' \
 	  -e 's!@''MYSQL_UNIX_ADDR''@!@MYSQL_UNIX_ADDR@!' \
 	  -e 's!@''MYSQL_TCP_PORT''@!@MYSQL_TCP_PORT@!' \
-	  -e 's!@''IS_LINUX''@!@IS_LINUX@!' \
+	  -e 's!@''TARGET_LINUX''@!@TARGET_LINUX@!' \
 	  -e "s!@""CONF_COMMAND""@!@CONF_COMMAND@!" \
 	  -e 's!@''MYSQLD_USER''@!@MYSQLD_USER@!' \
 	  -e 's!@''STATIC_NSS_FLAGS''@!@STATIC_NSS_FLAGS@!' \
diff --git a/scripts/mysqld_safe.sh b/scripts/mysqld_safe.sh
index 308db27082..8a232f4f7f 100644
--- a/scripts/mysqld_safe.sh
+++ b/scripts/mysqld_safe.sh
@@ -324,7 +324,7 @@ do
     break
   fi
 
-  if @IS_LINUX@ && test $KILL_MYSQLD -eq 1
+  if @TARGET_LINUX@ && test $KILL_MYSQLD -eq 1
   then
     # Test if one process was hanging.
     # This is only a fix for Linux (running as base 3 mysqld processes)
diff --git a/support-files/Makefile.am b/support-files/Makefile.am
index 0a6077f0ef..5f5a10fc1f 100644
--- a/support-files/Makefile.am
+++ b/support-files/Makefile.am
@@ -90,7 +90,7 @@ SUFFIXES = .sh
 	  -e 's!@''FIND_PROC''@!@FIND_PROC@!' \
 	  -e 's!@''MYSQLD_DEFAULT_SWITCHES''@!@MYSQLD_DEFAULT_SWITCHES@!' \
 	  -e 's!@''MYSQL_UNIX_ADDR''@!@MYSQL_UNIX_ADDR@!' \
-	  -e 's!@''IS_LINUX''@!@IS_LINUX@!' \
+	  -e 's!@''TARGET_LINUX''@!@TARGET_LINUX@!' \
 	  -e "s!@""CONF_COMMAND""@!@CONF_COMMAND@!" \
 	  -e 's!@''MYSQLD_USER''@!@MYSQLD_USER@!' \
 	  -e 's!@''sysconfdir''@!@sysconfdir@!' \
-- 
2.30.9