X-Git-Url: http://ncurses.scripts.mit.edu/?p=ncurses.git;a=blobdiff_plain;f=aclocal.m4;h=1b4b72d082b8179b46ffe28cdfdcbfb45aa158a2;hp=d73d5eaa34dfd5f4fd036dd803bbfd13e5b2dcba;hb=b35ecb17e0406b48556609207aa52e9fee15cec6;hpb=f7340994c9dc299dd54a1b4cde949027436f1599 diff --git a/aclocal.m4 b/aclocal.m4 index d73d5eaa..1b4b72d0 100644 --- a/aclocal.m4 +++ b/aclocal.m4 @@ -28,7 +28,7 @@ dnl*************************************************************************** dnl dnl Author: Thomas E. Dickey 1995-on dnl -dnl $Id: aclocal.m4,v 1.544 2010/09/04 23:25:24 tom Exp $ +dnl $Id: aclocal.m4,v 1.546 2010/10/23 20:14:30 tom Exp $ dnl Macros used in NCURSES auto-configuration script. dnl dnl These macros are maintained separately from NCURSES. The copyright on @@ -313,13 +313,13 @@ ifelse([$5],NONE,,[(test $5 = NONE || test "$4" != "$5") &&]) { } ])dnl dnl --------------------------------------------------------------------------- -dnl CF_ANSI_CC_CHECK version: 9 updated: 2001/12/30 17:53:34 +dnl CF_ANSI_CC_CHECK version: 10 updated: 2010/10/23 15:52:32 dnl ---------------- dnl This is adapted from the macros 'fp_PROG_CC_STDC' and 'fp_C_PROTOTYPES' dnl in the sharutils 4.2 distribution. AC_DEFUN([CF_ANSI_CC_CHECK], [ -AC_CACHE_CHECK(for ${CC-cc} option to accept ANSI C, cf_cv_ansi_cc,[ +AC_CACHE_CHECK(for ${CC:-cc} option to accept ANSI C, cf_cv_ansi_cc,[ cf_cv_ansi_cc=no cf_save_CFLAGS="$CFLAGS" cf_save_CPPFLAGS="$CPPFLAGS" @@ -1536,7 +1536,7 @@ esac ])dnl dnl --------------------------------------------------------------------------- -dnl CF_GCC_ATTRIBUTES version: 13 updated: 2009/08/11 20:19:56 +dnl CF_GCC_ATTRIBUTES version: 14 updated: 2010/10/23 15:52:32 dnl ----------------- dnl Test for availability of useful gcc __attribute__ directives to quiet dnl compiler warnings. Though useful, not all are supported -- and contrary @@ -1563,7 +1563,7 @@ if test "$GCC" = yes then AC_CHECKING([for $CC __attribute__ directives]) cat > conftest.$ac_ext < conftest.$ac_ext <&1 | grep '[[0-9]].[[0-9]][[0-9]]*' |\ +cf_gnat_version=`${cf_ada_make:-gnatmake} -v 2>&1 | grep '[[0-9]].[[0-9]][[0-9]]*' |\ sed -e '2,$d' -e 's/[[^0-9 \.]]//g' -e 's/^[[ ]]*//' -e 's/ .*//'` AC_MSG_RESULT($cf_gnat_version) @@ -1977,7 +1977,7 @@ if test "$GXX" = yes; then fi ])dnl dnl --------------------------------------------------------------------------- -dnl CF_GXX_VERSION version: 5 updated: 2005/08/27 09:53:42 +dnl CF_GXX_VERSION version: 6 updated: 2010/10/23 15:44:18 dnl -------------- dnl Check for version of g++ AC_DEFUN([CF_GXX_VERSION],[ @@ -1985,7 +1985,7 @@ AC_REQUIRE([AC_PROG_CPP]) GXX_VERSION=none if test "$GXX" = yes; then AC_MSG_CHECKING(version of g++) - GXX_VERSION="`${CXX-g++} --version| sed -e '2,$d' -e 's/^.*(GCC) //' -e 's/^[[^0-9.]]*//' -e 's/[[^0-9.]].*//'`" + GXX_VERSION="`${CXX:-g++} --version| sed -e '2,$d' -e 's/^.*(GCC) //' -e 's/^[[^0-9.]]*//' -e 's/[[^0-9.]].*//'`" test -z "$GXX_VERSION" && GXX_VERSION=unknown AC_MSG_RESULT($GXX_VERSION) fi @@ -2422,7 +2422,7 @@ ifdef([AC_FUNC_FSEEKO],[ ]) ]) dnl --------------------------------------------------------------------------- -dnl CF_LDFLAGS_STATIC version: 7 updated: 2009/04/04 18:31:04 +dnl CF_LDFLAGS_STATIC version: 8 updated: 2010/10/23 14:39:56 dnl ----------------- dnl Check for compiler/linker flags used to temporarily force usage of static dnl libraries. This depends on the compiler and platform. Use this to help @@ -2468,6 +2468,48 @@ else esac fi +if test -n "$LDFLAGS_STATIC" && test -n "$LDFLAGS_SHARED" +then + AC_MSG_CHECKING(if linker supports switching between static/dynamic) + + rm -f libconftest.a + cat >conftest.$ac_ext < +int cf_ldflags_static(FILE *fp) { return fflush(fp); } +EOF + if AC_TRY_EVAL(ac_compile) ; then + ( $AR $ARFLAGS libconftest.a conftest.o ) 2>&AC_FD_CC 1>/dev/null + ( eval $RANLIB libconftest.a ) 2>&AC_FD_CC >/dev/null + fi + rm -f conftest.* + + cf_save_LIBS="$LIBS" + + LIBS="$LDFLAGS_STATIC -L`pwd` -lconftest $LDFLAGS_DYNAMIC $LIBS" + AC_TRY_LINK([ +#line __oline__ "configure" +#include +int cf_ldflags_static(FILE *fp); +],[ + return cf_ldflags_static(stdin); +],[cf_ldflags_static=yes],[cf_ldflags_static=no]) + + rm -f libconftest.* + LIBS="$cf_save_LIBS" + + AC_MSG_RESULT($cf_ldflags_static) + + if test $cf_ldflags_static != yes + then + LDFLAGS_STATIC= + LDFLAGS_SHARED= + fi +else + LDFLAGS_STATIC= + LDFLAGS_SHARED= +fi + AC_SUBST(LDFLAGS_STATIC) AC_SUBST(LDFLAGS_SHARED) ]) @@ -2572,7 +2614,7 @@ ifelse($1,,,[$1=$LIB_PREFIX]) AC_SUBST(LIB_PREFIX) ])dnl dnl --------------------------------------------------------------------------- -dnl CF_LIB_RULES version: 59 updated: 2010/09/04 19:24:20 +dnl CF_LIB_RULES version: 61 updated: 2010/10/23 16:10:30 dnl ------------ dnl Append definitions and rules for the given models to the subdirectory dnl Makefiles, and the recursion rule for the top-level Makefile. If the @@ -2814,7 +2856,7 @@ do TermlibSuffix=$TINFO_SUFFIX \ ShlibVer=$cf_cv_shlib_version \ ShlibVerInfix=$cf_cv_shlib_version_infix \ - ReLink=${cf_cv_do_relink-no} \ + ReLink=${cf_cv_do_relink:-no} \ DoLinks=$cf_cv_do_symlinks \ rmSoLocs=$cf_cv_rm_so_locs \ ldconfig="$LDCONFIG" \ @@ -2963,8 +3005,8 @@ done DST=\[$]1 REF=\[$]2 SRC=\[$]3 -TMPSRC=\${TMPDIR-/tmp}/\`basename \$SRC\`\$\$ -TMPSED=\${TMPDIR-/tmp}/headers.sed\$\$ +TMPSRC=\${TMPDIR:-/tmp}/\`basename \$SRC\`\$\$ +TMPSED=\${TMPDIR:-/tmp}/headers.sed\$\$ echo installing \$SRC in \$DST CF_EOF @@ -3303,7 +3345,7 @@ AC_DEFUN([CF_MAIN_RETURN], cf_cv_main_return=return ])dnl dnl --------------------------------------------------------------------------- -dnl CF_MAKEFLAGS version: 12 updated: 2006/10/21 08:27:03 +dnl CF_MAKEFLAGS version: 13 updated: 2010/10/23 15:52:32 dnl ------------ dnl Some 'make' programs support ${MAKEFLAGS}, some ${MFLAGS}, to pass 'make' dnl options to lower-levels. It's very useful for "make -n" -- if we have it. @@ -3320,10 +3362,10 @@ SHELL = /bin/sh all : @ echo '.$cf_option' CF_EOF - cf_result=`${MAKE-make} -k -f cf_makeflags.tmp 2>/dev/null | sed -e 's,[[ ]]*$,,'` + cf_result=`${MAKE:-make} -k -f cf_makeflags.tmp 2>/dev/null | sed -e 's,[[ ]]*$,,'` case "$cf_result" in .*k) - cf_result=`${MAKE-make} -k -f cf_makeflags.tmp CC=cc 2>/dev/null` + cf_result=`${MAKE:-make} -k -f cf_makeflags.tmp CC=cc 2>/dev/null` case "$cf_result" in .*CC=*) cf_cv_makeflags= ;; @@ -3343,7 +3385,7 @@ CF_EOF AC_SUBST(cf_cv_makeflags) ])dnl dnl --------------------------------------------------------------------------- -dnl CF_MAKE_TAGS version: 5 updated: 2010/04/03 20:07:32 +dnl CF_MAKE_TAGS version: 6 updated: 2010/10/23 15:52:32 dnl ------------ dnl Generate tags/TAGS targets for makefiles. Do not generate TAGS if we have dnl a monocase filesystem. @@ -3353,10 +3395,10 @@ AC_REQUIRE([CF_MIXEDCASE_FILENAMES]) AC_CHECK_PROGS(CTAGS, exctags ctags) AC_CHECK_PROGS(ETAGS, exetags etags) -AC_CHECK_PROG(MAKE_LOWER_TAGS, ${CTAGS-ctags}, yes, no) +AC_CHECK_PROG(MAKE_LOWER_TAGS, ${CTAGS:-ctags}, yes, no) if test "$cf_cv_mixedcase" = yes ; then - AC_CHECK_PROG(MAKE_UPPER_TAGS, ${ETAGS-etags}, yes, no) + AC_CHECK_PROG(MAKE_UPPER_TAGS, ${ETAGS:-etags}, yes, no) else MAKE_UPPER_TAGS=no fi @@ -3380,7 +3422,7 @@ AC_SUBST(MAKE_UPPER_TAGS) AC_SUBST(MAKE_LOWER_TAGS) ])dnl dnl --------------------------------------------------------------------------- -dnl CF_MANPAGE_FORMAT version: 8 updated: 2009/01/11 20:30:50 +dnl CF_MANPAGE_FORMAT version: 9 updated: 2010/10/23 16:10:30 dnl ----------------- dnl Option to allow user to override automatic configuration of manpage format. dnl There are several special cases: @@ -3422,7 +3464,7 @@ unknown) cf_catonly=yes cf_example=date - IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR}" + IFS="${IFS:- }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR}" for cf_dir in $MANPATH; do test -z "$cf_dir" && cf_dir=/usr/man for cf_name in $cf_dir/man*/$cf_example.[[01]]* $cf_dir/cat*/$cf_example.[[01]]* $cf_dir/man*/$cf_example $cf_dir/cat*/$cf_example @@ -3598,7 +3640,7 @@ AC_ARG_WITH(manpage-tbl, AC_MSG_RESULT($MANPAGE_TBL) ])dnl dnl --------------------------------------------------------------------------- -dnl CF_MAN_PAGES version: 38 updated: 2010/07/24 17:12:40 +dnl CF_MAN_PAGES version: 39 updated: 2010/10/23 15:44:18 dnl ------------ dnl Try to determine if the man-pages on the system are compressed, and if dnl so, what format is used. Use this information to construct a script that @@ -3669,7 +3711,7 @@ INSTALL_DATA="$INSTALL_DATA" transform="$program_transform_name" -TMP=\${TMPDIR-/tmp}/man\$\$ +TMP=\${TMPDIR:=/tmp}/man\$\$ trap "rm -f \$TMP" 0 1 2 5 15 form=\[$]1 @@ -4033,12 +4075,12 @@ if test "x$cf_cv_func_mkstemp" = xyes || test "x$ac_cv_func_mkstemp" = xyes ; th fi ])dnl dnl --------------------------------------------------------------------------- -dnl CF_MSG_LOG version: 4 updated: 2007/07/29 09:55:12 +dnl CF_MSG_LOG version: 5 updated: 2010/10/23 15:52:32 dnl ---------- dnl Write a debug message to config.log, along with the line number in the dnl configure script. AC_DEFUN([CF_MSG_LOG],[ -echo "${as_me-configure}:__oline__: testing $* ..." 1>&AC_FD_CC +echo "${as_me:-configure}:__oline__: testing $* ..." 1>&AC_FD_CC ])dnl dnl --------------------------------------------------------------------------- dnl CF_NCURSES_ABI_6 version: 1 updated: 2005/09/17 18:42:49 @@ -5954,7 +5996,7 @@ if test "$with_gpm" != no ; then fi ]) dnl --------------------------------------------------------------------------- -dnl CF_WITH_LIBTOOL version: 25 updated: 2010/05/15 15:45:59 +dnl CF_WITH_LIBTOOL version: 26 updated: 2010/10/23 15:55:24 dnl --------------- dnl Provide a configure option to incorporate libtool. Define several useful dnl symbols for the makefile rules. @@ -5983,7 +6025,7 @@ dnl rm -f $ORIG dnl mv $LOCAL $ORIG dnl dnl # sed the LIBTOOL= assignment to omit the current directory? -dnl sed -e 's/^LIBTOOL=.*/LIBTOOL=${LIBTOOL-libtool}/' $ACLOCAL/libtool.m4 >>$LOCAL +dnl sed -e 's/^LIBTOOL=.*/LIBTOOL=${LIBTOOL:-libtool}/' $ACLOCAL/libtool.m4 >>$LOCAL dnl cat $ORIG >>$LOCAL dnl dnl autoconf-257 $* @@ -6095,7 +6137,7 @@ AC_SUBST(LIB_UNINSTALL) ])dnl dnl --------------------------------------------------------------------------- -dnl CF_WITH_PATH version: 9 updated: 2010/05/26 05:38:42 +dnl CF_WITH_PATH version: 10 updated: 2010/10/23 15:44:18 dnl ------------ dnl Wrapper for AC_ARG_WITH to ensure that user supplies a pathname, not just dnl defaulting to yes/no. @@ -6108,7 +6150,7 @@ dnl $5 = default value, if it's an expression & cannot be in the help-message dnl AC_DEFUN([CF_WITH_PATH], [AC_ARG_WITH($1,[$2 ](default: ifelse([$4],,empty,[$4])),, -ifelse([$4],,[withval="${$3}"],[withval="${$3-ifelse([$5],,[$4],[$5])}"]))dnl +ifelse([$4],,[withval="${$3}"],[withval="${$3:-ifelse([$5],,[$4],[$5])}"]))dnl if ifelse([$5],,true,[test -n "$5"]) ; then CF_PATH_SYNTAX(withval) fi @@ -6116,7 +6158,7 @@ $3="$withval" AC_SUBST($3)dnl ])dnl dnl --------------------------------------------------------------------------- -dnl CF_WITH_PATHLIST version: 6 updated: 2009/01/11 20:30:23 +dnl CF_WITH_PATHLIST version: 7 updated: 2010/10/23 16:10:30 dnl ---------------- dnl Process an option specifying a list of colon-separated paths. dnl @@ -6130,9 +6172,9 @@ dnl AC_DEFUN([CF_WITH_PATHLIST],[ AC_REQUIRE([CF_PATHSEP]) AC_ARG_WITH($1,[$2 ](default: ifelse($4,,empty,$4)),, -ifelse($4,,[withval=${$3}],[withval=${$3-ifelse($5,,$4,$5)}]))dnl +ifelse($4,,[withval=${$3}],[withval=${$3:-ifelse($5,,$4,$5)}]))dnl -IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${PATH_SEPARATOR}" +IFS="${IFS:- }"; ac_save_ifs="$IFS"; IFS="${PATH_SEPARATOR}" cf_dst_path= for cf_src_path in $withval do