⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 zlib.m4

📁 这是linux下运行的mysql软件包,可用于linux 下安装 php + mysql + apach 的网络配置
💻 M4
字号:
dnl Define zlib paths to point at bundled zlibAC_DEFUN([MYSQL_USE_BUNDLED_ZLIB], [ZLIB_INCLUDES="-I\$(top_srcdir)/zlib"ZLIB_LIBS="\$(top_builddir)/zlib/libz.la"dnl Omit -L$pkglibdir as it's always in the list of mysql_config deps.ZLIB_DEPS="-lz"zlib_dir="zlib"AC_SUBST([zlib_dir])mysql_cv_compress="yes"])dnl Auxiliary macro to check for zlib at given pathAC_DEFUN([MYSQL_CHECK_ZLIB_DIR], [save_INCLUDES="$INCLUDES"save_LIBS="$LIBS"INCLUDES="$INCLUDES $ZLIB_INCLUDES"LIBS="$LIBS $ZLIB_LIBS"AC_CACHE_VAL([mysql_cv_compress],  [AC_TRY_LINK([#include <zlib.h>],    [return zlibCompileFlags();],    [mysql_cv_compress="yes"    AC_MSG_RESULT([ok])],    [mysql_cv_compress="no"])  ])INCLUDES="$save_INCLUDES"LIBS="$save_LIBS"])dnl MYSQL_CHECK_ZLIB_WITH_COMPRESSdnl ------------------------------------------------------------------------dnl @synopsis MYSQL_CHECK_ZLIB_WITH_COMPRESSdnldnl Provides the following configure options:dnl --with-zlib-dir=DIRdnl Possible DIR values are:dnl - "no" - the macro will disable use of compression functionsdnl - "bundled" - means use zlib bundled along with MySQL sourcesdnl - empty, or not specified - the macro will try default systemdnl   library (if present), and in case of error will fall back to dnl   bundled zlibdnl - zlib location prefix - given location prefix, the macro expectsdnl   to find the library headers in $prefix/include, and binaries indnl   $prefix/lib. If zlib headers or binaries weren't found at $prefix, thednl   macro bails out with error.dnl dnl If the library was found, this function #defines HAVE_COMPRESSdnl and configure variables ZLIB_INCLUDES (i.e. -I/path/to/zlib/include),dnl ZLIB_LIBS (i. e. -L/path/to/zlib/lib -lz) and ZLIB_DEPS which isdnl used in mysql_config and is always the same as ZLIB_LIBS except todnl when we use the bundled zlib. In the latter case ZLIB_LIBS points to thednl build dir ($top_builddir/zlib), while mysql_config must point to thednl installation dir ($pkglibdir), so ZLIB_DEPS is set to point todnl $pkglibdir.AC_DEFUN([MYSQL_CHECK_ZLIB_WITH_COMPRESS], [AC_MSG_CHECKING([for zlib compression library])case $SYSTEM_TYPE in*netware* | *modesto*)     AC_MSG_RESULT(ok)     AC_DEFINE([HAVE_COMPRESS], [1], [Define to enable compression support])    ;;  *)    AC_ARG_WITH([zlib-dir],                AC_HELP_STRING([--with-zlib-dir=DIR],                               [Provide MySQL with a custom location of                               compression library. Given DIR, zlib binary is                                assumed to be in $DIR/lib and header files                               in $DIR/include.]),                [mysql_zlib_dir=${withval}],                [mysql_zlib_dir=""])    case "$mysql_zlib_dir" in      "no")        mysql_cv_compress="no"        AC_MSG_RESULT([disabled])        ;;      "bundled")        MYSQL_USE_BUNDLED_ZLIB        AC_MSG_RESULT([using bundled zlib])        ;;      "")        ZLIB_INCLUDES=""        ZLIB_LIBS="-lz"        MYSQL_CHECK_ZLIB_DIR        if test "$mysql_cv_compress" = "no"; then          MYSQL_USE_BUNDLED_ZLIB          AC_MSG_RESULT([system-wide zlib not found, using one bundled with MySQL])        fi        ;;      *)        if test \( -f "$mysql_zlib_dir/lib/libz.a"  -o -f "$mysql_zlib_dir/lib/libz.so" -o \                   -f "$mysql_zlib_dir/lib/libz.sl" -o -f "$mysql_zlib_dir/lib/libz.dylib" \) \                -a -f "$mysql_zlib_dir/include/zlib.h"; then          ZLIB_INCLUDES="-I$mysql_zlib_dir/include"          ZLIB_LIBS="-L$mysql_zlib_dir/lib -lz"          MYSQL_CHECK_ZLIB_DIR        fi        if test "x$mysql_cv_compress" != "xyes"; then           AC_MSG_ERROR([headers or binaries were not found in $mysql_zlib_dir/{include,lib}])        fi        ;;    esac    if test "$mysql_cv_compress" = "yes"; then      if test "x$ZLIB_DEPS" = "x"; then        ZLIB_DEPS="$ZLIB_LIBS"      fi      AC_SUBST([ZLIB_LIBS])      AC_SUBST([ZLIB_DEPS])      AC_SUBST([ZLIB_INCLUDES])      AC_DEFINE([HAVE_COMPRESS], [1], [Define to enable compression support])    fi    ;;esac])dnl ------------------------------------------------------------------------

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -