"Fossies" - the Fresh Open Source Software Archive

Member "ftwin-master/acinclude.m4" (15 Feb 2015, 7587 Bytes) of package /linux/privat/ftwin-master.tar.gz:


As a special service "Fossies" has tried to format the requested text file into HTML format (style: standard) with prefixed line numbers. Alternatively you can here view or download the uninterpreted source code file.

    1 AC_DEFUN([APR_CONFIG_CHECK],[
    2 	AC_ARG_WITH( apr-config, AC_HELP_STRING([--with-apr-config=PATH], [prefix where libapr is installed default=auto]), [apr_config=$withval],[apr_config=])
    3 	if test "x$apr_config" != "x"
    4 	    then
    5 	    # If we passed a apr-config
    6 	    if test -f $apr_config
    7 	        then
    8 	        APR_CFLAGS="`$apr_config --cflags` -DHAVE_APR" 
    9 	        APR_CPPFLAGS="`$apr_config --cppflags --includes`"
   10 	        APR_LTLIBS="`$apr_config --libs --link-libtool`"
   11 	        APR_LIBS="`$apr_config --libs --link-ld`"
   12 	    else
   13 		AC_MSG_ERROR([apr-config program not found (1), please make sure you installed devel files for libapr])
   14 	    fi
   15 	else
   16 	    # else check apr install with apr-config
   17 	    AC_PATH_PROG(apr_config, apr-config)
   18 	    if test "x$apr_config" != "x"
   19 		then
   20 		APR_CFLAGS="`$apr_config --cflags` -DHAVE_APR" 
   21 		APR_CPPFLAGS="`$apr_config --cppflags --includes`"
   22 		APR_LTLIBS="`$apr_config --libs --link-libtool`"
   23 		APR_LIBS="`$apr_config --libs --link-ld`"
   24 	    else
   25 		# Try a mandriva standard name
   26 		AC_PATH_PROG(apr_config, apr-1-config)
   27 		if test "x$apr_config" != "x"
   28 		    then
   29 		    APR_CFLAGS="`$apr_config --cflags` -DHAVE_APR" 
   30 		    APR_CPPFLAGS="`$apr_config --cppflags --includes`"
   31 		    APR_LTLIBS="`$apr_config --libs --link-libtool`"
   32 		    APR_LIBS="`$apr_config --libs --link-ld`"
   33 		else
   34 		    AC_MSG_ERROR([apr-config program not found (2), please make sure you installed devel files for libapr])
   35 		fi
   36 	    fi
   37 	fi
   38 
   39 	AC_SUBST([apr_config])
   40 	AC_SUBST([APR_CFLAGS])
   41 	AC_SUBST([APR_CPPFLAGS])
   42 	AC_SUBST([APR_LTLIBS])
   43 	AC_SUBST([APR_LIBS])
   44 
   45     ])
   46 
   47 AC_DEFUN([APR_UTIL_CONFIG_CHECK], [
   48 	AC_ARG_WITH( apr-util-config, AC_HELP_STRING([--with-apr-util-config=PATH], [prefix where apu-config is installed default=auto]), [apr_util_config=$withval],[apr_util_config=])
   49 
   50 	if test "x$apr_util_config" != "x"
   51 	    then
   52 	    # If we passed a apr-util-config
   53 	    if test -f $apr_util_config
   54 	        then
   55 		APU_LTLIBS="`$apr_util_config --libs --link-libtool`"
   56 		APU_LIBS="`$apr_util_config --libs --link-ld`"
   57 	    else
   58 		AC_MSG_ERROR([apu-config program not found (1), please make sure you installed devel files for libaprutil])
   59 	    fi
   60 	else
   61 	    AC_PATH_PROG(apr_util_config, apu-config)
   62 	    if test "x$apr_util_config" != "x"
   63 		then
   64 		APU_LTLIBS="`$apr_util_config --libs --link-libtool`"
   65 		APU_LIBS="`$apr_util_config --libs --link-ld`"
   66 	    else
   67 		# else check apr install with apr-config
   68 		AC_PATH_PROG(apr_util_config, apu-1-config)
   69 		if test "x$apr_util_config" != "x"
   70 		    then
   71 		    APU_LTLIBS="`$apr_util_config --libs --link-libtool`"
   72 		    APU_LIBS="`$apr_util_config --libs --link-ld`"
   73 		else
   74 		    AC_MSG_ERROR([apu-config program not found (2), please make sure you installed devel files for libaprutil])
   75 		fi
   76 	    fi
   77 	fi
   78 	AC_SUBST([APU_LTLIBS])
   79 	AC_SUBST([APU_LIBS])
   80 
   81     ])
   82 
   83 AC_DEFUN([PATH_DOXYGEN],[
   84 	AC_ARG_VAR([DOXYGEN], [Full path to doxygen binary.])
   85 	AC_PATH_PROG([DOXYGEN], [doxygen],,)
   86 
   87 	if test "x$DOXYGEN" = 'x'; then
   88 	    AC_MSG_WARN([*** doxygen not found, docs will not be available])
   89 	fi
   90 
   91 	AM_CONDITIONAL(HAVE_DOXYGEN, test "x$DOXYGEN" != 'x')
   92 
   93 	AC_SUBST([DOXYGEN])
   94 	])
   95 
   96 AC_DEFUN([PATH_DOT],[
   97 	AC_ARG_VAR([DOT], [Full path to dot binary.])
   98 	AC_PATH_PROG([DOT], [dot],,)
   99 
  100 	if test "x$DOT" = 'x'; then
  101 	    AC_MSG_WARN([*** dot not found, graphs will not be available. Please install graphviz wich includes dot.])
  102 	    HAVE_DOT="NO"
  103 	else
  104 	    HAVE_DOT="YES"
  105 	fi
  106 
  107 	AC_SUBST([DOT])
  108 	AC_SUBST([HAVE_DOT])
  109 	])
  110 
  111 #
  112 # PCRE_CHECK
  113 #
  114 AC_DEFUN([PCRE_CONFIG_CHECK],[
  115 	AC_ARG_WITH( pcre-config, AC_HELP_STRING([--with-pcre-config=PATH], [prefix where libpcre is installed default=auto]), [pcre_config=$withval],[pcre_config=])
  116 	if test "x$pcre_config" != "x"
  117 	    then
  118 	    # If we passed a pcre-config
  119 	    if test -f $pcre_config
  120 		then
  121 		PCRE_CFLAGS="`$pcre_config --cflags`"
  122 		PCRE_LIBS="`$pcre_config --libs`"
  123 	    else
  124 		AC_MSG_ERROR([pcre-config program not found (1), please make sure you installed devel files for libpcre])
  125 	    fi
  126 	else
  127 	    # else check pcre install with pcre-config
  128 	    AC_PATH_PROG(pcre_config, pcre-config)
  129 	    if test "x$pcre_config" != "x"
  130 		then
  131 		PCRE_CFLAGS="`$pcre_config --cflags`"
  132 		PCRE_LIBS="`$pcre_config --libs`"
  133 	    else
  134 		AC_MSG_ERROR([pcre-config program not found (2), please make sure you installed devel files for libpcre])
  135 	    fi
  136 	fi
  137 	AC_SUBST([pcre_config])
  138 	AC_SUBST([PCRE_CFLAGS])
  139 	AC_SUBST([PCRE_LIBS])
  140 
  141     ])
  142 
  143 #
  144 # libpuzzle is used to compare two images
  145 #
  146 AC_DEFUN([PUZZLE],[
  147 	AC_ARG_WITH( puzzle, AC_HELP_STRING([--with-puzzle=PATH], [prefix where libpuzzle is installed default=/usr/local/]), [puzzle=$withval],[puzzle=/usr/local/])
  148 	if test "x$puzzle" != "x"
  149 	    then
  150 	    #
  151 	    # Make sure we have "puzzle.h".  If we don't, it means we probably
  152 	    # don't have libpuzzle, so don't use it.
  153 	    #
  154 	    AC_CHECK_HEADER(puzzle.h,
  155 		[
  156 		# Check if the lib is OK
  157 		AC_CHECK_LIB(puzzle, puzzle_init_context,
  158 		    [
  159 		     AC_DEFINE([HAVE_PUZZLE], 1, [for image comparison mode])
  160 		     with_puzzle=yes
  161 		     PUZZLE_CPPFLAGS="-I$puzzle/include"
  162 		     PUZZLE_LDFLAGS="-L$puzzle/lib"
  163 		     PUZZLE_LDADD="-lpuzzle -lgd"
  164 		    ],
  165 		    [
  166 		     with_puzzle=no
  167 		     AC_DEFINE([HAVE_PUZZLE], 0, [for image comparison mode])
  168 		    ])	
  169 		],
  170 		[
  171 		 with_puzzle=no
  172 		 AC_DEFINE([HAVE_PUZZLE], 0, [for image comparison mode])
  173 		])
  174 
  175 	else
  176 	    with_puzzle=no
  177 	    AC_DEFINE([HAVE_PUZZLE], 0, [for image comparison mode])
  178 	fi
  179 	AC_SUBST([with_puzzle])
  180 	AC_SUBST([PUZZLE_CPPFLAGS])
  181 	AC_SUBST([PUZZLE_LDFLAGS])
  182 	AC_SUBST([PUZZLE_LDADD])
  183     ])
  184 
  185 
  186 #
  187 # libz used to uncompress .tar.gz for the moment.
  188 #
  189 AC_DEFUN([ZLIB],[
  190 	AC_ARG_WITH(zlib, AC_HELP_STRING([--with-zlib=PATH], [prefix where zlib is installed default=/usr]), [zlib=$withval],[zlib=/usr/])
  191 	if test "x$zlib" != "x"
  192 	    then
  193 	    #
  194 	    # Make sure we have "zlib.h".  If we don't, it means we probably
  195 	    # don't have libzlib, so don't use it.
  196 	    #
  197 	    AC_CHECK_HEADER(zlib.h,
  198 		[
  199 		# Check if the lib is OK
  200 		AC_CHECK_LIB(z, gzread,
  201 		    [
  202 		     AC_DEFINE([HAVE_LIBZ], 1, [for decompressing mode])
  203 		     with_zlib=yes
  204 		     ZLIB_CPPFLAGS="-I$zlib/include"
  205 		     ZLIB_LDFLAGS="-L$zlib/lib"
  206 		     ZLIB_LDADD="-lz"
  207 		    ],
  208 		    [
  209 		     with_zlib=no
  210 		     AC_DEFINE([HAVE_ZLIB], 0, [for decompressing mode])
  211 		    ])	
  212 		],
  213 		[
  214 		 with_zlib=no
  215 		 AC_DEFINE([HAVE_ZLIB], 0, [for decompressing mode])
  216 		])
  217 
  218 	else
  219 	    with_zlib=no
  220 	    AC_DEFINE([HAVE_ZLIB], 0, [for decompressing mode])
  221 	fi
  222 	AC_SUBST([with_zlib])
  223 	AC_SUBST([ZLIB_CPPFLAGS])
  224 	AC_SUBST([ZLIB_LDFLAGS])
  225 	AC_SUBST([ZLIB_LDADD])
  226     ])
  227 
  228 #
  229 # libbz2 used to uncompress .tar.bz2 for the moment.
  230 #
  231 AC_DEFUN([BZ2],[
  232 	AC_ARG_WITH(bz2, AC_HELP_STRING([--with-bz2=PATH], [prefix where bz2 is installed default=/usr]), [bz2=$withval],[bz2=/usr/])
  233 	if test "x$bz2" != "x"
  234 	    then
  235 	    #
  236 	    # Make sure we have "bzlib.h".  If we don't, it means we probably
  237 	    # don't have libbz2, so don't use it.
  238 	    #
  239 	    AC_CHECK_HEADER(bzlib.h,
  240 		[
  241 		# Check if the lib is OK
  242 		AC_CHECK_LIB(bz2, BZ2_bzCompressInit,
  243 		    [
  244 		     AC_DEFINE([HAVE_BZ2], 1, [for decompressing mode])
  245 		     with_bz2=yes
  246 		     BZ2_CPPFLAGS="-I$bz2/include"
  247 		     BZ2_LDFLAGS="-L$bz2/lib"
  248 		     BZ2_LDADD="-lz"
  249 		    ],
  250 		    [
  251 		     with_bz2=no
  252 		     AC_DEFINE([HAVE_BZ2], 0, [for decompressing mode])
  253 		    ])	
  254 		],
  255 		[
  256 		 with_bz2=no
  257 		 AC_DEFINE([HAVE_BZ2], 0, [for decompressing mode])
  258 		])
  259 
  260 	else
  261 	    with_bz2=no
  262 	    AC_DEFINE([HAVE_BZ2], 0, [for decompressing mode])
  263 	fi
  264 	AC_SUBST([with_bz2])
  265 	AC_SUBST([BZ2_CPPFLAGS])
  266 	AC_SUBST([BZ2_LDFLAGS])
  267 	AC_SUBST([BZ2_LDADD])
  268     ])