X-Git-Url: https://ncurses.scripts.mit.edu/?p=ncurses.git;a=blobdiff_plain;f=Ada95%2Faclocal.m4;h=cab841a38ee298946e4f8b33372756fdad8767e9;hp=ad44f8a2c5ff1e1fdf719df5ceed58e2afebcba7;hb=da518a7ad2d94c8e63186a49621e907967a31a37;hpb=0141530788318928d6e4da45eb1ec88c86940645 diff --git a/Ada95/aclocal.m4 b/Ada95/aclocal.m4 index ad44f8a2..cab841a3 100644 --- a/Ada95/aclocal.m4 +++ b/Ada95/aclocal.m4 @@ -28,7 +28,7 @@ dnl*************************************************************************** dnl dnl Author: Thomas E. Dickey dnl -dnl $Id: aclocal.m4,v 1.11 2010/06/19 20:18:12 tom Exp $ +dnl $Id: aclocal.m4,v 1.15 2010/07/24 21:33:12 tom Exp $ dnl Macros used in NCURSES Ada95 auto-configuration script. dnl dnl These macros are maintained separately from NCURSES. The copyright on @@ -268,7 +268,7 @@ dnl $1 = libraries to add, with the "-l", etc. dnl $2 = variable to update (default $LIBS) AC_DEFUN([CF_ADD_LIBS],[ifelse($2,,LIBS,[$2])="$1 [$]ifelse($2,,LIBS,[$2])"])dnl dnl --------------------------------------------------------------------------- -dnl CF_ADD_SUBDIR_PATH version: 2 updated: 2007/07/29 10:12:59 +dnl CF_ADD_SUBDIR_PATH version: 3 updated: 2010/07/03 20:58:12 dnl ------------------ dnl Append to a search-list for a nonstandard header/lib-file dnl $1 = the variable to return as result @@ -280,7 +280,7 @@ AC_DEFUN([CF_ADD_SUBDIR_PATH], [ test "$4" != "$5" && \ test -d "$4" && \ -ifelse([$5],NONE,,[(test $5 = NONE || test -d $5) &&]) { +ifelse([$5],NONE,,[(test $5 = NONE || test "$4" != "$5") &&]) { test -n "$verbose" && echo " ... testing for $3-directories under $4" test -d $4/$3 && $1="[$]$1 $4/$3" test -d $4/$3/$2 && $1="[$]$1 $4/$3/$2" @@ -1127,7 +1127,7 @@ fi rm -f conftest* ])dnl dnl --------------------------------------------------------------------------- -dnl CF_GNAT_VERSION version: 13 updated: 2010/06/19 15:22:18 +dnl CF_GNAT_VERSION version: 14 updated: 2010/07/03 17:45:09 dnl --------------- dnl Verify version of GNAT. AC_DEFUN([CF_GNAT_VERSION], @@ -1145,6 +1145,7 @@ case $cf_gnat_version in cf_cv_prog_gnat_correct=no ;; esac + case $cf_gnat_version in 3.[[1-9]]*|[[4-9]].*) cf_compile_generics=generics @@ -1155,8 +1156,22 @@ case $cf_gnat_version in ;; esac +case $cf_gnat_version in + 3.[[0-9]]*) + USE_OLD_MAKERULES="" + USE_GNAT_PROJECTS="#" + ;; + *) + USE_OLD_MAKERULES="#" + USE_GNAT_PROJECTS="" + ;; +esac + AC_SUBST(cf_compile_generics) AC_SUBST(cf_generic_objects) + +AC_SUBST(USE_OLD_MAKERULES) +AC_SUBST(USE_GNAT_PROJECTS) ]) dnl --------------------------------------------------------------------------- dnl CF_GNU_SOURCE version: 6 updated: 2005/07/09 13:23:07 @@ -1967,10 +1982,10 @@ printf("old\n"); ,[$1=no]) ])dnl dnl --------------------------------------------------------------------------- -dnl CF_NCURSES_CONFIG version: 6 updated: 2010/04/28 06:02:16 +dnl CF_NCURSES_CONFIG version: 8 updated: 2010/07/08 05:17:30 dnl ----------------- dnl Tie together the configure-script macros for ncurses. -dnl Prefer the "-config" script from ncurses 5.6, to simplify analysis. +dnl Prefer the "-config" script from ncurses 6.x, to simplify analysis. dnl Allow that to be overridden using the $NCURSES_CONFIG environment variable. dnl dnl $1 is the root library name (default: "ncurses") @@ -1984,7 +1999,7 @@ AC_PATH_PROGS(NCURSES_CONFIG,${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5- if test "$NCURSES_CONFIG" != none ; then CPPFLAGS="$CPPFLAGS `$NCURSES_CONFIG --cflags`" -LIBS="`$NCURSES_CONFIG --libs` $LIBS" +CF_ADD_LIBS(`$NCURSES_CONFIG --libs`) # even with config script, some packages use no-override for curses.h CF_CURSES_HEADER(ifelse($1,,ncurses,$1)) @@ -2124,7 +2139,7 @@ esac ])dnl dnl --------------------------------------------------------------------------- -dnl CF_NCURSES_LIBS version: 13 updated: 2007/07/29 10:29:20 +dnl CF_NCURSES_LIBS version: 14 updated: 2010/06/20 09:24:28 dnl --------------- dnl Look for the ncurses library. This is a little complicated on Linux, dnl because it may be linked with the gpm (general purpose mouse) library. @@ -2160,12 +2175,12 @@ freebsd*) ;; esac -LIBS="$cf_ncurses_LIBS $LIBS" +CF_ADD_LIBS($cf_ncurses_LIBS) if ( test -n "$cf_cv_curses_dir" && test "$cf_cv_curses_dir" != "no" ) then CF_ADD_LIBDIR($cf_cv_curses_dir/lib) - LIBS="-l$cf_nculib_root $LIBS" + CF_ADD_LIBS(-l$cf_nculib_root) else CF_FIND_LIBRARY($cf_nculib_root,$cf_nculib_root, [#include <${cf_cv_ncurses_header-curses.h}>], @@ -2606,6 +2621,28 @@ fi AC_SUBST(cf_ada_make) ])dnl dnl --------------------------------------------------------------------------- +dnl CF_PROG_LN_S version: 1 updated: 2010/07/24 17:12:40 +dnl ------------ +dnl Combine checks for "ln -s" and "ln -sf", updating $LN_S to include "-f" +dnl option if it is supported. +AC_DEFUN([CF_PROG_LN_S],[ +AC_PROG_LN_S +AC_MSG_CHECKING(if $LN_S -f options work) + +rm -f conf$$.src conf$$dst +echo >conf$$.dst +echo first >conf$$.src +if $LN_S -f conf$$.src conf$$.dst 2>/dev/null; then + cf_prog_ln_sf=yes +else + cf_prog_ln_sf=no +fi + +AC_MSG_RESULT($cf_prog_ln_sf) + +test "$cf_prog_ln_sf" = yes && LN_S="$LN_S -f" +])dnl +dnl --------------------------------------------------------------------------- dnl CF_REMOVE_DEFINE version: 3 updated: 2010/01/09 11:05:50 dnl ---------------- dnl Remove all -U and -D options that refer to the given symbol from a list @@ -3067,7 +3104,7 @@ AC_DEFUN([CF_UPPER], $1=`echo "$2" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%` ])dnl dnl --------------------------------------------------------------------------- -dnl CF_UTF8_LIB version: 6 updated: 2010/04/21 06:20:50 +dnl CF_UTF8_LIB version: 7 updated: 2010/06/20 09:24:28 dnl ----------- dnl Check for multibyte support, and if not found, utf8 compatibility library AC_DEFUN([CF_UTF8_LIB], @@ -3089,7 +3126,7 @@ if test "$cf_cv_utf8_lib" = "add-on" ; then AC_DEFINE(HAVE_LIBUTF8_H) CF_ADD_INCDIR($cf_cv_header_path_utf8) CF_ADD_LIBDIR($cf_cv_library_path_utf8) - LIBS="$cf_cv_library_file_utf8 $LIBS" + CF_ADD_LIBS($cf_cv_library_file_utf8) fi ])dnl dnl --------------------------------------------------------------------------- @@ -3127,63 +3164,69 @@ weak_symbol(fopen); ]) ])dnl dnl --------------------------------------------------------------------------- -dnl CF_WITH_ADA_COMPILER version: 1 updated: 2010/06/19 15:22:18 +dnl CF_WITH_ADA_COMPILER version: 2 updated: 2010/06/26 17:35:58 dnl -------------------- dnl Command-line option to specify the Ada95 compiler. AC_DEFUN([CF_WITH_ADA_COMPILER],[ +AC_MSG_CHECKING(for ada-compiler) AC_ARG_WITH(ada-compiler, [ --with-ada-compiler=CMD specify Ada95 compiler command (default gnatmake)], [cf_ada_compiler=$withval], [cf_ada_compiler=gnatmake]) AC_SUBST(cf_ada_compiler) +AC_MSG_RESULT($cf_ada_compiler) ])dnl dnl --------------------------------------------------------------------------- -dnl CF_WITH_ADA_INCLUDE version: 1 updated: 2010/06/19 15:22:18 +dnl CF_WITH_ADA_INCLUDE version: 2 updated: 2010/06/26 17:35:58 dnl ------------------- dnl Command-line option to specify where Ada includes will install. AC_DEFUN([CF_WITH_ADA_INCLUDE],[ +AC_MSG_CHECKING(for ada-include) CF_WITH_PATH(ada-include, [ --with-ada-include=DIR Ada includes are in DIR], ADA_INCLUDE, PREFIX/share/ada/adainclude, [$]prefix/share/ada/adainclude) AC_SUBST(ADA_INCLUDE) +AC_MSG_RESULT($ADA_INCLUDE) ])dnl dnl --------------------------------------------------------------------------- -dnl CF_WITH_ADA_OBJECTS version: 1 updated: 2010/06/19 15:22:18 +dnl CF_WITH_ADA_OBJECTS version: 2 updated: 2010/06/26 17:35:58 dnl ------------------- dnl Command-line option to specify where Ada objects will install. AC_DEFUN([CF_WITH_ADA_OBJECTS],[ +AC_MSG_CHECKING(for ada-objects) CF_WITH_PATH(ada-objects, [ --with-ada-objects=DIR Ada objects are in DIR], ADA_OBJECTS, PREFIX/lib/ada/adalib, [$]prefix/lib/ada/adalib) AC_SUBST(ADA_OBJECTS) +AC_MSG_RESULT($ADA_OBJECTS) ])dnl dnl --------------------------------------------------------------------------- -dnl CF_WITH_ADA_SHAREDLIB version: 1 updated: 2010/06/19 16:12:21 +dnl CF_WITH_ADA_SHAREDLIB version: 2 updated: 2010/06/26 17:35:58 dnl --------------------- dnl Command-line option to specify if an Ada95 shared-library should be built, dnl and optionally what its soname should be. AC_DEFUN([CF_WITH_ADA_SHAREDLIB],[ +AC_MSG_CHECKING(if an Ada95 shared-library should be built) AC_ARG_WITH(ada-sharedlib, [ --with-ada-sharedlib=XX build Ada95 shared-library], [with_ada_sharedlib=$withval], [with_ada_sharedlib=no]) AC_MSG_RESULT($with_ada_sharedlib) +ADA_SHAREDLIB='lib$(LIB_NAME).so.1' +MAKE_ADA_SHAREDLIB="#" + if test "x$with_ada_sharedlib" != xno then MAKE_ADA_SHAREDLIB= if test "x$with_ada_sharedlib" != xyes then ADA_SHAREDLIB="$with_ada_sharedlib" - else - ADA_SHAREDLIB='lib$(LIB_NAME).so.1' fi -else - MAKE_ADA_SHAREDLIB="#" fi AC_SUBST(ADA_SHAREDLIB)