From f025f43fc4140349a95ace94617a8be52c10d395 Mon Sep 17 00:00:00 2001 From: jlam Date: Thu, 22 Jun 2006 18:52:00 +0000 Subject: Reorder the linker tests in the configure script so that we test for C libraries *before* we throw the AC_LANG([C++]) switch. This makes the generated configure script use the C compiler/linker instead of the C++ compiler/linker when running tests. This avoids errors like these based on not correctly getting the function signature correct: conftest.cc:36: error: nonnull argument with out-of-range operand number (arg 1, operand 2) This error was causing the configure script to not detect *gettext() routines and not building and installing the *.mo files. This fixes the error noted in the bulk build results: http://mail-index.netbsd.org/pkgsrc-bulk/2006/06/20/0000.html --- math/qalculate-bases/distinfo | 4 +- math/qalculate-bases/patches/patch-aa | 3957 ++++++++++++++++++++++++++ math/qalculate-bases/patches/patch-ab | 72 + math/qalculate-currency/distinfo | 4 +- math/qalculate-currency/patches/patch-aa | 3972 ++++++++++++++++++++++++++ math/qalculate-currency/patches/patch-ab | 72 + math/qalculate-gtk/distinfo | 4 +- math/qalculate-gtk/patches/patch-ab | 4437 ++++++++++++++++++++++++++++++ math/qalculate-gtk/patches/patch-ac | 76 + math/qalculate-units/distinfo | 4 +- math/qalculate-units/patches/patch-aa | 3972 ++++++++++++++++++++++++++ math/qalculate-units/patches/patch-ab | 72 + math/qalculate/distinfo | 5 +- math/qalculate/patches/patch-ab | 4020 ++++++++++++++++++++++++++- math/qalculate/patches/patch-ad | 62 + 15 files changed, 20711 insertions(+), 22 deletions(-) create mode 100644 math/qalculate-bases/patches/patch-aa create mode 100644 math/qalculate-bases/patches/patch-ab create mode 100644 math/qalculate-currency/patches/patch-aa create mode 100644 math/qalculate-currency/patches/patch-ab create mode 100644 math/qalculate-gtk/patches/patch-ab create mode 100644 math/qalculate-gtk/patches/patch-ac create mode 100644 math/qalculate-units/patches/patch-aa create mode 100644 math/qalculate-units/patches/patch-ab create mode 100644 math/qalculate/patches/patch-ad (limited to 'math') diff --git a/math/qalculate-bases/distinfo b/math/qalculate-bases/distinfo index fb747e233c7..4c5aa60b992 100644 --- a/math/qalculate-bases/distinfo +++ b/math/qalculate-bases/distinfo @@ -1,5 +1,7 @@ -$NetBSD: distinfo,v 1.4 2006/06/14 20:14:21 adam Exp $ +$NetBSD: distinfo,v 1.5 2006/06/22 18:52:00 jlam Exp $ SHA1 (qalculate-bases-0.9.4.tar.gz) = 71f4071bfd6217eb30788c41e95c531cca55b610 RMD160 (qalculate-bases-0.9.4.tar.gz) = be0c2e11eaca3dfce064b751903249486264f857 Size (qalculate-bases-0.9.4.tar.gz) = 368685 bytes +SHA1 (patch-aa) = 8bafc00b8daa26fe72c88f7415f8dceaf748b3e1 +SHA1 (patch-ab) = f162586746600d18621068ca6af94c9f00f559dd diff --git a/math/qalculate-bases/patches/patch-aa b/math/qalculate-bases/patches/patch-aa new file mode 100644 index 00000000000..3f2d35abf9b --- /dev/null +++ b/math/qalculate-bases/patches/patch-aa @@ -0,0 +1,3957 @@ +$NetBSD: patch-aa,v 1.1 2006/06/22 18:52:00 jlam Exp $ + +--- configure.orig 2006-06-02 01:51:11.000000000 -0400 ++++ configure +@@ -20064,32 +20064,184 @@ if test "x$GCC" = "xyes"; then + fi + + ++GETTEXT_PACKAGE=qalculate-bases + +-echo "$as_me:$LINENO: checking for pthread_create in -lpthread" >&5 +-echo $ECHO_N "checking for pthread_create in -lpthread... $ECHO_C" >&6 +-if test "${ac_cv_lib_pthread_pthread_create+set}" = set; then ++ ++cat >>confdefs.h <<_ACEOF ++#define GETTEXT_PACKAGE "$GETTEXT_PACKAGE" ++_ACEOF ++ ++ ++ALL_LINGUAS="nl sv" ++ ++ ++ ++for ac_header in locale.h ++do ++as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh` ++if eval "test \"\${$as_ac_Header+set}\" = set"; then ++ echo "$as_me:$LINENO: checking for $ac_header" >&5 ++echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6 ++if eval "test \"\${$as_ac_Header+set}\" = set"; then + echo $ECHO_N "(cached) $ECHO_C" >&6 ++fi ++echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5 ++echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6 + else +- ac_check_lib_save_LIBS=$LIBS +-LIBS="-lpthread $LIBS" ++ # Is the header compilable? ++echo "$as_me:$LINENO: checking $ac_header usability" >&5 ++echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6 + cat >conftest.$ac_ext <<_ACEOF + /* confdefs.h. */ + _ACEOF + cat confdefs.h >>conftest.$ac_ext + cat >>conftest.$ac_ext <<_ACEOF + /* end confdefs.h. */ ++$ac_includes_default ++#include <$ac_header> ++_ACEOF ++rm -f conftest.$ac_objext ++if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 ++ (eval $ac_compile) 2>conftest.er1 ++ ac_status=$? ++ grep -v '^ *+' conftest.er1 >conftest.err ++ rm -f conftest.er1 ++ cat conftest.err >&5 ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); } && ++ { ac_try='test -z "$ac_cxx_werror_flag" ++ || test ! -s conftest.err' ++ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 ++ (eval $ac_try) 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; } && ++ { ac_try='test -s conftest.$ac_objext' ++ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 ++ (eval $ac_try) 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; }; then ++ ac_header_compiler=yes ++else ++ echo "$as_me: failed program was:" >&5 ++sed 's/^/| /' conftest.$ac_ext >&5 + +-/* Override any gcc2 internal prototype to avoid an error. */ +-#ifdef __cplusplus +-extern "C" +-#endif +-/* We use char because int might match the return type of a gcc2 +- builtin and then its argument prototype would still apply. */ +-char pthread_create (); ++ac_header_compiler=no ++fi ++rm -f conftest.err conftest.$ac_objext conftest.$ac_ext ++echo "$as_me:$LINENO: result: $ac_header_compiler" >&5 ++echo "${ECHO_T}$ac_header_compiler" >&6 ++ ++# Is the header present? ++echo "$as_me:$LINENO: checking $ac_header presence" >&5 ++echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6 ++cat >conftest.$ac_ext <<_ACEOF ++/* confdefs.h. */ ++_ACEOF ++cat confdefs.h >>conftest.$ac_ext ++cat >>conftest.$ac_ext <<_ACEOF ++/* end confdefs.h. */ ++#include <$ac_header> ++_ACEOF ++if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5 ++ (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 ++ ac_status=$? ++ grep -v '^ *+' conftest.er1 >conftest.err ++ rm -f conftest.er1 ++ cat conftest.err >&5 ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); } >/dev/null; then ++ if test -s conftest.err; then ++ ac_cpp_err=$ac_cxx_preproc_warn_flag ++ ac_cpp_err=$ac_cpp_err$ac_cxx_werror_flag ++ else ++ ac_cpp_err= ++ fi ++else ++ ac_cpp_err=yes ++fi ++if test -z "$ac_cpp_err"; then ++ ac_header_preproc=yes ++else ++ echo "$as_me: failed program was:" >&5 ++sed 's/^/| /' conftest.$ac_ext >&5 ++ ++ ac_header_preproc=no ++fi ++rm -f conftest.err conftest.$ac_ext ++echo "$as_me:$LINENO: result: $ac_header_preproc" >&5 ++echo "${ECHO_T}$ac_header_preproc" >&6 ++ ++# So? What about this header? ++case $ac_header_compiler:$ac_header_preproc:$ac_cxx_preproc_warn_flag in ++ yes:no: ) ++ { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5 ++echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;} ++ { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5 ++echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;} ++ ac_header_preproc=yes ++ ;; ++ no:yes:* ) ++ { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5 ++echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;} ++ { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5 ++echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;} ++ { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5 ++echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;} ++ { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5 ++echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;} ++ { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5 ++echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;} ++ { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5 ++echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;} ++ ( ++ cat <<\_ASBOX ++## ------------------------------------------ ## ++## Report this to the AC_PACKAGE_NAME lists. ## ++## ------------------------------------------ ## ++_ASBOX ++ ) | ++ sed "s/^/$as_me: WARNING: /" >&2 ++ ;; ++esac ++echo "$as_me:$LINENO: checking for $ac_header" >&5 ++echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6 ++if eval "test \"\${$as_ac_Header+set}\" = set"; then ++ echo $ECHO_N "(cached) $ECHO_C" >&6 ++else ++ eval "$as_ac_Header=\$ac_header_preproc" ++fi ++echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5 ++echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6 ++ ++fi ++if test `eval echo '${'$as_ac_Header'}'` = yes; then ++ cat >>confdefs.h <<_ACEOF ++#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1 ++_ACEOF ++ ++fi ++ ++done ++ ++ if test $ac_cv_header_locale_h = yes; then ++ echo "$as_me:$LINENO: checking for LC_MESSAGES" >&5 ++echo $ECHO_N "checking for LC_MESSAGES... $ECHO_C" >&6 ++if test "${am_cv_val_LC_MESSAGES+set}" = set; then ++ echo $ECHO_N "(cached) $ECHO_C" >&6 ++else ++ cat >conftest.$ac_ext <<_ACEOF ++/* confdefs.h. */ ++_ACEOF ++cat confdefs.h >>conftest.$ac_ext ++cat >>conftest.$ac_ext <<_ACEOF ++/* end confdefs.h. */ ++#include + int + main () + { +-pthread_create (); ++return LC_MESSAGES + ; + return 0; + } +@@ -20103,7 +20255,7 @@ if { (eval echo "$as_me:$LINENO: \"$ac_l + cat conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } && +- { ac_try='test -z "$ac_c_werror_flag" ++ { ac_try='test -z "$ac_cxx_werror_flag" + || test ! -s conftest.err' + { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 +@@ -20116,885 +20268,361 @@ if { (eval echo "$as_me:$LINENO: \"$ac_l + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then +- ac_cv_lib_pthread_pthread_create=yes ++ am_cv_val_LC_MESSAGES=yes + else + echo "$as_me: failed program was:" >&5 + sed 's/^/| /' conftest.$ac_ext >&5 + +-ac_cv_lib_pthread_pthread_create=no ++am_cv_val_LC_MESSAGES=no + fi + rm -f conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +-LIBS=$ac_check_lib_save_LIBS +-fi +-echo "$as_me:$LINENO: result: $ac_cv_lib_pthread_pthread_create" >&5 +-echo "${ECHO_T}$ac_cv_lib_pthread_pthread_create" >&6 +-if test $ac_cv_lib_pthread_pthread_create = yes; then +- LIBS="$LIBS -lpthread" + fi ++echo "$as_me:$LINENO: result: $am_cv_val_LC_MESSAGES" >&5 ++echo "${ECHO_T}$am_cv_val_LC_MESSAGES" >&6 ++ if test $am_cv_val_LC_MESSAGES = yes; then + ++cat >>confdefs.h <<\_ACEOF ++#define HAVE_LC_MESSAGES 1 ++_ACEOF + +-ac_ext=cc +-ac_cpp='$CXXCPP $CPPFLAGS' +-ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' +-ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +-ac_compiler_gnu=$ac_cv_cxx_compiler_gnu +- +- +- +-# Check whether --with-cln-prefix or --without-cln-prefix was given. +-if test "${with_cln_prefix+set}" = set; then +- withval="$with_cln_prefix" +- cln_config_prefix="$withval" +-else +- cln_config_prefix="" +-fi; ++ fi ++ fi ++ USE_NLS=yes + +-# Check whether --with-cln-exec-prefix or --without-cln-exec-prefix was given. +-if test "${with_cln_exec_prefix+set}" = set; then +- withval="$with_cln_exec_prefix" +- cln_config_exec_prefix="$withval" +-else +- cln_config_exec_prefix="" +-fi; +-# Check whether --enable-clntest or --disable-clntest was given. +-if test "${enable_clntest+set}" = set; then +- enableval="$enable_clntest" + +-else +- enable_clntest=yes +-fi; ++ gt_cv_have_gettext=no + +-if test x$cln_config_exec_prefix != x ; then +- cln_config_args="$cln_config_args --exec-prefix=$cln_config_exec_prefix" +- if test x${CLN_CONFIG+set} != xset ; then +- CLN_CONFIG=$cln_config_exec_prefix/bin/cln-config +- fi +-fi +-if test x$cln_config_prefix != x ; then +- cln_config_args="$cln_config_args --prefix=$cln_config_prefix" +- if test x${CLN_CONFIG+set} != xset ; then +- CLN_CONFIG=$cln_config_prefix/bin/cln-config +- fi +-fi ++ CATOBJEXT=NONE ++ XGETTEXT=: ++ INTLLIBS= + +-# Extract the first word of "cln-config", so it can be a program name with args. +-set dummy cln-config; ac_word=$2 +-echo "$as_me:$LINENO: checking for $ac_word" >&5 +-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 +-if test "${ac_cv_path_CLN_CONFIG+set}" = set; then ++ if test "${ac_cv_header_libintl_h+set}" = set; then ++ echo "$as_me:$LINENO: checking for libintl.h" >&5 ++echo $ECHO_N "checking for libintl.h... $ECHO_C" >&6 ++if test "${ac_cv_header_libintl_h+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 ++fi ++echo "$as_me:$LINENO: result: $ac_cv_header_libintl_h" >&5 ++echo "${ECHO_T}$ac_cv_header_libintl_h" >&6 + else +- case $CLN_CONFIG in +- [\\/]* | ?:[\\/]*) +- ac_cv_path_CLN_CONFIG="$CLN_CONFIG" # Let the user override the test with a path. +- ;; +- *) +- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +-for as_dir in $PATH +-do +- IFS=$as_save_IFS +- test -z "$as_dir" && as_dir=. +- for ac_exec_ext in '' $ac_executable_extensions; do +- if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then +- ac_cv_path_CLN_CONFIG="$as_dir/$ac_word$ac_exec_ext" +- echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 +- break 2 +- fi +-done +-done +- +- test -z "$ac_cv_path_CLN_CONFIG" && ac_cv_path_CLN_CONFIG="no" +- ;; +-esac +-fi +-CLN_CONFIG=$ac_cv_path_CLN_CONFIG +- +-if test -n "$CLN_CONFIG"; then +- echo "$as_me:$LINENO: result: $CLN_CONFIG" >&5 +-echo "${ECHO_T}$CLN_CONFIG" >&6 +-else +- echo "$as_me:$LINENO: result: no" >&5 +-echo "${ECHO_T}no" >&6 +-fi +- +-cln_min_version=1.1.0 +-echo "$as_me:$LINENO: checking for CLN - version >= $cln_min_version" >&5 +-echo $ECHO_N "checking for CLN - version >= $cln_min_version... $ECHO_C" >&6 +-if test "$CLN_CONFIG" = "no" ; then +- echo "$as_me:$LINENO: result: no" >&5 +-echo "${ECHO_T}no" >&6 +- echo "*** The cln-config script installed by CLN could not be found" +- echo "*** If CLN was installed in PREFIX, make sure PREFIX/bin is in" +- echo "*** your path, or set the CLN_CONFIG environment variable to the" +- echo "*** full path to cln-config." +- { { echo "$as_me:$LINENO: error: No suitable installed version of CLN could be found." >&5 +-echo "$as_me: error: No suitable installed version of CLN could be found." >&2;} +- { (exit 1); exit 1; }; } +-else +- cln_min_major_version=`echo $cln_min_version | \ +- sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\1/'` +- cln_min_minor_version=`echo $cln_min_version | \ +- sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\2/'` +- cln_min_micro_version=`echo $cln_min_version | \ +- sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\3/'` +- CLN_CPPFLAGS=`$CLN_CONFIG $cln_config_args --cppflags` +- CLN_LIBS=`$CLN_CONFIG $cln_config_args --libs` +- cln_config_version=`$CLN_CONFIG $cln_config_args --version` +- cln_config_major_version=`echo $cln_config_version | \ +- sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\1/'` +- cln_config_minor_version=`echo $cln_config_version | \ +- sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\2/'` +- cln_config_micro_version=`echo $cln_config_version | \ +- sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\3/'` +- if test \( $cln_config_major_version -lt $cln_min_major_version \) -o \ +- \( $cln_config_major_version -eq $cln_min_major_version -a $cln_config_minor_version -lt $cln_min_minor_version \) -o \ +- \( $cln_config_major_version -eq $cln_min_major_version -a $cln_config_minor_version -eq $cln_min_minor_version -a $cln_config_micro_version -lt $cln_min_micro_version \); then +- echo -e "\n*** 'cln-config --version' returned $cln_config_major_version.$cln_config_minor_version.$cln_config_micro_version, but the minimum version" +- echo "*** of CLN required is $cln_min_major_version.$cln_min_minor_version.$cln_min_micro_version. If cln-config is correct, then it is" +- echo "*** best to upgrade to the required version." +- echo "*** If cln-config was wrong, set the environment variable CLN_CONFIG" +- echo "*** to point to the correct copy of cln-config, and remove the file" +- echo "*** config.cache before re-running configure." +- { { echo "$as_me:$LINENO: error: No suitable installed version of CLN could be found." >&5 +-echo "$as_me: error: No suitable installed version of CLN could be found." >&2;} +- { (exit 1); exit 1; }; } +- else +- no_cln="" +- if test "x$enable_clntest" = "xyes" ; then +- ac_save_CPPFLAGS="$CPPFLAGS" +- ac_save_LIBS="$LIBS" +- CPPFLAGS="$CPPFLAGS $CLN_CPPFLAGS" +- LIBS="$LIBS $CLN_LIBS" +- rm -f conf.clntest +- if test "$cross_compiling" = yes; then +- echo $ac_n "cross compiling; assumed OK... $ac_c" +-else +- cat >conftest.$ac_ext <<_ACEOF ++ # Is the header compilable? ++echo "$as_me:$LINENO: checking libintl.h usability" >&5 ++echo $ECHO_N "checking libintl.h usability... $ECHO_C" >&6 ++cat >conftest.$ac_ext <<_ACEOF + /* confdefs.h. */ + _ACEOF + cat confdefs.h >>conftest.$ac_ext + cat >>conftest.$ac_ext <<_ACEOF + /* end confdefs.h. */ +- +-#include +-#include +-#include +- +-/* we do not #include because autoconf in C++ mode inserts a +- prototype for exit() that conflicts with the one in stdlib.h */ +-extern "C" int system(const char *); +- +-int main(void) +-{ +- system("touch conf.clntest"); +- +- if ((CL_VERSION_MAJOR != $cln_config_major_version) || +- (CL_VERSION_MINOR != $cln_config_minor_version) || +- (CL_VERSION_PATCHLEVEL != $cln_config_micro_version)) { +- printf("\n*** 'cln-config --version' returned %d.%d.%d, but the header file I found\n", $cln_config_major_version, $cln_config_minor_version, $cln_config_micro_version); +- printf("*** corresponds to %d.%d.%d. This mismatch suggests your installation of CLN\n", CL_VERSION_MAJOR, CL_VERSION_MINOR, CL_VERSION_PATCHLEVEL); +- printf("*** is corrupted or you have specified some wrong -I compiler flags.\n"); +- printf("*** Please inquire and consider reinstalling CLN.\n"); +- return 1; +- } +- if ((cln::version_major != $cln_config_major_version) || +- (cln::version_minor != $cln_config_minor_version) || +- (cln::version_patchlevel != $cln_config_micro_version)) { +- printf("\n*** 'cln-config --version' returned %d.%d.%d, but the library I found\n", $cln_config_major_version, $cln_config_minor_version, $cln_config_micro_version); +- printf("*** corresponds to %d.%d.%d. This mismatch suggests your installation of CLN\n", cln::version_major, cln::version_minor, cln::version_patchlevel); +- printf("*** is corrupted or you have specified some wrong -L compiler flags.\n"); +- printf("*** Please inquire and consider reinstalling CLN.\n"); +- return 1; +- } +- return 0; +-} +- ++$ac_includes_default ++#include + _ACEOF +-rm -f conftest$ac_exeext +-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 +- (eval $ac_link) 2>&5 ++rm -f conftest.$ac_objext ++if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 ++ (eval $ac_compile) 2>conftest.er1 + ac_status=$? ++ grep -v '^ *+' conftest.er1 >conftest.err ++ rm -f conftest.er1 ++ cat conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); } && { ac_try='./conftest$ac_exeext' ++ (exit $ac_status); } && ++ { ac_try='test -z "$ac_cxx_werror_flag" ++ || test ! -s conftest.err' ++ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 ++ (eval $ac_try) 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; } && ++ { ac_try='test -s conftest.$ac_objext' + { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then +- : ++ ac_header_compiler=yes + else +- echo "$as_me: program exited with status $ac_status" >&5 +-echo "$as_me: failed program was:" >&5 ++ echo "$as_me: failed program was:" >&5 + sed 's/^/| /' conftest.$ac_ext >&5 + +-( exit $ac_status ) +-no_cln=yes +-fi +-rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext ++ac_header_compiler=no + fi +- CPPFLAGS="$ac_save_CPPFLAGS" +- LIBS="$ac_save_LIBS" +- fi +- if test "x$no_cln" = x ; then +- echo "$as_me:$LINENO: result: yes, $cln_config_version" >&5 +-echo "${ECHO_T}yes, $cln_config_version" >&6 +- +- LIBS="$LIBS $CLN_LIBS" +- CPPFLAGS="$CPPFLAGS $CLN_CPPFLAGS" +- +-cat >>confdefs.h <<\_ACEOF +-#define HAVE_LIBCLN 1 +-_ACEOF +- ++rm -f conftest.err conftest.$ac_objext conftest.$ac_ext ++echo "$as_me:$LINENO: result: $ac_header_compiler" >&5 ++echo "${ECHO_T}$ac_header_compiler" >&6 + +- else +- echo "$as_me:$LINENO: result: no" >&5 +-echo "${ECHO_T}no" >&6 +- if test ! -f conf.clntest ; then +- echo "*** Could not run CLN test program, checking why..." +- CPPFLAGS="$CFLAGS $CLN_CPPFLAGS" +- LIBS="$LIBS $CLN_LIBS" +- cat >conftest.$ac_ext <<_ACEOF ++# Is the header present? ++echo "$as_me:$LINENO: checking libintl.h presence" >&5 ++echo $ECHO_N "checking libintl.h presence... $ECHO_C" >&6 ++cat >conftest.$ac_ext <<_ACEOF + /* confdefs.h. */ + _ACEOF + cat confdefs.h >>conftest.$ac_ext + cat >>conftest.$ac_ext <<_ACEOF + /* end confdefs.h. */ +- +-#include +-#include +- +-int +-main () +-{ +- return 0; +- ; +- return 0; +-} ++#include + _ACEOF +-rm -f conftest.$ac_objext conftest$ac_exeext +-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 +- (eval $ac_link) 2>conftest.er1 ++if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5 ++ (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 + ac_status=$? + grep -v '^ *+' conftest.er1 >conftest.err + rm -f conftest.er1 + cat conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); } && +- { ac_try='test -z "$ac_cxx_werror_flag" +- || test ! -s conftest.err' +- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 +- (eval $ac_try) 2>&5 +- ac_status=$? +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; } && +- { ac_try='test -s conftest$ac_exeext' +- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 +- (eval $ac_try) 2>&5 +- ac_status=$? +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; }; then +- echo "*** The test program compiled, but did not run. This usually means" +- echo "*** that the run-time linker is not finding CLN or finding the wrong" +- echo "*** version of CLN. If it is not finding CLN, you'll need to set your" +- echo "*** LD_LIBRARY_PATH environment variable, or edit /etc/ld.so.conf to point" +- echo "*** to the installed location. Also, make sure you have run ldconfig if that" +- echo "*** is required on your system." ++ (exit $ac_status); } >/dev/null; then ++ if test -s conftest.err; then ++ ac_cpp_err=$ac_cxx_preproc_warn_flag ++ ac_cpp_err=$ac_cpp_err$ac_cxx_werror_flag ++ else ++ ac_cpp_err= ++ fi ++else ++ ac_cpp_err=yes ++fi ++if test -z "$ac_cpp_err"; then ++ ac_header_preproc=yes + else + echo "$as_me: failed program was:" >&5 + sed 's/^/| /' conftest.$ac_ext >&5 + +- echo "*** The test program failed to compile or link. See the file config.log for the" +- echo "*** exact error that occured. This usually means CLN was incorrectly installed" +- echo "*** or that you have moved CLN since it was installed. In the latter case, you" +- echo "*** may want to edit the cln-config script: $CLN_CONFIG." +-fi +-rm -f conftest.err conftest.$ac_objext \ +- conftest$ac_exeext conftest.$ac_ext +- CPPFLAGS="$ac_save_CPPFLAGS" +- LIBS="$ac_save_LIBS" +- fi +- CLN_CPPFLAGS="" +- CLN_LIBS="" +- { { echo "$as_me:$LINENO: error: No suitable installed version of CLN could be found." >&5 +-echo "$as_me: error: No suitable installed version of CLN could be found." >&2;} +- { (exit 1); exit 1; }; } +- fi +- fi ++ ac_header_preproc=no + fi ++rm -f conftest.err conftest.$ac_ext ++echo "$as_me:$LINENO: result: $ac_header_preproc" >&5 ++echo "${ECHO_T}$ac_header_preproc" >&6 + +- +-rm -f conf.clntest +- +- +- +- +-if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then +- if test -n "$ac_tool_prefix"; then +- # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args. +-set dummy ${ac_tool_prefix}pkg-config; ac_word=$2 +-echo "$as_me:$LINENO: checking for $ac_word" >&5 +-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 +-if test "${ac_cv_path_PKG_CONFIG+set}" = set; then ++# So? What about this header? ++case $ac_header_compiler:$ac_header_preproc:$ac_cxx_preproc_warn_flag in ++ yes:no: ) ++ { echo "$as_me:$LINENO: WARNING: libintl.h: accepted by the compiler, rejected by the preprocessor!" >&5 ++echo "$as_me: WARNING: libintl.h: accepted by the compiler, rejected by the preprocessor!" >&2;} ++ { echo "$as_me:$LINENO: WARNING: libintl.h: proceeding with the compiler's result" >&5 ++echo "$as_me: WARNING: libintl.h: proceeding with the compiler's result" >&2;} ++ ac_header_preproc=yes ++ ;; ++ no:yes:* ) ++ { echo "$as_me:$LINENO: WARNING: libintl.h: present but cannot be compiled" >&5 ++echo "$as_me: WARNING: libintl.h: present but cannot be compiled" >&2;} ++ { echo "$as_me:$LINENO: WARNING: libintl.h: check for missing prerequisite headers?" >&5 ++echo "$as_me: WARNING: libintl.h: check for missing prerequisite headers?" >&2;} ++ { echo "$as_me:$LINENO: WARNING: libintl.h: see the Autoconf documentation" >&5 ++echo "$as_me: WARNING: libintl.h: see the Autoconf documentation" >&2;} ++ { echo "$as_me:$LINENO: WARNING: libintl.h: section \"Present But Cannot Be Compiled\"" >&5 ++echo "$as_me: WARNING: libintl.h: section \"Present But Cannot Be Compiled\"" >&2;} ++ { echo "$as_me:$LINENO: WARNING: libintl.h: proceeding with the preprocessor's result" >&5 ++echo "$as_me: WARNING: libintl.h: proceeding with the preprocessor's result" >&2;} ++ { echo "$as_me:$LINENO: WARNING: libintl.h: in the future, the compiler will take precedence" >&5 ++echo "$as_me: WARNING: libintl.h: in the future, the compiler will take precedence" >&2;} ++ ( ++ cat <<\_ASBOX ++## ------------------------------------------ ## ++## Report this to the AC_PACKAGE_NAME lists. ## ++## ------------------------------------------ ## ++_ASBOX ++ ) | ++ sed "s/^/$as_me: WARNING: /" >&2 ++ ;; ++esac ++echo "$as_me:$LINENO: checking for libintl.h" >&5 ++echo $ECHO_N "checking for libintl.h... $ECHO_C" >&6 ++if test "${ac_cv_header_libintl_h+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 + else +- case $PKG_CONFIG in +- [\\/]* | ?:[\\/]*) +- ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path. +- ;; +- *) +- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +-for as_dir in $PATH +-do +- IFS=$as_save_IFS +- test -z "$as_dir" && as_dir=. +- for ac_exec_ext in '' $ac_executable_extensions; do +- if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then +- ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" +- echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 +- break 2 +- fi +-done +-done +- +- ;; +-esac ++ ac_cv_header_libintl_h=$ac_header_preproc + fi +-PKG_CONFIG=$ac_cv_path_PKG_CONFIG ++echo "$as_me:$LINENO: result: $ac_cv_header_libintl_h" >&5 ++echo "${ECHO_T}$ac_cv_header_libintl_h" >&6 + +-if test -n "$PKG_CONFIG"; then +- echo "$as_me:$LINENO: result: $PKG_CONFIG" >&5 +-echo "${ECHO_T}$PKG_CONFIG" >&6 +-else +- echo "$as_me:$LINENO: result: no" >&5 +-echo "${ECHO_T}no" >&6 + fi ++if test $ac_cv_header_libintl_h = yes; then ++ gt_cv_func_dgettext_libintl="no" ++ libintl_extra_libs="" + +-fi +-if test -z "$ac_cv_path_PKG_CONFIG"; then +- ac_pt_PKG_CONFIG=$PKG_CONFIG +- # Extract the first word of "pkg-config", so it can be a program name with args. +-set dummy pkg-config; ac_word=$2 +-echo "$as_me:$LINENO: checking for $ac_word" >&5 +-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 +-if test "${ac_cv_path_ac_pt_PKG_CONFIG+set}" = set; then ++ # ++ # First check in libc ++ # ++ echo "$as_me:$LINENO: checking for ngettext in libc" >&5 ++echo $ECHO_N "checking for ngettext in libc... $ECHO_C" >&6 ++if test "${gt_cv_func_ngettext_libc+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 + else +- case $ac_pt_PKG_CONFIG in +- [\\/]* | ?:[\\/]*) +- ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path. +- ;; +- *) +- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +-for as_dir in $PATH +-do +- IFS=$as_save_IFS +- test -z "$as_dir" && as_dir=. +- for ac_exec_ext in '' $ac_executable_extensions; do +- if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then +- ac_cv_path_ac_pt_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" +- echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 +- break 2 +- fi +-done +-done ++ cat >conftest.$ac_ext <<_ACEOF ++/* confdefs.h. */ ++_ACEOF ++cat confdefs.h >>conftest.$ac_ext ++cat >>conftest.$ac_ext <<_ACEOF ++/* end confdefs.h. */ + +- ;; +-esac +-fi +-ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG ++#include + +-if test -n "$ac_pt_PKG_CONFIG"; then +- echo "$as_me:$LINENO: result: $ac_pt_PKG_CONFIG" >&5 +-echo "${ECHO_T}$ac_pt_PKG_CONFIG" >&6 ++int ++main () ++{ ++return !ngettext ("","", 1) ++ ; ++ return 0; ++} ++_ACEOF ++rm -f conftest.$ac_objext conftest$ac_exeext ++if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 ++ (eval $ac_link) 2>conftest.er1 ++ ac_status=$? ++ grep -v '^ *+' conftest.er1 >conftest.err ++ rm -f conftest.er1 ++ cat conftest.err >&5 ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); } && ++ { ac_try='test -z "$ac_cxx_werror_flag" ++ || test ! -s conftest.err' ++ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 ++ (eval $ac_try) 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; } && ++ { ac_try='test -s conftest$ac_exeext' ++ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 ++ (eval $ac_try) 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; }; then ++ gt_cv_func_ngettext_libc=yes + else +- echo "$as_me:$LINENO: result: no" >&5 +-echo "${ECHO_T}no" >&6 +-fi ++ echo "$as_me: failed program was:" >&5 ++sed 's/^/| /' conftest.$ac_ext >&5 + +- PKG_CONFIG=$ac_pt_PKG_CONFIG +-else +- PKG_CONFIG="$ac_cv_path_PKG_CONFIG" ++gt_cv_func_ngettext_libc=no + fi ++rm -f conftest.err conftest.$ac_objext \ ++ conftest$ac_exeext conftest.$ac_ext + + fi +-if test -n "$PKG_CONFIG"; then +- _pkg_min_version=0.9.0 +- echo "$as_me:$LINENO: checking pkg-config is at least version $_pkg_min_version" >&5 +-echo $ECHO_N "checking pkg-config is at least version $_pkg_min_version... $ECHO_C" >&6 +- if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then +- echo "$as_me:$LINENO: result: yes" >&5 +-echo "${ECHO_T}yes" >&6 +- else +- echo "$as_me:$LINENO: result: no" >&5 +-echo "${ECHO_T}no" >&6 +- PKG_CONFIG="" +- fi ++echo "$as_me:$LINENO: result: $gt_cv_func_ngettext_libc" >&5 ++echo "${ECHO_T}$gt_cv_func_ngettext_libc" >&6 + +-fi ++ if test "$gt_cv_func_ngettext_libc" = "yes" ; then ++ echo "$as_me:$LINENO: checking for dgettext in libc" >&5 ++echo $ECHO_N "checking for dgettext in libc... $ECHO_C" >&6 ++if test "${gt_cv_func_dgettext_libc+set}" = set; then ++ echo $ECHO_N "(cached) $ECHO_C" >&6 ++else ++ cat >conftest.$ac_ext <<_ACEOF ++/* confdefs.h. */ ++_ACEOF ++cat confdefs.h >>conftest.$ac_ext ++cat >>conftest.$ac_ext <<_ACEOF ++/* end confdefs.h. */ + +-pkg_failed=no +-echo "$as_me:$LINENO: checking for GLIB" >&5 +-echo $ECHO_N "checking for GLIB... $ECHO_C" >&6 ++#include + +-if test -n "$PKG_CONFIG"; then +- if test -n "$GLIB_CFLAGS"; then +- pkg_cv_GLIB_CFLAGS="$GLIB_CFLAGS" +- else +- if test -n "$PKG_CONFIG" && \ +- { (echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \" +- glib-2.0 >= 2.4 +- libxml-2.0 +- \"") >&5 +- ($PKG_CONFIG --exists --print-errors " +- glib-2.0 >= 2.4 +- libxml-2.0 +- ") 2>&5 ++int ++main () ++{ ++return !dgettext ("","") ++ ; ++ return 0; ++} ++_ACEOF ++rm -f conftest.$ac_objext conftest$ac_exeext ++if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 ++ (eval $ac_link) 2>conftest.er1 ++ ac_status=$? ++ grep -v '^ *+' conftest.er1 >conftest.err ++ rm -f conftest.er1 ++ cat conftest.err >&5 ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); } && ++ { ac_try='test -z "$ac_cxx_werror_flag" ++ || test ! -s conftest.err' ++ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 ++ (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; then +- pkg_cv_GLIB_CFLAGS=`$PKG_CONFIG --cflags " +- glib-2.0 >= 2.4 +- libxml-2.0 +- " 2>/dev/null` ++ (exit $ac_status); }; } && ++ { ac_try='test -s conftest$ac_exeext' ++ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 ++ (eval $ac_try) 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; }; then ++ gt_cv_func_dgettext_libc=yes + else +- pkg_failed=yes ++ echo "$as_me: failed program was:" >&5 ++sed 's/^/| /' conftest.$ac_ext >&5 ++ ++gt_cv_func_dgettext_libc=no + fi +- fi +-else +- pkg_failed=untried ++rm -f conftest.err conftest.$ac_objext \ ++ conftest$ac_exeext conftest.$ac_ext ++ + fi +-if test -n "$PKG_CONFIG"; then +- if test -n "$GLIB_LIBS"; then +- pkg_cv_GLIB_LIBS="$GLIB_LIBS" +- else +- if test -n "$PKG_CONFIG" && \ +- { (echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \" +- glib-2.0 >= 2.4 +- libxml-2.0 +- \"") >&5 +- ($PKG_CONFIG --exists --print-errors " +- glib-2.0 >= 2.4 +- libxml-2.0 +- ") 2>&5 +- ac_status=$? +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; then +- pkg_cv_GLIB_LIBS=`$PKG_CONFIG --libs " +- glib-2.0 >= 2.4 +- libxml-2.0 +- " 2>/dev/null` +-else +- pkg_failed=yes +-fi +- fi +-else +- pkg_failed=untried +-fi +- +- +- +-if test $pkg_failed = yes; then +- +-if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then +- _pkg_short_errors_supported=yes +-else +- _pkg_short_errors_supported=no +-fi +- if test $_pkg_short_errors_supported = yes; then +- GLIB_PKG_ERRORS=`$PKG_CONFIG --short-errors --errors-to-stdout --print-errors " +- glib-2.0 >= 2.4 +- libxml-2.0 +- "` +- else +- GLIB_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors " +- glib-2.0 >= 2.4 +- libxml-2.0 +- "` +- fi +- # Put the nasty error message in config.log where it belongs +- echo "$GLIB_PKG_ERRORS" >&5 +- +- { { echo "$as_me:$LINENO: error: Package requirements ( +- glib-2.0 >= 2.4 +- libxml-2.0 +- ) were not met: +- +-$GLIB_PKG_ERRORS +- +-Consider adjusting the PKG_CONFIG_PATH environment variable if you +-installed software in a non-standard prefix. +- +-Alternatively, you may set the environment variables GLIB_CFLAGS +-and GLIB_LIBS to avoid the need to call pkg-config. +-See the pkg-config man page for more details. +-" >&5 +-echo "$as_me: error: Package requirements ( +- glib-2.0 >= 2.4 +- libxml-2.0 +- ) were not met: +- +-$GLIB_PKG_ERRORS +- +-Consider adjusting the PKG_CONFIG_PATH environment variable if you +-installed software in a non-standard prefix. +- +-Alternatively, you may set the environment variables GLIB_CFLAGS +-and GLIB_LIBS to avoid the need to call pkg-config. +-See the pkg-config man page for more details. +-" >&2;} +- { (exit 1); exit 1; }; } +-elif test $pkg_failed = untried; then +- { { echo "$as_me:$LINENO: error: The pkg-config script could not be found or is too old. Make sure it +-is in your PATH or set the PKG_CONFIG environment variable to the full +-path to pkg-config. +- +-Alternatively, you may set the environment variables GLIB_CFLAGS +-and GLIB_LIBS to avoid the need to call pkg-config. +-See the pkg-config man page for more details. +- +-To get pkg-config, see . +-See \`config.log' for more details." >&5 +-echo "$as_me: error: The pkg-config script could not be found or is too old. Make sure it +-is in your PATH or set the PKG_CONFIG environment variable to the full +-path to pkg-config. +- +-Alternatively, you may set the environment variables GLIB_CFLAGS +-and GLIB_LIBS to avoid the need to call pkg-config. +-See the pkg-config man page for more details. +- +-To get pkg-config, see . +-See \`config.log' for more details." >&2;} +- { (exit 1); exit 1; }; } +-else +- GLIB_CFLAGS=$pkg_cv_GLIB_CFLAGS +- GLIB_LIBS=$pkg_cv_GLIB_LIBS +- echo "$as_me:$LINENO: result: yes" >&5 +-echo "${ECHO_T}yes" >&6 +- : +-fi +- +- +- +- +-pkg_failed=no +-echo "$as_me:$LINENO: checking for GTK" >&5 +-echo $ECHO_N "checking for GTK... $ECHO_C" >&6 +- +-if test -n "$PKG_CONFIG"; then +- if test -n "$GTK_CFLAGS"; then +- pkg_cv_GTK_CFLAGS="$GTK_CFLAGS" +- else +- if test -n "$PKG_CONFIG" && \ +- { (echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \" +- gtk+-2.0 >= 2.4 +- gdk-pixbuf-2.0 +- \"") >&5 +- ($PKG_CONFIG --exists --print-errors " +- gtk+-2.0 >= 2.4 +- gdk-pixbuf-2.0 +- ") 2>&5 +- ac_status=$? +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; then +- pkg_cv_GTK_CFLAGS=`$PKG_CONFIG --cflags " +- gtk+-2.0 >= 2.4 +- gdk-pixbuf-2.0 +- " 2>/dev/null` +-else +- pkg_failed=yes +-fi +- fi +-else +- pkg_failed=untried +-fi +-if test -n "$PKG_CONFIG"; then +- if test -n "$GTK_LIBS"; then +- pkg_cv_GTK_LIBS="$GTK_LIBS" +- else +- if test -n "$PKG_CONFIG" && \ +- { (echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \" +- gtk+-2.0 >= 2.4 +- gdk-pixbuf-2.0 +- \"") >&5 +- ($PKG_CONFIG --exists --print-errors " +- gtk+-2.0 >= 2.4 +- gdk-pixbuf-2.0 +- ") 2>&5 +- ac_status=$? +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; then +- pkg_cv_GTK_LIBS=`$PKG_CONFIG --libs " +- gtk+-2.0 >= 2.4 +- gdk-pixbuf-2.0 +- " 2>/dev/null` +-else +- pkg_failed=yes +-fi +- fi +-else +- pkg_failed=untried +-fi +- +- +- +-if test $pkg_failed = yes; then +- +-if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then +- _pkg_short_errors_supported=yes +-else +- _pkg_short_errors_supported=no +-fi +- if test $_pkg_short_errors_supported = yes; then +- GTK_PKG_ERRORS=`$PKG_CONFIG --short-errors --errors-to-stdout --print-errors " +- gtk+-2.0 >= 2.4 +- gdk-pixbuf-2.0 +- "` +- else +- GTK_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors " +- gtk+-2.0 >= 2.4 +- gdk-pixbuf-2.0 +- "` +- fi +- # Put the nasty error message in config.log where it belongs +- echo "$GTK_PKG_ERRORS" >&5 +- +- { { echo "$as_me:$LINENO: error: Package requirements ( +- gtk+-2.0 >= 2.4 +- gdk-pixbuf-2.0 +- ) were not met: +- +-$GTK_PKG_ERRORS +- +-Consider adjusting the PKG_CONFIG_PATH environment variable if you +-installed software in a non-standard prefix. +- +-Alternatively, you may set the environment variables GTK_CFLAGS +-and GTK_LIBS to avoid the need to call pkg-config. +-See the pkg-config man page for more details. +-" >&5 +-echo "$as_me: error: Package requirements ( +- gtk+-2.0 >= 2.4 +- gdk-pixbuf-2.0 +- ) were not met: +- +-$GTK_PKG_ERRORS +- +-Consider adjusting the PKG_CONFIG_PATH environment variable if you +-installed software in a non-standard prefix. +- +-Alternatively, you may set the environment variables GTK_CFLAGS +-and GTK_LIBS to avoid the need to call pkg-config. +-See the pkg-config man page for more details. +-" >&2;} +- { (exit 1); exit 1; }; } +-elif test $pkg_failed = untried; then +- { { echo "$as_me:$LINENO: error: The pkg-config script could not be found or is too old. Make sure it +-is in your PATH or set the PKG_CONFIG environment variable to the full +-path to pkg-config. +- +-Alternatively, you may set the environment variables GTK_CFLAGS +-and GTK_LIBS to avoid the need to call pkg-config. +-See the pkg-config man page for more details. +- +-To get pkg-config, see . +-See \`config.log' for more details." >&5 +-echo "$as_me: error: The pkg-config script could not be found or is too old. Make sure it +-is in your PATH or set the PKG_CONFIG environment variable to the full +-path to pkg-config. +- +-Alternatively, you may set the environment variables GTK_CFLAGS +-and GTK_LIBS to avoid the need to call pkg-config. +-See the pkg-config man page for more details. +- +-To get pkg-config, see . +-See \`config.log' for more details." >&2;} +- { (exit 1); exit 1; }; } +-else +- GTK_CFLAGS=$pkg_cv_GTK_CFLAGS +- GTK_LIBS=$pkg_cv_GTK_LIBS +- echo "$as_me:$LINENO: result: yes" >&5 +-echo "${ECHO_T}yes" >&6 +- : +-fi +- +- +- +- +-pkg_failed=no +-echo "$as_me:$LINENO: checking for QALCULATE" >&5 +-echo $ECHO_N "checking for QALCULATE... $ECHO_C" >&6 +- +-if test -n "$PKG_CONFIG"; then +- if test -n "$QALCULATE_CFLAGS"; then +- pkg_cv_QALCULATE_CFLAGS="$QALCULATE_CFLAGS" +- else +- if test -n "$PKG_CONFIG" && \ +- { (echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \" +- libqalculate >= 0.9.4 +- \"") >&5 +- ($PKG_CONFIG --exists --print-errors " +- libqalculate >= 0.9.4 +- ") 2>&5 +- ac_status=$? +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; then +- pkg_cv_QALCULATE_CFLAGS=`$PKG_CONFIG --cflags " +- libqalculate >= 0.9.4 +- " 2>/dev/null` +-else +- pkg_failed=yes +-fi +- fi +-else +- pkg_failed=untried +-fi +-if test -n "$PKG_CONFIG"; then +- if test -n "$QALCULATE_LIBS"; then +- pkg_cv_QALCULATE_LIBS="$QALCULATE_LIBS" +- else +- if test -n "$PKG_CONFIG" && \ +- { (echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \" +- libqalculate >= 0.9.4 +- \"") >&5 +- ($PKG_CONFIG --exists --print-errors " +- libqalculate >= 0.9.4 +- ") 2>&5 +- ac_status=$? +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; then +- pkg_cv_QALCULATE_LIBS=`$PKG_CONFIG --libs " +- libqalculate >= 0.9.4 +- " 2>/dev/null` +-else +- pkg_failed=yes +-fi +- fi +-else +- pkg_failed=untried +-fi +- +- +- +-if test $pkg_failed = yes; then +- +-if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then +- _pkg_short_errors_supported=yes +-else +- _pkg_short_errors_supported=no +-fi +- if test $_pkg_short_errors_supported = yes; then +- QALCULATE_PKG_ERRORS=`$PKG_CONFIG --short-errors --errors-to-stdout --print-errors " +- libqalculate >= 0.9.4 +- "` +- else +- QALCULATE_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors " +- libqalculate >= 0.9.4 +- "` +- fi +- # Put the nasty error message in config.log where it belongs +- echo "$QALCULATE_PKG_ERRORS" >&5 +- +- { { echo "$as_me:$LINENO: error: Package requirements ( +- libqalculate >= 0.9.4 +- ) were not met: +- +-$QALCULATE_PKG_ERRORS +- +-Consider adjusting the PKG_CONFIG_PATH environment variable if you +-installed software in a non-standard prefix. +- +-Alternatively, you may set the environment variables QALCULATE_CFLAGS +-and QALCULATE_LIBS to avoid the need to call pkg-config. +-See the pkg-config man page for more details. +-" >&5 +-echo "$as_me: error: Package requirements ( +- libqalculate >= 0.9.4 +- ) were not met: +- +-$QALCULATE_PKG_ERRORS +- +-Consider adjusting the PKG_CONFIG_PATH environment variable if you +-installed software in a non-standard prefix. +- +-Alternatively, you may set the environment variables QALCULATE_CFLAGS +-and QALCULATE_LIBS to avoid the need to call pkg-config. +-See the pkg-config man page for more details. +-" >&2;} +- { (exit 1); exit 1; }; } +-elif test $pkg_failed = untried; then +- { { echo "$as_me:$LINENO: error: The pkg-config script could not be found or is too old. Make sure it +-is in your PATH or set the PKG_CONFIG environment variable to the full +-path to pkg-config. +- +-Alternatively, you may set the environment variables QALCULATE_CFLAGS +-and QALCULATE_LIBS to avoid the need to call pkg-config. +-See the pkg-config man page for more details. +- +-To get pkg-config, see . +-See \`config.log' for more details." >&5 +-echo "$as_me: error: The pkg-config script could not be found or is too old. Make sure it +-is in your PATH or set the PKG_CONFIG environment variable to the full +-path to pkg-config. +- +-Alternatively, you may set the environment variables QALCULATE_CFLAGS +-and QALCULATE_LIBS to avoid the need to call pkg-config. +-See the pkg-config man page for more details. +- +-To get pkg-config, see . +-See \`config.log' for more details." >&2;} +- { (exit 1); exit 1; }; } +-else +- QALCULATE_CFLAGS=$pkg_cv_QALCULATE_CFLAGS +- QALCULATE_LIBS=$pkg_cv_QALCULATE_LIBS +- echo "$as_me:$LINENO: result: yes" >&5 +-echo "${ECHO_T}yes" >&6 +- : +-fi +- +- +- +- +-GETTEXT_PACKAGE=qalculate-bases +- +- +-cat >>confdefs.h <<_ACEOF +-#define GETTEXT_PACKAGE "$GETTEXT_PACKAGE" +-_ACEOF +- +- +-ALL_LINGUAS="nl sv" +- ++echo "$as_me:$LINENO: result: $gt_cv_func_dgettext_libc" >&5 ++echo "${ECHO_T}$gt_cv_func_dgettext_libc" >&6 ++ fi + ++ if test "$gt_cv_func_ngettext_libc" = "yes" ; then + +-for ac_header in locale.h ++for ac_func in bind_textdomain_codeset + do +-as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh` +-if eval "test \"\${$as_ac_Header+set}\" = set"; then +- echo "$as_me:$LINENO: checking for $ac_header" >&5 +-echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6 +-if eval "test \"\${$as_ac_Header+set}\" = set"; then ++as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh` ++echo "$as_me:$LINENO: checking for $ac_func" >&5 ++echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6 ++if eval "test \"\${$as_ac_var+set}\" = set"; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +-fi +-echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5 +-echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6 + else +- # Is the header compilable? +-echo "$as_me:$LINENO: checking $ac_header usability" >&5 +-echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6 +-cat >conftest.$ac_ext <<_ACEOF ++ cat >conftest.$ac_ext <<_ACEOF + /* confdefs.h. */ + _ACEOF + cat confdefs.h >>conftest.$ac_ext + cat >>conftest.$ac_ext <<_ACEOF + /* end confdefs.h. */ +-$ac_includes_default +-#include <$ac_header> ++/* Define $ac_func to an innocuous variant, in case declares $ac_func. ++ For example, HP-UX 11i declares gettimeofday. */ ++#define $ac_func innocuous_$ac_func ++ ++/* System header to define __stub macros and hopefully few prototypes, ++ which can conflict with char $ac_func (); below. ++ Prefer to if __STDC__ is defined, since ++ exists even on freestanding compilers. */ ++ ++#ifdef __STDC__ ++# include ++#else ++# include ++#endif ++ ++#undef $ac_func ++ ++/* Override any gcc2 internal prototype to avoid an error. */ ++#ifdef __cplusplus ++extern "C" ++{ ++#endif ++/* We use char because int might match the return type of a gcc2 ++ builtin and then its argument prototype would still apply. */ ++char $ac_func (); ++/* The GNU C library defines this for functions which it implements ++ to always fail with ENOSYS. Some functions are actually named ++ something starting with __ and the normal name is an alias. */ ++#if defined (__stub_$ac_func) || defined (__stub___$ac_func) ++choke me ++#else ++char (*f) () = $ac_func; ++#endif ++#ifdef __cplusplus ++} ++#endif ++ ++int ++main () ++{ ++return f != $ac_func; ++ ; ++ return 0; ++} + _ACEOF +-rm -f conftest.$ac_objext +-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 +- (eval $ac_compile) 2>conftest.er1 ++rm -f conftest.$ac_objext conftest$ac_exeext ++if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 ++ (eval $ac_link) 2>conftest.er1 + ac_status=$? + grep -v '^ *+' conftest.er1 >conftest.err + rm -f conftest.er1 +@@ -21008,132 +20636,131 @@ if { (eval echo "$as_me:$LINENO: \"$ac_c + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; } && +- { ac_try='test -s conftest.$ac_objext' ++ { ac_try='test -s conftest$ac_exeext' + { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then +- ac_header_compiler=yes ++ eval "$as_ac_var=yes" + else + echo "$as_me: failed program was:" >&5 + sed 's/^/| /' conftest.$ac_ext >&5 + +-ac_header_compiler=no ++eval "$as_ac_var=no" + fi +-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext +-echo "$as_me:$LINENO: result: $ac_header_compiler" >&5 +-echo "${ECHO_T}$ac_header_compiler" >&6 ++rm -f conftest.err conftest.$ac_objext \ ++ conftest$ac_exeext conftest.$ac_ext ++fi ++echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5 ++echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6 ++if test `eval echo '${'$as_ac_var'}'` = yes; then ++ cat >>confdefs.h <<_ACEOF ++#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1 ++_ACEOF + +-# Is the header present? +-echo "$as_me:$LINENO: checking $ac_header presence" >&5 +-echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6 ++fi ++done ++ ++ fi ++ ++ # ++ # If we don't have everything we want, check in libintl ++ # ++ if test "$gt_cv_func_dgettext_libc" != "yes" \ ++ || test "$gt_cv_func_ngettext_libc" != "yes" \ ++ || test "$ac_cv_func_bind_textdomain_codeset" != "yes" ; then ++ ++ echo "$as_me:$LINENO: checking for bindtextdomain in -lintl" >&5 ++echo $ECHO_N "checking for bindtextdomain in -lintl... $ECHO_C" >&6 ++if test "${ac_cv_lib_intl_bindtextdomain+set}" = set; then ++ echo $ECHO_N "(cached) $ECHO_C" >&6 ++else ++ ac_check_lib_save_LIBS=$LIBS ++LIBS="-lintl $LIBS" + cat >conftest.$ac_ext <<_ACEOF + /* confdefs.h. */ + _ACEOF + cat confdefs.h >>conftest.$ac_ext + cat >>conftest.$ac_ext <<_ACEOF + /* end confdefs.h. */ +-#include <$ac_header> ++ ++/* Override any gcc2 internal prototype to avoid an error. */ ++#ifdef __cplusplus ++extern "C" ++#endif ++/* We use char because int might match the return type of a gcc2 ++ builtin and then its argument prototype would still apply. */ ++char bindtextdomain (); ++int ++main () ++{ ++bindtextdomain (); ++ ; ++ return 0; ++} + _ACEOF +-if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5 +- (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 ++rm -f conftest.$ac_objext conftest$ac_exeext ++if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 ++ (eval $ac_link) 2>conftest.er1 + ac_status=$? + grep -v '^ *+' conftest.er1 >conftest.err + rm -f conftest.er1 + cat conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); } >/dev/null; then +- if test -s conftest.err; then +- ac_cpp_err=$ac_cxx_preproc_warn_flag +- ac_cpp_err=$ac_cpp_err$ac_cxx_werror_flag +- else +- ac_cpp_err= +- fi +-else +- ac_cpp_err=yes +-fi +-if test -z "$ac_cpp_err"; then +- ac_header_preproc=yes +-else +- echo "$as_me: failed program was:" >&5 +-sed 's/^/| /' conftest.$ac_ext >&5 +- +- ac_header_preproc=no +-fi +-rm -f conftest.err conftest.$ac_ext +-echo "$as_me:$LINENO: result: $ac_header_preproc" >&5 +-echo "${ECHO_T}$ac_header_preproc" >&6 +- +-# So? What about this header? +-case $ac_header_compiler:$ac_header_preproc:$ac_cxx_preproc_warn_flag in +- yes:no: ) +- { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5 +-echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;} +- { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5 +-echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;} +- ac_header_preproc=yes +- ;; +- no:yes:* ) +- { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5 +-echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;} +- { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5 +-echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;} +- { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5 +-echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;} +- { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5 +-echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;} +- { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5 +-echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;} +- { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5 +-echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;} +- ( +- cat <<\_ASBOX +-## ------------------------------------------ ## +-## Report this to the AC_PACKAGE_NAME lists. ## +-## ------------------------------------------ ## +-_ASBOX +- ) | +- sed "s/^/$as_me: WARNING: /" >&2 +- ;; +-esac +-echo "$as_me:$LINENO: checking for $ac_header" >&5 +-echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6 +-if eval "test \"\${$as_ac_Header+set}\" = set"; then +- echo $ECHO_N "(cached) $ECHO_C" >&6 ++ (exit $ac_status); } && ++ { ac_try='test -z "$ac_cxx_werror_flag" ++ || test ! -s conftest.err' ++ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 ++ (eval $ac_try) 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; } && ++ { ac_try='test -s conftest$ac_exeext' ++ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 ++ (eval $ac_try) 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; }; then ++ ac_cv_lib_intl_bindtextdomain=yes + else +- eval "$as_ac_Header=\$ac_header_preproc" +-fi +-echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5 +-echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6 ++ echo "$as_me: failed program was:" >&5 ++sed 's/^/| /' conftest.$ac_ext >&5 + ++ac_cv_lib_intl_bindtextdomain=no + fi +-if test `eval echo '${'$as_ac_Header'}'` = yes; then +- cat >>confdefs.h <<_ACEOF +-#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1 +-_ACEOF +- ++rm -f conftest.err conftest.$ac_objext \ ++ conftest$ac_exeext conftest.$ac_ext ++LIBS=$ac_check_lib_save_LIBS + fi +- +-done +- +- if test $ac_cv_header_locale_h = yes; then +- echo "$as_me:$LINENO: checking for LC_MESSAGES" >&5 +-echo $ECHO_N "checking for LC_MESSAGES... $ECHO_C" >&6 +-if test "${am_cv_val_LC_MESSAGES+set}" = set; then ++echo "$as_me:$LINENO: result: $ac_cv_lib_intl_bindtextdomain" >&5 ++echo "${ECHO_T}$ac_cv_lib_intl_bindtextdomain" >&6 ++if test $ac_cv_lib_intl_bindtextdomain = yes; then ++ echo "$as_me:$LINENO: checking for ngettext in -lintl" >&5 ++echo $ECHO_N "checking for ngettext in -lintl... $ECHO_C" >&6 ++if test "${ac_cv_lib_intl_ngettext+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 + else +- cat >conftest.$ac_ext <<_ACEOF ++ ac_check_lib_save_LIBS=$LIBS ++LIBS="-lintl $LIBS" ++cat >conftest.$ac_ext <<_ACEOF + /* confdefs.h. */ + _ACEOF + cat confdefs.h >>conftest.$ac_ext + cat >>conftest.$ac_ext <<_ACEOF + /* end confdefs.h. */ +-#include ++ ++/* Override any gcc2 internal prototype to avoid an error. */ ++#ifdef __cplusplus ++extern "C" ++#endif ++/* We use char because int might match the return type of a gcc2 ++ builtin and then its argument prototype would still apply. */ ++char ngettext (); + int + main () + { +-return LC_MESSAGES ++ngettext (); + ; + return 0; + } +@@ -21160,59 +20787,52 @@ if { (eval echo "$as_me:$LINENO: \"$ac_l + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then +- am_cv_val_LC_MESSAGES=yes ++ ac_cv_lib_intl_ngettext=yes + else + echo "$as_me: failed program was:" >&5 + sed 's/^/| /' conftest.$ac_ext >&5 + +-am_cv_val_LC_MESSAGES=no ++ac_cv_lib_intl_ngettext=no + fi + rm -f conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext ++LIBS=$ac_check_lib_save_LIBS + fi +-echo "$as_me:$LINENO: result: $am_cv_val_LC_MESSAGES" >&5 +-echo "${ECHO_T}$am_cv_val_LC_MESSAGES" >&6 +- if test $am_cv_val_LC_MESSAGES = yes; then +- +-cat >>confdefs.h <<\_ACEOF +-#define HAVE_LC_MESSAGES 1 +-_ACEOF +- +- fi +- fi +- USE_NLS=yes +- +- +- gt_cv_have_gettext=no +- +- CATOBJEXT=NONE +- XGETTEXT=: +- INTLLIBS= +- +- if test "${ac_cv_header_libintl_h+set}" = set; then +- echo "$as_me:$LINENO: checking for libintl.h" >&5 +-echo $ECHO_N "checking for libintl.h... $ECHO_C" >&6 +-if test "${ac_cv_header_libintl_h+set}" = set; then ++echo "$as_me:$LINENO: result: $ac_cv_lib_intl_ngettext" >&5 ++echo "${ECHO_T}$ac_cv_lib_intl_ngettext" >&6 ++if test $ac_cv_lib_intl_ngettext = yes; then ++ echo "$as_me:$LINENO: checking for dgettext in -lintl" >&5 ++echo $ECHO_N "checking for dgettext in -lintl... $ECHO_C" >&6 ++if test "${ac_cv_lib_intl_dgettext+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +-fi +-echo "$as_me:$LINENO: result: $ac_cv_header_libintl_h" >&5 +-echo "${ECHO_T}$ac_cv_header_libintl_h" >&6 + else +- # Is the header compilable? +-echo "$as_me:$LINENO: checking libintl.h usability" >&5 +-echo $ECHO_N "checking libintl.h usability... $ECHO_C" >&6 ++ ac_check_lib_save_LIBS=$LIBS ++LIBS="-lintl $LIBS" + cat >conftest.$ac_ext <<_ACEOF + /* confdefs.h. */ + _ACEOF + cat confdefs.h >>conftest.$ac_ext + cat >>conftest.$ac_ext <<_ACEOF + /* end confdefs.h. */ +-$ac_includes_default +-#include ++ ++/* Override any gcc2 internal prototype to avoid an error. */ ++#ifdef __cplusplus ++extern "C" ++#endif ++/* We use char because int might match the return type of a gcc2 ++ builtin and then its argument prototype would still apply. */ ++char dgettext (); ++int ++main () ++{ ++dgettext (); ++ ; ++ return 0; ++} + _ACEOF +-rm -f conftest.$ac_objext +-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 +- (eval $ac_compile) 2>conftest.er1 ++rm -f conftest.$ac_objext conftest$ac_exeext ++if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 ++ (eval $ac_link) 2>conftest.er1 + ac_status=$? + grep -v '^ *+' conftest.er1 >conftest.err + rm -f conftest.er1 +@@ -21226,131 +20846,129 @@ if { (eval echo "$as_me:$LINENO: \"$ac_c + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; } && +- { ac_try='test -s conftest.$ac_objext' ++ { ac_try='test -s conftest$ac_exeext' + { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then +- ac_header_compiler=yes ++ ac_cv_lib_intl_dgettext=yes + else + echo "$as_me: failed program was:" >&5 + sed 's/^/| /' conftest.$ac_ext >&5 + +-ac_header_compiler=no ++ac_cv_lib_intl_dgettext=no ++fi ++rm -f conftest.err conftest.$ac_objext \ ++ conftest$ac_exeext conftest.$ac_ext ++LIBS=$ac_check_lib_save_LIBS ++fi ++echo "$as_me:$LINENO: result: $ac_cv_lib_intl_dgettext" >&5 ++echo "${ECHO_T}$ac_cv_lib_intl_dgettext" >&6 ++if test $ac_cv_lib_intl_dgettext = yes; then ++ gt_cv_func_dgettext_libintl=yes + fi +-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext +-echo "$as_me:$LINENO: result: $ac_header_compiler" >&5 +-echo "${ECHO_T}$ac_header_compiler" >&6 + +-# Is the header present? +-echo "$as_me:$LINENO: checking libintl.h presence" >&5 +-echo $ECHO_N "checking libintl.h presence... $ECHO_C" >&6 ++fi ++ ++fi ++ ++ ++ if test "$gt_cv_func_dgettext_libintl" != "yes" ; then ++ echo "$as_me:$LINENO: checking if -liconv is needed to use gettext" >&5 ++echo $ECHO_N "checking if -liconv is needed to use gettext... $ECHO_C" >&6 ++ echo "$as_me:$LINENO: result: " >&5 ++echo "${ECHO_T}" >&6 ++ echo "$as_me:$LINENO: checking for ngettext in -lintl" >&5 ++echo $ECHO_N "checking for ngettext in -lintl... $ECHO_C" >&6 ++if test "${ac_cv_lib_intl_ngettext+set}" = set; then ++ echo $ECHO_N "(cached) $ECHO_C" >&6 ++else ++ ac_check_lib_save_LIBS=$LIBS ++LIBS="-lintl -liconv $LIBS" + cat >conftest.$ac_ext <<_ACEOF + /* confdefs.h. */ + _ACEOF + cat confdefs.h >>conftest.$ac_ext + cat >>conftest.$ac_ext <<_ACEOF + /* end confdefs.h. */ +-#include ++ ++/* Override any gcc2 internal prototype to avoid an error. */ ++#ifdef __cplusplus ++extern "C" ++#endif ++/* We use char because int might match the return type of a gcc2 ++ builtin and then its argument prototype would still apply. */ ++char ngettext (); ++int ++main () ++{ ++ngettext (); ++ ; ++ return 0; ++} + _ACEOF +-if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5 +- (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 ++rm -f conftest.$ac_objext conftest$ac_exeext ++if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 ++ (eval $ac_link) 2>conftest.er1 + ac_status=$? + grep -v '^ *+' conftest.er1 >conftest.err + rm -f conftest.er1 + cat conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); } >/dev/null; then +- if test -s conftest.err; then +- ac_cpp_err=$ac_cxx_preproc_warn_flag +- ac_cpp_err=$ac_cpp_err$ac_cxx_werror_flag +- else +- ac_cpp_err= +- fi +-else +- ac_cpp_err=yes +-fi +-if test -z "$ac_cpp_err"; then +- ac_header_preproc=yes ++ (exit $ac_status); } && ++ { ac_try='test -z "$ac_cxx_werror_flag" ++ || test ! -s conftest.err' ++ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 ++ (eval $ac_try) 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; } && ++ { ac_try='test -s conftest$ac_exeext' ++ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 ++ (eval $ac_try) 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; }; then ++ ac_cv_lib_intl_ngettext=yes + else + echo "$as_me: failed program was:" >&5 +-sed 's/^/| /' conftest.$ac_ext >&5 +- +- ac_header_preproc=no +-fi +-rm -f conftest.err conftest.$ac_ext +-echo "$as_me:$LINENO: result: $ac_header_preproc" >&5 +-echo "${ECHO_T}$ac_header_preproc" >&6 +- +-# So? What about this header? +-case $ac_header_compiler:$ac_header_preproc:$ac_cxx_preproc_warn_flag in +- yes:no: ) +- { echo "$as_me:$LINENO: WARNING: libintl.h: accepted by the compiler, rejected by the preprocessor!" >&5 +-echo "$as_me: WARNING: libintl.h: accepted by the compiler, rejected by the preprocessor!" >&2;} +- { echo "$as_me:$LINENO: WARNING: libintl.h: proceeding with the compiler's result" >&5 +-echo "$as_me: WARNING: libintl.h: proceeding with the compiler's result" >&2;} +- ac_header_preproc=yes +- ;; +- no:yes:* ) +- { echo "$as_me:$LINENO: WARNING: libintl.h: present but cannot be compiled" >&5 +-echo "$as_me: WARNING: libintl.h: present but cannot be compiled" >&2;} +- { echo "$as_me:$LINENO: WARNING: libintl.h: check for missing prerequisite headers?" >&5 +-echo "$as_me: WARNING: libintl.h: check for missing prerequisite headers?" >&2;} +- { echo "$as_me:$LINENO: WARNING: libintl.h: see the Autoconf documentation" >&5 +-echo "$as_me: WARNING: libintl.h: see the Autoconf documentation" >&2;} +- { echo "$as_me:$LINENO: WARNING: libintl.h: section \"Present But Cannot Be Compiled\"" >&5 +-echo "$as_me: WARNING: libintl.h: section \"Present But Cannot Be Compiled\"" >&2;} +- { echo "$as_me:$LINENO: WARNING: libintl.h: proceeding with the preprocessor's result" >&5 +-echo "$as_me: WARNING: libintl.h: proceeding with the preprocessor's result" >&2;} +- { echo "$as_me:$LINENO: WARNING: libintl.h: in the future, the compiler will take precedence" >&5 +-echo "$as_me: WARNING: libintl.h: in the future, the compiler will take precedence" >&2;} +- ( +- cat <<\_ASBOX +-## ------------------------------------------ ## +-## Report this to the AC_PACKAGE_NAME lists. ## +-## ------------------------------------------ ## +-_ASBOX +- ) | +- sed "s/^/$as_me: WARNING: /" >&2 +- ;; +-esac +-echo "$as_me:$LINENO: checking for libintl.h" >&5 +-echo $ECHO_N "checking for libintl.h... $ECHO_C" >&6 +-if test "${ac_cv_header_libintl_h+set}" = set; then +- echo $ECHO_N "(cached) $ECHO_C" >&6 +-else +- ac_cv_header_libintl_h=$ac_header_preproc +-fi +-echo "$as_me:$LINENO: result: $ac_cv_header_libintl_h" >&5 +-echo "${ECHO_T}$ac_cv_header_libintl_h" >&6 ++sed 's/^/| /' conftest.$ac_ext >&5 + ++ac_cv_lib_intl_ngettext=no + fi +-if test $ac_cv_header_libintl_h = yes; then +- gt_cv_func_dgettext_libintl="no" +- libintl_extra_libs="" +- +- # +- # First check in libc +- # +- echo "$as_me:$LINENO: checking for ngettext in libc" >&5 +-echo $ECHO_N "checking for ngettext in libc... $ECHO_C" >&6 +-if test "${gt_cv_func_ngettext_libc+set}" = set; then ++rm -f conftest.err conftest.$ac_objext \ ++ conftest$ac_exeext conftest.$ac_ext ++LIBS=$ac_check_lib_save_LIBS ++fi ++echo "$as_me:$LINENO: result: $ac_cv_lib_intl_ngettext" >&5 ++echo "${ECHO_T}$ac_cv_lib_intl_ngettext" >&6 ++if test $ac_cv_lib_intl_ngettext = yes; then ++ echo "$as_me:$LINENO: checking for dcgettext in -lintl" >&5 ++echo $ECHO_N "checking for dcgettext in -lintl... $ECHO_C" >&6 ++if test "${ac_cv_lib_intl_dcgettext+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 + else +- cat >conftest.$ac_ext <<_ACEOF ++ ac_check_lib_save_LIBS=$LIBS ++LIBS="-lintl -liconv $LIBS" ++cat >conftest.$ac_ext <<_ACEOF + /* confdefs.h. */ + _ACEOF + cat confdefs.h >>conftest.$ac_ext + cat >>conftest.$ac_ext <<_ACEOF + /* end confdefs.h. */ + +-#include +- ++/* Override any gcc2 internal prototype to avoid an error. */ ++#ifdef __cplusplus ++extern "C" ++#endif ++/* We use char because int might match the return type of a gcc2 ++ builtin and then its argument prototype would still apply. */ ++char dcgettext (); + int + main () + { +-return !ngettext ("","", 1) ++dcgettext (); + ; + return 0; + } +@@ -21377,24 +20995,48 @@ if { (eval echo "$as_me:$LINENO: \"$ac_l + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then +- gt_cv_func_ngettext_libc=yes ++ ac_cv_lib_intl_dcgettext=yes + else + echo "$as_me: failed program was:" >&5 + sed 's/^/| /' conftest.$ac_ext >&5 + +-gt_cv_func_ngettext_libc=no ++ac_cv_lib_intl_dcgettext=no + fi + rm -f conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext ++LIBS=$ac_check_lib_save_LIBS ++fi ++echo "$as_me:$LINENO: result: $ac_cv_lib_intl_dcgettext" >&5 ++echo "${ECHO_T}$ac_cv_lib_intl_dcgettext" >&6 ++if test $ac_cv_lib_intl_dcgettext = yes; then ++ gt_cv_func_dgettext_libintl=yes ++ libintl_extra_libs=-liconv ++else ++ : ++fi + ++else ++ : + fi +-echo "$as_me:$LINENO: result: $gt_cv_func_ngettext_libc" >&5 +-echo "${ECHO_T}$gt_cv_func_ngettext_libc" >&6 + +- if test "$gt_cv_func_ngettext_libc" = "yes" ; then +- echo "$as_me:$LINENO: checking for dgettext in libc" >&5 +-echo $ECHO_N "checking for dgettext in libc... $ECHO_C" >&6 +-if test "${gt_cv_func_dgettext_libc+set}" = set; then ++ fi ++ ++ # ++ # If we found libintl, then check in it for bind_textdomain_codeset(); ++ # we'll prefer libc if neither have bind_textdomain_codeset(), ++ # and both have dgettext and ngettext ++ # ++ if test "$gt_cv_func_dgettext_libintl" = "yes" ; then ++ glib_save_LIBS="$LIBS" ++ LIBS="$LIBS -lintl $libintl_extra_libs" ++ unset ac_cv_func_bind_textdomain_codeset ++ ++for ac_func in bind_textdomain_codeset ++do ++as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh` ++echo "$as_me:$LINENO: checking for $ac_func" >&5 ++echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6 ++if eval "test \"\${$as_ac_var+set}\" = set"; then + echo $ECHO_N "(cached) $ECHO_C" >&6 + else + cat >conftest.$ac_ext <<_ACEOF +@@ -21403,13 +21045,47 @@ _ACEOF + cat confdefs.h >>conftest.$ac_ext + cat >>conftest.$ac_ext <<_ACEOF + /* end confdefs.h. */ ++/* Define $ac_func to an innocuous variant, in case declares $ac_func. ++ For example, HP-UX 11i declares gettimeofday. */ ++#define $ac_func innocuous_$ac_func + +-#include ++/* System header to define __stub macros and hopefully few prototypes, ++ which can conflict with char $ac_func (); below. ++ Prefer to if __STDC__ is defined, since ++ exists even on freestanding compilers. */ ++ ++#ifdef __STDC__ ++# include ++#else ++# include ++#endif ++ ++#undef $ac_func ++ ++/* Override any gcc2 internal prototype to avoid an error. */ ++#ifdef __cplusplus ++extern "C" ++{ ++#endif ++/* We use char because int might match the return type of a gcc2 ++ builtin and then its argument prototype would still apply. */ ++char $ac_func (); ++/* The GNU C library defines this for functions which it implements ++ to always fail with ENOSYS. Some functions are actually named ++ something starting with __ and the normal name is an alias. */ ++#if defined (__stub_$ac_func) || defined (__stub___$ac_func) ++choke me ++#else ++char (*f) () = $ac_func; ++#endif ++#ifdef __cplusplus ++} ++#endif + + int + main () + { +-return !dgettext ("","") ++return f != $ac_func; + ; + return 0; + } +@@ -21436,24 +21112,94 @@ if { (eval echo "$as_me:$LINENO: \"$ac_l + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then +- gt_cv_func_dgettext_libc=yes ++ eval "$as_ac_var=yes" + else + echo "$as_me: failed program was:" >&5 + sed 's/^/| /' conftest.$ac_ext >&5 + +-gt_cv_func_dgettext_libc=no ++eval "$as_ac_var=no" + fi + rm -f conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext ++fi ++echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5 ++echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6 ++if test `eval echo '${'$as_ac_var'}'` = yes; then ++ cat >>confdefs.h <<_ACEOF ++#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1 ++_ACEOF + + fi +-echo "$as_me:$LINENO: result: $gt_cv_func_dgettext_libc" >&5 +-echo "${ECHO_T}$gt_cv_func_dgettext_libc" >&6 ++done ++ ++ LIBS="$glib_save_LIBS" ++ ++ if test "$ac_cv_func_bind_textdomain_codeset" = "yes" ; then ++ gt_cv_func_dgettext_libc=no ++ else ++ if test "$gt_cv_func_dgettext_libc" = "yes" \ ++ && test "$gt_cv_func_ngettext_libc" = "yes"; then ++ gt_cv_func_dgettext_libintl=no ++ fi ++ fi ++ fi + fi + +- if test "$gt_cv_func_ngettext_libc" = "yes" ; then ++ if test "$gt_cv_func_dgettext_libc" = "yes" \ ++ || test "$gt_cv_func_dgettext_libintl" = "yes"; then ++ gt_cv_have_gettext=yes ++ fi + +-for ac_func in bind_textdomain_codeset ++ if test "$gt_cv_func_dgettext_libintl" = "yes"; then ++ INTLLIBS="-lintl $libintl_extra_libs" ++ fi ++ ++ if test "$gt_cv_have_gettext" = "yes"; then ++ ++cat >>confdefs.h <<\_ACEOF ++#define HAVE_GETTEXT 1 ++_ACEOF ++ ++ # Extract the first word of "msgfmt", so it can be a program name with args. ++set dummy msgfmt; ac_word=$2 ++echo "$as_me:$LINENO: checking for $ac_word" >&5 ++echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 ++if test "${ac_cv_path_MSGFMT+set}" = set; then ++ echo $ECHO_N "(cached) $ECHO_C" >&6 ++else ++ case "$MSGFMT" in ++ /*) ++ ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path. ++ ;; ++ *) ++ IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" ++ for ac_dir in $PATH; do ++ test -z "$ac_dir" && ac_dir=. ++ if test -f $ac_dir/$ac_word; then ++ if test -z "`$ac_dir/$ac_word -h 2>&1 | grep 'dv '`"; then ++ ac_cv_path_MSGFMT="$ac_dir/$ac_word" ++ break ++ fi ++ fi ++ done ++ IFS="$ac_save_ifs" ++ test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT="no" ++ ;; ++esac ++fi ++MSGFMT="$ac_cv_path_MSGFMT" ++if test "$MSGFMT" != "no"; then ++ echo "$as_me:$LINENO: result: $MSGFMT" >&5 ++echo "${ECHO_T}$MSGFMT" >&6 ++else ++ echo "$as_me:$LINENO: result: no" >&5 ++echo "${ECHO_T}no" >&6 ++fi ++ if test "$MSGFMT" != "no"; then ++ glib_save_LIBS="$LIBS" ++ LIBS="$LIBS $INTLLIBS" ++ ++for ac_func in dcgettext + do + as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh` + echo "$as_me:$LINENO: checking for $ac_func" >&5 +@@ -21554,40 +21300,94 @@ _ACEOF + fi + done + ++ # Extract the first word of "gmsgfmt", so it can be a program name with args. ++set dummy gmsgfmt; ac_word=$2 ++echo "$as_me:$LINENO: checking for $ac_word" >&5 ++echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 ++if test "${ac_cv_path_GMSGFMT+set}" = set; then ++ echo $ECHO_N "(cached) $ECHO_C" >&6 ++else ++ case $GMSGFMT in ++ [\\/]* | ?:[\\/]*) ++ ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path. ++ ;; ++ *) ++ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR ++for as_dir in $PATH ++do ++ IFS=$as_save_IFS ++ test -z "$as_dir" && as_dir=. ++ for ac_exec_ext in '' $ac_executable_extensions; do ++ if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ++ ac_cv_path_GMSGFMT="$as_dir/$ac_word$ac_exec_ext" ++ echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 ++ break 2 ++ fi ++done ++done ++ ++ test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT" ++ ;; ++esac ++fi ++GMSGFMT=$ac_cv_path_GMSGFMT ++ ++if test -n "$GMSGFMT"; then ++ echo "$as_me:$LINENO: result: $GMSGFMT" >&5 ++echo "${ECHO_T}$GMSGFMT" >&6 ++else ++ echo "$as_me:$LINENO: result: no" >&5 ++echo "${ECHO_T}no" >&6 ++fi ++ ++ # Extract the first word of "xgettext", so it can be a program name with args. ++set dummy xgettext; ac_word=$2 ++echo "$as_me:$LINENO: checking for $ac_word" >&5 ++echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 ++if test "${ac_cv_path_XGETTEXT+set}" = set; then ++ echo $ECHO_N "(cached) $ECHO_C" >&6 ++else ++ case "$XGETTEXT" in ++ /*) ++ ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path. ++ ;; ++ *) ++ IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" ++ for ac_dir in $PATH; do ++ test -z "$ac_dir" && ac_dir=. ++ if test -f $ac_dir/$ac_word; then ++ if test -z "`$ac_dir/$ac_word -h 2>&1 | grep '(HELP)'`"; then ++ ac_cv_path_XGETTEXT="$ac_dir/$ac_word" ++ break + fi +- +- # +- # If we don't have everything we want, check in libintl +- # +- if test "$gt_cv_func_dgettext_libc" != "yes" \ +- || test "$gt_cv_func_ngettext_libc" != "yes" \ +- || test "$ac_cv_func_bind_textdomain_codeset" != "yes" ; then +- +- echo "$as_me:$LINENO: checking for bindtextdomain in -lintl" >&5 +-echo $ECHO_N "checking for bindtextdomain in -lintl... $ECHO_C" >&6 +-if test "${ac_cv_lib_intl_bindtextdomain+set}" = set; then +- echo $ECHO_N "(cached) $ECHO_C" >&6 ++ fi ++ done ++ IFS="$ac_save_ifs" ++ test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":" ++ ;; ++esac ++fi ++XGETTEXT="$ac_cv_path_XGETTEXT" ++if test "$XGETTEXT" != ":"; then ++ echo "$as_me:$LINENO: result: $XGETTEXT" >&5 ++echo "${ECHO_T}$XGETTEXT" >&6 + else +- ac_check_lib_save_LIBS=$LIBS +-LIBS="-lintl $LIBS" +-cat >conftest.$ac_ext <<_ACEOF ++ echo "$as_me:$LINENO: result: no" >&5 ++echo "${ECHO_T}no" >&6 ++fi ++ ++ cat >conftest.$ac_ext <<_ACEOF + /* confdefs.h. */ + _ACEOF + cat confdefs.h >>conftest.$ac_ext + cat >>conftest.$ac_ext <<_ACEOF + /* end confdefs.h. */ + +-/* Override any gcc2 internal prototype to avoid an error. */ +-#ifdef __cplusplus +-extern "C" +-#endif +-/* We use char because int might match the return type of a gcc2 +- builtin and then its argument prototype would still apply. */ +-char bindtextdomain (); + int + main () + { +-bindtextdomain (); ++extern int _nl_msg_cat_cntr; ++ return _nl_msg_cat_cntr + ; + return 0; + } +@@ -21614,45 +21414,66 @@ if { (eval echo "$as_me:$LINENO: \"$ac_l + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then +- ac_cv_lib_intl_bindtextdomain=yes ++ CATOBJEXT=.gmo ++ DATADIRNAME=share + else + echo "$as_me: failed program was:" >&5 + sed 's/^/| /' conftest.$ac_ext >&5 + +-ac_cv_lib_intl_bindtextdomain=no +-fi +-rm -f conftest.err conftest.$ac_objext \ +- conftest$ac_exeext conftest.$ac_ext +-LIBS=$ac_check_lib_save_LIBS +-fi +-echo "$as_me:$LINENO: result: $ac_cv_lib_intl_bindtextdomain" >&5 +-echo "${ECHO_T}$ac_cv_lib_intl_bindtextdomain" >&6 +-if test $ac_cv_lib_intl_bindtextdomain = yes; then +- echo "$as_me:$LINENO: checking for ngettext in -lintl" >&5 +-echo $ECHO_N "checking for ngettext in -lintl... $ECHO_C" >&6 +-if test "${ac_cv_lib_intl_ngettext+set}" = set; then ++case $host in ++ *-*-solaris*) ++ echo "$as_me:$LINENO: checking for bind_textdomain_codeset" >&5 ++echo $ECHO_N "checking for bind_textdomain_codeset... $ECHO_C" >&6 ++if test "${ac_cv_func_bind_textdomain_codeset+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 + else +- ac_check_lib_save_LIBS=$LIBS +-LIBS="-lintl $LIBS" +-cat >conftest.$ac_ext <<_ACEOF ++ cat >conftest.$ac_ext <<_ACEOF + /* confdefs.h. */ + _ACEOF + cat confdefs.h >>conftest.$ac_ext + cat >>conftest.$ac_ext <<_ACEOF + /* end confdefs.h. */ ++/* Define bind_textdomain_codeset to an innocuous variant, in case declares bind_textdomain_codeset. ++ For example, HP-UX 11i declares gettimeofday. */ ++#define bind_textdomain_codeset innocuous_bind_textdomain_codeset ++ ++/* System header to define __stub macros and hopefully few prototypes, ++ which can conflict with char bind_textdomain_codeset (); below. ++ Prefer to if __STDC__ is defined, since ++ exists even on freestanding compilers. */ ++ ++#ifdef __STDC__ ++# include ++#else ++# include ++#endif ++ ++#undef bind_textdomain_codeset + + /* Override any gcc2 internal prototype to avoid an error. */ + #ifdef __cplusplus + extern "C" ++{ + #endif + /* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +-char ngettext (); ++char bind_textdomain_codeset (); ++/* The GNU C library defines this for functions which it implements ++ to always fail with ENOSYS. Some functions are actually named ++ something starting with __ and the normal name is an alias. */ ++#if defined (__stub_bind_textdomain_codeset) || defined (__stub___bind_textdomain_codeset) ++choke me ++#else ++char (*f) () = bind_textdomain_codeset; ++#endif ++#ifdef __cplusplus ++} ++#endif ++ + int + main () + { +-ngettext (); ++return f != bind_textdomain_codeset; + ; + return 0; + } +@@ -21679,27 +21500,176 @@ if { (eval echo "$as_me:$LINENO: \"$ac_l + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then +- ac_cv_lib_intl_ngettext=yes ++ ac_cv_func_bind_textdomain_codeset=yes + else + echo "$as_me: failed program was:" >&5 + sed 's/^/| /' conftest.$ac_ext >&5 + +-ac_cv_lib_intl_ngettext=no +-fi +-rm -f conftest.err conftest.$ac_objext \ +- conftest$ac_exeext conftest.$ac_ext +-LIBS=$ac_check_lib_save_LIBS +-fi +-echo "$as_me:$LINENO: result: $ac_cv_lib_intl_ngettext" >&5 +-echo "${ECHO_T}$ac_cv_lib_intl_ngettext" >&6 +-if test $ac_cv_lib_intl_ngettext = yes; then +- echo "$as_me:$LINENO: checking for dgettext in -lintl" >&5 +-echo $ECHO_N "checking for dgettext in -lintl... $ECHO_C" >&6 +-if test "${ac_cv_lib_intl_dgettext+set}" = set; then ++ac_cv_func_bind_textdomain_codeset=no ++fi ++rm -f conftest.err conftest.$ac_objext \ ++ conftest$ac_exeext conftest.$ac_ext ++fi ++echo "$as_me:$LINENO: result: $ac_cv_func_bind_textdomain_codeset" >&5 ++echo "${ECHO_T}$ac_cv_func_bind_textdomain_codeset" >&6 ++if test $ac_cv_func_bind_textdomain_codeset = yes; then ++ CATOBJEXT=.gmo ++ DATADIRNAME=share ++else ++ CATOBJEXT=.mo ++ DATADIRNAME=lib ++fi ++ ++ ;; ++ *) ++ CATOBJEXT=.mo ++ DATADIRNAME=lib ++ ;; ++ esac ++fi ++rm -f conftest.err conftest.$ac_objext \ ++ conftest$ac_exeext conftest.$ac_ext ++ LIBS="$glib_save_LIBS" ++ INSTOBJEXT=.mo ++ else ++ gt_cv_have_gettext=no ++ fi ++ fi ++ ++fi ++ ++ ++ ++ if test "$gt_cv_have_gettext" = "yes" ; then ++ ++cat >>confdefs.h <<\_ACEOF ++#define ENABLE_NLS 1 ++_ACEOF ++ ++ fi ++ ++ if test "$XGETTEXT" != ":"; then ++ if $XGETTEXT --omit-header /dev/null 2> /dev/null; then ++ : ; ++ else ++ echo "$as_me:$LINENO: result: found xgettext program is not GNU xgettext; ignore it" >&5 ++echo "${ECHO_T}found xgettext program is not GNU xgettext; ignore it" >&6 ++ XGETTEXT=":" ++ fi ++ fi ++ ++ # We need to process the po/ directory. ++ POSUB=po ++ ++ ac_config_commands="$ac_config_commands default-1" ++ ++ ++ for lang in $ALL_LINGUAS; do ++ GMOFILES="$GMOFILES $lang.gmo" ++ POFILES="$POFILES $lang.po" ++ done ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ if test "$gt_cv_have_gettext" = "yes"; then ++ if test "x$ALL_LINGUAS" = "x"; then ++ LINGUAS= ++ else ++ echo "$as_me:$LINENO: checking for catalogs to be installed" >&5 ++echo $ECHO_N "checking for catalogs to be installed... $ECHO_C" >&6 ++ NEW_LINGUAS= ++ for presentlang in $ALL_LINGUAS; do ++ useit=no ++ if test "%UNSET%" != "${LINGUAS-%UNSET%}"; then ++ desiredlanguages="$LINGUAS" ++ else ++ desiredlanguages="$ALL_LINGUAS" ++ fi ++ for desiredlang in $desiredlanguages; do ++ # Use the presentlang catalog if desiredlang is ++ # a. equal to presentlang, or ++ # b. a variant of presentlang (because in this case, ++ # presentlang can be used as a fallback for messages ++ # which are not translated in the desiredlang catalog). ++ case "$desiredlang" in ++ "$presentlang"*) useit=yes;; ++ esac ++ done ++ if test $useit = yes; then ++ NEW_LINGUAS="$NEW_LINGUAS $presentlang" ++ fi ++ done ++ LINGUAS=$NEW_LINGUAS ++ echo "$as_me:$LINENO: result: $LINGUAS" >&5 ++echo "${ECHO_T}$LINGUAS" >&6 ++ fi ++ ++ if test -n "$LINGUAS"; then ++ for lang in $LINGUAS; do CATALOGS="$CATALOGS $lang$CATOBJEXT"; done ++ fi ++ fi ++ ++ MKINSTALLDIRS= ++ if test -n "$ac_aux_dir"; then ++ MKINSTALLDIRS="$ac_aux_dir/mkinstalldirs" ++ fi ++ if test -z "$MKINSTALLDIRS"; then ++ MKINSTALLDIRS="\$(top_srcdir)/mkinstalldirs" ++ fi ++ ++ ++ test -d po || mkdir po ++ if test "x$srcdir" != "x."; then ++ if test "x`echo $srcdir | sed 's@/.*@@'`" = "x"; then ++ posrcprefix="$srcdir/" ++ else ++ posrcprefix="../$srcdir/" ++ fi ++ else ++ posrcprefix="../" ++ fi ++ rm -f po/POTFILES ++ sed -e "/^#/d" -e "/^\$/d" -e "s,.*, $posrcprefix& \\\\," -e "\$s/\(.*\) \\\\/\1/" \ ++ < $srcdir/po/POTFILES.in > po/POTFILES ++ ++ ++echo "$as_me:$LINENO: checking locale directory" >&5 ++echo $ECHO_N "checking locale directory... $ECHO_C" >&6 ++if test "x$prefix" = "xNONE"; then ++ PACKAGE_LOCALE_DIR=$ac_default_prefix/share/locale ++else ++ PACKAGE_LOCALE_DIR=$prefix/share/locale ++fi ++ ++ ++cat >>confdefs.h <<_ACEOF ++#define PACKAGE_LOCALE_DIR "$PACKAGE_LOCALE_DIR" ++_ACEOF ++ ++ echo "$as_me:$LINENO: result: \"$PACKAGE_LOCALE_DIR\"" >&5 ++echo "${ECHO_T}\"$PACKAGE_LOCALE_DIR\"" >&6 ++ ++INTLTOOL_QALCULATE_DEFINITIONS_RULE='%.xml: %.xml.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po-defs/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -x -u -c $(top_builddir)/po-defs/.intltool-merge-cache $(top_srcdir)/po-defs $< $@' ++ ++ ++ ++echo "$as_me:$LINENO: checking for pthread_create in -lpthread" >&5 ++echo $ECHO_N "checking for pthread_create in -lpthread... $ECHO_C" >&6 ++if test "${ac_cv_lib_pthread_pthread_create+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 + else + ac_check_lib_save_LIBS=$LIBS +-LIBS="-lintl $LIBS" ++LIBS="-lpthread $LIBS" + cat >conftest.$ac_ext <<_ACEOF + /* confdefs.h. */ + _ACEOF +@@ -21713,11 +21683,11 @@ extern "C" + #endif + /* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +-char dgettext (); ++char pthread_create (); + int + main () + { +-dgettext (); ++pthread_create (); + ; + return 0; + } +@@ -21731,7 +21701,7 @@ if { (eval echo "$as_me:$LINENO: \"$ac_l + cat conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } && +- { ac_try='test -z "$ac_cxx_werror_flag" ++ { ac_try='test -z "$ac_c_werror_flag" + || test ! -s conftest.err' + { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 +@@ -21744,192 +21714,159 @@ if { (eval echo "$as_me:$LINENO: \"$ac_l + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then +- ac_cv_lib_intl_dgettext=yes ++ ac_cv_lib_pthread_pthread_create=yes + else + echo "$as_me: failed program was:" >&5 + sed 's/^/| /' conftest.$ac_ext >&5 + +-ac_cv_lib_intl_dgettext=no ++ac_cv_lib_pthread_pthread_create=no + fi + rm -f conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + LIBS=$ac_check_lib_save_LIBS + fi +-echo "$as_me:$LINENO: result: $ac_cv_lib_intl_dgettext" >&5 +-echo "${ECHO_T}$ac_cv_lib_intl_dgettext" >&6 +-if test $ac_cv_lib_intl_dgettext = yes; then +- gt_cv_func_dgettext_libintl=yes ++echo "$as_me:$LINENO: result: $ac_cv_lib_pthread_pthread_create" >&5 ++echo "${ECHO_T}$ac_cv_lib_pthread_pthread_create" >&6 ++if test $ac_cv_lib_pthread_pthread_create = yes; then ++ LIBS="$LIBS -lpthread" + fi + +-fi + +-fi ++ac_ext=cc ++ac_cpp='$CXXCPP $CPPFLAGS' ++ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' ++ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ++ac_compiler_gnu=$ac_cv_cxx_compiler_gnu + + +- if test "$gt_cv_func_dgettext_libintl" != "yes" ; then +- echo "$as_me:$LINENO: checking if -liconv is needed to use gettext" >&5 +-echo $ECHO_N "checking if -liconv is needed to use gettext... $ECHO_C" >&6 +- echo "$as_me:$LINENO: result: " >&5 +-echo "${ECHO_T}" >&6 +- echo "$as_me:$LINENO: checking for ngettext in -lintl" >&5 +-echo $ECHO_N "checking for ngettext in -lintl... $ECHO_C" >&6 +-if test "${ac_cv_lib_intl_ngettext+set}" = set; then +- echo $ECHO_N "(cached) $ECHO_C" >&6 +-else +- ac_check_lib_save_LIBS=$LIBS +-LIBS="-lintl -liconv $LIBS" +-cat >conftest.$ac_ext <<_ACEOF +-/* confdefs.h. */ +-_ACEOF +-cat confdefs.h >>conftest.$ac_ext +-cat >>conftest.$ac_ext <<_ACEOF +-/* end confdefs.h. */ + +-/* Override any gcc2 internal prototype to avoid an error. */ +-#ifdef __cplusplus +-extern "C" +-#endif +-/* We use char because int might match the return type of a gcc2 +- builtin and then its argument prototype would still apply. */ +-char ngettext (); +-int +-main () +-{ +-ngettext (); +- ; +- return 0; +-} +-_ACEOF +-rm -f conftest.$ac_objext conftest$ac_exeext +-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 +- (eval $ac_link) 2>conftest.er1 +- ac_status=$? +- grep -v '^ *+' conftest.er1 >conftest.err +- rm -f conftest.er1 +- cat conftest.err >&5 +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); } && +- { ac_try='test -z "$ac_cxx_werror_flag" +- || test ! -s conftest.err' +- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 +- (eval $ac_try) 2>&5 +- ac_status=$? +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; } && +- { ac_try='test -s conftest$ac_exeext' +- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 +- (eval $ac_try) 2>&5 +- ac_status=$? +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; }; then +- ac_cv_lib_intl_ngettext=yes ++# Check whether --with-cln-prefix or --without-cln-prefix was given. ++if test "${with_cln_prefix+set}" = set; then ++ withval="$with_cln_prefix" ++ cln_config_prefix="$withval" + else +- echo "$as_me: failed program was:" >&5 +-sed 's/^/| /' conftest.$ac_ext >&5 ++ cln_config_prefix="" ++fi; + +-ac_cv_lib_intl_ngettext=no +-fi +-rm -f conftest.err conftest.$ac_objext \ +- conftest$ac_exeext conftest.$ac_ext +-LIBS=$ac_check_lib_save_LIBS +-fi +-echo "$as_me:$LINENO: result: $ac_cv_lib_intl_ngettext" >&5 +-echo "${ECHO_T}$ac_cv_lib_intl_ngettext" >&6 +-if test $ac_cv_lib_intl_ngettext = yes; then +- echo "$as_me:$LINENO: checking for dcgettext in -lintl" >&5 +-echo $ECHO_N "checking for dcgettext in -lintl... $ECHO_C" >&6 +-if test "${ac_cv_lib_intl_dcgettext+set}" = set; then +- echo $ECHO_N "(cached) $ECHO_C" >&6 ++# Check whether --with-cln-exec-prefix or --without-cln-exec-prefix was given. ++if test "${with_cln_exec_prefix+set}" = set; then ++ withval="$with_cln_exec_prefix" ++ cln_config_exec_prefix="$withval" + else +- ac_check_lib_save_LIBS=$LIBS +-LIBS="-lintl -liconv $LIBS" +-cat >conftest.$ac_ext <<_ACEOF +-/* confdefs.h. */ +-_ACEOF +-cat confdefs.h >>conftest.$ac_ext +-cat >>conftest.$ac_ext <<_ACEOF +-/* end confdefs.h. */ ++ cln_config_exec_prefix="" ++fi; ++# Check whether --enable-clntest or --disable-clntest was given. ++if test "${enable_clntest+set}" = set; then ++ enableval="$enable_clntest" + +-/* Override any gcc2 internal prototype to avoid an error. */ +-#ifdef __cplusplus +-extern "C" +-#endif +-/* We use char because int might match the return type of a gcc2 +- builtin and then its argument prototype would still apply. */ +-char dcgettext (); +-int +-main () +-{ +-dcgettext (); +- ; +- return 0; +-} +-_ACEOF +-rm -f conftest.$ac_objext conftest$ac_exeext +-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 +- (eval $ac_link) 2>conftest.er1 +- ac_status=$? +- grep -v '^ *+' conftest.er1 >conftest.err +- rm -f conftest.er1 +- cat conftest.err >&5 +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); } && +- { ac_try='test -z "$ac_cxx_werror_flag" +- || test ! -s conftest.err' +- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 +- (eval $ac_try) 2>&5 +- ac_status=$? +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; } && +- { ac_try='test -s conftest$ac_exeext' +- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 +- (eval $ac_try) 2>&5 +- ac_status=$? +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; }; then +- ac_cv_lib_intl_dcgettext=yes + else +- echo "$as_me: failed program was:" >&5 +-sed 's/^/| /' conftest.$ac_ext >&5 ++ enable_clntest=yes ++fi; + +-ac_cv_lib_intl_dcgettext=no +-fi +-rm -f conftest.err conftest.$ac_objext \ +- conftest$ac_exeext conftest.$ac_ext +-LIBS=$ac_check_lib_save_LIBS ++if test x$cln_config_exec_prefix != x ; then ++ cln_config_args="$cln_config_args --exec-prefix=$cln_config_exec_prefix" ++ if test x${CLN_CONFIG+set} != xset ; then ++ CLN_CONFIG=$cln_config_exec_prefix/bin/cln-config ++ fi + fi +-echo "$as_me:$LINENO: result: $ac_cv_lib_intl_dcgettext" >&5 +-echo "${ECHO_T}$ac_cv_lib_intl_dcgettext" >&6 +-if test $ac_cv_lib_intl_dcgettext = yes; then +- gt_cv_func_dgettext_libintl=yes +- libintl_extra_libs=-liconv +-else +- : ++if test x$cln_config_prefix != x ; then ++ cln_config_args="$cln_config_args --prefix=$cln_config_prefix" ++ if test x${CLN_CONFIG+set} != xset ; then ++ CLN_CONFIG=$cln_config_prefix/bin/cln-config ++ fi + fi + ++# Extract the first word of "cln-config", so it can be a program name with args. ++set dummy cln-config; ac_word=$2 ++echo "$as_me:$LINENO: checking for $ac_word" >&5 ++echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 ++if test "${ac_cv_path_CLN_CONFIG+set}" = set; then ++ echo $ECHO_N "(cached) $ECHO_C" >&6 + else +- : +-fi +- +- fi ++ case $CLN_CONFIG in ++ [\\/]* | ?:[\\/]*) ++ ac_cv_path_CLN_CONFIG="$CLN_CONFIG" # Let the user override the test with a path. ++ ;; ++ *) ++ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR ++for as_dir in $PATH ++do ++ IFS=$as_save_IFS ++ test -z "$as_dir" && as_dir=. ++ for ac_exec_ext in '' $ac_executable_extensions; do ++ if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ++ ac_cv_path_CLN_CONFIG="$as_dir/$ac_word$ac_exec_ext" ++ echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 ++ break 2 ++ fi ++done ++done + +- # +- # If we found libintl, then check in it for bind_textdomain_codeset(); +- # we'll prefer libc if neither have bind_textdomain_codeset(), +- # and both have dgettext and ngettext +- # +- if test "$gt_cv_func_dgettext_libintl" = "yes" ; then +- glib_save_LIBS="$LIBS" +- LIBS="$LIBS -lintl $libintl_extra_libs" +- unset ac_cv_func_bind_textdomain_codeset ++ test -z "$ac_cv_path_CLN_CONFIG" && ac_cv_path_CLN_CONFIG="no" ++ ;; ++esac ++fi ++CLN_CONFIG=$ac_cv_path_CLN_CONFIG + +-for ac_func in bind_textdomain_codeset +-do +-as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh` +-echo "$as_me:$LINENO: checking for $ac_func" >&5 +-echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6 +-if eval "test \"\${$as_ac_var+set}\" = set"; then +- echo $ECHO_N "(cached) $ECHO_C" >&6 ++if test -n "$CLN_CONFIG"; then ++ echo "$as_me:$LINENO: result: $CLN_CONFIG" >&5 ++echo "${ECHO_T}$CLN_CONFIG" >&6 ++else ++ echo "$as_me:$LINENO: result: no" >&5 ++echo "${ECHO_T}no" >&6 ++fi ++ ++cln_min_version=1.1.0 ++echo "$as_me:$LINENO: checking for CLN - version >= $cln_min_version" >&5 ++echo $ECHO_N "checking for CLN - version >= $cln_min_version... $ECHO_C" >&6 ++if test "$CLN_CONFIG" = "no" ; then ++ echo "$as_me:$LINENO: result: no" >&5 ++echo "${ECHO_T}no" >&6 ++ echo "*** The cln-config script installed by CLN could not be found" ++ echo "*** If CLN was installed in PREFIX, make sure PREFIX/bin is in" ++ echo "*** your path, or set the CLN_CONFIG environment variable to the" ++ echo "*** full path to cln-config." ++ { { echo "$as_me:$LINENO: error: No suitable installed version of CLN could be found." >&5 ++echo "$as_me: error: No suitable installed version of CLN could be found." >&2;} ++ { (exit 1); exit 1; }; } ++else ++ cln_min_major_version=`echo $cln_min_version | \ ++ sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\1/'` ++ cln_min_minor_version=`echo $cln_min_version | \ ++ sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\2/'` ++ cln_min_micro_version=`echo $cln_min_version | \ ++ sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\3/'` ++ CLN_CPPFLAGS=`$CLN_CONFIG $cln_config_args --cppflags` ++ CLN_LIBS=`$CLN_CONFIG $cln_config_args --libs` ++ cln_config_version=`$CLN_CONFIG $cln_config_args --version` ++ cln_config_major_version=`echo $cln_config_version | \ ++ sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\1/'` ++ cln_config_minor_version=`echo $cln_config_version | \ ++ sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\2/'` ++ cln_config_micro_version=`echo $cln_config_version | \ ++ sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\3/'` ++ if test \( $cln_config_major_version -lt $cln_min_major_version \) -o \ ++ \( $cln_config_major_version -eq $cln_min_major_version -a $cln_config_minor_version -lt $cln_min_minor_version \) -o \ ++ \( $cln_config_major_version -eq $cln_min_major_version -a $cln_config_minor_version -eq $cln_min_minor_version -a $cln_config_micro_version -lt $cln_min_micro_version \); then ++ echo -e "\n*** 'cln-config --version' returned $cln_config_major_version.$cln_config_minor_version.$cln_config_micro_version, but the minimum version" ++ echo "*** of CLN required is $cln_min_major_version.$cln_min_minor_version.$cln_min_micro_version. If cln-config is correct, then it is" ++ echo "*** best to upgrade to the required version." ++ echo "*** If cln-config was wrong, set the environment variable CLN_CONFIG" ++ echo "*** to point to the correct copy of cln-config, and remove the file" ++ echo "*** config.cache before re-running configure." ++ { { echo "$as_me:$LINENO: error: No suitable installed version of CLN could be found." >&5 ++echo "$as_me: error: No suitable installed version of CLN could be found." >&2;} ++ { (exit 1); exit 1; }; } ++ else ++ no_cln="" ++ if test "x$enable_clntest" = "xyes" ; then ++ ac_save_CPPFLAGS="$CPPFLAGS" ++ ac_save_LIBS="$LIBS" ++ CPPFLAGS="$CPPFLAGS $CLN_CPPFLAGS" ++ LIBS="$LIBS $CLN_LIBS" ++ rm -f conf.clntest ++ if test "$cross_compiling" = yes; then ++ echo $ac_n "cross compiling; assumed OK... $ac_c" + else + cat >conftest.$ac_ext <<_ACEOF + /* confdefs.h. */ +@@ -21937,215 +21874,99 @@ _ACEOF + cat confdefs.h >>conftest.$ac_ext + cat >>conftest.$ac_ext <<_ACEOF + /* end confdefs.h. */ +-/* Define $ac_func to an innocuous variant, in case declares $ac_func. +- For example, HP-UX 11i declares gettimeofday. */ +-#define $ac_func innocuous_$ac_func +- +-/* System header to define __stub macros and hopefully few prototypes, +- which can conflict with char $ac_func (); below. +- Prefer to if __STDC__ is defined, since +- exists even on freestanding compilers. */ + +-#ifdef __STDC__ +-# include +-#else +-# include +-#endif ++#include ++#include ++#include + +-#undef $ac_func ++/* we do not #include because autoconf in C++ mode inserts a ++ prototype for exit() that conflicts with the one in stdlib.h */ ++extern "C" int system(const char *); + +-/* Override any gcc2 internal prototype to avoid an error. */ +-#ifdef __cplusplus +-extern "C" ++int main(void) + { +-#endif +-/* We use char because int might match the return type of a gcc2 +- builtin and then its argument prototype would still apply. */ +-char $ac_func (); +-/* The GNU C library defines this for functions which it implements +- to always fail with ENOSYS. Some functions are actually named +- something starting with __ and the normal name is an alias. */ +-#if defined (__stub_$ac_func) || defined (__stub___$ac_func) +-choke me +-#else +-char (*f) () = $ac_func; +-#endif +-#ifdef __cplusplus +-} +-#endif ++ system("touch conf.clntest"); + +-int +-main () +-{ +-return f != $ac_func; +- ; +- return 0; ++ if ((CL_VERSION_MAJOR != $cln_config_major_version) || ++ (CL_VERSION_MINOR != $cln_config_minor_version) || ++ (CL_VERSION_PATCHLEVEL != $cln_config_micro_version)) { ++ printf("\n*** 'cln-config --version' returned %d.%d.%d, but the header file I found\n", $cln_config_major_version, $cln_config_minor_version, $cln_config_micro_version); ++ printf("*** corresponds to %d.%d.%d. This mismatch suggests your installation of CLN\n", CL_VERSION_MAJOR, CL_VERSION_MINOR, CL_VERSION_PATCHLEVEL); ++ printf("*** is corrupted or you have specified some wrong -I compiler flags.\n"); ++ printf("*** Please inquire and consider reinstalling CLN.\n"); ++ return 1; ++ } ++ if ((cln::version_major != $cln_config_major_version) || ++ (cln::version_minor != $cln_config_minor_version) || ++ (cln::version_patchlevel != $cln_config_micro_version)) { ++ printf("\n*** 'cln-config --version' returned %d.%d.%d, but the library I found\n", $cln_config_major_version, $cln_config_minor_version, $cln_config_micro_version); ++ printf("*** corresponds to %d.%d.%d. This mismatch suggests your installation of CLN\n", cln::version_major, cln::version_minor, cln::version_patchlevel); ++ printf("*** is corrupted or you have specified some wrong -L compiler flags.\n"); ++ printf("*** Please inquire and consider reinstalling CLN.\n"); ++ return 1; ++ } ++ return 0; + } ++ + _ACEOF +-rm -f conftest.$ac_objext conftest$ac_exeext ++rm -f conftest$ac_exeext + if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 +- (eval $ac_link) 2>conftest.er1 +- ac_status=$? +- grep -v '^ *+' conftest.er1 >conftest.err +- rm -f conftest.er1 +- cat conftest.err >&5 +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); } && +- { ac_try='test -z "$ac_cxx_werror_flag" +- || test ! -s conftest.err' +- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 +- (eval $ac_try) 2>&5 ++ (eval $ac_link) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; } && +- { ac_try='test -s conftest$ac_exeext' ++ (exit $ac_status); } && { ac_try='./conftest$ac_exeext' + { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then +- eval "$as_ac_var=yes" ++ : + else +- echo "$as_me: failed program was:" >&5 ++ echo "$as_me: program exited with status $ac_status" >&5 ++echo "$as_me: failed program was:" >&5 + sed 's/^/| /' conftest.$ac_ext >&5 + +-eval "$as_ac_var=no" +-fi +-rm -f conftest.err conftest.$ac_objext \ +- conftest$ac_exeext conftest.$ac_ext ++( exit $ac_status ) ++no_cln=yes + fi +-echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5 +-echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6 +-if test `eval echo '${'$as_ac_var'}'` = yes; then +- cat >>confdefs.h <<_ACEOF +-#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1 +-_ACEOF +- ++rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext + fi +-done +- +- LIBS="$glib_save_LIBS" +- +- if test "$ac_cv_func_bind_textdomain_codeset" = "yes" ; then +- gt_cv_func_dgettext_libc=no +- else +- if test "$gt_cv_func_dgettext_libc" = "yes" \ +- && test "$gt_cv_func_ngettext_libc" = "yes"; then +- gt_cv_func_dgettext_libintl=no +- fi +- fi ++ CPPFLAGS="$ac_save_CPPFLAGS" ++ LIBS="$ac_save_LIBS" + fi +- fi +- +- if test "$gt_cv_func_dgettext_libc" = "yes" \ +- || test "$gt_cv_func_dgettext_libintl" = "yes"; then +- gt_cv_have_gettext=yes +- fi +- +- if test "$gt_cv_func_dgettext_libintl" = "yes"; then +- INTLLIBS="-lintl $libintl_extra_libs" +- fi ++ if test "x$no_cln" = x ; then ++ echo "$as_me:$LINENO: result: yes, $cln_config_version" >&5 ++echo "${ECHO_T}yes, $cln_config_version" >&6 + +- if test "$gt_cv_have_gettext" = "yes"; then ++ LIBS="$LIBS $CLN_LIBS" ++ CPPFLAGS="$CPPFLAGS $CLN_CPPFLAGS" + + cat >>confdefs.h <<\_ACEOF +-#define HAVE_GETTEXT 1 +-_ACEOF +- +- # Extract the first word of "msgfmt", so it can be a program name with args. +-set dummy msgfmt; ac_word=$2 +-echo "$as_me:$LINENO: checking for $ac_word" >&5 +-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 +-if test "${ac_cv_path_MSGFMT+set}" = set; then +- echo $ECHO_N "(cached) $ECHO_C" >&6 +-else +- case "$MSGFMT" in +- /*) +- ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path. +- ;; +- *) +- IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" +- for ac_dir in $PATH; do +- test -z "$ac_dir" && ac_dir=. +- if test -f $ac_dir/$ac_word; then +- if test -z "`$ac_dir/$ac_word -h 2>&1 | grep 'dv '`"; then +- ac_cv_path_MSGFMT="$ac_dir/$ac_word" +- break +- fi +- fi +- done +- IFS="$ac_save_ifs" +- test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT="no" +- ;; +-esac +-fi +-MSGFMT="$ac_cv_path_MSGFMT" +-if test "$MSGFMT" != "no"; then +- echo "$as_me:$LINENO: result: $MSGFMT" >&5 +-echo "${ECHO_T}$MSGFMT" >&6 +-else +- echo "$as_me:$LINENO: result: no" >&5 +-echo "${ECHO_T}no" >&6 +-fi +- if test "$MSGFMT" != "no"; then +- glib_save_LIBS="$LIBS" +- LIBS="$LIBS $INTLLIBS" +- +-for ac_func in dcgettext +-do +-as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh` +-echo "$as_me:$LINENO: checking for $ac_func" >&5 +-echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6 +-if eval "test \"\${$as_ac_var+set}\" = set"; then +- echo $ECHO_N "(cached) $ECHO_C" >&6 +-else +- cat >conftest.$ac_ext <<_ACEOF +-/* confdefs.h. */ ++#define HAVE_LIBCLN 1 + _ACEOF +-cat confdefs.h >>conftest.$ac_ext +-cat >>conftest.$ac_ext <<_ACEOF +-/* end confdefs.h. */ +-/* Define $ac_func to an innocuous variant, in case declares $ac_func. +- For example, HP-UX 11i declares gettimeofday. */ +-#define $ac_func innocuous_$ac_func +- +-/* System header to define __stub macros and hopefully few prototypes, +- which can conflict with char $ac_func (); below. +- Prefer to if __STDC__ is defined, since +- exists even on freestanding compilers. */ + +-#ifdef __STDC__ +-# include +-#else +-# include +-#endif + +-#undef $ac_func ++ else ++ echo "$as_me:$LINENO: result: no" >&5 ++echo "${ECHO_T}no" >&6 ++ if test ! -f conf.clntest ; then ++ echo "*** Could not run CLN test program, checking why..." ++ CPPFLAGS="$CFLAGS $CLN_CPPFLAGS" ++ LIBS="$LIBS $CLN_LIBS" ++ cat >conftest.$ac_ext <<_ACEOF ++/* confdefs.h. */ ++_ACEOF ++cat confdefs.h >>conftest.$ac_ext ++cat >>conftest.$ac_ext <<_ACEOF ++/* end confdefs.h. */ + +-/* Override any gcc2 internal prototype to avoid an error. */ +-#ifdef __cplusplus +-extern "C" +-{ +-#endif +-/* We use char because int might match the return type of a gcc2 +- builtin and then its argument prototype would still apply. */ +-char $ac_func (); +-/* The GNU C library defines this for functions which it implements +- to always fail with ENOSYS. Some functions are actually named +- something starting with __ and the normal name is an alias. */ +-#if defined (__stub_$ac_func) || defined (__stub___$ac_func) +-choke me +-#else +-char (*f) () = $ac_func; +-#endif +-#ifdef __cplusplus +-} +-#endif ++#include ++#include + + int + main () + { +-return f != $ac_func; ++ return 0; + ; + return 0; + } +@@ -22172,36 +21993,53 @@ if { (eval echo "$as_me:$LINENO: \"$ac_l + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then +- eval "$as_ac_var=yes" ++ echo "*** The test program compiled, but did not run. This usually means" ++ echo "*** that the run-time linker is not finding CLN or finding the wrong" ++ echo "*** version of CLN. If it is not finding CLN, you'll need to set your" ++ echo "*** LD_LIBRARY_PATH environment variable, or edit /etc/ld.so.conf to point" ++ echo "*** to the installed location. Also, make sure you have run ldconfig if that" ++ echo "*** is required on your system." + else + echo "$as_me: failed program was:" >&5 + sed 's/^/| /' conftest.$ac_ext >&5 + +-eval "$as_ac_var=no" ++ echo "*** The test program failed to compile or link. See the file config.log for the" ++ echo "*** exact error that occured. This usually means CLN was incorrectly installed" ++ echo "*** or that you have moved CLN since it was installed. In the latter case, you" ++ echo "*** may want to edit the cln-config script: $CLN_CONFIG." + fi + rm -f conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext ++ CPPFLAGS="$ac_save_CPPFLAGS" ++ LIBS="$ac_save_LIBS" ++ fi ++ CLN_CPPFLAGS="" ++ CLN_LIBS="" ++ { { echo "$as_me:$LINENO: error: No suitable installed version of CLN could be found." >&5 ++echo "$as_me: error: No suitable installed version of CLN could be found." >&2;} ++ { (exit 1); exit 1; }; } ++ fi ++ fi + fi +-echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5 +-echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6 +-if test `eval echo '${'$as_ac_var'}'` = yes; then +- cat >>confdefs.h <<_ACEOF +-#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1 +-_ACEOF + +-fi +-done + +- # Extract the first word of "gmsgfmt", so it can be a program name with args. +-set dummy gmsgfmt; ac_word=$2 ++rm -f conf.clntest ++ ++ ++ ++ ++if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then ++ if test -n "$ac_tool_prefix"; then ++ # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args. ++set dummy ${ac_tool_prefix}pkg-config; ac_word=$2 + echo "$as_me:$LINENO: checking for $ac_word" >&5 + echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 +-if test "${ac_cv_path_GMSGFMT+set}" = set; then ++if test "${ac_cv_path_PKG_CONFIG+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 + else +- case $GMSGFMT in ++ case $PKG_CONFIG in + [\\/]* | ?:[\\/]*) +- ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path. ++ ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path. + ;; + *) + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +@@ -22211,350 +22049,509 @@ do + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then +- ac_cv_path_GMSGFMT="$as_dir/$ac_word$ac_exec_ext" ++ ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" + echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi + done + done + +- test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT" + ;; + esac + fi +-GMSGFMT=$ac_cv_path_GMSGFMT ++PKG_CONFIG=$ac_cv_path_PKG_CONFIG + +-if test -n "$GMSGFMT"; then +- echo "$as_me:$LINENO: result: $GMSGFMT" >&5 +-echo "${ECHO_T}$GMSGFMT" >&6 ++if test -n "$PKG_CONFIG"; then ++ echo "$as_me:$LINENO: result: $PKG_CONFIG" >&5 ++echo "${ECHO_T}$PKG_CONFIG" >&6 + else + echo "$as_me:$LINENO: result: no" >&5 + echo "${ECHO_T}no" >&6 + fi + +- # Extract the first word of "xgettext", so it can be a program name with args. +-set dummy xgettext; ac_word=$2 ++fi ++if test -z "$ac_cv_path_PKG_CONFIG"; then ++ ac_pt_PKG_CONFIG=$PKG_CONFIG ++ # Extract the first word of "pkg-config", so it can be a program name with args. ++set dummy pkg-config; ac_word=$2 + echo "$as_me:$LINENO: checking for $ac_word" >&5 + echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 +-if test "${ac_cv_path_XGETTEXT+set}" = set; then ++if test "${ac_cv_path_ac_pt_PKG_CONFIG+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 + else +- case "$XGETTEXT" in +- /*) +- ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path. ++ case $ac_pt_PKG_CONFIG in ++ [\\/]* | ?:[\\/]*) ++ ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path. + ;; + *) +- IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" +- for ac_dir in $PATH; do +- test -z "$ac_dir" && ac_dir=. +- if test -f $ac_dir/$ac_word; then +- if test -z "`$ac_dir/$ac_word -h 2>&1 | grep '(HELP)'`"; then +- ac_cv_path_XGETTEXT="$ac_dir/$ac_word" +- break +- fi +- fi +- done +- IFS="$ac_save_ifs" +- test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":" ++ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR ++for as_dir in $PATH ++do ++ IFS=$as_save_IFS ++ test -z "$as_dir" && as_dir=. ++ for ac_exec_ext in '' $ac_executable_extensions; do ++ if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ++ ac_cv_path_ac_pt_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" ++ echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 ++ break 2 ++ fi ++done ++done ++ + ;; + esac + fi +-XGETTEXT="$ac_cv_path_XGETTEXT" +-if test "$XGETTEXT" != ":"; then +- echo "$as_me:$LINENO: result: $XGETTEXT" >&5 +-echo "${ECHO_T}$XGETTEXT" >&6 ++ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG ++ ++if test -n "$ac_pt_PKG_CONFIG"; then ++ echo "$as_me:$LINENO: result: $ac_pt_PKG_CONFIG" >&5 ++echo "${ECHO_T}$ac_pt_PKG_CONFIG" >&6 + else + echo "$as_me:$LINENO: result: no" >&5 + echo "${ECHO_T}no" >&6 + fi + +- cat >conftest.$ac_ext <<_ACEOF +-/* confdefs.h. */ +-_ACEOF +-cat confdefs.h >>conftest.$ac_ext +-cat >>conftest.$ac_ext <<_ACEOF +-/* end confdefs.h. */ ++ PKG_CONFIG=$ac_pt_PKG_CONFIG ++else ++ PKG_CONFIG="$ac_cv_path_PKG_CONFIG" ++fi ++ ++fi ++if test -n "$PKG_CONFIG"; then ++ _pkg_min_version=0.9.0 ++ echo "$as_me:$LINENO: checking pkg-config is at least version $_pkg_min_version" >&5 ++echo $ECHO_N "checking pkg-config is at least version $_pkg_min_version... $ECHO_C" >&6 ++ if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then ++ echo "$as_me:$LINENO: result: yes" >&5 ++echo "${ECHO_T}yes" >&6 ++ else ++ echo "$as_me:$LINENO: result: no" >&5 ++echo "${ECHO_T}no" >&6 ++ PKG_CONFIG="" ++ fi ++ ++fi ++ ++pkg_failed=no ++echo "$as_me:$LINENO: checking for GLIB" >&5 ++echo $ECHO_N "checking for GLIB... $ECHO_C" >&6 ++ ++if test -n "$PKG_CONFIG"; then ++ if test -n "$GLIB_CFLAGS"; then ++ pkg_cv_GLIB_CFLAGS="$GLIB_CFLAGS" ++ else ++ if test -n "$PKG_CONFIG" && \ ++ { (echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \" ++ glib-2.0 >= 2.4 ++ libxml-2.0 ++ \"") >&5 ++ ($PKG_CONFIG --exists --print-errors " ++ glib-2.0 >= 2.4 ++ libxml-2.0 ++ ") 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; then ++ pkg_cv_GLIB_CFLAGS=`$PKG_CONFIG --cflags " ++ glib-2.0 >= 2.4 ++ libxml-2.0 ++ " 2>/dev/null` ++else ++ pkg_failed=yes ++fi ++ fi ++else ++ pkg_failed=untried ++fi ++if test -n "$PKG_CONFIG"; then ++ if test -n "$GLIB_LIBS"; then ++ pkg_cv_GLIB_LIBS="$GLIB_LIBS" ++ else ++ if test -n "$PKG_CONFIG" && \ ++ { (echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \" ++ glib-2.0 >= 2.4 ++ libxml-2.0 ++ \"") >&5 ++ ($PKG_CONFIG --exists --print-errors " ++ glib-2.0 >= 2.4 ++ libxml-2.0 ++ ") 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; then ++ pkg_cv_GLIB_LIBS=`$PKG_CONFIG --libs " ++ glib-2.0 >= 2.4 ++ libxml-2.0 ++ " 2>/dev/null` ++else ++ pkg_failed=yes ++fi ++ fi ++else ++ pkg_failed=untried ++fi ++ ++ ++ ++if test $pkg_failed = yes; then ++ ++if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then ++ _pkg_short_errors_supported=yes ++else ++ _pkg_short_errors_supported=no ++fi ++ if test $_pkg_short_errors_supported = yes; then ++ GLIB_PKG_ERRORS=`$PKG_CONFIG --short-errors --errors-to-stdout --print-errors " ++ glib-2.0 >= 2.4 ++ libxml-2.0 ++ "` ++ else ++ GLIB_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors " ++ glib-2.0 >= 2.4 ++ libxml-2.0 ++ "` ++ fi ++ # Put the nasty error message in config.log where it belongs ++ echo "$GLIB_PKG_ERRORS" >&5 ++ ++ { { echo "$as_me:$LINENO: error: Package requirements ( ++ glib-2.0 >= 2.4 ++ libxml-2.0 ++ ) were not met: ++ ++$GLIB_PKG_ERRORS ++ ++Consider adjusting the PKG_CONFIG_PATH environment variable if you ++installed software in a non-standard prefix. ++ ++Alternatively, you may set the environment variables GLIB_CFLAGS ++and GLIB_LIBS to avoid the need to call pkg-config. ++See the pkg-config man page for more details. ++" >&5 ++echo "$as_me: error: Package requirements ( ++ glib-2.0 >= 2.4 ++ libxml-2.0 ++ ) were not met: + +-int +-main () +-{ +-extern int _nl_msg_cat_cntr; +- return _nl_msg_cat_cntr +- ; +- return 0; +-} +-_ACEOF +-rm -f conftest.$ac_objext conftest$ac_exeext +-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 +- (eval $ac_link) 2>conftest.er1 +- ac_status=$? +- grep -v '^ *+' conftest.er1 >conftest.err +- rm -f conftest.er1 +- cat conftest.err >&5 +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); } && +- { ac_try='test -z "$ac_cxx_werror_flag" +- || test ! -s conftest.err' +- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 +- (eval $ac_try) 2>&5 +- ac_status=$? +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; } && +- { ac_try='test -s conftest$ac_exeext' +- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 +- (eval $ac_try) 2>&5 +- ac_status=$? +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; }; then +- CATOBJEXT=.gmo +- DATADIRNAME=share +-else +- echo "$as_me: failed program was:" >&5 +-sed 's/^/| /' conftest.$ac_ext >&5 ++$GLIB_PKG_ERRORS + +-case $host in +- *-*-solaris*) +- echo "$as_me:$LINENO: checking for bind_textdomain_codeset" >&5 +-echo $ECHO_N "checking for bind_textdomain_codeset... $ECHO_C" >&6 +-if test "${ac_cv_func_bind_textdomain_codeset+set}" = set; then +- echo $ECHO_N "(cached) $ECHO_C" >&6 ++Consider adjusting the PKG_CONFIG_PATH environment variable if you ++installed software in a non-standard prefix. ++ ++Alternatively, you may set the environment variables GLIB_CFLAGS ++and GLIB_LIBS to avoid the need to call pkg-config. ++See the pkg-config man page for more details. ++" >&2;} ++ { (exit 1); exit 1; }; } ++elif test $pkg_failed = untried; then ++ { { echo "$as_me:$LINENO: error: The pkg-config script could not be found or is too old. Make sure it ++is in your PATH or set the PKG_CONFIG environment variable to the full ++path to pkg-config. ++ ++Alternatively, you may set the environment variables GLIB_CFLAGS ++and GLIB_LIBS to avoid the need to call pkg-config. ++See the pkg-config man page for more details. ++ ++To get pkg-config, see . ++See \`config.log' for more details." >&5 ++echo "$as_me: error: The pkg-config script could not be found or is too old. Make sure it ++is in your PATH or set the PKG_CONFIG environment variable to the full ++path to pkg-config. ++ ++Alternatively, you may set the environment variables GLIB_CFLAGS ++and GLIB_LIBS to avoid the need to call pkg-config. ++See the pkg-config man page for more details. ++ ++To get pkg-config, see . ++See \`config.log' for more details." >&2;} ++ { (exit 1); exit 1; }; } + else +- cat >conftest.$ac_ext <<_ACEOF +-/* confdefs.h. */ +-_ACEOF +-cat confdefs.h >>conftest.$ac_ext +-cat >>conftest.$ac_ext <<_ACEOF +-/* end confdefs.h. */ +-/* Define bind_textdomain_codeset to an innocuous variant, in case declares bind_textdomain_codeset. +- For example, HP-UX 11i declares gettimeofday. */ +-#define bind_textdomain_codeset innocuous_bind_textdomain_codeset ++ GLIB_CFLAGS=$pkg_cv_GLIB_CFLAGS ++ GLIB_LIBS=$pkg_cv_GLIB_LIBS ++ echo "$as_me:$LINENO: result: yes" >&5 ++echo "${ECHO_T}yes" >&6 ++ : ++fi + +-/* System header to define __stub macros and hopefully few prototypes, +- which can conflict with char bind_textdomain_codeset (); below. +- Prefer to if __STDC__ is defined, since +- exists even on freestanding compilers. */ + +-#ifdef __STDC__ +-# include +-#else +-# include +-#endif + +-#undef bind_textdomain_codeset + +-/* Override any gcc2 internal prototype to avoid an error. */ +-#ifdef __cplusplus +-extern "C" +-{ +-#endif +-/* We use char because int might match the return type of a gcc2 +- builtin and then its argument prototype would still apply. */ +-char bind_textdomain_codeset (); +-/* The GNU C library defines this for functions which it implements +- to always fail with ENOSYS. Some functions are actually named +- something starting with __ and the normal name is an alias. */ +-#if defined (__stub_bind_textdomain_codeset) || defined (__stub___bind_textdomain_codeset) +-choke me +-#else +-char (*f) () = bind_textdomain_codeset; +-#endif +-#ifdef __cplusplus +-} +-#endif ++pkg_failed=no ++echo "$as_me:$LINENO: checking for GTK" >&5 ++echo $ECHO_N "checking for GTK... $ECHO_C" >&6 + +-int +-main () +-{ +-return f != bind_textdomain_codeset; +- ; +- return 0; +-} +-_ACEOF +-rm -f conftest.$ac_objext conftest$ac_exeext +-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 +- (eval $ac_link) 2>conftest.er1 +- ac_status=$? +- grep -v '^ *+' conftest.er1 >conftest.err +- rm -f conftest.er1 +- cat conftest.err >&5 +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); } && +- { ac_try='test -z "$ac_cxx_werror_flag" +- || test ! -s conftest.err' +- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 +- (eval $ac_try) 2>&5 ++if test -n "$PKG_CONFIG"; then ++ if test -n "$GTK_CFLAGS"; then ++ pkg_cv_GTK_CFLAGS="$GTK_CFLAGS" ++ else ++ if test -n "$PKG_CONFIG" && \ ++ { (echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \" ++ gtk+-2.0 >= 2.4 ++ gdk-pixbuf-2.0 ++ \"") >&5 ++ ($PKG_CONFIG --exists --print-errors " ++ gtk+-2.0 >= 2.4 ++ gdk-pixbuf-2.0 ++ ") 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; } && +- { ac_try='test -s conftest$ac_exeext' +- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 +- (eval $ac_try) 2>&5 ++ (exit $ac_status); }; then ++ pkg_cv_GTK_CFLAGS=`$PKG_CONFIG --cflags " ++ gtk+-2.0 >= 2.4 ++ gdk-pixbuf-2.0 ++ " 2>/dev/null` ++else ++ pkg_failed=yes ++fi ++ fi ++else ++ pkg_failed=untried ++fi ++if test -n "$PKG_CONFIG"; then ++ if test -n "$GTK_LIBS"; then ++ pkg_cv_GTK_LIBS="$GTK_LIBS" ++ else ++ if test -n "$PKG_CONFIG" && \ ++ { (echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \" ++ gtk+-2.0 >= 2.4 ++ gdk-pixbuf-2.0 ++ \"") >&5 ++ ($PKG_CONFIG --exists --print-errors " ++ gtk+-2.0 >= 2.4 ++ gdk-pixbuf-2.0 ++ ") 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; }; then +- ac_cv_func_bind_textdomain_codeset=yes ++ (exit $ac_status); }; then ++ pkg_cv_GTK_LIBS=`$PKG_CONFIG --libs " ++ gtk+-2.0 >= 2.4 ++ gdk-pixbuf-2.0 ++ " 2>/dev/null` + else +- echo "$as_me: failed program was:" >&5 +-sed 's/^/| /' conftest.$ac_ext >&5 +- +-ac_cv_func_bind_textdomain_codeset=no +-fi +-rm -f conftest.err conftest.$ac_objext \ +- conftest$ac_exeext conftest.$ac_ext ++ pkg_failed=yes + fi +-echo "$as_me:$LINENO: result: $ac_cv_func_bind_textdomain_codeset" >&5 +-echo "${ECHO_T}$ac_cv_func_bind_textdomain_codeset" >&6 +-if test $ac_cv_func_bind_textdomain_codeset = yes; then +- CATOBJEXT=.gmo +- DATADIRNAME=share ++ fi + else +- CATOBJEXT=.mo +- DATADIRNAME=lib ++ pkg_failed=untried + fi + +- ;; +- *) +- CATOBJEXT=.mo +- DATADIRNAME=lib +- ;; +- esac ++ ++ ++if test $pkg_failed = yes; then ++ ++if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then ++ _pkg_short_errors_supported=yes ++else ++ _pkg_short_errors_supported=no + fi +-rm -f conftest.err conftest.$ac_objext \ +- conftest$ac_exeext conftest.$ac_ext +- LIBS="$glib_save_LIBS" +- INSTOBJEXT=.mo +- else +- gt_cv_have_gettext=no +- fi +- fi ++ if test $_pkg_short_errors_supported = yes; then ++ GTK_PKG_ERRORS=`$PKG_CONFIG --short-errors --errors-to-stdout --print-errors " ++ gtk+-2.0 >= 2.4 ++ gdk-pixbuf-2.0 ++ "` ++ else ++ GTK_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors " ++ gtk+-2.0 >= 2.4 ++ gdk-pixbuf-2.0 ++ "` ++ fi ++ # Put the nasty error message in config.log where it belongs ++ echo "$GTK_PKG_ERRORS" >&5 + +-fi ++ { { echo "$as_me:$LINENO: error: Package requirements ( ++ gtk+-2.0 >= 2.4 ++ gdk-pixbuf-2.0 ++ ) were not met: + ++$GTK_PKG_ERRORS + ++Consider adjusting the PKG_CONFIG_PATH environment variable if you ++installed software in a non-standard prefix. + +- if test "$gt_cv_have_gettext" = "yes" ; then ++Alternatively, you may set the environment variables GTK_CFLAGS ++and GTK_LIBS to avoid the need to call pkg-config. ++See the pkg-config man page for more details. ++" >&5 ++echo "$as_me: error: Package requirements ( ++ gtk+-2.0 >= 2.4 ++ gdk-pixbuf-2.0 ++ ) were not met: + +-cat >>confdefs.h <<\_ACEOF +-#define ENABLE_NLS 1 +-_ACEOF ++$GTK_PKG_ERRORS + +- fi ++Consider adjusting the PKG_CONFIG_PATH environment variable if you ++installed software in a non-standard prefix. + +- if test "$XGETTEXT" != ":"; then +- if $XGETTEXT --omit-header /dev/null 2> /dev/null; then +- : ; +- else +- echo "$as_me:$LINENO: result: found xgettext program is not GNU xgettext; ignore it" >&5 +-echo "${ECHO_T}found xgettext program is not GNU xgettext; ignore it" >&6 +- XGETTEXT=":" +- fi +- fi ++Alternatively, you may set the environment variables GTK_CFLAGS ++and GTK_LIBS to avoid the need to call pkg-config. ++See the pkg-config man page for more details. ++" >&2;} ++ { (exit 1); exit 1; }; } ++elif test $pkg_failed = untried; then ++ { { echo "$as_me:$LINENO: error: The pkg-config script could not be found or is too old. Make sure it ++is in your PATH or set the PKG_CONFIG environment variable to the full ++path to pkg-config. + +- # We need to process the po/ directory. +- POSUB=po ++Alternatively, you may set the environment variables GTK_CFLAGS ++and GTK_LIBS to avoid the need to call pkg-config. ++See the pkg-config man page for more details. + +- ac_config_commands="$ac_config_commands default-1" ++To get pkg-config, see . ++See \`config.log' for more details." >&5 ++echo "$as_me: error: The pkg-config script could not be found or is too old. Make sure it ++is in your PATH or set the PKG_CONFIG environment variable to the full ++path to pkg-config. + ++Alternatively, you may set the environment variables GTK_CFLAGS ++and GTK_LIBS to avoid the need to call pkg-config. ++See the pkg-config man page for more details. ++ ++To get pkg-config, see . ++See \`config.log' for more details." >&2;} ++ { (exit 1); exit 1; }; } ++else ++ GTK_CFLAGS=$pkg_cv_GTK_CFLAGS ++ GTK_LIBS=$pkg_cv_GTK_LIBS ++ echo "$as_me:$LINENO: result: yes" >&5 ++echo "${ECHO_T}yes" >&6 ++ : ++fi + +- for lang in $ALL_LINGUAS; do +- GMOFILES="$GMOFILES $lang.gmo" +- POFILES="$POFILES $lang.po" +- done + + + ++pkg_failed=no ++echo "$as_me:$LINENO: checking for QALCULATE" >&5 ++echo $ECHO_N "checking for QALCULATE... $ECHO_C" >&6 + ++if test -n "$PKG_CONFIG"; then ++ if test -n "$QALCULATE_CFLAGS"; then ++ pkg_cv_QALCULATE_CFLAGS="$QALCULATE_CFLAGS" ++ else ++ if test -n "$PKG_CONFIG" && \ ++ { (echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \" ++ libqalculate >= 0.9.4 ++ \"") >&5 ++ ($PKG_CONFIG --exists --print-errors " ++ libqalculate >= 0.9.4 ++ ") 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; then ++ pkg_cv_QALCULATE_CFLAGS=`$PKG_CONFIG --cflags " ++ libqalculate >= 0.9.4 ++ " 2>/dev/null` ++else ++ pkg_failed=yes ++fi ++ fi ++else ++ pkg_failed=untried ++fi ++if test -n "$PKG_CONFIG"; then ++ if test -n "$QALCULATE_LIBS"; then ++ pkg_cv_QALCULATE_LIBS="$QALCULATE_LIBS" ++ else ++ if test -n "$PKG_CONFIG" && \ ++ { (echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \" ++ libqalculate >= 0.9.4 ++ \"") >&5 ++ ($PKG_CONFIG --exists --print-errors " ++ libqalculate >= 0.9.4 ++ ") 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; then ++ pkg_cv_QALCULATE_LIBS=`$PKG_CONFIG --libs " ++ libqalculate >= 0.9.4 ++ " 2>/dev/null` ++else ++ pkg_failed=yes ++fi ++ fi ++else ++ pkg_failed=untried ++fi + + + ++if test $pkg_failed = yes; then + ++if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then ++ _pkg_short_errors_supported=yes ++else ++ _pkg_short_errors_supported=no ++fi ++ if test $_pkg_short_errors_supported = yes; then ++ QALCULATE_PKG_ERRORS=`$PKG_CONFIG --short-errors --errors-to-stdout --print-errors " ++ libqalculate >= 0.9.4 ++ "` ++ else ++ QALCULATE_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors " ++ libqalculate >= 0.9.4 ++ "` ++ fi ++ # Put the nasty error message in config.log where it belongs ++ echo "$QALCULATE_PKG_ERRORS" >&5 + ++ { { echo "$as_me:$LINENO: error: Package requirements ( ++ libqalculate >= 0.9.4 ++ ) were not met: + ++$QALCULATE_PKG_ERRORS + ++Consider adjusting the PKG_CONFIG_PATH environment variable if you ++installed software in a non-standard prefix. + ++Alternatively, you may set the environment variables QALCULATE_CFLAGS ++and QALCULATE_LIBS to avoid the need to call pkg-config. ++See the pkg-config man page for more details. ++" >&5 ++echo "$as_me: error: Package requirements ( ++ libqalculate >= 0.9.4 ++ ) were not met: + +- if test "$gt_cv_have_gettext" = "yes"; then +- if test "x$ALL_LINGUAS" = "x"; then +- LINGUAS= +- else +- echo "$as_me:$LINENO: checking for catalogs to be installed" >&5 +-echo $ECHO_N "checking for catalogs to be installed... $ECHO_C" >&6 +- NEW_LINGUAS= +- for presentlang in $ALL_LINGUAS; do +- useit=no +- if test "%UNSET%" != "${LINGUAS-%UNSET%}"; then +- desiredlanguages="$LINGUAS" +- else +- desiredlanguages="$ALL_LINGUAS" +- fi +- for desiredlang in $desiredlanguages; do +- # Use the presentlang catalog if desiredlang is +- # a. equal to presentlang, or +- # b. a variant of presentlang (because in this case, +- # presentlang can be used as a fallback for messages +- # which are not translated in the desiredlang catalog). +- case "$desiredlang" in +- "$presentlang"*) useit=yes;; +- esac +- done +- if test $useit = yes; then +- NEW_LINGUAS="$NEW_LINGUAS $presentlang" +- fi +- done +- LINGUAS=$NEW_LINGUAS +- echo "$as_me:$LINENO: result: $LINGUAS" >&5 +-echo "${ECHO_T}$LINGUAS" >&6 +- fi ++$QALCULATE_PKG_ERRORS + +- if test -n "$LINGUAS"; then +- for lang in $LINGUAS; do CATALOGS="$CATALOGS $lang$CATOBJEXT"; done +- fi +- fi ++Consider adjusting the PKG_CONFIG_PATH environment variable if you ++installed software in a non-standard prefix. + +- MKINSTALLDIRS= +- if test -n "$ac_aux_dir"; then +- MKINSTALLDIRS="$ac_aux_dir/mkinstalldirs" +- fi +- if test -z "$MKINSTALLDIRS"; then +- MKINSTALLDIRS="\$(top_srcdir)/mkinstalldirs" +- fi ++Alternatively, you may set the environment variables QALCULATE_CFLAGS ++and QALCULATE_LIBS to avoid the need to call pkg-config. ++See the pkg-config man page for more details. ++" >&2;} ++ { (exit 1); exit 1; }; } ++elif test $pkg_failed = untried; then ++ { { echo "$as_me:$LINENO: error: The pkg-config script could not be found or is too old. Make sure it ++is in your PATH or set the PKG_CONFIG environment variable to the full ++path to pkg-config. + ++Alternatively, you may set the environment variables QALCULATE_CFLAGS ++and QALCULATE_LIBS to avoid the need to call pkg-config. ++See the pkg-config man page for more details. + +- test -d po || mkdir po +- if test "x$srcdir" != "x."; then +- if test "x`echo $srcdir | sed 's@/.*@@'`" = "x"; then +- posrcprefix="$srcdir/" +- else +- posrcprefix="../$srcdir/" +- fi +- else +- posrcprefix="../" +- fi +- rm -f po/POTFILES +- sed -e "/^#/d" -e "/^\$/d" -e "s,.*, $posrcprefix& \\\\," -e "\$s/\(.*\) \\\\/\1/" \ +- < $srcdir/po/POTFILES.in > po/POTFILES ++To get pkg-config, see . ++See \`config.log' for more details." >&5 ++echo "$as_me: error: The pkg-config script could not be found or is too old. Make sure it ++is in your PATH or set the PKG_CONFIG environment variable to the full ++path to pkg-config. + ++Alternatively, you may set the environment variables QALCULATE_CFLAGS ++and QALCULATE_LIBS to avoid the need to call pkg-config. ++See the pkg-config man page for more details. + +-echo "$as_me:$LINENO: checking locale directory" >&5 +-echo $ECHO_N "checking locale directory... $ECHO_C" >&6 +-if test "x$prefix" = "xNONE"; then +- PACKAGE_LOCALE_DIR=$ac_default_prefix/share/locale ++To get pkg-config, see . ++See \`config.log' for more details." >&2;} ++ { (exit 1); exit 1; }; } + else +- PACKAGE_LOCALE_DIR=$prefix/share/locale ++ QALCULATE_CFLAGS=$pkg_cv_QALCULATE_CFLAGS ++ QALCULATE_LIBS=$pkg_cv_QALCULATE_LIBS ++ echo "$as_me:$LINENO: result: yes" >&5 ++echo "${ECHO_T}yes" >&6 ++ : + fi + + +-cat >>confdefs.h <<_ACEOF +-#define PACKAGE_LOCALE_DIR "$PACKAGE_LOCALE_DIR" +-_ACEOF +- +- echo "$as_me:$LINENO: result: \"$PACKAGE_LOCALE_DIR\"" >&5 +-echo "${ECHO_T}\"$PACKAGE_LOCALE_DIR\"" >&6 +- +-INTLTOOL_QALCULATE_DEFINITIONS_RULE='%.xml: %.xml.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po-defs/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -x -u -c $(top_builddir)/po-defs/.intltool-merge-cache $(top_srcdir)/po-defs $< $@' +- +- +- + ac_config_files="$ac_config_files Makefile data/Makefile src/Makefile po/Makefile.in" + cat >confcache <<\_ACEOF + # This file is a shell script that caches the results of configure diff --git a/math/qalculate-bases/patches/patch-ab b/math/qalculate-bases/patches/patch-ab new file mode 100644 index 00000000000..5d4bf6c4a20 --- /dev/null +++ b/math/qalculate-bases/patches/patch-ab @@ -0,0 +1,72 @@ +$NetBSD: patch-ab,v 1.1 2006/06/22 18:52:00 jlam Exp $ + +--- configure.in.orig 2006-04-18 03:13:35.000000000 -0400 ++++ configure.in +@@ -54,7 +54,33 @@ if test "x$GCC" = "xyes"; then + fi + changequote([,])dnl + ++dnl ------------------------------------- ++dnl | internationalization (i18n) support |------------------------------------ ++dnl ------------------------------------- ++ ++GETTEXT_PACKAGE=qalculate-bases ++AC_SUBST(GETTEXT_PACKAGE) ++AC_DEFINE_UNQUOTED(GETTEXT_PACKAGE,"$GETTEXT_PACKAGE",[The package name for gettext]) + ++dnl Please keep this in alphabetical order ++ALL_LINGUAS="nl sv" ++AM_GLIB_GNU_GETTEXT ++ ++dnl AM_GLIB_GNU_GETTEXT sets $DATADIRNAME ++AC_MSG_CHECKING(locale directory) ++if test "x$prefix" = "xNONE"; then ++ PACKAGE_LOCALE_DIR=$ac_default_prefix/share/locale ++else ++ PACKAGE_LOCALE_DIR=$prefix/share/locale ++fi ++ ++AC_DEFINE_UNQUOTED(PACKAGE_LOCALE_DIR, "$PACKAGE_LOCALE_DIR", ++ [The directory in which qalculate's locale data will be stored]) ++ AC_MSG_RESULT("$PACKAGE_LOCALE_DIR") ++ ++INTLTOOL_QALCULATE_DEFINITIONS_RULE='%.xml: %.xml.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po-defs/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -x -u -c $(top_builddir)/po-defs/.intltool-merge-cache $(top_srcdir)/po-defs $< [$]@' ++AC_SUBST(INTLTOOL_QALCULATE_DEFINITIONS_RULE) ++ + dnl -------------------------------- + dnl | check for neccessary libraries |----------------------------------------- + dnl -------------------------------- +@@ -89,33 +115,6 @@ PKG_CHECK_MODULES(QALCULATE, [ + AC_SUBST(QALCULATE_CFLAGS) + AC_SUBST(QALCULATE_LIBS) + +-dnl ------------------------------------- +-dnl | internationalization (i18n) support |------------------------------------ +-dnl ------------------------------------- +- +-GETTEXT_PACKAGE=qalculate-bases +-AC_SUBST(GETTEXT_PACKAGE) +-AC_DEFINE_UNQUOTED(GETTEXT_PACKAGE,"$GETTEXT_PACKAGE",[The package name for gettext]) +- +-dnl Please keep this in alphabetical order +-ALL_LINGUAS="nl sv" +-AM_GLIB_GNU_GETTEXT +- +-dnl AM_GLIB_GNU_GETTEXT sets $DATADIRNAME +-AC_MSG_CHECKING(locale directory) +-if test "x$prefix" = "xNONE"; then +- PACKAGE_LOCALE_DIR=$ac_default_prefix/share/locale +-else +- PACKAGE_LOCALE_DIR=$prefix/share/locale +-fi +- +-AC_DEFINE_UNQUOTED(PACKAGE_LOCALE_DIR, "$PACKAGE_LOCALE_DIR", +- [The directory in which qalculate's locale data will be stored]) +- AC_MSG_RESULT("$PACKAGE_LOCALE_DIR") +- +-INTLTOOL_QALCULATE_DEFINITIONS_RULE='%.xml: %.xml.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po-defs/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -x -u -c $(top_builddir)/po-defs/.intltool-merge-cache $(top_srcdir)/po-defs $< [$]@' +-AC_SUBST(INTLTOOL_QALCULATE_DEFINITIONS_RULE) +- + dnl -------- + dnl | output |----------------------------------------------------------------- + dnl -------- diff --git a/math/qalculate-currency/distinfo b/math/qalculate-currency/distinfo index 8608e6a3e77..01dd6c2cf99 100644 --- a/math/qalculate-currency/distinfo +++ b/math/qalculate-currency/distinfo @@ -1,5 +1,7 @@ -$NetBSD: distinfo,v 1.4 2006/06/14 20:14:21 adam Exp $ +$NetBSD: distinfo,v 1.5 2006/06/22 18:52:00 jlam Exp $ SHA1 (qalculate-currency-0.9.4.tar.gz) = 8352fd1bc8434299e4c3a1111f1b6b275246ee0f RMD160 (qalculate-currency-0.9.4.tar.gz) = fa7a52c922ed0c01494e43b6a9c971124a9856cb Size (qalculate-currency-0.9.4.tar.gz) = 370506 bytes +SHA1 (patch-aa) = 40d2dcb92b1affa6df71679cfce4027291fcd894 +SHA1 (patch-ab) = 06824dc714d112ce6ed422f550939ae802e2452b diff --git a/math/qalculate-currency/patches/patch-aa b/math/qalculate-currency/patches/patch-aa new file mode 100644 index 00000000000..456a97fcef6 --- /dev/null +++ b/math/qalculate-currency/patches/patch-aa @@ -0,0 +1,3972 @@ +$NetBSD: patch-aa,v 1.1 2006/06/22 18:52:00 jlam Exp $ + +--- configure.orig 2006-06-02 01:55:41.000000000 -0400 ++++ configure +@@ -20065,31 +20065,184 @@ fi + + + +-echo "$as_me:$LINENO: checking for pthread_create in -lpthread" >&5 +-echo $ECHO_N "checking for pthread_create in -lpthread... $ECHO_C" >&6 +-if test "${ac_cv_lib_pthread_pthread_create+set}" = set; then ++GETTEXT_PACKAGE=qalculate-currency ++ ++ ++cat >>confdefs.h <<_ACEOF ++#define GETTEXT_PACKAGE "$GETTEXT_PACKAGE" ++_ACEOF ++ ++ ++ALL_LINGUAS="nl sv" ++ ++ ++ ++for ac_header in locale.h ++do ++as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh` ++if eval "test \"\${$as_ac_Header+set}\" = set"; then ++ echo "$as_me:$LINENO: checking for $ac_header" >&5 ++echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6 ++if eval "test \"\${$as_ac_Header+set}\" = set"; then + echo $ECHO_N "(cached) $ECHO_C" >&6 ++fi ++echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5 ++echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6 + else +- ac_check_lib_save_LIBS=$LIBS +-LIBS="-lpthread $LIBS" ++ # Is the header compilable? ++echo "$as_me:$LINENO: checking $ac_header usability" >&5 ++echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6 + cat >conftest.$ac_ext <<_ACEOF + /* confdefs.h. */ + _ACEOF + cat confdefs.h >>conftest.$ac_ext + cat >>conftest.$ac_ext <<_ACEOF + /* end confdefs.h. */ ++$ac_includes_default ++#include <$ac_header> ++_ACEOF ++rm -f conftest.$ac_objext ++if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 ++ (eval $ac_compile) 2>conftest.er1 ++ ac_status=$? ++ grep -v '^ *+' conftest.er1 >conftest.err ++ rm -f conftest.er1 ++ cat conftest.err >&5 ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); } && ++ { ac_try='test -z "$ac_cxx_werror_flag" ++ || test ! -s conftest.err' ++ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 ++ (eval $ac_try) 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; } && ++ { ac_try='test -s conftest.$ac_objext' ++ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 ++ (eval $ac_try) 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; }; then ++ ac_header_compiler=yes ++else ++ echo "$as_me: failed program was:" >&5 ++sed 's/^/| /' conftest.$ac_ext >&5 + +-/* Override any gcc2 internal prototype to avoid an error. */ +-#ifdef __cplusplus +-extern "C" +-#endif +-/* We use char because int might match the return type of a gcc2 +- builtin and then its argument prototype would still apply. */ +-char pthread_create (); ++ac_header_compiler=no ++fi ++rm -f conftest.err conftest.$ac_objext conftest.$ac_ext ++echo "$as_me:$LINENO: result: $ac_header_compiler" >&5 ++echo "${ECHO_T}$ac_header_compiler" >&6 ++ ++# Is the header present? ++echo "$as_me:$LINENO: checking $ac_header presence" >&5 ++echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6 ++cat >conftest.$ac_ext <<_ACEOF ++/* confdefs.h. */ ++_ACEOF ++cat confdefs.h >>conftest.$ac_ext ++cat >>conftest.$ac_ext <<_ACEOF ++/* end confdefs.h. */ ++#include <$ac_header> ++_ACEOF ++if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5 ++ (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 ++ ac_status=$? ++ grep -v '^ *+' conftest.er1 >conftest.err ++ rm -f conftest.er1 ++ cat conftest.err >&5 ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); } >/dev/null; then ++ if test -s conftest.err; then ++ ac_cpp_err=$ac_cxx_preproc_warn_flag ++ ac_cpp_err=$ac_cpp_err$ac_cxx_werror_flag ++ else ++ ac_cpp_err= ++ fi ++else ++ ac_cpp_err=yes ++fi ++if test -z "$ac_cpp_err"; then ++ ac_header_preproc=yes ++else ++ echo "$as_me: failed program was:" >&5 ++sed 's/^/| /' conftest.$ac_ext >&5 ++ ++ ac_header_preproc=no ++fi ++rm -f conftest.err conftest.$ac_ext ++echo "$as_me:$LINENO: result: $ac_header_preproc" >&5 ++echo "${ECHO_T}$ac_header_preproc" >&6 ++ ++# So? What about this header? ++case $ac_header_compiler:$ac_header_preproc:$ac_cxx_preproc_warn_flag in ++ yes:no: ) ++ { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5 ++echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;} ++ { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5 ++echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;} ++ ac_header_preproc=yes ++ ;; ++ no:yes:* ) ++ { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5 ++echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;} ++ { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5 ++echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;} ++ { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5 ++echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;} ++ { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5 ++echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;} ++ { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5 ++echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;} ++ { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5 ++echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;} ++ ( ++ cat <<\_ASBOX ++## ------------------------------------------ ## ++## Report this to the AC_PACKAGE_NAME lists. ## ++## ------------------------------------------ ## ++_ASBOX ++ ) | ++ sed "s/^/$as_me: WARNING: /" >&2 ++ ;; ++esac ++echo "$as_me:$LINENO: checking for $ac_header" >&5 ++echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6 ++if eval "test \"\${$as_ac_Header+set}\" = set"; then ++ echo $ECHO_N "(cached) $ECHO_C" >&6 ++else ++ eval "$as_ac_Header=\$ac_header_preproc" ++fi ++echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5 ++echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6 ++ ++fi ++if test `eval echo '${'$as_ac_Header'}'` = yes; then ++ cat >>confdefs.h <<_ACEOF ++#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1 ++_ACEOF ++ ++fi ++ ++done ++ ++ if test $ac_cv_header_locale_h = yes; then ++ echo "$as_me:$LINENO: checking for LC_MESSAGES" >&5 ++echo $ECHO_N "checking for LC_MESSAGES... $ECHO_C" >&6 ++if test "${am_cv_val_LC_MESSAGES+set}" = set; then ++ echo $ECHO_N "(cached) $ECHO_C" >&6 ++else ++ cat >conftest.$ac_ext <<_ACEOF ++/* confdefs.h. */ ++_ACEOF ++cat confdefs.h >>conftest.$ac_ext ++cat >>conftest.$ac_ext <<_ACEOF ++/* end confdefs.h. */ ++#include + int + main () + { +-pthread_create (); ++return LC_MESSAGES + ; + return 0; + } +@@ -20103,7 +20256,7 @@ if { (eval echo "$as_me:$LINENO: \"$ac_l + cat conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } && +- { ac_try='test -z "$ac_c_werror_flag" ++ { ac_try='test -z "$ac_cxx_werror_flag" + || test ! -s conftest.err' + { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 +@@ -20116,885 +20269,441 @@ if { (eval echo "$as_me:$LINENO: \"$ac_l + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then +- ac_cv_lib_pthread_pthread_create=yes ++ am_cv_val_LC_MESSAGES=yes + else + echo "$as_me: failed program was:" >&5 + sed 's/^/| /' conftest.$ac_ext >&5 + +-ac_cv_lib_pthread_pthread_create=no ++am_cv_val_LC_MESSAGES=no + fi + rm -f conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +-LIBS=$ac_check_lib_save_LIBS +-fi +-echo "$as_me:$LINENO: result: $ac_cv_lib_pthread_pthread_create" >&5 +-echo "${ECHO_T}$ac_cv_lib_pthread_pthread_create" >&6 +-if test $ac_cv_lib_pthread_pthread_create = yes; then +- LIBS="$LIBS -lpthread" + fi ++echo "$as_me:$LINENO: result: $am_cv_val_LC_MESSAGES" >&5 ++echo "${ECHO_T}$am_cv_val_LC_MESSAGES" >&6 ++ if test $am_cv_val_LC_MESSAGES = yes; then + ++cat >>confdefs.h <<\_ACEOF ++#define HAVE_LC_MESSAGES 1 ++_ACEOF + +-ac_ext=cc +-ac_cpp='$CXXCPP $CPPFLAGS' +-ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' +-ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +-ac_compiler_gnu=$ac_cv_cxx_compiler_gnu +- +- +- +-# Check whether --with-cln-prefix or --without-cln-prefix was given. +-if test "${with_cln_prefix+set}" = set; then +- withval="$with_cln_prefix" +- cln_config_prefix="$withval" +-else +- cln_config_prefix="" +-fi; ++ fi ++ fi ++ USE_NLS=yes + +-# Check whether --with-cln-exec-prefix or --without-cln-exec-prefix was given. +-if test "${with_cln_exec_prefix+set}" = set; then +- withval="$with_cln_exec_prefix" +- cln_config_exec_prefix="$withval" +-else +- cln_config_exec_prefix="" +-fi; +-# Check whether --enable-clntest or --disable-clntest was given. +-if test "${enable_clntest+set}" = set; then +- enableval="$enable_clntest" + +-else +- enable_clntest=yes +-fi; ++ gt_cv_have_gettext=no + +-if test x$cln_config_exec_prefix != x ; then +- cln_config_args="$cln_config_args --exec-prefix=$cln_config_exec_prefix" +- if test x${CLN_CONFIG+set} != xset ; then +- CLN_CONFIG=$cln_config_exec_prefix/bin/cln-config +- fi +-fi +-if test x$cln_config_prefix != x ; then +- cln_config_args="$cln_config_args --prefix=$cln_config_prefix" +- if test x${CLN_CONFIG+set} != xset ; then +- CLN_CONFIG=$cln_config_prefix/bin/cln-config +- fi +-fi ++ CATOBJEXT=NONE ++ XGETTEXT=: ++ INTLLIBS= + +-# Extract the first word of "cln-config", so it can be a program name with args. +-set dummy cln-config; ac_word=$2 +-echo "$as_me:$LINENO: checking for $ac_word" >&5 +-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 +-if test "${ac_cv_path_CLN_CONFIG+set}" = set; then ++ if test "${ac_cv_header_libintl_h+set}" = set; then ++ echo "$as_me:$LINENO: checking for libintl.h" >&5 ++echo $ECHO_N "checking for libintl.h... $ECHO_C" >&6 ++if test "${ac_cv_header_libintl_h+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 ++fi ++echo "$as_me:$LINENO: result: $ac_cv_header_libintl_h" >&5 ++echo "${ECHO_T}$ac_cv_header_libintl_h" >&6 + else +- case $CLN_CONFIG in +- [\\/]* | ?:[\\/]*) +- ac_cv_path_CLN_CONFIG="$CLN_CONFIG" # Let the user override the test with a path. +- ;; +- *) +- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +-for as_dir in $PATH +-do +- IFS=$as_save_IFS +- test -z "$as_dir" && as_dir=. +- for ac_exec_ext in '' $ac_executable_extensions; do +- if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then +- ac_cv_path_CLN_CONFIG="$as_dir/$ac_word$ac_exec_ext" +- echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 +- break 2 +- fi +-done +-done +- +- test -z "$ac_cv_path_CLN_CONFIG" && ac_cv_path_CLN_CONFIG="no" +- ;; +-esac +-fi +-CLN_CONFIG=$ac_cv_path_CLN_CONFIG +- +-if test -n "$CLN_CONFIG"; then +- echo "$as_me:$LINENO: result: $CLN_CONFIG" >&5 +-echo "${ECHO_T}$CLN_CONFIG" >&6 +-else +- echo "$as_me:$LINENO: result: no" >&5 +-echo "${ECHO_T}no" >&6 +-fi +- +-cln_min_version=1.1.0 +-echo "$as_me:$LINENO: checking for CLN - version >= $cln_min_version" >&5 +-echo $ECHO_N "checking for CLN - version >= $cln_min_version... $ECHO_C" >&6 +-if test "$CLN_CONFIG" = "no" ; then +- echo "$as_me:$LINENO: result: no" >&5 +-echo "${ECHO_T}no" >&6 +- echo "*** The cln-config script installed by CLN could not be found" +- echo "*** If CLN was installed in PREFIX, make sure PREFIX/bin is in" +- echo "*** your path, or set the CLN_CONFIG environment variable to the" +- echo "*** full path to cln-config." +- { { echo "$as_me:$LINENO: error: No suitable installed version of CLN could be found." >&5 +-echo "$as_me: error: No suitable installed version of CLN could be found." >&2;} +- { (exit 1); exit 1; }; } +-else +- cln_min_major_version=`echo $cln_min_version | \ +- sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\1/'` +- cln_min_minor_version=`echo $cln_min_version | \ +- sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\2/'` +- cln_min_micro_version=`echo $cln_min_version | \ +- sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\3/'` +- CLN_CPPFLAGS=`$CLN_CONFIG $cln_config_args --cppflags` +- CLN_LIBS=`$CLN_CONFIG $cln_config_args --libs` +- cln_config_version=`$CLN_CONFIG $cln_config_args --version` +- cln_config_major_version=`echo $cln_config_version | \ +- sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\1/'` +- cln_config_minor_version=`echo $cln_config_version | \ +- sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\2/'` +- cln_config_micro_version=`echo $cln_config_version | \ +- sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\3/'` +- if test \( $cln_config_major_version -lt $cln_min_major_version \) -o \ +- \( $cln_config_major_version -eq $cln_min_major_version -a $cln_config_minor_version -lt $cln_min_minor_version \) -o \ +- \( $cln_config_major_version -eq $cln_min_major_version -a $cln_config_minor_version -eq $cln_min_minor_version -a $cln_config_micro_version -lt $cln_min_micro_version \); then +- echo -e "\n*** 'cln-config --version' returned $cln_config_major_version.$cln_config_minor_version.$cln_config_micro_version, but the minimum version" +- echo "*** of CLN required is $cln_min_major_version.$cln_min_minor_version.$cln_min_micro_version. If cln-config is correct, then it is" +- echo "*** best to upgrade to the required version." +- echo "*** If cln-config was wrong, set the environment variable CLN_CONFIG" +- echo "*** to point to the correct copy of cln-config, and remove the file" +- echo "*** config.cache before re-running configure." +- { { echo "$as_me:$LINENO: error: No suitable installed version of CLN could be found." >&5 +-echo "$as_me: error: No suitable installed version of CLN could be found." >&2;} +- { (exit 1); exit 1; }; } +- else +- no_cln="" +- if test "x$enable_clntest" = "xyes" ; then +- ac_save_CPPFLAGS="$CPPFLAGS" +- ac_save_LIBS="$LIBS" +- CPPFLAGS="$CPPFLAGS $CLN_CPPFLAGS" +- LIBS="$LIBS $CLN_LIBS" +- rm -f conf.clntest +- if test "$cross_compiling" = yes; then +- echo $ac_n "cross compiling; assumed OK... $ac_c" +-else +- cat >conftest.$ac_ext <<_ACEOF ++ # Is the header compilable? ++echo "$as_me:$LINENO: checking libintl.h usability" >&5 ++echo $ECHO_N "checking libintl.h usability... $ECHO_C" >&6 ++cat >conftest.$ac_ext <<_ACEOF + /* confdefs.h. */ + _ACEOF + cat confdefs.h >>conftest.$ac_ext + cat >>conftest.$ac_ext <<_ACEOF + /* end confdefs.h. */ +- +-#include +-#include +-#include +- +-/* we do not #include because autoconf in C++ mode inserts a +- prototype for exit() that conflicts with the one in stdlib.h */ +-extern "C" int system(const char *); +- +-int main(void) +-{ +- system("touch conf.clntest"); +- +- if ((CL_VERSION_MAJOR != $cln_config_major_version) || +- (CL_VERSION_MINOR != $cln_config_minor_version) || +- (CL_VERSION_PATCHLEVEL != $cln_config_micro_version)) { +- printf("\n*** 'cln-config --version' returned %d.%d.%d, but the header file I found\n", $cln_config_major_version, $cln_config_minor_version, $cln_config_micro_version); +- printf("*** corresponds to %d.%d.%d. This mismatch suggests your installation of CLN\n", CL_VERSION_MAJOR, CL_VERSION_MINOR, CL_VERSION_PATCHLEVEL); +- printf("*** is corrupted or you have specified some wrong -I compiler flags.\n"); +- printf("*** Please inquire and consider reinstalling CLN.\n"); +- return 1; +- } +- if ((cln::version_major != $cln_config_major_version) || +- (cln::version_minor != $cln_config_minor_version) || +- (cln::version_patchlevel != $cln_config_micro_version)) { +- printf("\n*** 'cln-config --version' returned %d.%d.%d, but the library I found\n", $cln_config_major_version, $cln_config_minor_version, $cln_config_micro_version); +- printf("*** corresponds to %d.%d.%d. This mismatch suggests your installation of CLN\n", cln::version_major, cln::version_minor, cln::version_patchlevel); +- printf("*** is corrupted or you have specified some wrong -L compiler flags.\n"); +- printf("*** Please inquire and consider reinstalling CLN.\n"); +- return 1; +- } +- return 0; +-} +- ++$ac_includes_default ++#include + _ACEOF +-rm -f conftest$ac_exeext +-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 +- (eval $ac_link) 2>&5 ++rm -f conftest.$ac_objext ++if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 ++ (eval $ac_compile) 2>conftest.er1 + ac_status=$? ++ grep -v '^ *+' conftest.er1 >conftest.err ++ rm -f conftest.er1 ++ cat conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); } && { ac_try='./conftest$ac_exeext' ++ (exit $ac_status); } && ++ { ac_try='test -z "$ac_cxx_werror_flag" ++ || test ! -s conftest.err' ++ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 ++ (eval $ac_try) 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; } && ++ { ac_try='test -s conftest.$ac_objext' + { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then +- : ++ ac_header_compiler=yes + else +- echo "$as_me: program exited with status $ac_status" >&5 +-echo "$as_me: failed program was:" >&5 ++ echo "$as_me: failed program was:" >&5 + sed 's/^/| /' conftest.$ac_ext >&5 + +-( exit $ac_status ) +-no_cln=yes +-fi +-rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext ++ac_header_compiler=no + fi +- CPPFLAGS="$ac_save_CPPFLAGS" +- LIBS="$ac_save_LIBS" +- fi +- if test "x$no_cln" = x ; then +- echo "$as_me:$LINENO: result: yes, $cln_config_version" >&5 +-echo "${ECHO_T}yes, $cln_config_version" >&6 +- +- LIBS="$LIBS $CLN_LIBS" +- CPPFLAGS="$CPPFLAGS $CLN_CPPFLAGS" +- +-cat >>confdefs.h <<\_ACEOF +-#define HAVE_LIBCLN 1 +-_ACEOF +- ++rm -f conftest.err conftest.$ac_objext conftest.$ac_ext ++echo "$as_me:$LINENO: result: $ac_header_compiler" >&5 ++echo "${ECHO_T}$ac_header_compiler" >&6 + +- else +- echo "$as_me:$LINENO: result: no" >&5 +-echo "${ECHO_T}no" >&6 +- if test ! -f conf.clntest ; then +- echo "*** Could not run CLN test program, checking why..." +- CPPFLAGS="$CFLAGS $CLN_CPPFLAGS" +- LIBS="$LIBS $CLN_LIBS" +- cat >conftest.$ac_ext <<_ACEOF ++# Is the header present? ++echo "$as_me:$LINENO: checking libintl.h presence" >&5 ++echo $ECHO_N "checking libintl.h presence... $ECHO_C" >&6 ++cat >conftest.$ac_ext <<_ACEOF + /* confdefs.h. */ + _ACEOF + cat confdefs.h >>conftest.$ac_ext + cat >>conftest.$ac_ext <<_ACEOF + /* end confdefs.h. */ +- +-#include +-#include +- +-int +-main () +-{ +- return 0; +- ; +- return 0; +-} ++#include + _ACEOF +-rm -f conftest.$ac_objext conftest$ac_exeext +-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 +- (eval $ac_link) 2>conftest.er1 ++if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5 ++ (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 + ac_status=$? + grep -v '^ *+' conftest.er1 >conftest.err + rm -f conftest.er1 + cat conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); } && +- { ac_try='test -z "$ac_cxx_werror_flag" +- || test ! -s conftest.err' +- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 +- (eval $ac_try) 2>&5 +- ac_status=$? +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; } && +- { ac_try='test -s conftest$ac_exeext' +- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 +- (eval $ac_try) 2>&5 +- ac_status=$? +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; }; then +- echo "*** The test program compiled, but did not run. This usually means" +- echo "*** that the run-time linker is not finding CLN or finding the wrong" +- echo "*** version of CLN. If it is not finding CLN, you'll need to set your" +- echo "*** LD_LIBRARY_PATH environment variable, or edit /etc/ld.so.conf to point" +- echo "*** to the installed location. Also, make sure you have run ldconfig if that" +- echo "*** is required on your system." ++ (exit $ac_status); } >/dev/null; then ++ if test -s conftest.err; then ++ ac_cpp_err=$ac_cxx_preproc_warn_flag ++ ac_cpp_err=$ac_cpp_err$ac_cxx_werror_flag ++ else ++ ac_cpp_err= ++ fi ++else ++ ac_cpp_err=yes ++fi ++if test -z "$ac_cpp_err"; then ++ ac_header_preproc=yes + else + echo "$as_me: failed program was:" >&5 + sed 's/^/| /' conftest.$ac_ext >&5 + +- echo "*** The test program failed to compile or link. See the file config.log for the" +- echo "*** exact error that occured. This usually means CLN was incorrectly installed" +- echo "*** or that you have moved CLN since it was installed. In the latter case, you" +- echo "*** may want to edit the cln-config script: $CLN_CONFIG." +-fi +-rm -f conftest.err conftest.$ac_objext \ +- conftest$ac_exeext conftest.$ac_ext +- CPPFLAGS="$ac_save_CPPFLAGS" +- LIBS="$ac_save_LIBS" +- fi +- CLN_CPPFLAGS="" +- CLN_LIBS="" +- { { echo "$as_me:$LINENO: error: No suitable installed version of CLN could be found." >&5 +-echo "$as_me: error: No suitable installed version of CLN could be found." >&2;} +- { (exit 1); exit 1; }; } +- fi +- fi ++ ac_header_preproc=no + fi ++rm -f conftest.err conftest.$ac_ext ++echo "$as_me:$LINENO: result: $ac_header_preproc" >&5 ++echo "${ECHO_T}$ac_header_preproc" >&6 + +- +-rm -f conf.clntest +- +- +- +- +-if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then +- if test -n "$ac_tool_prefix"; then +- # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args. +-set dummy ${ac_tool_prefix}pkg-config; ac_word=$2 +-echo "$as_me:$LINENO: checking for $ac_word" >&5 +-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 +-if test "${ac_cv_path_PKG_CONFIG+set}" = set; then ++# So? What about this header? ++case $ac_header_compiler:$ac_header_preproc:$ac_cxx_preproc_warn_flag in ++ yes:no: ) ++ { echo "$as_me:$LINENO: WARNING: libintl.h: accepted by the compiler, rejected by the preprocessor!" >&5 ++echo "$as_me: WARNING: libintl.h: accepted by the compiler, rejected by the preprocessor!" >&2;} ++ { echo "$as_me:$LINENO: WARNING: libintl.h: proceeding with the compiler's result" >&5 ++echo "$as_me: WARNING: libintl.h: proceeding with the compiler's result" >&2;} ++ ac_header_preproc=yes ++ ;; ++ no:yes:* ) ++ { echo "$as_me:$LINENO: WARNING: libintl.h: present but cannot be compiled" >&5 ++echo "$as_me: WARNING: libintl.h: present but cannot be compiled" >&2;} ++ { echo "$as_me:$LINENO: WARNING: libintl.h: check for missing prerequisite headers?" >&5 ++echo "$as_me: WARNING: libintl.h: check for missing prerequisite headers?" >&2;} ++ { echo "$as_me:$LINENO: WARNING: libintl.h: see the Autoconf documentation" >&5 ++echo "$as_me: WARNING: libintl.h: see the Autoconf documentation" >&2;} ++ { echo "$as_me:$LINENO: WARNING: libintl.h: section \"Present But Cannot Be Compiled\"" >&5 ++echo "$as_me: WARNING: libintl.h: section \"Present But Cannot Be Compiled\"" >&2;} ++ { echo "$as_me:$LINENO: WARNING: libintl.h: proceeding with the preprocessor's result" >&5 ++echo "$as_me: WARNING: libintl.h: proceeding with the preprocessor's result" >&2;} ++ { echo "$as_me:$LINENO: WARNING: libintl.h: in the future, the compiler will take precedence" >&5 ++echo "$as_me: WARNING: libintl.h: in the future, the compiler will take precedence" >&2;} ++ ( ++ cat <<\_ASBOX ++## ------------------------------------------ ## ++## Report this to the AC_PACKAGE_NAME lists. ## ++## ------------------------------------------ ## ++_ASBOX ++ ) | ++ sed "s/^/$as_me: WARNING: /" >&2 ++ ;; ++esac ++echo "$as_me:$LINENO: checking for libintl.h" >&5 ++echo $ECHO_N "checking for libintl.h... $ECHO_C" >&6 ++if test "${ac_cv_header_libintl_h+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 + else +- case $PKG_CONFIG in +- [\\/]* | ?:[\\/]*) +- ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path. +- ;; +- *) +- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +-for as_dir in $PATH +-do +- IFS=$as_save_IFS +- test -z "$as_dir" && as_dir=. +- for ac_exec_ext in '' $ac_executable_extensions; do +- if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then +- ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" +- echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 +- break 2 +- fi +-done +-done +- +- ;; +-esac ++ ac_cv_header_libintl_h=$ac_header_preproc + fi +-PKG_CONFIG=$ac_cv_path_PKG_CONFIG ++echo "$as_me:$LINENO: result: $ac_cv_header_libintl_h" >&5 ++echo "${ECHO_T}$ac_cv_header_libintl_h" >&6 + +-if test -n "$PKG_CONFIG"; then +- echo "$as_me:$LINENO: result: $PKG_CONFIG" >&5 +-echo "${ECHO_T}$PKG_CONFIG" >&6 +-else +- echo "$as_me:$LINENO: result: no" >&5 +-echo "${ECHO_T}no" >&6 + fi ++if test $ac_cv_header_libintl_h = yes; then ++ gt_cv_func_dgettext_libintl="no" ++ libintl_extra_libs="" + +-fi +-if test -z "$ac_cv_path_PKG_CONFIG"; then +- ac_pt_PKG_CONFIG=$PKG_CONFIG +- # Extract the first word of "pkg-config", so it can be a program name with args. +-set dummy pkg-config; ac_word=$2 +-echo "$as_me:$LINENO: checking for $ac_word" >&5 +-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 +-if test "${ac_cv_path_ac_pt_PKG_CONFIG+set}" = set; then ++ # ++ # First check in libc ++ # ++ echo "$as_me:$LINENO: checking for ngettext in libc" >&5 ++echo $ECHO_N "checking for ngettext in libc... $ECHO_C" >&6 ++if test "${gt_cv_func_ngettext_libc+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 + else +- case $ac_pt_PKG_CONFIG in +- [\\/]* | ?:[\\/]*) +- ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path. +- ;; +- *) +- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +-for as_dir in $PATH +-do +- IFS=$as_save_IFS +- test -z "$as_dir" && as_dir=. +- for ac_exec_ext in '' $ac_executable_extensions; do +- if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then +- ac_cv_path_ac_pt_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" +- echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 +- break 2 +- fi +-done +-done ++ cat >conftest.$ac_ext <<_ACEOF ++/* confdefs.h. */ ++_ACEOF ++cat confdefs.h >>conftest.$ac_ext ++cat >>conftest.$ac_ext <<_ACEOF ++/* end confdefs.h. */ + +- ;; +-esac +-fi +-ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG ++#include + +-if test -n "$ac_pt_PKG_CONFIG"; then +- echo "$as_me:$LINENO: result: $ac_pt_PKG_CONFIG" >&5 +-echo "${ECHO_T}$ac_pt_PKG_CONFIG" >&6 ++int ++main () ++{ ++return !ngettext ("","", 1) ++ ; ++ return 0; ++} ++_ACEOF ++rm -f conftest.$ac_objext conftest$ac_exeext ++if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 ++ (eval $ac_link) 2>conftest.er1 ++ ac_status=$? ++ grep -v '^ *+' conftest.er1 >conftest.err ++ rm -f conftest.er1 ++ cat conftest.err >&5 ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); } && ++ { ac_try='test -z "$ac_cxx_werror_flag" ++ || test ! -s conftest.err' ++ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 ++ (eval $ac_try) 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; } && ++ { ac_try='test -s conftest$ac_exeext' ++ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 ++ (eval $ac_try) 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; }; then ++ gt_cv_func_ngettext_libc=yes + else +- echo "$as_me:$LINENO: result: no" >&5 +-echo "${ECHO_T}no" >&6 +-fi ++ echo "$as_me: failed program was:" >&5 ++sed 's/^/| /' conftest.$ac_ext >&5 + +- PKG_CONFIG=$ac_pt_PKG_CONFIG +-else +- PKG_CONFIG="$ac_cv_path_PKG_CONFIG" ++gt_cv_func_ngettext_libc=no + fi ++rm -f conftest.err conftest.$ac_objext \ ++ conftest$ac_exeext conftest.$ac_ext + + fi +-if test -n "$PKG_CONFIG"; then +- _pkg_min_version=0.9.0 +- echo "$as_me:$LINENO: checking pkg-config is at least version $_pkg_min_version" >&5 +-echo $ECHO_N "checking pkg-config is at least version $_pkg_min_version... $ECHO_C" >&6 +- if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then +- echo "$as_me:$LINENO: result: yes" >&5 +-echo "${ECHO_T}yes" >&6 +- else +- echo "$as_me:$LINENO: result: no" >&5 +-echo "${ECHO_T}no" >&6 +- PKG_CONFIG="" +- fi ++echo "$as_me:$LINENO: result: $gt_cv_func_ngettext_libc" >&5 ++echo "${ECHO_T}$gt_cv_func_ngettext_libc" >&6 + +-fi ++ if test "$gt_cv_func_ngettext_libc" = "yes" ; then ++ echo "$as_me:$LINENO: checking for dgettext in libc" >&5 ++echo $ECHO_N "checking for dgettext in libc... $ECHO_C" >&6 ++if test "${gt_cv_func_dgettext_libc+set}" = set; then ++ echo $ECHO_N "(cached) $ECHO_C" >&6 ++else ++ cat >conftest.$ac_ext <<_ACEOF ++/* confdefs.h. */ ++_ACEOF ++cat confdefs.h >>conftest.$ac_ext ++cat >>conftest.$ac_ext <<_ACEOF ++/* end confdefs.h. */ + +-pkg_failed=no +-echo "$as_me:$LINENO: checking for GLIB" >&5 +-echo $ECHO_N "checking for GLIB... $ECHO_C" >&6 ++#include + +-if test -n "$PKG_CONFIG"; then +- if test -n "$GLIB_CFLAGS"; then +- pkg_cv_GLIB_CFLAGS="$GLIB_CFLAGS" +- else +- if test -n "$PKG_CONFIG" && \ +- { (echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \" +- glib-2.0 >= 2.4 +- libxml-2.0 +- \"") >&5 +- ($PKG_CONFIG --exists --print-errors " +- glib-2.0 >= 2.4 +- libxml-2.0 +- ") 2>&5 ++int ++main () ++{ ++return !dgettext ("","") ++ ; ++ return 0; ++} ++_ACEOF ++rm -f conftest.$ac_objext conftest$ac_exeext ++if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 ++ (eval $ac_link) 2>conftest.er1 + ac_status=$? ++ grep -v '^ *+' conftest.er1 >conftest.err ++ rm -f conftest.er1 ++ cat conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; then +- pkg_cv_GLIB_CFLAGS=`$PKG_CONFIG --cflags " +- glib-2.0 >= 2.4 +- libxml-2.0 +- " 2>/dev/null` +-else +- pkg_failed=yes +-fi +- fi +-else +- pkg_failed=untried +-fi +-if test -n "$PKG_CONFIG"; then +- if test -n "$GLIB_LIBS"; then +- pkg_cv_GLIB_LIBS="$GLIB_LIBS" +- else +- if test -n "$PKG_CONFIG" && \ +- { (echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \" +- glib-2.0 >= 2.4 +- libxml-2.0 +- \"") >&5 +- ($PKG_CONFIG --exists --print-errors " +- glib-2.0 >= 2.4 +- libxml-2.0 +- ") 2>&5 ++ (exit $ac_status); } && ++ { ac_try='test -z "$ac_cxx_werror_flag" ++ || test ! -s conftest.err' ++ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 ++ (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; then +- pkg_cv_GLIB_LIBS=`$PKG_CONFIG --libs " +- glib-2.0 >= 2.4 +- libxml-2.0 +- " 2>/dev/null` +-else +- pkg_failed=yes +-fi +- fi ++ (exit $ac_status); }; } && ++ { ac_try='test -s conftest$ac_exeext' ++ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 ++ (eval $ac_try) 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; }; then ++ gt_cv_func_dgettext_libc=yes + else +- pkg_failed=untried +-fi +- +- +- +-if test $pkg_failed = yes; then ++ echo "$as_me: failed program was:" >&5 ++sed 's/^/| /' conftest.$ac_ext >&5 + +-if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then +- _pkg_short_errors_supported=yes +-else +- _pkg_short_errors_supported=no ++gt_cv_func_dgettext_libc=no + fi +- if test $_pkg_short_errors_supported = yes; then +- GLIB_PKG_ERRORS=`$PKG_CONFIG --short-errors --errors-to-stdout --print-errors " +- glib-2.0 >= 2.4 +- libxml-2.0 +- "` +- else +- GLIB_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors " +- glib-2.0 >= 2.4 +- libxml-2.0 +- "` +- fi +- # Put the nasty error message in config.log where it belongs +- echo "$GLIB_PKG_ERRORS" >&5 +- +- { { echo "$as_me:$LINENO: error: Package requirements ( +- glib-2.0 >= 2.4 +- libxml-2.0 +- ) were not met: +- +-$GLIB_PKG_ERRORS +- +-Consider adjusting the PKG_CONFIG_PATH environment variable if you +-installed software in a non-standard prefix. +- +-Alternatively, you may set the environment variables GLIB_CFLAGS +-and GLIB_LIBS to avoid the need to call pkg-config. +-See the pkg-config man page for more details. +-" >&5 +-echo "$as_me: error: Package requirements ( +- glib-2.0 >= 2.4 +- libxml-2.0 +- ) were not met: +- +-$GLIB_PKG_ERRORS +- +-Consider adjusting the PKG_CONFIG_PATH environment variable if you +-installed software in a non-standard prefix. +- +-Alternatively, you may set the environment variables GLIB_CFLAGS +-and GLIB_LIBS to avoid the need to call pkg-config. +-See the pkg-config man page for more details. +-" >&2;} +- { (exit 1); exit 1; }; } +-elif test $pkg_failed = untried; then +- { { echo "$as_me:$LINENO: error: The pkg-config script could not be found or is too old. Make sure it +-is in your PATH or set the PKG_CONFIG environment variable to the full +-path to pkg-config. +- +-Alternatively, you may set the environment variables GLIB_CFLAGS +-and GLIB_LIBS to avoid the need to call pkg-config. +-See the pkg-config man page for more details. ++rm -f conftest.err conftest.$ac_objext \ ++ conftest$ac_exeext conftest.$ac_ext + +-To get pkg-config, see . +-See \`config.log' for more details." >&5 +-echo "$as_me: error: The pkg-config script could not be found or is too old. Make sure it +-is in your PATH or set the PKG_CONFIG environment variable to the full +-path to pkg-config. ++fi ++echo "$as_me:$LINENO: result: $gt_cv_func_dgettext_libc" >&5 ++echo "${ECHO_T}$gt_cv_func_dgettext_libc" >&6 ++ fi + +-Alternatively, you may set the environment variables GLIB_CFLAGS +-and GLIB_LIBS to avoid the need to call pkg-config. +-See the pkg-config man page for more details. ++ if test "$gt_cv_func_ngettext_libc" = "yes" ; then + +-To get pkg-config, see . +-See \`config.log' for more details." >&2;} +- { (exit 1); exit 1; }; } ++for ac_func in bind_textdomain_codeset ++do ++as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh` ++echo "$as_me:$LINENO: checking for $ac_func" >&5 ++echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6 ++if eval "test \"\${$as_ac_var+set}\" = set"; then ++ echo $ECHO_N "(cached) $ECHO_C" >&6 + else +- GLIB_CFLAGS=$pkg_cv_GLIB_CFLAGS +- GLIB_LIBS=$pkg_cv_GLIB_LIBS +- echo "$as_me:$LINENO: result: yes" >&5 +-echo "${ECHO_T}yes" >&6 +- : +-fi ++ cat >conftest.$ac_ext <<_ACEOF ++/* confdefs.h. */ ++_ACEOF ++cat confdefs.h >>conftest.$ac_ext ++cat >>conftest.$ac_ext <<_ACEOF ++/* end confdefs.h. */ ++/* Define $ac_func to an innocuous variant, in case declares $ac_func. ++ For example, HP-UX 11i declares gettimeofday. */ ++#define $ac_func innocuous_$ac_func + ++/* System header to define __stub macros and hopefully few prototypes, ++ which can conflict with char $ac_func (); below. ++ Prefer to if __STDC__ is defined, since ++ exists even on freestanding compilers. */ + ++#ifdef __STDC__ ++# include ++#else ++# include ++#endif + ++#undef $ac_func + +-pkg_failed=no +-echo "$as_me:$LINENO: checking for GTK" >&5 +-echo $ECHO_N "checking for GTK... $ECHO_C" >&6 ++/* Override any gcc2 internal prototype to avoid an error. */ ++#ifdef __cplusplus ++extern "C" ++{ ++#endif ++/* We use char because int might match the return type of a gcc2 ++ builtin and then its argument prototype would still apply. */ ++char $ac_func (); ++/* The GNU C library defines this for functions which it implements ++ to always fail with ENOSYS. Some functions are actually named ++ something starting with __ and the normal name is an alias. */ ++#if defined (__stub_$ac_func) || defined (__stub___$ac_func) ++choke me ++#else ++char (*f) () = $ac_func; ++#endif ++#ifdef __cplusplus ++} ++#endif + +-if test -n "$PKG_CONFIG"; then +- if test -n "$GTK_CFLAGS"; then +- pkg_cv_GTK_CFLAGS="$GTK_CFLAGS" +- else +- if test -n "$PKG_CONFIG" && \ +- { (echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \" +- gtk+-2.0 >= 2.4 +- gdk-pixbuf-2.0 +- \"") >&5 +- ($PKG_CONFIG --exists --print-errors " +- gtk+-2.0 >= 2.4 +- gdk-pixbuf-2.0 +- ") 2>&5 ++int ++main () ++{ ++return f != $ac_func; ++ ; ++ return 0; ++} ++_ACEOF ++rm -f conftest.$ac_objext conftest$ac_exeext ++if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 ++ (eval $ac_link) 2>conftest.er1 + ac_status=$? ++ grep -v '^ *+' conftest.er1 >conftest.err ++ rm -f conftest.er1 ++ cat conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; then +- pkg_cv_GTK_CFLAGS=`$PKG_CONFIG --cflags " +- gtk+-2.0 >= 2.4 +- gdk-pixbuf-2.0 +- " 2>/dev/null` +-else +- pkg_failed=yes +-fi +- fi +-else +- pkg_failed=untried +-fi +-if test -n "$PKG_CONFIG"; then +- if test -n "$GTK_LIBS"; then +- pkg_cv_GTK_LIBS="$GTK_LIBS" +- else +- if test -n "$PKG_CONFIG" && \ +- { (echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \" +- gtk+-2.0 >= 2.4 +- gdk-pixbuf-2.0 +- \"") >&5 +- ($PKG_CONFIG --exists --print-errors " +- gtk+-2.0 >= 2.4 +- gdk-pixbuf-2.0 +- ") 2>&5 ++ (exit $ac_status); } && ++ { ac_try='test -z "$ac_cxx_werror_flag" ++ || test ! -s conftest.err' ++ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 ++ (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; then +- pkg_cv_GTK_LIBS=`$PKG_CONFIG --libs " +- gtk+-2.0 >= 2.4 +- gdk-pixbuf-2.0 +- " 2>/dev/null` ++ (exit $ac_status); }; } && ++ { ac_try='test -s conftest$ac_exeext' ++ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 ++ (eval $ac_try) 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; }; then ++ eval "$as_ac_var=yes" + else +- pkg_failed=yes ++ echo "$as_me: failed program was:" >&5 ++sed 's/^/| /' conftest.$ac_ext >&5 ++ ++eval "$as_ac_var=no" + fi +- fi +-else +- pkg_failed=untried ++rm -f conftest.err conftest.$ac_objext \ ++ conftest$ac_exeext conftest.$ac_ext + fi ++echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5 ++echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6 ++if test `eval echo '${'$as_ac_var'}'` = yes; then ++ cat >>confdefs.h <<_ACEOF ++#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1 ++_ACEOF + ++fi ++done + ++ fi + +-if test $pkg_failed = yes; then ++ # ++ # If we don't have everything we want, check in libintl ++ # ++ if test "$gt_cv_func_dgettext_libc" != "yes" \ ++ || test "$gt_cv_func_ngettext_libc" != "yes" \ ++ || test "$ac_cv_func_bind_textdomain_codeset" != "yes" ; then + +-if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then +- _pkg_short_errors_supported=yes ++ echo "$as_me:$LINENO: checking for bindtextdomain in -lintl" >&5 ++echo $ECHO_N "checking for bindtextdomain in -lintl... $ECHO_C" >&6 ++if test "${ac_cv_lib_intl_bindtextdomain+set}" = set; then ++ echo $ECHO_N "(cached) $ECHO_C" >&6 + else +- _pkg_short_errors_supported=no +-fi +- if test $_pkg_short_errors_supported = yes; then +- GTK_PKG_ERRORS=`$PKG_CONFIG --short-errors --errors-to-stdout --print-errors " +- gtk+-2.0 >= 2.4 +- gdk-pixbuf-2.0 +- "` +- else +- GTK_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors " +- gtk+-2.0 >= 2.4 +- gdk-pixbuf-2.0 +- "` +- fi +- # Put the nasty error message in config.log where it belongs +- echo "$GTK_PKG_ERRORS" >&5 +- +- { { echo "$as_me:$LINENO: error: Package requirements ( +- gtk+-2.0 >= 2.4 +- gdk-pixbuf-2.0 +- ) were not met: +- +-$GTK_PKG_ERRORS +- +-Consider adjusting the PKG_CONFIG_PATH environment variable if you +-installed software in a non-standard prefix. +- +-Alternatively, you may set the environment variables GTK_CFLAGS +-and GTK_LIBS to avoid the need to call pkg-config. +-See the pkg-config man page for more details. +-" >&5 +-echo "$as_me: error: Package requirements ( +- gtk+-2.0 >= 2.4 +- gdk-pixbuf-2.0 +- ) were not met: +- +-$GTK_PKG_ERRORS +- +-Consider adjusting the PKG_CONFIG_PATH environment variable if you +-installed software in a non-standard prefix. +- +-Alternatively, you may set the environment variables GTK_CFLAGS +-and GTK_LIBS to avoid the need to call pkg-config. +-See the pkg-config man page for more details. +-" >&2;} +- { (exit 1); exit 1; }; } +-elif test $pkg_failed = untried; then +- { { echo "$as_me:$LINENO: error: The pkg-config script could not be found or is too old. Make sure it +-is in your PATH or set the PKG_CONFIG environment variable to the full +-path to pkg-config. +- +-Alternatively, you may set the environment variables GTK_CFLAGS +-and GTK_LIBS to avoid the need to call pkg-config. +-See the pkg-config man page for more details. +- +-To get pkg-config, see . +-See \`config.log' for more details." >&5 +-echo "$as_me: error: The pkg-config script could not be found or is too old. Make sure it +-is in your PATH or set the PKG_CONFIG environment variable to the full +-path to pkg-config. +- +-Alternatively, you may set the environment variables GTK_CFLAGS +-and GTK_LIBS to avoid the need to call pkg-config. +-See the pkg-config man page for more details. +- +-To get pkg-config, see . +-See \`config.log' for more details." >&2;} +- { (exit 1); exit 1; }; } +-else +- GTK_CFLAGS=$pkg_cv_GTK_CFLAGS +- GTK_LIBS=$pkg_cv_GTK_LIBS +- echo "$as_me:$LINENO: result: yes" >&5 +-echo "${ECHO_T}yes" >&6 +- : +-fi +- +- +- +- +-pkg_failed=no +-echo "$as_me:$LINENO: checking for QALCULATE" >&5 +-echo $ECHO_N "checking for QALCULATE... $ECHO_C" >&6 +- +-if test -n "$PKG_CONFIG"; then +- if test -n "$QALCULATE_CFLAGS"; then +- pkg_cv_QALCULATE_CFLAGS="$QALCULATE_CFLAGS" +- else +- if test -n "$PKG_CONFIG" && \ +- { (echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \" +- libqalculate >= 0.9.4 +- \"") >&5 +- ($PKG_CONFIG --exists --print-errors " +- libqalculate >= 0.9.4 +- ") 2>&5 +- ac_status=$? +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; then +- pkg_cv_QALCULATE_CFLAGS=`$PKG_CONFIG --cflags " +- libqalculate >= 0.9.4 +- " 2>/dev/null` +-else +- pkg_failed=yes +-fi +- fi +-else +- pkg_failed=untried +-fi +-if test -n "$PKG_CONFIG"; then +- if test -n "$QALCULATE_LIBS"; then +- pkg_cv_QALCULATE_LIBS="$QALCULATE_LIBS" +- else +- if test -n "$PKG_CONFIG" && \ +- { (echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \" +- libqalculate >= 0.9.4 +- \"") >&5 +- ($PKG_CONFIG --exists --print-errors " +- libqalculate >= 0.9.4 +- ") 2>&5 +- ac_status=$? +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; then +- pkg_cv_QALCULATE_LIBS=`$PKG_CONFIG --libs " +- libqalculate >= 0.9.4 +- " 2>/dev/null` +-else +- pkg_failed=yes +-fi +- fi +-else +- pkg_failed=untried +-fi +- +- +- +-if test $pkg_failed = yes; then +- +-if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then +- _pkg_short_errors_supported=yes +-else +- _pkg_short_errors_supported=no +-fi +- if test $_pkg_short_errors_supported = yes; then +- QALCULATE_PKG_ERRORS=`$PKG_CONFIG --short-errors --errors-to-stdout --print-errors " +- libqalculate >= 0.9.4 +- "` +- else +- QALCULATE_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors " +- libqalculate >= 0.9.4 +- "` +- fi +- # Put the nasty error message in config.log where it belongs +- echo "$QALCULATE_PKG_ERRORS" >&5 +- +- { { echo "$as_me:$LINENO: error: Package requirements ( +- libqalculate >= 0.9.4 +- ) were not met: +- +-$QALCULATE_PKG_ERRORS +- +-Consider adjusting the PKG_CONFIG_PATH environment variable if you +-installed software in a non-standard prefix. +- +-Alternatively, you may set the environment variables QALCULATE_CFLAGS +-and QALCULATE_LIBS to avoid the need to call pkg-config. +-See the pkg-config man page for more details. +-" >&5 +-echo "$as_me: error: Package requirements ( +- libqalculate >= 0.9.4 +- ) were not met: +- +-$QALCULATE_PKG_ERRORS +- +-Consider adjusting the PKG_CONFIG_PATH environment variable if you +-installed software in a non-standard prefix. +- +-Alternatively, you may set the environment variables QALCULATE_CFLAGS +-and QALCULATE_LIBS to avoid the need to call pkg-config. +-See the pkg-config man page for more details. +-" >&2;} +- { (exit 1); exit 1; }; } +-elif test $pkg_failed = untried; then +- { { echo "$as_me:$LINENO: error: The pkg-config script could not be found or is too old. Make sure it +-is in your PATH or set the PKG_CONFIG environment variable to the full +-path to pkg-config. +- +-Alternatively, you may set the environment variables QALCULATE_CFLAGS +-and QALCULATE_LIBS to avoid the need to call pkg-config. +-See the pkg-config man page for more details. +- +-To get pkg-config, see . +-See \`config.log' for more details." >&5 +-echo "$as_me: error: The pkg-config script could not be found or is too old. Make sure it +-is in your PATH or set the PKG_CONFIG environment variable to the full +-path to pkg-config. +- +-Alternatively, you may set the environment variables QALCULATE_CFLAGS +-and QALCULATE_LIBS to avoid the need to call pkg-config. +-See the pkg-config man page for more details. +- +-To get pkg-config, see . +-See \`config.log' for more details." >&2;} +- { (exit 1); exit 1; }; } +-else +- QALCULATE_CFLAGS=$pkg_cv_QALCULATE_CFLAGS +- QALCULATE_LIBS=$pkg_cv_QALCULATE_LIBS +- echo "$as_me:$LINENO: result: yes" >&5 +-echo "${ECHO_T}yes" >&6 +- : +-fi +- +- +- +- +-GETTEXT_PACKAGE=qalculate-currency +- +- +-cat >>confdefs.h <<_ACEOF +-#define GETTEXT_PACKAGE "$GETTEXT_PACKAGE" +-_ACEOF +- +- +-ALL_LINGUAS="nl sv" +- +- +- +-for ac_header in locale.h +-do +-as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh` +-if eval "test \"\${$as_ac_Header+set}\" = set"; then +- echo "$as_me:$LINENO: checking for $ac_header" >&5 +-echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6 +-if eval "test \"\${$as_ac_Header+set}\" = set"; then +- echo $ECHO_N "(cached) $ECHO_C" >&6 +-fi +-echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5 +-echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6 +-else +- # Is the header compilable? +-echo "$as_me:$LINENO: checking $ac_header usability" >&5 +-echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6 ++ ac_check_lib_save_LIBS=$LIBS ++LIBS="-lintl $LIBS" + cat >conftest.$ac_ext <<_ACEOF + /* confdefs.h. */ + _ACEOF + cat confdefs.h >>conftest.$ac_ext + cat >>conftest.$ac_ext <<_ACEOF + /* end confdefs.h. */ +-$ac_includes_default +-#include <$ac_header> ++ ++/* Override any gcc2 internal prototype to avoid an error. */ ++#ifdef __cplusplus ++extern "C" ++#endif ++/* We use char because int might match the return type of a gcc2 ++ builtin and then its argument prototype would still apply. */ ++char bindtextdomain (); ++int ++main () ++{ ++bindtextdomain (); ++ ; ++ return 0; ++} + _ACEOF +-rm -f conftest.$ac_objext +-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 +- (eval $ac_compile) 2>conftest.er1 ++rm -f conftest.$ac_objext conftest$ac_exeext ++if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 ++ (eval $ac_link) 2>conftest.er1 + ac_status=$? + grep -v '^ *+' conftest.er1 >conftest.err + rm -f conftest.er1 +@@ -21002,138 +20711,57 @@ if { (eval echo "$as_me:$LINENO: \"$ac_c + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } && + { ac_try='test -z "$ac_cxx_werror_flag" +- || test ! -s conftest.err' +- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 +- (eval $ac_try) 2>&5 +- ac_status=$? +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; } && +- { ac_try='test -s conftest.$ac_objext' +- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 +- (eval $ac_try) 2>&5 +- ac_status=$? +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; }; then +- ac_header_compiler=yes +-else +- echo "$as_me: failed program was:" >&5 +-sed 's/^/| /' conftest.$ac_ext >&5 +- +-ac_header_compiler=no +-fi +-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext +-echo "$as_me:$LINENO: result: $ac_header_compiler" >&5 +-echo "${ECHO_T}$ac_header_compiler" >&6 +- +-# Is the header present? +-echo "$as_me:$LINENO: checking $ac_header presence" >&5 +-echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6 +-cat >conftest.$ac_ext <<_ACEOF +-/* confdefs.h. */ +-_ACEOF +-cat confdefs.h >>conftest.$ac_ext +-cat >>conftest.$ac_ext <<_ACEOF +-/* end confdefs.h. */ +-#include <$ac_header> +-_ACEOF +-if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5 +- (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 +- ac_status=$? +- grep -v '^ *+' conftest.er1 >conftest.err +- rm -f conftest.er1 +- cat conftest.err >&5 +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); } >/dev/null; then +- if test -s conftest.err; then +- ac_cpp_err=$ac_cxx_preproc_warn_flag +- ac_cpp_err=$ac_cpp_err$ac_cxx_werror_flag +- else +- ac_cpp_err= +- fi +-else +- ac_cpp_err=yes +-fi +-if test -z "$ac_cpp_err"; then +- ac_header_preproc=yes +-else +- echo "$as_me: failed program was:" >&5 +-sed 's/^/| /' conftest.$ac_ext >&5 +- +- ac_header_preproc=no +-fi +-rm -f conftest.err conftest.$ac_ext +-echo "$as_me:$LINENO: result: $ac_header_preproc" >&5 +-echo "${ECHO_T}$ac_header_preproc" >&6 +- +-# So? What about this header? +-case $ac_header_compiler:$ac_header_preproc:$ac_cxx_preproc_warn_flag in +- yes:no: ) +- { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5 +-echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;} +- { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5 +-echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;} +- ac_header_preproc=yes +- ;; +- no:yes:* ) +- { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5 +-echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;} +- { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5 +-echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;} +- { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5 +-echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;} +- { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5 +-echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;} +- { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5 +-echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;} +- { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5 +-echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;} +- ( +- cat <<\_ASBOX +-## ------------------------------------------ ## +-## Report this to the AC_PACKAGE_NAME lists. ## +-## ------------------------------------------ ## +-_ASBOX +- ) | +- sed "s/^/$as_me: WARNING: /" >&2 +- ;; +-esac +-echo "$as_me:$LINENO: checking for $ac_header" >&5 +-echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6 +-if eval "test \"\${$as_ac_Header+set}\" = set"; then +- echo $ECHO_N "(cached) $ECHO_C" >&6 ++ || test ! -s conftest.err' ++ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 ++ (eval $ac_try) 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; } && ++ { ac_try='test -s conftest$ac_exeext' ++ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 ++ (eval $ac_try) 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; }; then ++ ac_cv_lib_intl_bindtextdomain=yes + else +- eval "$as_ac_Header=\$ac_header_preproc" +-fi +-echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5 +-echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6 ++ echo "$as_me: failed program was:" >&5 ++sed 's/^/| /' conftest.$ac_ext >&5 + ++ac_cv_lib_intl_bindtextdomain=no + fi +-if test `eval echo '${'$as_ac_Header'}'` = yes; then +- cat >>confdefs.h <<_ACEOF +-#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1 +-_ACEOF +- ++rm -f conftest.err conftest.$ac_objext \ ++ conftest$ac_exeext conftest.$ac_ext ++LIBS=$ac_check_lib_save_LIBS + fi +- +-done +- +- if test $ac_cv_header_locale_h = yes; then +- echo "$as_me:$LINENO: checking for LC_MESSAGES" >&5 +-echo $ECHO_N "checking for LC_MESSAGES... $ECHO_C" >&6 +-if test "${am_cv_val_LC_MESSAGES+set}" = set; then ++echo "$as_me:$LINENO: result: $ac_cv_lib_intl_bindtextdomain" >&5 ++echo "${ECHO_T}$ac_cv_lib_intl_bindtextdomain" >&6 ++if test $ac_cv_lib_intl_bindtextdomain = yes; then ++ echo "$as_me:$LINENO: checking for ngettext in -lintl" >&5 ++echo $ECHO_N "checking for ngettext in -lintl... $ECHO_C" >&6 ++if test "${ac_cv_lib_intl_ngettext+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 + else +- cat >conftest.$ac_ext <<_ACEOF ++ ac_check_lib_save_LIBS=$LIBS ++LIBS="-lintl $LIBS" ++cat >conftest.$ac_ext <<_ACEOF + /* confdefs.h. */ + _ACEOF + cat confdefs.h >>conftest.$ac_ext + cat >>conftest.$ac_ext <<_ACEOF + /* end confdefs.h. */ +-#include ++ ++/* Override any gcc2 internal prototype to avoid an error. */ ++#ifdef __cplusplus ++extern "C" ++#endif ++/* We use char because int might match the return type of a gcc2 ++ builtin and then its argument prototype would still apply. */ ++char ngettext (); + int + main () + { +-return LC_MESSAGES ++ngettext (); + ; + return 0; + } +@@ -21160,59 +20788,52 @@ if { (eval echo "$as_me:$LINENO: \"$ac_l + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then +- am_cv_val_LC_MESSAGES=yes ++ ac_cv_lib_intl_ngettext=yes + else + echo "$as_me: failed program was:" >&5 + sed 's/^/| /' conftest.$ac_ext >&5 + +-am_cv_val_LC_MESSAGES=no ++ac_cv_lib_intl_ngettext=no + fi + rm -f conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext ++LIBS=$ac_check_lib_save_LIBS + fi +-echo "$as_me:$LINENO: result: $am_cv_val_LC_MESSAGES" >&5 +-echo "${ECHO_T}$am_cv_val_LC_MESSAGES" >&6 +- if test $am_cv_val_LC_MESSAGES = yes; then +- +-cat >>confdefs.h <<\_ACEOF +-#define HAVE_LC_MESSAGES 1 +-_ACEOF +- +- fi +- fi +- USE_NLS=yes +- +- +- gt_cv_have_gettext=no +- +- CATOBJEXT=NONE +- XGETTEXT=: +- INTLLIBS= +- +- if test "${ac_cv_header_libintl_h+set}" = set; then +- echo "$as_me:$LINENO: checking for libintl.h" >&5 +-echo $ECHO_N "checking for libintl.h... $ECHO_C" >&6 +-if test "${ac_cv_header_libintl_h+set}" = set; then ++echo "$as_me:$LINENO: result: $ac_cv_lib_intl_ngettext" >&5 ++echo "${ECHO_T}$ac_cv_lib_intl_ngettext" >&6 ++if test $ac_cv_lib_intl_ngettext = yes; then ++ echo "$as_me:$LINENO: checking for dgettext in -lintl" >&5 ++echo $ECHO_N "checking for dgettext in -lintl... $ECHO_C" >&6 ++if test "${ac_cv_lib_intl_dgettext+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +-fi +-echo "$as_me:$LINENO: result: $ac_cv_header_libintl_h" >&5 +-echo "${ECHO_T}$ac_cv_header_libintl_h" >&6 + else +- # Is the header compilable? +-echo "$as_me:$LINENO: checking libintl.h usability" >&5 +-echo $ECHO_N "checking libintl.h usability... $ECHO_C" >&6 ++ ac_check_lib_save_LIBS=$LIBS ++LIBS="-lintl $LIBS" + cat >conftest.$ac_ext <<_ACEOF + /* confdefs.h. */ + _ACEOF + cat confdefs.h >>conftest.$ac_ext + cat >>conftest.$ac_ext <<_ACEOF + /* end confdefs.h. */ +-$ac_includes_default +-#include ++ ++/* Override any gcc2 internal prototype to avoid an error. */ ++#ifdef __cplusplus ++extern "C" ++#endif ++/* We use char because int might match the return type of a gcc2 ++ builtin and then its argument prototype would still apply. */ ++char dgettext (); ++int ++main () ++{ ++dgettext (); ++ ; ++ return 0; ++} + _ACEOF +-rm -f conftest.$ac_objext +-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 +- (eval $ac_compile) 2>conftest.er1 ++rm -f conftest.$ac_objext conftest$ac_exeext ++if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 ++ (eval $ac_link) 2>conftest.er1 + ac_status=$? + grep -v '^ *+' conftest.er1 >conftest.err + rm -f conftest.er1 +@@ -21226,131 +20847,129 @@ if { (eval echo "$as_me:$LINENO: \"$ac_c + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; } && +- { ac_try='test -s conftest.$ac_objext' ++ { ac_try='test -s conftest$ac_exeext' + { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then +- ac_header_compiler=yes ++ ac_cv_lib_intl_dgettext=yes + else + echo "$as_me: failed program was:" >&5 + sed 's/^/| /' conftest.$ac_ext >&5 + +-ac_header_compiler=no ++ac_cv_lib_intl_dgettext=no ++fi ++rm -f conftest.err conftest.$ac_objext \ ++ conftest$ac_exeext conftest.$ac_ext ++LIBS=$ac_check_lib_save_LIBS ++fi ++echo "$as_me:$LINENO: result: $ac_cv_lib_intl_dgettext" >&5 ++echo "${ECHO_T}$ac_cv_lib_intl_dgettext" >&6 ++if test $ac_cv_lib_intl_dgettext = yes; then ++ gt_cv_func_dgettext_libintl=yes + fi +-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext +-echo "$as_me:$LINENO: result: $ac_header_compiler" >&5 +-echo "${ECHO_T}$ac_header_compiler" >&6 + +-# Is the header present? +-echo "$as_me:$LINENO: checking libintl.h presence" >&5 +-echo $ECHO_N "checking libintl.h presence... $ECHO_C" >&6 ++fi ++ ++fi ++ ++ ++ if test "$gt_cv_func_dgettext_libintl" != "yes" ; then ++ echo "$as_me:$LINENO: checking if -liconv is needed to use gettext" >&5 ++echo $ECHO_N "checking if -liconv is needed to use gettext... $ECHO_C" >&6 ++ echo "$as_me:$LINENO: result: " >&5 ++echo "${ECHO_T}" >&6 ++ echo "$as_me:$LINENO: checking for ngettext in -lintl" >&5 ++echo $ECHO_N "checking for ngettext in -lintl... $ECHO_C" >&6 ++if test "${ac_cv_lib_intl_ngettext+set}" = set; then ++ echo $ECHO_N "(cached) $ECHO_C" >&6 ++else ++ ac_check_lib_save_LIBS=$LIBS ++LIBS="-lintl -liconv $LIBS" + cat >conftest.$ac_ext <<_ACEOF + /* confdefs.h. */ + _ACEOF + cat confdefs.h >>conftest.$ac_ext + cat >>conftest.$ac_ext <<_ACEOF + /* end confdefs.h. */ +-#include ++ ++/* Override any gcc2 internal prototype to avoid an error. */ ++#ifdef __cplusplus ++extern "C" ++#endif ++/* We use char because int might match the return type of a gcc2 ++ builtin and then its argument prototype would still apply. */ ++char ngettext (); ++int ++main () ++{ ++ngettext (); ++ ; ++ return 0; ++} + _ACEOF +-if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5 +- (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 ++rm -f conftest.$ac_objext conftest$ac_exeext ++if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 ++ (eval $ac_link) 2>conftest.er1 + ac_status=$? + grep -v '^ *+' conftest.er1 >conftest.err + rm -f conftest.er1 + cat conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); } >/dev/null; then +- if test -s conftest.err; then +- ac_cpp_err=$ac_cxx_preproc_warn_flag +- ac_cpp_err=$ac_cpp_err$ac_cxx_werror_flag +- else +- ac_cpp_err= +- fi +-else +- ac_cpp_err=yes +-fi +-if test -z "$ac_cpp_err"; then +- ac_header_preproc=yes ++ (exit $ac_status); } && ++ { ac_try='test -z "$ac_cxx_werror_flag" ++ || test ! -s conftest.err' ++ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 ++ (eval $ac_try) 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; } && ++ { ac_try='test -s conftest$ac_exeext' ++ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 ++ (eval $ac_try) 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; }; then ++ ac_cv_lib_intl_ngettext=yes + else + echo "$as_me: failed program was:" >&5 +-sed 's/^/| /' conftest.$ac_ext >&5 +- +- ac_header_preproc=no +-fi +-rm -f conftest.err conftest.$ac_ext +-echo "$as_me:$LINENO: result: $ac_header_preproc" >&5 +-echo "${ECHO_T}$ac_header_preproc" >&6 +- +-# So? What about this header? +-case $ac_header_compiler:$ac_header_preproc:$ac_cxx_preproc_warn_flag in +- yes:no: ) +- { echo "$as_me:$LINENO: WARNING: libintl.h: accepted by the compiler, rejected by the preprocessor!" >&5 +-echo "$as_me: WARNING: libintl.h: accepted by the compiler, rejected by the preprocessor!" >&2;} +- { echo "$as_me:$LINENO: WARNING: libintl.h: proceeding with the compiler's result" >&5 +-echo "$as_me: WARNING: libintl.h: proceeding with the compiler's result" >&2;} +- ac_header_preproc=yes +- ;; +- no:yes:* ) +- { echo "$as_me:$LINENO: WARNING: libintl.h: present but cannot be compiled" >&5 +-echo "$as_me: WARNING: libintl.h: present but cannot be compiled" >&2;} +- { echo "$as_me:$LINENO: WARNING: libintl.h: check for missing prerequisite headers?" >&5 +-echo "$as_me: WARNING: libintl.h: check for missing prerequisite headers?" >&2;} +- { echo "$as_me:$LINENO: WARNING: libintl.h: see the Autoconf documentation" >&5 +-echo "$as_me: WARNING: libintl.h: see the Autoconf documentation" >&2;} +- { echo "$as_me:$LINENO: WARNING: libintl.h: section \"Present But Cannot Be Compiled\"" >&5 +-echo "$as_me: WARNING: libintl.h: section \"Present But Cannot Be Compiled\"" >&2;} +- { echo "$as_me:$LINENO: WARNING: libintl.h: proceeding with the preprocessor's result" >&5 +-echo "$as_me: WARNING: libintl.h: proceeding with the preprocessor's result" >&2;} +- { echo "$as_me:$LINENO: WARNING: libintl.h: in the future, the compiler will take precedence" >&5 +-echo "$as_me: WARNING: libintl.h: in the future, the compiler will take precedence" >&2;} +- ( +- cat <<\_ASBOX +-## ------------------------------------------ ## +-## Report this to the AC_PACKAGE_NAME lists. ## +-## ------------------------------------------ ## +-_ASBOX +- ) | +- sed "s/^/$as_me: WARNING: /" >&2 +- ;; +-esac +-echo "$as_me:$LINENO: checking for libintl.h" >&5 +-echo $ECHO_N "checking for libintl.h... $ECHO_C" >&6 +-if test "${ac_cv_header_libintl_h+set}" = set; then +- echo $ECHO_N "(cached) $ECHO_C" >&6 +-else +- ac_cv_header_libintl_h=$ac_header_preproc +-fi +-echo "$as_me:$LINENO: result: $ac_cv_header_libintl_h" >&5 +-echo "${ECHO_T}$ac_cv_header_libintl_h" >&6 ++sed 's/^/| /' conftest.$ac_ext >&5 + ++ac_cv_lib_intl_ngettext=no + fi +-if test $ac_cv_header_libintl_h = yes; then +- gt_cv_func_dgettext_libintl="no" +- libintl_extra_libs="" +- +- # +- # First check in libc +- # +- echo "$as_me:$LINENO: checking for ngettext in libc" >&5 +-echo $ECHO_N "checking for ngettext in libc... $ECHO_C" >&6 +-if test "${gt_cv_func_ngettext_libc+set}" = set; then ++rm -f conftest.err conftest.$ac_objext \ ++ conftest$ac_exeext conftest.$ac_ext ++LIBS=$ac_check_lib_save_LIBS ++fi ++echo "$as_me:$LINENO: result: $ac_cv_lib_intl_ngettext" >&5 ++echo "${ECHO_T}$ac_cv_lib_intl_ngettext" >&6 ++if test $ac_cv_lib_intl_ngettext = yes; then ++ echo "$as_me:$LINENO: checking for dcgettext in -lintl" >&5 ++echo $ECHO_N "checking for dcgettext in -lintl... $ECHO_C" >&6 ++if test "${ac_cv_lib_intl_dcgettext+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 + else +- cat >conftest.$ac_ext <<_ACEOF ++ ac_check_lib_save_LIBS=$LIBS ++LIBS="-lintl -liconv $LIBS" ++cat >conftest.$ac_ext <<_ACEOF + /* confdefs.h. */ + _ACEOF + cat confdefs.h >>conftest.$ac_ext + cat >>conftest.$ac_ext <<_ACEOF + /* end confdefs.h. */ + +-#include +- ++/* Override any gcc2 internal prototype to avoid an error. */ ++#ifdef __cplusplus ++extern "C" ++#endif ++/* We use char because int might match the return type of a gcc2 ++ builtin and then its argument prototype would still apply. */ ++char dcgettext (); + int + main () + { +-return !ngettext ("","", 1) ++dcgettext (); + ; + return 0; + } +@@ -21377,24 +20996,48 @@ if { (eval echo "$as_me:$LINENO: \"$ac_l + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then +- gt_cv_func_ngettext_libc=yes ++ ac_cv_lib_intl_dcgettext=yes + else + echo "$as_me: failed program was:" >&5 + sed 's/^/| /' conftest.$ac_ext >&5 + +-gt_cv_func_ngettext_libc=no ++ac_cv_lib_intl_dcgettext=no + fi + rm -f conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext ++LIBS=$ac_check_lib_save_LIBS ++fi ++echo "$as_me:$LINENO: result: $ac_cv_lib_intl_dcgettext" >&5 ++echo "${ECHO_T}$ac_cv_lib_intl_dcgettext" >&6 ++if test $ac_cv_lib_intl_dcgettext = yes; then ++ gt_cv_func_dgettext_libintl=yes ++ libintl_extra_libs=-liconv ++else ++ : ++fi + ++else ++ : + fi +-echo "$as_me:$LINENO: result: $gt_cv_func_ngettext_libc" >&5 +-echo "${ECHO_T}$gt_cv_func_ngettext_libc" >&6 + +- if test "$gt_cv_func_ngettext_libc" = "yes" ; then +- echo "$as_me:$LINENO: checking for dgettext in libc" >&5 +-echo $ECHO_N "checking for dgettext in libc... $ECHO_C" >&6 +-if test "${gt_cv_func_dgettext_libc+set}" = set; then ++ fi ++ ++ # ++ # If we found libintl, then check in it for bind_textdomain_codeset(); ++ # we'll prefer libc if neither have bind_textdomain_codeset(), ++ # and both have dgettext and ngettext ++ # ++ if test "$gt_cv_func_dgettext_libintl" = "yes" ; then ++ glib_save_LIBS="$LIBS" ++ LIBS="$LIBS -lintl $libintl_extra_libs" ++ unset ac_cv_func_bind_textdomain_codeset ++ ++for ac_func in bind_textdomain_codeset ++do ++as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh` ++echo "$as_me:$LINENO: checking for $ac_func" >&5 ++echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6 ++if eval "test \"\${$as_ac_var+set}\" = set"; then + echo $ECHO_N "(cached) $ECHO_C" >&6 + else + cat >conftest.$ac_ext <<_ACEOF +@@ -21403,13 +21046,47 @@ _ACEOF + cat confdefs.h >>conftest.$ac_ext + cat >>conftest.$ac_ext <<_ACEOF + /* end confdefs.h. */ ++/* Define $ac_func to an innocuous variant, in case declares $ac_func. ++ For example, HP-UX 11i declares gettimeofday. */ ++#define $ac_func innocuous_$ac_func + +-#include ++/* System header to define __stub macros and hopefully few prototypes, ++ which can conflict with char $ac_func (); below. ++ Prefer to if __STDC__ is defined, since ++ exists even on freestanding compilers. */ ++ ++#ifdef __STDC__ ++# include ++#else ++# include ++#endif ++ ++#undef $ac_func ++ ++/* Override any gcc2 internal prototype to avoid an error. */ ++#ifdef __cplusplus ++extern "C" ++{ ++#endif ++/* We use char because int might match the return type of a gcc2 ++ builtin and then its argument prototype would still apply. */ ++char $ac_func (); ++/* The GNU C library defines this for functions which it implements ++ to always fail with ENOSYS. Some functions are actually named ++ something starting with __ and the normal name is an alias. */ ++#if defined (__stub_$ac_func) || defined (__stub___$ac_func) ++choke me ++#else ++char (*f) () = $ac_func; ++#endif ++#ifdef __cplusplus ++} ++#endif + + int + main () + { +-return !dgettext ("","") ++return f != $ac_func; + ; + return 0; + } +@@ -21436,24 +21113,94 @@ if { (eval echo "$as_me:$LINENO: \"$ac_l + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then +- gt_cv_func_dgettext_libc=yes ++ eval "$as_ac_var=yes" + else + echo "$as_me: failed program was:" >&5 + sed 's/^/| /' conftest.$ac_ext >&5 + +-gt_cv_func_dgettext_libc=no ++eval "$as_ac_var=no" + fi + rm -f conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext ++fi ++echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5 ++echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6 ++if test `eval echo '${'$as_ac_var'}'` = yes; then ++ cat >>confdefs.h <<_ACEOF ++#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1 ++_ACEOF + + fi +-echo "$as_me:$LINENO: result: $gt_cv_func_dgettext_libc" >&5 +-echo "${ECHO_T}$gt_cv_func_dgettext_libc" >&6 ++done ++ ++ LIBS="$glib_save_LIBS" ++ ++ if test "$ac_cv_func_bind_textdomain_codeset" = "yes" ; then ++ gt_cv_func_dgettext_libc=no ++ else ++ if test "$gt_cv_func_dgettext_libc" = "yes" \ ++ && test "$gt_cv_func_ngettext_libc" = "yes"; then ++ gt_cv_func_dgettext_libintl=no ++ fi ++ fi ++ fi + fi + +- if test "$gt_cv_func_ngettext_libc" = "yes" ; then ++ if test "$gt_cv_func_dgettext_libc" = "yes" \ ++ || test "$gt_cv_func_dgettext_libintl" = "yes"; then ++ gt_cv_have_gettext=yes ++ fi + +-for ac_func in bind_textdomain_codeset ++ if test "$gt_cv_func_dgettext_libintl" = "yes"; then ++ INTLLIBS="-lintl $libintl_extra_libs" ++ fi ++ ++ if test "$gt_cv_have_gettext" = "yes"; then ++ ++cat >>confdefs.h <<\_ACEOF ++#define HAVE_GETTEXT 1 ++_ACEOF ++ ++ # Extract the first word of "msgfmt", so it can be a program name with args. ++set dummy msgfmt; ac_word=$2 ++echo "$as_me:$LINENO: checking for $ac_word" >&5 ++echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 ++if test "${ac_cv_path_MSGFMT+set}" = set; then ++ echo $ECHO_N "(cached) $ECHO_C" >&6 ++else ++ case "$MSGFMT" in ++ /*) ++ ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path. ++ ;; ++ *) ++ IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" ++ for ac_dir in $PATH; do ++ test -z "$ac_dir" && ac_dir=. ++ if test -f $ac_dir/$ac_word; then ++ if test -z "`$ac_dir/$ac_word -h 2>&1 | grep 'dv '`"; then ++ ac_cv_path_MSGFMT="$ac_dir/$ac_word" ++ break ++ fi ++ fi ++ done ++ IFS="$ac_save_ifs" ++ test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT="no" ++ ;; ++esac ++fi ++MSGFMT="$ac_cv_path_MSGFMT" ++if test "$MSGFMT" != "no"; then ++ echo "$as_me:$LINENO: result: $MSGFMT" >&5 ++echo "${ECHO_T}$MSGFMT" >&6 ++else ++ echo "$as_me:$LINENO: result: no" >&5 ++echo "${ECHO_T}no" >&6 ++fi ++ if test "$MSGFMT" != "no"; then ++ glib_save_LIBS="$LIBS" ++ LIBS="$LIBS $INTLLIBS" ++ ++for ac_func in dcgettext + do + as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh` + echo "$as_me:$LINENO: checking for $ac_func" >&5 +@@ -21554,40 +21301,94 @@ _ACEOF + fi + done + ++ # Extract the first word of "gmsgfmt", so it can be a program name with args. ++set dummy gmsgfmt; ac_word=$2 ++echo "$as_me:$LINENO: checking for $ac_word" >&5 ++echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 ++if test "${ac_cv_path_GMSGFMT+set}" = set; then ++ echo $ECHO_N "(cached) $ECHO_C" >&6 ++else ++ case $GMSGFMT in ++ [\\/]* | ?:[\\/]*) ++ ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path. ++ ;; ++ *) ++ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR ++for as_dir in $PATH ++do ++ IFS=$as_save_IFS ++ test -z "$as_dir" && as_dir=. ++ for ac_exec_ext in '' $ac_executable_extensions; do ++ if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ++ ac_cv_path_GMSGFMT="$as_dir/$ac_word$ac_exec_ext" ++ echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 ++ break 2 ++ fi ++done ++done ++ ++ test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT" ++ ;; ++esac ++fi ++GMSGFMT=$ac_cv_path_GMSGFMT ++ ++if test -n "$GMSGFMT"; then ++ echo "$as_me:$LINENO: result: $GMSGFMT" >&5 ++echo "${ECHO_T}$GMSGFMT" >&6 ++else ++ echo "$as_me:$LINENO: result: no" >&5 ++echo "${ECHO_T}no" >&6 ++fi ++ ++ # Extract the first word of "xgettext", so it can be a program name with args. ++set dummy xgettext; ac_word=$2 ++echo "$as_me:$LINENO: checking for $ac_word" >&5 ++echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 ++if test "${ac_cv_path_XGETTEXT+set}" = set; then ++ echo $ECHO_N "(cached) $ECHO_C" >&6 ++else ++ case "$XGETTEXT" in ++ /*) ++ ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path. ++ ;; ++ *) ++ IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" ++ for ac_dir in $PATH; do ++ test -z "$ac_dir" && ac_dir=. ++ if test -f $ac_dir/$ac_word; then ++ if test -z "`$ac_dir/$ac_word -h 2>&1 | grep '(HELP)'`"; then ++ ac_cv_path_XGETTEXT="$ac_dir/$ac_word" ++ break + fi +- +- # +- # If we don't have everything we want, check in libintl +- # +- if test "$gt_cv_func_dgettext_libc" != "yes" \ +- || test "$gt_cv_func_ngettext_libc" != "yes" \ +- || test "$ac_cv_func_bind_textdomain_codeset" != "yes" ; then +- +- echo "$as_me:$LINENO: checking for bindtextdomain in -lintl" >&5 +-echo $ECHO_N "checking for bindtextdomain in -lintl... $ECHO_C" >&6 +-if test "${ac_cv_lib_intl_bindtextdomain+set}" = set; then +- echo $ECHO_N "(cached) $ECHO_C" >&6 ++ fi ++ done ++ IFS="$ac_save_ifs" ++ test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":" ++ ;; ++esac ++fi ++XGETTEXT="$ac_cv_path_XGETTEXT" ++if test "$XGETTEXT" != ":"; then ++ echo "$as_me:$LINENO: result: $XGETTEXT" >&5 ++echo "${ECHO_T}$XGETTEXT" >&6 + else +- ac_check_lib_save_LIBS=$LIBS +-LIBS="-lintl $LIBS" +-cat >conftest.$ac_ext <<_ACEOF ++ echo "$as_me:$LINENO: result: no" >&5 ++echo "${ECHO_T}no" >&6 ++fi ++ ++ cat >conftest.$ac_ext <<_ACEOF + /* confdefs.h. */ + _ACEOF + cat confdefs.h >>conftest.$ac_ext + cat >>conftest.$ac_ext <<_ACEOF + /* end confdefs.h. */ + +-/* Override any gcc2 internal prototype to avoid an error. */ +-#ifdef __cplusplus +-extern "C" +-#endif +-/* We use char because int might match the return type of a gcc2 +- builtin and then its argument prototype would still apply. */ +-char bindtextdomain (); + int + main () + { +-bindtextdomain (); ++extern int _nl_msg_cat_cntr; ++ return _nl_msg_cat_cntr + ; + return 0; + } +@@ -21614,45 +21415,66 @@ if { (eval echo "$as_me:$LINENO: \"$ac_l + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then +- ac_cv_lib_intl_bindtextdomain=yes ++ CATOBJEXT=.gmo ++ DATADIRNAME=share + else + echo "$as_me: failed program was:" >&5 + sed 's/^/| /' conftest.$ac_ext >&5 + +-ac_cv_lib_intl_bindtextdomain=no +-fi +-rm -f conftest.err conftest.$ac_objext \ +- conftest$ac_exeext conftest.$ac_ext +-LIBS=$ac_check_lib_save_LIBS +-fi +-echo "$as_me:$LINENO: result: $ac_cv_lib_intl_bindtextdomain" >&5 +-echo "${ECHO_T}$ac_cv_lib_intl_bindtextdomain" >&6 +-if test $ac_cv_lib_intl_bindtextdomain = yes; then +- echo "$as_me:$LINENO: checking for ngettext in -lintl" >&5 +-echo $ECHO_N "checking for ngettext in -lintl... $ECHO_C" >&6 +-if test "${ac_cv_lib_intl_ngettext+set}" = set; then ++case $host in ++ *-*-solaris*) ++ echo "$as_me:$LINENO: checking for bind_textdomain_codeset" >&5 ++echo $ECHO_N "checking for bind_textdomain_codeset... $ECHO_C" >&6 ++if test "${ac_cv_func_bind_textdomain_codeset+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 + else +- ac_check_lib_save_LIBS=$LIBS +-LIBS="-lintl $LIBS" +-cat >conftest.$ac_ext <<_ACEOF ++ cat >conftest.$ac_ext <<_ACEOF + /* confdefs.h. */ + _ACEOF + cat confdefs.h >>conftest.$ac_ext + cat >>conftest.$ac_ext <<_ACEOF + /* end confdefs.h. */ ++/* Define bind_textdomain_codeset to an innocuous variant, in case declares bind_textdomain_codeset. ++ For example, HP-UX 11i declares gettimeofday. */ ++#define bind_textdomain_codeset innocuous_bind_textdomain_codeset ++ ++/* System header to define __stub macros and hopefully few prototypes, ++ which can conflict with char bind_textdomain_codeset (); below. ++ Prefer to if __STDC__ is defined, since ++ exists even on freestanding compilers. */ ++ ++#ifdef __STDC__ ++# include ++#else ++# include ++#endif ++ ++#undef bind_textdomain_codeset + + /* Override any gcc2 internal prototype to avoid an error. */ + #ifdef __cplusplus + extern "C" ++{ + #endif + /* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +-char ngettext (); ++char bind_textdomain_codeset (); ++/* The GNU C library defines this for functions which it implements ++ to always fail with ENOSYS. Some functions are actually named ++ something starting with __ and the normal name is an alias. */ ++#if defined (__stub_bind_textdomain_codeset) || defined (__stub___bind_textdomain_codeset) ++choke me ++#else ++char (*f) () = bind_textdomain_codeset; ++#endif ++#ifdef __cplusplus ++} ++#endif ++ + int + main () + { +-ngettext (); ++return f != bind_textdomain_codeset; + ; + return 0; + } +@@ -21679,27 +21501,176 @@ if { (eval echo "$as_me:$LINENO: \"$ac_l + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then +- ac_cv_lib_intl_ngettext=yes ++ ac_cv_func_bind_textdomain_codeset=yes + else + echo "$as_me: failed program was:" >&5 + sed 's/^/| /' conftest.$ac_ext >&5 + +-ac_cv_lib_intl_ngettext=no +-fi +-rm -f conftest.err conftest.$ac_objext \ +- conftest$ac_exeext conftest.$ac_ext +-LIBS=$ac_check_lib_save_LIBS +-fi +-echo "$as_me:$LINENO: result: $ac_cv_lib_intl_ngettext" >&5 +-echo "${ECHO_T}$ac_cv_lib_intl_ngettext" >&6 +-if test $ac_cv_lib_intl_ngettext = yes; then +- echo "$as_me:$LINENO: checking for dgettext in -lintl" >&5 +-echo $ECHO_N "checking for dgettext in -lintl... $ECHO_C" >&6 +-if test "${ac_cv_lib_intl_dgettext+set}" = set; then ++ac_cv_func_bind_textdomain_codeset=no ++fi ++rm -f conftest.err conftest.$ac_objext \ ++ conftest$ac_exeext conftest.$ac_ext ++fi ++echo "$as_me:$LINENO: result: $ac_cv_func_bind_textdomain_codeset" >&5 ++echo "${ECHO_T}$ac_cv_func_bind_textdomain_codeset" >&6 ++if test $ac_cv_func_bind_textdomain_codeset = yes; then ++ CATOBJEXT=.gmo ++ DATADIRNAME=share ++else ++ CATOBJEXT=.mo ++ DATADIRNAME=lib ++fi ++ ++ ;; ++ *) ++ CATOBJEXT=.mo ++ DATADIRNAME=lib ++ ;; ++ esac ++fi ++rm -f conftest.err conftest.$ac_objext \ ++ conftest$ac_exeext conftest.$ac_ext ++ LIBS="$glib_save_LIBS" ++ INSTOBJEXT=.mo ++ else ++ gt_cv_have_gettext=no ++ fi ++ fi ++ ++fi ++ ++ ++ ++ if test "$gt_cv_have_gettext" = "yes" ; then ++ ++cat >>confdefs.h <<\_ACEOF ++#define ENABLE_NLS 1 ++_ACEOF ++ ++ fi ++ ++ if test "$XGETTEXT" != ":"; then ++ if $XGETTEXT --omit-header /dev/null 2> /dev/null; then ++ : ; ++ else ++ echo "$as_me:$LINENO: result: found xgettext program is not GNU xgettext; ignore it" >&5 ++echo "${ECHO_T}found xgettext program is not GNU xgettext; ignore it" >&6 ++ XGETTEXT=":" ++ fi ++ fi ++ ++ # We need to process the po/ directory. ++ POSUB=po ++ ++ ac_config_commands="$ac_config_commands default-1" ++ ++ ++ for lang in $ALL_LINGUAS; do ++ GMOFILES="$GMOFILES $lang.gmo" ++ POFILES="$POFILES $lang.po" ++ done ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ if test "$gt_cv_have_gettext" = "yes"; then ++ if test "x$ALL_LINGUAS" = "x"; then ++ LINGUAS= ++ else ++ echo "$as_me:$LINENO: checking for catalogs to be installed" >&5 ++echo $ECHO_N "checking for catalogs to be installed... $ECHO_C" >&6 ++ NEW_LINGUAS= ++ for presentlang in $ALL_LINGUAS; do ++ useit=no ++ if test "%UNSET%" != "${LINGUAS-%UNSET%}"; then ++ desiredlanguages="$LINGUAS" ++ else ++ desiredlanguages="$ALL_LINGUAS" ++ fi ++ for desiredlang in $desiredlanguages; do ++ # Use the presentlang catalog if desiredlang is ++ # a. equal to presentlang, or ++ # b. a variant of presentlang (because in this case, ++ # presentlang can be used as a fallback for messages ++ # which are not translated in the desiredlang catalog). ++ case "$desiredlang" in ++ "$presentlang"*) useit=yes;; ++ esac ++ done ++ if test $useit = yes; then ++ NEW_LINGUAS="$NEW_LINGUAS $presentlang" ++ fi ++ done ++ LINGUAS=$NEW_LINGUAS ++ echo "$as_me:$LINENO: result: $LINGUAS" >&5 ++echo "${ECHO_T}$LINGUAS" >&6 ++ fi ++ ++ if test -n "$LINGUAS"; then ++ for lang in $LINGUAS; do CATALOGS="$CATALOGS $lang$CATOBJEXT"; done ++ fi ++ fi ++ ++ MKINSTALLDIRS= ++ if test -n "$ac_aux_dir"; then ++ MKINSTALLDIRS="$ac_aux_dir/mkinstalldirs" ++ fi ++ if test -z "$MKINSTALLDIRS"; then ++ MKINSTALLDIRS="\$(top_srcdir)/mkinstalldirs" ++ fi ++ ++ ++ test -d po || mkdir po ++ if test "x$srcdir" != "x."; then ++ if test "x`echo $srcdir | sed 's@/.*@@'`" = "x"; then ++ posrcprefix="$srcdir/" ++ else ++ posrcprefix="../$srcdir/" ++ fi ++ else ++ posrcprefix="../" ++ fi ++ rm -f po/POTFILES ++ sed -e "/^#/d" -e "/^\$/d" -e "s,.*, $posrcprefix& \\\\," -e "\$s/\(.*\) \\\\/\1/" \ ++ < $srcdir/po/POTFILES.in > po/POTFILES ++ ++ ++echo "$as_me:$LINENO: checking locale directory" >&5 ++echo $ECHO_N "checking locale directory... $ECHO_C" >&6 ++if test "x$prefix" = "xNONE"; then ++ PACKAGE_LOCALE_DIR=$ac_default_prefix/share/locale ++else ++ PACKAGE_LOCALE_DIR=$prefix/share/locale ++fi ++ ++ ++cat >>confdefs.h <<_ACEOF ++#define PACKAGE_LOCALE_DIR "$PACKAGE_LOCALE_DIR" ++_ACEOF ++ ++ echo "$as_me:$LINENO: result: \"$PACKAGE_LOCALE_DIR\"" >&5 ++echo "${ECHO_T}\"$PACKAGE_LOCALE_DIR\"" >&6 ++ ++INTLTOOL_QALCULATE_DEFINITIONS_RULE='%.xml: %.xml.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po-defs/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -x -u -c $(top_builddir)/po-defs/.intltool-merge-cache $(top_srcdir)/po-defs $< $@' ++ ++ ++ ++echo "$as_me:$LINENO: checking for pthread_create in -lpthread" >&5 ++echo $ECHO_N "checking for pthread_create in -lpthread... $ECHO_C" >&6 ++if test "${ac_cv_lib_pthread_pthread_create+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 + else + ac_check_lib_save_LIBS=$LIBS +-LIBS="-lintl $LIBS" ++LIBS="-lpthread $LIBS" + cat >conftest.$ac_ext <<_ACEOF + /* confdefs.h. */ + _ACEOF +@@ -21713,11 +21684,11 @@ extern "C" + #endif + /* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +-char dgettext (); ++char pthread_create (); + int + main () + { +-dgettext (); ++pthread_create (); + ; + return 0; + } +@@ -21731,7 +21702,7 @@ if { (eval echo "$as_me:$LINENO: \"$ac_l + cat conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } && +- { ac_try='test -z "$ac_cxx_werror_flag" ++ { ac_try='test -z "$ac_c_werror_flag" + || test ! -s conftest.err' + { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 +@@ -21744,192 +21715,159 @@ if { (eval echo "$as_me:$LINENO: \"$ac_l + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then +- ac_cv_lib_intl_dgettext=yes ++ ac_cv_lib_pthread_pthread_create=yes + else + echo "$as_me: failed program was:" >&5 + sed 's/^/| /' conftest.$ac_ext >&5 + +-ac_cv_lib_intl_dgettext=no ++ac_cv_lib_pthread_pthread_create=no + fi + rm -f conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + LIBS=$ac_check_lib_save_LIBS + fi +-echo "$as_me:$LINENO: result: $ac_cv_lib_intl_dgettext" >&5 +-echo "${ECHO_T}$ac_cv_lib_intl_dgettext" >&6 +-if test $ac_cv_lib_intl_dgettext = yes; then +- gt_cv_func_dgettext_libintl=yes ++echo "$as_me:$LINENO: result: $ac_cv_lib_pthread_pthread_create" >&5 ++echo "${ECHO_T}$ac_cv_lib_pthread_pthread_create" >&6 ++if test $ac_cv_lib_pthread_pthread_create = yes; then ++ LIBS="$LIBS -lpthread" + fi + +-fi + +-fi ++ac_ext=cc ++ac_cpp='$CXXCPP $CPPFLAGS' ++ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' ++ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ++ac_compiler_gnu=$ac_cv_cxx_compiler_gnu + + +- if test "$gt_cv_func_dgettext_libintl" != "yes" ; then +- echo "$as_me:$LINENO: checking if -liconv is needed to use gettext" >&5 +-echo $ECHO_N "checking if -liconv is needed to use gettext... $ECHO_C" >&6 +- echo "$as_me:$LINENO: result: " >&5 +-echo "${ECHO_T}" >&6 +- echo "$as_me:$LINENO: checking for ngettext in -lintl" >&5 +-echo $ECHO_N "checking for ngettext in -lintl... $ECHO_C" >&6 +-if test "${ac_cv_lib_intl_ngettext+set}" = set; then +- echo $ECHO_N "(cached) $ECHO_C" >&6 +-else +- ac_check_lib_save_LIBS=$LIBS +-LIBS="-lintl -liconv $LIBS" +-cat >conftest.$ac_ext <<_ACEOF +-/* confdefs.h. */ +-_ACEOF +-cat confdefs.h >>conftest.$ac_ext +-cat >>conftest.$ac_ext <<_ACEOF +-/* end confdefs.h. */ + +-/* Override any gcc2 internal prototype to avoid an error. */ +-#ifdef __cplusplus +-extern "C" +-#endif +-/* We use char because int might match the return type of a gcc2 +- builtin and then its argument prototype would still apply. */ +-char ngettext (); +-int +-main () +-{ +-ngettext (); +- ; +- return 0; +-} +-_ACEOF +-rm -f conftest.$ac_objext conftest$ac_exeext +-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 +- (eval $ac_link) 2>conftest.er1 +- ac_status=$? +- grep -v '^ *+' conftest.er1 >conftest.err +- rm -f conftest.er1 +- cat conftest.err >&5 +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); } && +- { ac_try='test -z "$ac_cxx_werror_flag" +- || test ! -s conftest.err' +- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 +- (eval $ac_try) 2>&5 +- ac_status=$? +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; } && +- { ac_try='test -s conftest$ac_exeext' +- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 +- (eval $ac_try) 2>&5 +- ac_status=$? +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; }; then +- ac_cv_lib_intl_ngettext=yes ++# Check whether --with-cln-prefix or --without-cln-prefix was given. ++if test "${with_cln_prefix+set}" = set; then ++ withval="$with_cln_prefix" ++ cln_config_prefix="$withval" + else +- echo "$as_me: failed program was:" >&5 +-sed 's/^/| /' conftest.$ac_ext >&5 ++ cln_config_prefix="" ++fi; + +-ac_cv_lib_intl_ngettext=no +-fi +-rm -f conftest.err conftest.$ac_objext \ +- conftest$ac_exeext conftest.$ac_ext +-LIBS=$ac_check_lib_save_LIBS +-fi +-echo "$as_me:$LINENO: result: $ac_cv_lib_intl_ngettext" >&5 +-echo "${ECHO_T}$ac_cv_lib_intl_ngettext" >&6 +-if test $ac_cv_lib_intl_ngettext = yes; then +- echo "$as_me:$LINENO: checking for dcgettext in -lintl" >&5 +-echo $ECHO_N "checking for dcgettext in -lintl... $ECHO_C" >&6 +-if test "${ac_cv_lib_intl_dcgettext+set}" = set; then +- echo $ECHO_N "(cached) $ECHO_C" >&6 ++# Check whether --with-cln-exec-prefix or --without-cln-exec-prefix was given. ++if test "${with_cln_exec_prefix+set}" = set; then ++ withval="$with_cln_exec_prefix" ++ cln_config_exec_prefix="$withval" + else +- ac_check_lib_save_LIBS=$LIBS +-LIBS="-lintl -liconv $LIBS" +-cat >conftest.$ac_ext <<_ACEOF +-/* confdefs.h. */ +-_ACEOF +-cat confdefs.h >>conftest.$ac_ext +-cat >>conftest.$ac_ext <<_ACEOF +-/* end confdefs.h. */ ++ cln_config_exec_prefix="" ++fi; ++# Check whether --enable-clntest or --disable-clntest was given. ++if test "${enable_clntest+set}" = set; then ++ enableval="$enable_clntest" + +-/* Override any gcc2 internal prototype to avoid an error. */ +-#ifdef __cplusplus +-extern "C" +-#endif +-/* We use char because int might match the return type of a gcc2 +- builtin and then its argument prototype would still apply. */ +-char dcgettext (); +-int +-main () +-{ +-dcgettext (); +- ; +- return 0; +-} +-_ACEOF +-rm -f conftest.$ac_objext conftest$ac_exeext +-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 +- (eval $ac_link) 2>conftest.er1 +- ac_status=$? +- grep -v '^ *+' conftest.er1 >conftest.err +- rm -f conftest.er1 +- cat conftest.err >&5 +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); } && +- { ac_try='test -z "$ac_cxx_werror_flag" +- || test ! -s conftest.err' +- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 +- (eval $ac_try) 2>&5 +- ac_status=$? +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; } && +- { ac_try='test -s conftest$ac_exeext' +- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 +- (eval $ac_try) 2>&5 +- ac_status=$? +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; }; then +- ac_cv_lib_intl_dcgettext=yes + else +- echo "$as_me: failed program was:" >&5 +-sed 's/^/| /' conftest.$ac_ext >&5 ++ enable_clntest=yes ++fi; + +-ac_cv_lib_intl_dcgettext=no +-fi +-rm -f conftest.err conftest.$ac_objext \ +- conftest$ac_exeext conftest.$ac_ext +-LIBS=$ac_check_lib_save_LIBS ++if test x$cln_config_exec_prefix != x ; then ++ cln_config_args="$cln_config_args --exec-prefix=$cln_config_exec_prefix" ++ if test x${CLN_CONFIG+set} != xset ; then ++ CLN_CONFIG=$cln_config_exec_prefix/bin/cln-config ++ fi + fi +-echo "$as_me:$LINENO: result: $ac_cv_lib_intl_dcgettext" >&5 +-echo "${ECHO_T}$ac_cv_lib_intl_dcgettext" >&6 +-if test $ac_cv_lib_intl_dcgettext = yes; then +- gt_cv_func_dgettext_libintl=yes +- libintl_extra_libs=-liconv +-else +- : ++if test x$cln_config_prefix != x ; then ++ cln_config_args="$cln_config_args --prefix=$cln_config_prefix" ++ if test x${CLN_CONFIG+set} != xset ; then ++ CLN_CONFIG=$cln_config_prefix/bin/cln-config ++ fi + fi + ++# Extract the first word of "cln-config", so it can be a program name with args. ++set dummy cln-config; ac_word=$2 ++echo "$as_me:$LINENO: checking for $ac_word" >&5 ++echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 ++if test "${ac_cv_path_CLN_CONFIG+set}" = set; then ++ echo $ECHO_N "(cached) $ECHO_C" >&6 + else +- : +-fi +- +- fi ++ case $CLN_CONFIG in ++ [\\/]* | ?:[\\/]*) ++ ac_cv_path_CLN_CONFIG="$CLN_CONFIG" # Let the user override the test with a path. ++ ;; ++ *) ++ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR ++for as_dir in $PATH ++do ++ IFS=$as_save_IFS ++ test -z "$as_dir" && as_dir=. ++ for ac_exec_ext in '' $ac_executable_extensions; do ++ if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ++ ac_cv_path_CLN_CONFIG="$as_dir/$ac_word$ac_exec_ext" ++ echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 ++ break 2 ++ fi ++done ++done + +- # +- # If we found libintl, then check in it for bind_textdomain_codeset(); +- # we'll prefer libc if neither have bind_textdomain_codeset(), +- # and both have dgettext and ngettext +- # +- if test "$gt_cv_func_dgettext_libintl" = "yes" ; then +- glib_save_LIBS="$LIBS" +- LIBS="$LIBS -lintl $libintl_extra_libs" +- unset ac_cv_func_bind_textdomain_codeset ++ test -z "$ac_cv_path_CLN_CONFIG" && ac_cv_path_CLN_CONFIG="no" ++ ;; ++esac ++fi ++CLN_CONFIG=$ac_cv_path_CLN_CONFIG + +-for ac_func in bind_textdomain_codeset +-do +-as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh` +-echo "$as_me:$LINENO: checking for $ac_func" >&5 +-echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6 +-if eval "test \"\${$as_ac_var+set}\" = set"; then +- echo $ECHO_N "(cached) $ECHO_C" >&6 ++if test -n "$CLN_CONFIG"; then ++ echo "$as_me:$LINENO: result: $CLN_CONFIG" >&5 ++echo "${ECHO_T}$CLN_CONFIG" >&6 ++else ++ echo "$as_me:$LINENO: result: no" >&5 ++echo "${ECHO_T}no" >&6 ++fi ++ ++cln_min_version=1.1.0 ++echo "$as_me:$LINENO: checking for CLN - version >= $cln_min_version" >&5 ++echo $ECHO_N "checking for CLN - version >= $cln_min_version... $ECHO_C" >&6 ++if test "$CLN_CONFIG" = "no" ; then ++ echo "$as_me:$LINENO: result: no" >&5 ++echo "${ECHO_T}no" >&6 ++ echo "*** The cln-config script installed by CLN could not be found" ++ echo "*** If CLN was installed in PREFIX, make sure PREFIX/bin is in" ++ echo "*** your path, or set the CLN_CONFIG environment variable to the" ++ echo "*** full path to cln-config." ++ { { echo "$as_me:$LINENO: error: No suitable installed version of CLN could be found." >&5 ++echo "$as_me: error: No suitable installed version of CLN could be found." >&2;} ++ { (exit 1); exit 1; }; } ++else ++ cln_min_major_version=`echo $cln_min_version | \ ++ sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\1/'` ++ cln_min_minor_version=`echo $cln_min_version | \ ++ sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\2/'` ++ cln_min_micro_version=`echo $cln_min_version | \ ++ sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\3/'` ++ CLN_CPPFLAGS=`$CLN_CONFIG $cln_config_args --cppflags` ++ CLN_LIBS=`$CLN_CONFIG $cln_config_args --libs` ++ cln_config_version=`$CLN_CONFIG $cln_config_args --version` ++ cln_config_major_version=`echo $cln_config_version | \ ++ sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\1/'` ++ cln_config_minor_version=`echo $cln_config_version | \ ++ sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\2/'` ++ cln_config_micro_version=`echo $cln_config_version | \ ++ sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\3/'` ++ if test \( $cln_config_major_version -lt $cln_min_major_version \) -o \ ++ \( $cln_config_major_version -eq $cln_min_major_version -a $cln_config_minor_version -lt $cln_min_minor_version \) -o \ ++ \( $cln_config_major_version -eq $cln_min_major_version -a $cln_config_minor_version -eq $cln_min_minor_version -a $cln_config_micro_version -lt $cln_min_micro_version \); then ++ echo -e "\n*** 'cln-config --version' returned $cln_config_major_version.$cln_config_minor_version.$cln_config_micro_version, but the minimum version" ++ echo "*** of CLN required is $cln_min_major_version.$cln_min_minor_version.$cln_min_micro_version. If cln-config is correct, then it is" ++ echo "*** best to upgrade to the required version." ++ echo "*** If cln-config was wrong, set the environment variable CLN_CONFIG" ++ echo "*** to point to the correct copy of cln-config, and remove the file" ++ echo "*** config.cache before re-running configure." ++ { { echo "$as_me:$LINENO: error: No suitable installed version of CLN could be found." >&5 ++echo "$as_me: error: No suitable installed version of CLN could be found." >&2;} ++ { (exit 1); exit 1; }; } ++ else ++ no_cln="" ++ if test "x$enable_clntest" = "xyes" ; then ++ ac_save_CPPFLAGS="$CPPFLAGS" ++ ac_save_LIBS="$LIBS" ++ CPPFLAGS="$CPPFLAGS $CLN_CPPFLAGS" ++ LIBS="$LIBS $CLN_LIBS" ++ rm -f conf.clntest ++ if test "$cross_compiling" = yes; then ++ echo $ac_n "cross compiling; assumed OK... $ac_c" + else + cat >conftest.$ac_ext <<_ACEOF + /* confdefs.h. */ +@@ -21937,215 +21875,99 @@ _ACEOF + cat confdefs.h >>conftest.$ac_ext + cat >>conftest.$ac_ext <<_ACEOF + /* end confdefs.h. */ +-/* Define $ac_func to an innocuous variant, in case declares $ac_func. +- For example, HP-UX 11i declares gettimeofday. */ +-#define $ac_func innocuous_$ac_func +- +-/* System header to define __stub macros and hopefully few prototypes, +- which can conflict with char $ac_func (); below. +- Prefer to if __STDC__ is defined, since +- exists even on freestanding compilers. */ + +-#ifdef __STDC__ +-# include +-#else +-# include +-#endif ++#include ++#include ++#include + +-#undef $ac_func ++/* we do not #include because autoconf in C++ mode inserts a ++ prototype for exit() that conflicts with the one in stdlib.h */ ++extern "C" int system(const char *); + +-/* Override any gcc2 internal prototype to avoid an error. */ +-#ifdef __cplusplus +-extern "C" ++int main(void) + { +-#endif +-/* We use char because int might match the return type of a gcc2 +- builtin and then its argument prototype would still apply. */ +-char $ac_func (); +-/* The GNU C library defines this for functions which it implements +- to always fail with ENOSYS. Some functions are actually named +- something starting with __ and the normal name is an alias. */ +-#if defined (__stub_$ac_func) || defined (__stub___$ac_func) +-choke me +-#else +-char (*f) () = $ac_func; +-#endif +-#ifdef __cplusplus +-} +-#endif ++ system("touch conf.clntest"); + +-int +-main () +-{ +-return f != $ac_func; +- ; +- return 0; ++ if ((CL_VERSION_MAJOR != $cln_config_major_version) || ++ (CL_VERSION_MINOR != $cln_config_minor_version) || ++ (CL_VERSION_PATCHLEVEL != $cln_config_micro_version)) { ++ printf("\n*** 'cln-config --version' returned %d.%d.%d, but the header file I found\n", $cln_config_major_version, $cln_config_minor_version, $cln_config_micro_version); ++ printf("*** corresponds to %d.%d.%d. This mismatch suggests your installation of CLN\n", CL_VERSION_MAJOR, CL_VERSION_MINOR, CL_VERSION_PATCHLEVEL); ++ printf("*** is corrupted or you have specified some wrong -I compiler flags.\n"); ++ printf("*** Please inquire and consider reinstalling CLN.\n"); ++ return 1; ++ } ++ if ((cln::version_major != $cln_config_major_version) || ++ (cln::version_minor != $cln_config_minor_version) || ++ (cln::version_patchlevel != $cln_config_micro_version)) { ++ printf("\n*** 'cln-config --version' returned %d.%d.%d, but the library I found\n", $cln_config_major_version, $cln_config_minor_version, $cln_config_micro_version); ++ printf("*** corresponds to %d.%d.%d. This mismatch suggests your installation of CLN\n", cln::version_major, cln::version_minor, cln::version_patchlevel); ++ printf("*** is corrupted or you have specified some wrong -L compiler flags.\n"); ++ printf("*** Please inquire and consider reinstalling CLN.\n"); ++ return 1; ++ } ++ return 0; + } ++ + _ACEOF +-rm -f conftest.$ac_objext conftest$ac_exeext ++rm -f conftest$ac_exeext + if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 +- (eval $ac_link) 2>conftest.er1 +- ac_status=$? +- grep -v '^ *+' conftest.er1 >conftest.err +- rm -f conftest.er1 +- cat conftest.err >&5 +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); } && +- { ac_try='test -z "$ac_cxx_werror_flag" +- || test ! -s conftest.err' +- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 +- (eval $ac_try) 2>&5 ++ (eval $ac_link) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; } && +- { ac_try='test -s conftest$ac_exeext' ++ (exit $ac_status); } && { ac_try='./conftest$ac_exeext' + { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then +- eval "$as_ac_var=yes" ++ : + else +- echo "$as_me: failed program was:" >&5 ++ echo "$as_me: program exited with status $ac_status" >&5 ++echo "$as_me: failed program was:" >&5 + sed 's/^/| /' conftest.$ac_ext >&5 + +-eval "$as_ac_var=no" +-fi +-rm -f conftest.err conftest.$ac_objext \ +- conftest$ac_exeext conftest.$ac_ext ++( exit $ac_status ) ++no_cln=yes + fi +-echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5 +-echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6 +-if test `eval echo '${'$as_ac_var'}'` = yes; then +- cat >>confdefs.h <<_ACEOF +-#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1 +-_ACEOF +- ++rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext + fi +-done +- +- LIBS="$glib_save_LIBS" +- +- if test "$ac_cv_func_bind_textdomain_codeset" = "yes" ; then +- gt_cv_func_dgettext_libc=no +- else +- if test "$gt_cv_func_dgettext_libc" = "yes" \ +- && test "$gt_cv_func_ngettext_libc" = "yes"; then +- gt_cv_func_dgettext_libintl=no +- fi +- fi ++ CPPFLAGS="$ac_save_CPPFLAGS" ++ LIBS="$ac_save_LIBS" + fi +- fi +- +- if test "$gt_cv_func_dgettext_libc" = "yes" \ +- || test "$gt_cv_func_dgettext_libintl" = "yes"; then +- gt_cv_have_gettext=yes +- fi +- +- if test "$gt_cv_func_dgettext_libintl" = "yes"; then +- INTLLIBS="-lintl $libintl_extra_libs" +- fi ++ if test "x$no_cln" = x ; then ++ echo "$as_me:$LINENO: result: yes, $cln_config_version" >&5 ++echo "${ECHO_T}yes, $cln_config_version" >&6 + +- if test "$gt_cv_have_gettext" = "yes"; then ++ LIBS="$LIBS $CLN_LIBS" ++ CPPFLAGS="$CPPFLAGS $CLN_CPPFLAGS" + + cat >>confdefs.h <<\_ACEOF +-#define HAVE_GETTEXT 1 +-_ACEOF +- +- # Extract the first word of "msgfmt", so it can be a program name with args. +-set dummy msgfmt; ac_word=$2 +-echo "$as_me:$LINENO: checking for $ac_word" >&5 +-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 +-if test "${ac_cv_path_MSGFMT+set}" = set; then +- echo $ECHO_N "(cached) $ECHO_C" >&6 +-else +- case "$MSGFMT" in +- /*) +- ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path. +- ;; +- *) +- IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" +- for ac_dir in $PATH; do +- test -z "$ac_dir" && ac_dir=. +- if test -f $ac_dir/$ac_word; then +- if test -z "`$ac_dir/$ac_word -h 2>&1 | grep 'dv '`"; then +- ac_cv_path_MSGFMT="$ac_dir/$ac_word" +- break +- fi +- fi +- done +- IFS="$ac_save_ifs" +- test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT="no" +- ;; +-esac +-fi +-MSGFMT="$ac_cv_path_MSGFMT" +-if test "$MSGFMT" != "no"; then +- echo "$as_me:$LINENO: result: $MSGFMT" >&5 +-echo "${ECHO_T}$MSGFMT" >&6 +-else +- echo "$as_me:$LINENO: result: no" >&5 +-echo "${ECHO_T}no" >&6 +-fi +- if test "$MSGFMT" != "no"; then +- glib_save_LIBS="$LIBS" +- LIBS="$LIBS $INTLLIBS" +- +-for ac_func in dcgettext +-do +-as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh` +-echo "$as_me:$LINENO: checking for $ac_func" >&5 +-echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6 +-if eval "test \"\${$as_ac_var+set}\" = set"; then +- echo $ECHO_N "(cached) $ECHO_C" >&6 +-else +- cat >conftest.$ac_ext <<_ACEOF +-/* confdefs.h. */ ++#define HAVE_LIBCLN 1 + _ACEOF +-cat confdefs.h >>conftest.$ac_ext +-cat >>conftest.$ac_ext <<_ACEOF +-/* end confdefs.h. */ +-/* Define $ac_func to an innocuous variant, in case declares $ac_func. +- For example, HP-UX 11i declares gettimeofday. */ +-#define $ac_func innocuous_$ac_func +- +-/* System header to define __stub macros and hopefully few prototypes, +- which can conflict with char $ac_func (); below. +- Prefer to if __STDC__ is defined, since +- exists even on freestanding compilers. */ +- +-#ifdef __STDC__ +-# include +-#else +-# include +-#endif + +-#undef $ac_func + +-/* Override any gcc2 internal prototype to avoid an error. */ +-#ifdef __cplusplus +-extern "C" +-{ +-#endif +-/* We use char because int might match the return type of a gcc2 +- builtin and then its argument prototype would still apply. */ +-char $ac_func (); +-/* The GNU C library defines this for functions which it implements +- to always fail with ENOSYS. Some functions are actually named +- something starting with __ and the normal name is an alias. */ +-#if defined (__stub_$ac_func) || defined (__stub___$ac_func) +-choke me +-#else +-char (*f) () = $ac_func; +-#endif +-#ifdef __cplusplus +-} +-#endif ++ else ++ echo "$as_me:$LINENO: result: no" >&5 ++echo "${ECHO_T}no" >&6 ++ if test ! -f conf.clntest ; then ++ echo "*** Could not run CLN test program, checking why..." ++ CPPFLAGS="$CFLAGS $CLN_CPPFLAGS" ++ LIBS="$LIBS $CLN_LIBS" ++ cat >conftest.$ac_ext <<_ACEOF ++/* confdefs.h. */ ++_ACEOF ++cat confdefs.h >>conftest.$ac_ext ++cat >>conftest.$ac_ext <<_ACEOF ++/* end confdefs.h. */ ++ ++#include ++#include + + int + main () + { +-return f != $ac_func; ++ return 0; + ; + return 0; + } +@@ -22172,36 +21994,53 @@ if { (eval echo "$as_me:$LINENO: \"$ac_l + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then +- eval "$as_ac_var=yes" ++ echo "*** The test program compiled, but did not run. This usually means" ++ echo "*** that the run-time linker is not finding CLN or finding the wrong" ++ echo "*** version of CLN. If it is not finding CLN, you'll need to set your" ++ echo "*** LD_LIBRARY_PATH environment variable, or edit /etc/ld.so.conf to point" ++ echo "*** to the installed location. Also, make sure you have run ldconfig if that" ++ echo "*** is required on your system." + else + echo "$as_me: failed program was:" >&5 + sed 's/^/| /' conftest.$ac_ext >&5 + +-eval "$as_ac_var=no" ++ echo "*** The test program failed to compile or link. See the file config.log for the" ++ echo "*** exact error that occured. This usually means CLN was incorrectly installed" ++ echo "*** or that you have moved CLN since it was installed. In the latter case, you" ++ echo "*** may want to edit the cln-config script: $CLN_CONFIG." + fi + rm -f conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext ++ CPPFLAGS="$ac_save_CPPFLAGS" ++ LIBS="$ac_save_LIBS" ++ fi ++ CLN_CPPFLAGS="" ++ CLN_LIBS="" ++ { { echo "$as_me:$LINENO: error: No suitable installed version of CLN could be found." >&5 ++echo "$as_me: error: No suitable installed version of CLN could be found." >&2;} ++ { (exit 1); exit 1; }; } ++ fi ++ fi + fi +-echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5 +-echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6 +-if test `eval echo '${'$as_ac_var'}'` = yes; then +- cat >>confdefs.h <<_ACEOF +-#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1 +-_ACEOF + +-fi +-done + +- # Extract the first word of "gmsgfmt", so it can be a program name with args. +-set dummy gmsgfmt; ac_word=$2 ++rm -f conf.clntest ++ ++ ++ ++ ++if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then ++ if test -n "$ac_tool_prefix"; then ++ # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args. ++set dummy ${ac_tool_prefix}pkg-config; ac_word=$2 + echo "$as_me:$LINENO: checking for $ac_word" >&5 + echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 +-if test "${ac_cv_path_GMSGFMT+set}" = set; then ++if test "${ac_cv_path_PKG_CONFIG+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 + else +- case $GMSGFMT in ++ case $PKG_CONFIG in + [\\/]* | ?:[\\/]*) +- ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path. ++ ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path. + ;; + *) + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +@@ -22211,348 +22050,509 @@ do + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then +- ac_cv_path_GMSGFMT="$as_dir/$ac_word$ac_exec_ext" ++ ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" + echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi + done + done + +- test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT" + ;; + esac + fi +-GMSGFMT=$ac_cv_path_GMSGFMT ++PKG_CONFIG=$ac_cv_path_PKG_CONFIG + +-if test -n "$GMSGFMT"; then +- echo "$as_me:$LINENO: result: $GMSGFMT" >&5 +-echo "${ECHO_T}$GMSGFMT" >&6 ++if test -n "$PKG_CONFIG"; then ++ echo "$as_me:$LINENO: result: $PKG_CONFIG" >&5 ++echo "${ECHO_T}$PKG_CONFIG" >&6 + else + echo "$as_me:$LINENO: result: no" >&5 + echo "${ECHO_T}no" >&6 + fi + +- # Extract the first word of "xgettext", so it can be a program name with args. +-set dummy xgettext; ac_word=$2 ++fi ++if test -z "$ac_cv_path_PKG_CONFIG"; then ++ ac_pt_PKG_CONFIG=$PKG_CONFIG ++ # Extract the first word of "pkg-config", so it can be a program name with args. ++set dummy pkg-config; ac_word=$2 + echo "$as_me:$LINENO: checking for $ac_word" >&5 + echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 +-if test "${ac_cv_path_XGETTEXT+set}" = set; then ++if test "${ac_cv_path_ac_pt_PKG_CONFIG+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 + else +- case "$XGETTEXT" in +- /*) +- ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path. ++ case $ac_pt_PKG_CONFIG in ++ [\\/]* | ?:[\\/]*) ++ ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path. + ;; + *) +- IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" +- for ac_dir in $PATH; do +- test -z "$ac_dir" && ac_dir=. +- if test -f $ac_dir/$ac_word; then +- if test -z "`$ac_dir/$ac_word -h 2>&1 | grep '(HELP)'`"; then +- ac_cv_path_XGETTEXT="$ac_dir/$ac_word" +- break +- fi +- fi +- done +- IFS="$ac_save_ifs" +- test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":" ++ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR ++for as_dir in $PATH ++do ++ IFS=$as_save_IFS ++ test -z "$as_dir" && as_dir=. ++ for ac_exec_ext in '' $ac_executable_extensions; do ++ if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ++ ac_cv_path_ac_pt_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" ++ echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 ++ break 2 ++ fi ++done ++done ++ + ;; + esac + fi +-XGETTEXT="$ac_cv_path_XGETTEXT" +-if test "$XGETTEXT" != ":"; then +- echo "$as_me:$LINENO: result: $XGETTEXT" >&5 +-echo "${ECHO_T}$XGETTEXT" >&6 ++ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG ++ ++if test -n "$ac_pt_PKG_CONFIG"; then ++ echo "$as_me:$LINENO: result: $ac_pt_PKG_CONFIG" >&5 ++echo "${ECHO_T}$ac_pt_PKG_CONFIG" >&6 + else + echo "$as_me:$LINENO: result: no" >&5 + echo "${ECHO_T}no" >&6 + fi + +- cat >conftest.$ac_ext <<_ACEOF +-/* confdefs.h. */ +-_ACEOF +-cat confdefs.h >>conftest.$ac_ext +-cat >>conftest.$ac_ext <<_ACEOF +-/* end confdefs.h. */ ++ PKG_CONFIG=$ac_pt_PKG_CONFIG ++else ++ PKG_CONFIG="$ac_cv_path_PKG_CONFIG" ++fi ++ ++fi ++if test -n "$PKG_CONFIG"; then ++ _pkg_min_version=0.9.0 ++ echo "$as_me:$LINENO: checking pkg-config is at least version $_pkg_min_version" >&5 ++echo $ECHO_N "checking pkg-config is at least version $_pkg_min_version... $ECHO_C" >&6 ++ if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then ++ echo "$as_me:$LINENO: result: yes" >&5 ++echo "${ECHO_T}yes" >&6 ++ else ++ echo "$as_me:$LINENO: result: no" >&5 ++echo "${ECHO_T}no" >&6 ++ PKG_CONFIG="" ++ fi ++ ++fi ++ ++pkg_failed=no ++echo "$as_me:$LINENO: checking for GLIB" >&5 ++echo $ECHO_N "checking for GLIB... $ECHO_C" >&6 ++ ++if test -n "$PKG_CONFIG"; then ++ if test -n "$GLIB_CFLAGS"; then ++ pkg_cv_GLIB_CFLAGS="$GLIB_CFLAGS" ++ else ++ if test -n "$PKG_CONFIG" && \ ++ { (echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \" ++ glib-2.0 >= 2.4 ++ libxml-2.0 ++ \"") >&5 ++ ($PKG_CONFIG --exists --print-errors " ++ glib-2.0 >= 2.4 ++ libxml-2.0 ++ ") 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; then ++ pkg_cv_GLIB_CFLAGS=`$PKG_CONFIG --cflags " ++ glib-2.0 >= 2.4 ++ libxml-2.0 ++ " 2>/dev/null` ++else ++ pkg_failed=yes ++fi ++ fi ++else ++ pkg_failed=untried ++fi ++if test -n "$PKG_CONFIG"; then ++ if test -n "$GLIB_LIBS"; then ++ pkg_cv_GLIB_LIBS="$GLIB_LIBS" ++ else ++ if test -n "$PKG_CONFIG" && \ ++ { (echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \" ++ glib-2.0 >= 2.4 ++ libxml-2.0 ++ \"") >&5 ++ ($PKG_CONFIG --exists --print-errors " ++ glib-2.0 >= 2.4 ++ libxml-2.0 ++ ") 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; then ++ pkg_cv_GLIB_LIBS=`$PKG_CONFIG --libs " ++ glib-2.0 >= 2.4 ++ libxml-2.0 ++ " 2>/dev/null` ++else ++ pkg_failed=yes ++fi ++ fi ++else ++ pkg_failed=untried ++fi ++ ++ ++ ++if test $pkg_failed = yes; then ++ ++if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then ++ _pkg_short_errors_supported=yes ++else ++ _pkg_short_errors_supported=no ++fi ++ if test $_pkg_short_errors_supported = yes; then ++ GLIB_PKG_ERRORS=`$PKG_CONFIG --short-errors --errors-to-stdout --print-errors " ++ glib-2.0 >= 2.4 ++ libxml-2.0 ++ "` ++ else ++ GLIB_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors " ++ glib-2.0 >= 2.4 ++ libxml-2.0 ++ "` ++ fi ++ # Put the nasty error message in config.log where it belongs ++ echo "$GLIB_PKG_ERRORS" >&5 ++ ++ { { echo "$as_me:$LINENO: error: Package requirements ( ++ glib-2.0 >= 2.4 ++ libxml-2.0 ++ ) were not met: ++ ++$GLIB_PKG_ERRORS ++ ++Consider adjusting the PKG_CONFIG_PATH environment variable if you ++installed software in a non-standard prefix. + +-int +-main () +-{ +-extern int _nl_msg_cat_cntr; +- return _nl_msg_cat_cntr +- ; +- return 0; +-} +-_ACEOF +-rm -f conftest.$ac_objext conftest$ac_exeext +-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 +- (eval $ac_link) 2>conftest.er1 +- ac_status=$? +- grep -v '^ *+' conftest.er1 >conftest.err +- rm -f conftest.er1 +- cat conftest.err >&5 +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); } && +- { ac_try='test -z "$ac_cxx_werror_flag" +- || test ! -s conftest.err' +- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 +- (eval $ac_try) 2>&5 +- ac_status=$? +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; } && +- { ac_try='test -s conftest$ac_exeext' +- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 +- (eval $ac_try) 2>&5 +- ac_status=$? +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; }; then +- CATOBJEXT=.gmo +- DATADIRNAME=share +-else +- echo "$as_me: failed program was:" >&5 +-sed 's/^/| /' conftest.$ac_ext >&5 ++Alternatively, you may set the environment variables GLIB_CFLAGS ++and GLIB_LIBS to avoid the need to call pkg-config. ++See the pkg-config man page for more details. ++" >&5 ++echo "$as_me: error: Package requirements ( ++ glib-2.0 >= 2.4 ++ libxml-2.0 ++ ) were not met: + +-case $host in +- *-*-solaris*) +- echo "$as_me:$LINENO: checking for bind_textdomain_codeset" >&5 +-echo $ECHO_N "checking for bind_textdomain_codeset... $ECHO_C" >&6 +-if test "${ac_cv_func_bind_textdomain_codeset+set}" = set; then +- echo $ECHO_N "(cached) $ECHO_C" >&6 ++$GLIB_PKG_ERRORS ++ ++Consider adjusting the PKG_CONFIG_PATH environment variable if you ++installed software in a non-standard prefix. ++ ++Alternatively, you may set the environment variables GLIB_CFLAGS ++and GLIB_LIBS to avoid the need to call pkg-config. ++See the pkg-config man page for more details. ++" >&2;} ++ { (exit 1); exit 1; }; } ++elif test $pkg_failed = untried; then ++ { { echo "$as_me:$LINENO: error: The pkg-config script could not be found or is too old. Make sure it ++is in your PATH or set the PKG_CONFIG environment variable to the full ++path to pkg-config. ++ ++Alternatively, you may set the environment variables GLIB_CFLAGS ++and GLIB_LIBS to avoid the need to call pkg-config. ++See the pkg-config man page for more details. ++ ++To get pkg-config, see . ++See \`config.log' for more details." >&5 ++echo "$as_me: error: The pkg-config script could not be found or is too old. Make sure it ++is in your PATH or set the PKG_CONFIG environment variable to the full ++path to pkg-config. ++ ++Alternatively, you may set the environment variables GLIB_CFLAGS ++and GLIB_LIBS to avoid the need to call pkg-config. ++See the pkg-config man page for more details. ++ ++To get pkg-config, see . ++See \`config.log' for more details." >&2;} ++ { (exit 1); exit 1; }; } + else +- cat >conftest.$ac_ext <<_ACEOF +-/* confdefs.h. */ +-_ACEOF +-cat confdefs.h >>conftest.$ac_ext +-cat >>conftest.$ac_ext <<_ACEOF +-/* end confdefs.h. */ +-/* Define bind_textdomain_codeset to an innocuous variant, in case declares bind_textdomain_codeset. +- For example, HP-UX 11i declares gettimeofday. */ +-#define bind_textdomain_codeset innocuous_bind_textdomain_codeset ++ GLIB_CFLAGS=$pkg_cv_GLIB_CFLAGS ++ GLIB_LIBS=$pkg_cv_GLIB_LIBS ++ echo "$as_me:$LINENO: result: yes" >&5 ++echo "${ECHO_T}yes" >&6 ++ : ++fi + +-/* System header to define __stub macros and hopefully few prototypes, +- which can conflict with char bind_textdomain_codeset (); below. +- Prefer to if __STDC__ is defined, since +- exists even on freestanding compilers. */ + +-#ifdef __STDC__ +-# include +-#else +-# include +-#endif + +-#undef bind_textdomain_codeset + +-/* Override any gcc2 internal prototype to avoid an error. */ +-#ifdef __cplusplus +-extern "C" +-{ +-#endif +-/* We use char because int might match the return type of a gcc2 +- builtin and then its argument prototype would still apply. */ +-char bind_textdomain_codeset (); +-/* The GNU C library defines this for functions which it implements +- to always fail with ENOSYS. Some functions are actually named +- something starting with __ and the normal name is an alias. */ +-#if defined (__stub_bind_textdomain_codeset) || defined (__stub___bind_textdomain_codeset) +-choke me +-#else +-char (*f) () = bind_textdomain_codeset; +-#endif +-#ifdef __cplusplus +-} +-#endif ++pkg_failed=no ++echo "$as_me:$LINENO: checking for GTK" >&5 ++echo $ECHO_N "checking for GTK... $ECHO_C" >&6 + +-int +-main () +-{ +-return f != bind_textdomain_codeset; +- ; +- return 0; +-} +-_ACEOF +-rm -f conftest.$ac_objext conftest$ac_exeext +-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 +- (eval $ac_link) 2>conftest.er1 +- ac_status=$? +- grep -v '^ *+' conftest.er1 >conftest.err +- rm -f conftest.er1 +- cat conftest.err >&5 +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); } && +- { ac_try='test -z "$ac_cxx_werror_flag" +- || test ! -s conftest.err' +- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 +- (eval $ac_try) 2>&5 ++if test -n "$PKG_CONFIG"; then ++ if test -n "$GTK_CFLAGS"; then ++ pkg_cv_GTK_CFLAGS="$GTK_CFLAGS" ++ else ++ if test -n "$PKG_CONFIG" && \ ++ { (echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \" ++ gtk+-2.0 >= 2.4 ++ gdk-pixbuf-2.0 ++ \"") >&5 ++ ($PKG_CONFIG --exists --print-errors " ++ gtk+-2.0 >= 2.4 ++ gdk-pixbuf-2.0 ++ ") 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; } && +- { ac_try='test -s conftest$ac_exeext' +- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 +- (eval $ac_try) 2>&5 ++ (exit $ac_status); }; then ++ pkg_cv_GTK_CFLAGS=`$PKG_CONFIG --cflags " ++ gtk+-2.0 >= 2.4 ++ gdk-pixbuf-2.0 ++ " 2>/dev/null` ++else ++ pkg_failed=yes ++fi ++ fi ++else ++ pkg_failed=untried ++fi ++if test -n "$PKG_CONFIG"; then ++ if test -n "$GTK_LIBS"; then ++ pkg_cv_GTK_LIBS="$GTK_LIBS" ++ else ++ if test -n "$PKG_CONFIG" && \ ++ { (echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \" ++ gtk+-2.0 >= 2.4 ++ gdk-pixbuf-2.0 ++ \"") >&5 ++ ($PKG_CONFIG --exists --print-errors " ++ gtk+-2.0 >= 2.4 ++ gdk-pixbuf-2.0 ++ ") 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; }; then +- ac_cv_func_bind_textdomain_codeset=yes ++ (exit $ac_status); }; then ++ pkg_cv_GTK_LIBS=`$PKG_CONFIG --libs " ++ gtk+-2.0 >= 2.4 ++ gdk-pixbuf-2.0 ++ " 2>/dev/null` + else +- echo "$as_me: failed program was:" >&5 +-sed 's/^/| /' conftest.$ac_ext >&5 +- +-ac_cv_func_bind_textdomain_codeset=no +-fi +-rm -f conftest.err conftest.$ac_objext \ +- conftest$ac_exeext conftest.$ac_ext ++ pkg_failed=yes + fi +-echo "$as_me:$LINENO: result: $ac_cv_func_bind_textdomain_codeset" >&5 +-echo "${ECHO_T}$ac_cv_func_bind_textdomain_codeset" >&6 +-if test $ac_cv_func_bind_textdomain_codeset = yes; then +- CATOBJEXT=.gmo +- DATADIRNAME=share ++ fi + else +- CATOBJEXT=.mo +- DATADIRNAME=lib ++ pkg_failed=untried + fi + +- ;; +- *) +- CATOBJEXT=.mo +- DATADIRNAME=lib +- ;; +- esac ++ ++ ++if test $pkg_failed = yes; then ++ ++if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then ++ _pkg_short_errors_supported=yes ++else ++ _pkg_short_errors_supported=no + fi +-rm -f conftest.err conftest.$ac_objext \ +- conftest$ac_exeext conftest.$ac_ext +- LIBS="$glib_save_LIBS" +- INSTOBJEXT=.mo +- else +- gt_cv_have_gettext=no +- fi +- fi ++ if test $_pkg_short_errors_supported = yes; then ++ GTK_PKG_ERRORS=`$PKG_CONFIG --short-errors --errors-to-stdout --print-errors " ++ gtk+-2.0 >= 2.4 ++ gdk-pixbuf-2.0 ++ "` ++ else ++ GTK_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors " ++ gtk+-2.0 >= 2.4 ++ gdk-pixbuf-2.0 ++ "` ++ fi ++ # Put the nasty error message in config.log where it belongs ++ echo "$GTK_PKG_ERRORS" >&5 + +-fi ++ { { echo "$as_me:$LINENO: error: Package requirements ( ++ gtk+-2.0 >= 2.4 ++ gdk-pixbuf-2.0 ++ ) were not met: + ++$GTK_PKG_ERRORS + ++Consider adjusting the PKG_CONFIG_PATH environment variable if you ++installed software in a non-standard prefix. + +- if test "$gt_cv_have_gettext" = "yes" ; then ++Alternatively, you may set the environment variables GTK_CFLAGS ++and GTK_LIBS to avoid the need to call pkg-config. ++See the pkg-config man page for more details. ++" >&5 ++echo "$as_me: error: Package requirements ( ++ gtk+-2.0 >= 2.4 ++ gdk-pixbuf-2.0 ++ ) were not met: + +-cat >>confdefs.h <<\_ACEOF +-#define ENABLE_NLS 1 +-_ACEOF ++$GTK_PKG_ERRORS + +- fi ++Consider adjusting the PKG_CONFIG_PATH environment variable if you ++installed software in a non-standard prefix. + +- if test "$XGETTEXT" != ":"; then +- if $XGETTEXT --omit-header /dev/null 2> /dev/null; then +- : ; +- else +- echo "$as_me:$LINENO: result: found xgettext program is not GNU xgettext; ignore it" >&5 +-echo "${ECHO_T}found xgettext program is not GNU xgettext; ignore it" >&6 +- XGETTEXT=":" +- fi +- fi ++Alternatively, you may set the environment variables GTK_CFLAGS ++and GTK_LIBS to avoid the need to call pkg-config. ++See the pkg-config man page for more details. ++" >&2;} ++ { (exit 1); exit 1; }; } ++elif test $pkg_failed = untried; then ++ { { echo "$as_me:$LINENO: error: The pkg-config script could not be found or is too old. Make sure it ++is in your PATH or set the PKG_CONFIG environment variable to the full ++path to pkg-config. + +- # We need to process the po/ directory. +- POSUB=po ++Alternatively, you may set the environment variables GTK_CFLAGS ++and GTK_LIBS to avoid the need to call pkg-config. ++See the pkg-config man page for more details. + +- ac_config_commands="$ac_config_commands default-1" ++To get pkg-config, see . ++See \`config.log' for more details." >&5 ++echo "$as_me: error: The pkg-config script could not be found or is too old. Make sure it ++is in your PATH or set the PKG_CONFIG environment variable to the full ++path to pkg-config. + ++Alternatively, you may set the environment variables GTK_CFLAGS ++and GTK_LIBS to avoid the need to call pkg-config. ++See the pkg-config man page for more details. ++ ++To get pkg-config, see . ++See \`config.log' for more details." >&2;} ++ { (exit 1); exit 1; }; } ++else ++ GTK_CFLAGS=$pkg_cv_GTK_CFLAGS ++ GTK_LIBS=$pkg_cv_GTK_LIBS ++ echo "$as_me:$LINENO: result: yes" >&5 ++echo "${ECHO_T}yes" >&6 ++ : ++fi + +- for lang in $ALL_LINGUAS; do +- GMOFILES="$GMOFILES $lang.gmo" +- POFILES="$POFILES $lang.po" +- done + + + ++pkg_failed=no ++echo "$as_me:$LINENO: checking for QALCULATE" >&5 ++echo $ECHO_N "checking for QALCULATE... $ECHO_C" >&6 + ++if test -n "$PKG_CONFIG"; then ++ if test -n "$QALCULATE_CFLAGS"; then ++ pkg_cv_QALCULATE_CFLAGS="$QALCULATE_CFLAGS" ++ else ++ if test -n "$PKG_CONFIG" && \ ++ { (echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \" ++ libqalculate >= 0.9.4 ++ \"") >&5 ++ ($PKG_CONFIG --exists --print-errors " ++ libqalculate >= 0.9.4 ++ ") 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; then ++ pkg_cv_QALCULATE_CFLAGS=`$PKG_CONFIG --cflags " ++ libqalculate >= 0.9.4 ++ " 2>/dev/null` ++else ++ pkg_failed=yes ++fi ++ fi ++else ++ pkg_failed=untried ++fi ++if test -n "$PKG_CONFIG"; then ++ if test -n "$QALCULATE_LIBS"; then ++ pkg_cv_QALCULATE_LIBS="$QALCULATE_LIBS" ++ else ++ if test -n "$PKG_CONFIG" && \ ++ { (echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \" ++ libqalculate >= 0.9.4 ++ \"") >&5 ++ ($PKG_CONFIG --exists --print-errors " ++ libqalculate >= 0.9.4 ++ ") 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; then ++ pkg_cv_QALCULATE_LIBS=`$PKG_CONFIG --libs " ++ libqalculate >= 0.9.4 ++ " 2>/dev/null` ++else ++ pkg_failed=yes ++fi ++ fi ++else ++ pkg_failed=untried ++fi + + + ++if test $pkg_failed = yes; then + ++if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then ++ _pkg_short_errors_supported=yes ++else ++ _pkg_short_errors_supported=no ++fi ++ if test $_pkg_short_errors_supported = yes; then ++ QALCULATE_PKG_ERRORS=`$PKG_CONFIG --short-errors --errors-to-stdout --print-errors " ++ libqalculate >= 0.9.4 ++ "` ++ else ++ QALCULATE_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors " ++ libqalculate >= 0.9.4 ++ "` ++ fi ++ # Put the nasty error message in config.log where it belongs ++ echo "$QALCULATE_PKG_ERRORS" >&5 + ++ { { echo "$as_me:$LINENO: error: Package requirements ( ++ libqalculate >= 0.9.4 ++ ) were not met: + ++$QALCULATE_PKG_ERRORS + ++Consider adjusting the PKG_CONFIG_PATH environment variable if you ++installed software in a non-standard prefix. + ++Alternatively, you may set the environment variables QALCULATE_CFLAGS ++and QALCULATE_LIBS to avoid the need to call pkg-config. ++See the pkg-config man page for more details. ++" >&5 ++echo "$as_me: error: Package requirements ( ++ libqalculate >= 0.9.4 ++ ) were not met: + +- if test "$gt_cv_have_gettext" = "yes"; then +- if test "x$ALL_LINGUAS" = "x"; then +- LINGUAS= +- else +- echo "$as_me:$LINENO: checking for catalogs to be installed" >&5 +-echo $ECHO_N "checking for catalogs to be installed... $ECHO_C" >&6 +- NEW_LINGUAS= +- for presentlang in $ALL_LINGUAS; do +- useit=no +- if test "%UNSET%" != "${LINGUAS-%UNSET%}"; then +- desiredlanguages="$LINGUAS" +- else +- desiredlanguages="$ALL_LINGUAS" +- fi +- for desiredlang in $desiredlanguages; do +- # Use the presentlang catalog if desiredlang is +- # a. equal to presentlang, or +- # b. a variant of presentlang (because in this case, +- # presentlang can be used as a fallback for messages +- # which are not translated in the desiredlang catalog). +- case "$desiredlang" in +- "$presentlang"*) useit=yes;; +- esac +- done +- if test $useit = yes; then +- NEW_LINGUAS="$NEW_LINGUAS $presentlang" +- fi +- done +- LINGUAS=$NEW_LINGUAS +- echo "$as_me:$LINENO: result: $LINGUAS" >&5 +-echo "${ECHO_T}$LINGUAS" >&6 +- fi ++$QALCULATE_PKG_ERRORS + +- if test -n "$LINGUAS"; then +- for lang in $LINGUAS; do CATALOGS="$CATALOGS $lang$CATOBJEXT"; done +- fi +- fi ++Consider adjusting the PKG_CONFIG_PATH environment variable if you ++installed software in a non-standard prefix. + +- MKINSTALLDIRS= +- if test -n "$ac_aux_dir"; then +- MKINSTALLDIRS="$ac_aux_dir/mkinstalldirs" +- fi +- if test -z "$MKINSTALLDIRS"; then +- MKINSTALLDIRS="\$(top_srcdir)/mkinstalldirs" +- fi ++Alternatively, you may set the environment variables QALCULATE_CFLAGS ++and QALCULATE_LIBS to avoid the need to call pkg-config. ++See the pkg-config man page for more details. ++" >&2;} ++ { (exit 1); exit 1; }; } ++elif test $pkg_failed = untried; then ++ { { echo "$as_me:$LINENO: error: The pkg-config script could not be found or is too old. Make sure it ++is in your PATH or set the PKG_CONFIG environment variable to the full ++path to pkg-config. + ++Alternatively, you may set the environment variables QALCULATE_CFLAGS ++and QALCULATE_LIBS to avoid the need to call pkg-config. ++See the pkg-config man page for more details. + +- test -d po || mkdir po +- if test "x$srcdir" != "x."; then +- if test "x`echo $srcdir | sed 's@/.*@@'`" = "x"; then +- posrcprefix="$srcdir/" +- else +- posrcprefix="../$srcdir/" +- fi +- else +- posrcprefix="../" +- fi +- rm -f po/POTFILES +- sed -e "/^#/d" -e "/^\$/d" -e "s,.*, $posrcprefix& \\\\," -e "\$s/\(.*\) \\\\/\1/" \ +- < $srcdir/po/POTFILES.in > po/POTFILES ++To get pkg-config, see . ++See \`config.log' for more details." >&5 ++echo "$as_me: error: The pkg-config script could not be found or is too old. Make sure it ++is in your PATH or set the PKG_CONFIG environment variable to the full ++path to pkg-config. + ++Alternatively, you may set the environment variables QALCULATE_CFLAGS ++and QALCULATE_LIBS to avoid the need to call pkg-config. ++See the pkg-config man page for more details. + +-echo "$as_me:$LINENO: checking locale directory" >&5 +-echo $ECHO_N "checking locale directory... $ECHO_C" >&6 +-if test "x$prefix" = "xNONE"; then +- PACKAGE_LOCALE_DIR=$ac_default_prefix/share/locale ++To get pkg-config, see . ++See \`config.log' for more details." >&2;} ++ { (exit 1); exit 1; }; } + else +- PACKAGE_LOCALE_DIR=$prefix/share/locale ++ QALCULATE_CFLAGS=$pkg_cv_QALCULATE_CFLAGS ++ QALCULATE_LIBS=$pkg_cv_QALCULATE_LIBS ++ echo "$as_me:$LINENO: result: yes" >&5 ++echo "${ECHO_T}yes" >&6 ++ : + fi + + +-cat >>confdefs.h <<_ACEOF +-#define PACKAGE_LOCALE_DIR "$PACKAGE_LOCALE_DIR" +-_ACEOF +- +- echo "$as_me:$LINENO: result: \"$PACKAGE_LOCALE_DIR\"" >&5 +-echo "${ECHO_T}\"$PACKAGE_LOCALE_DIR\"" >&6 +- +-INTLTOOL_QALCULATE_DEFINITIONS_RULE='%.xml: %.xml.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po-defs/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -x -u -c $(top_builddir)/po-defs/.intltool-merge-cache $(top_srcdir)/po-defs $< $@' +- + + + ac_config_files="$ac_config_files Makefile data/Makefile src/Makefile po/Makefile.in" diff --git a/math/qalculate-currency/patches/patch-ab b/math/qalculate-currency/patches/patch-ab new file mode 100644 index 00000000000..c3c1731ed66 --- /dev/null +++ b/math/qalculate-currency/patches/patch-ab @@ -0,0 +1,72 @@ +$NetBSD: patch-ab,v 1.1 2006/06/22 18:52:00 jlam Exp $ + +--- configure.in.orig 2006-04-18 03:13:20.000000000 -0400 ++++ configure.in +@@ -55,6 +55,33 @@ fi + changequote([,])dnl + + ++dnl ------------------------------------- ++dnl | internationalization (i18n) support |------------------------------------ ++dnl ------------------------------------- ++ ++GETTEXT_PACKAGE=qalculate-currency ++AC_SUBST(GETTEXT_PACKAGE) ++AC_DEFINE_UNQUOTED(GETTEXT_PACKAGE,"$GETTEXT_PACKAGE",[The package name for gettext]) ++ ++dnl Please keep this in alphabetical order ++ALL_LINGUAS="nl sv" ++AM_GLIB_GNU_GETTEXT ++ ++dnl AM_GLIB_GNU_GETTEXT sets $DATADIRNAME ++AC_MSG_CHECKING(locale directory) ++if test "x$prefix" = "xNONE"; then ++ PACKAGE_LOCALE_DIR=$ac_default_prefix/share/locale ++else ++ PACKAGE_LOCALE_DIR=$prefix/share/locale ++fi ++ ++AC_DEFINE_UNQUOTED(PACKAGE_LOCALE_DIR, "$PACKAGE_LOCALE_DIR", ++ [The directory in which qalculate's locale data will be stored]) ++ AC_MSG_RESULT("$PACKAGE_LOCALE_DIR") ++ ++INTLTOOL_QALCULATE_DEFINITIONS_RULE='%.xml: %.xml.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po-defs/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -x -u -c $(top_builddir)/po-defs/.intltool-merge-cache $(top_srcdir)/po-defs $< [$]@' ++AC_SUBST(INTLTOOL_QALCULATE_DEFINITIONS_RULE) ++ + dnl -------------------------------- + dnl | check for neccessary libraries |----------------------------------------- + dnl -------------------------------- +@@ -89,33 +116,6 @@ PKG_CHECK_MODULES(QALCULATE, [ + AC_SUBST(QALCULATE_CFLAGS) + AC_SUBST(QALCULATE_LIBS) + +-dnl ------------------------------------- +-dnl | internationalization (i18n) support |------------------------------------ +-dnl ------------------------------------- +- +-GETTEXT_PACKAGE=qalculate-currency +-AC_SUBST(GETTEXT_PACKAGE) +-AC_DEFINE_UNQUOTED(GETTEXT_PACKAGE,"$GETTEXT_PACKAGE",[The package name for gettext]) +- +-dnl Please keep this in alphabetical order +-ALL_LINGUAS="nl sv" +-AM_GLIB_GNU_GETTEXT +- +-dnl AM_GLIB_GNU_GETTEXT sets $DATADIRNAME +-AC_MSG_CHECKING(locale directory) +-if test "x$prefix" = "xNONE"; then +- PACKAGE_LOCALE_DIR=$ac_default_prefix/share/locale +-else +- PACKAGE_LOCALE_DIR=$prefix/share/locale +-fi +- +-AC_DEFINE_UNQUOTED(PACKAGE_LOCALE_DIR, "$PACKAGE_LOCALE_DIR", +- [The directory in which qalculate's locale data will be stored]) +- AC_MSG_RESULT("$PACKAGE_LOCALE_DIR") +- +-INTLTOOL_QALCULATE_DEFINITIONS_RULE='%.xml: %.xml.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po-defs/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -x -u -c $(top_builddir)/po-defs/.intltool-merge-cache $(top_srcdir)/po-defs $< [$]@' +-AC_SUBST(INTLTOOL_QALCULATE_DEFINITIONS_RULE) +- + dnl -------- + dnl | output |----------------------------------------------------------------- + dnl -------- diff --git a/math/qalculate-gtk/distinfo b/math/qalculate-gtk/distinfo index 0e8f34e4cac..fc96c29c18c 100644 --- a/math/qalculate-gtk/distinfo +++ b/math/qalculate-gtk/distinfo @@ -1,6 +1,8 @@ -$NetBSD: distinfo,v 1.6 2006/06/14 20:14:21 adam Exp $ +$NetBSD: distinfo,v 1.7 2006/06/22 18:52:00 jlam Exp $ SHA1 (qalculate-gtk-0.9.4.tar.gz) = 1cf5219d7f5c5375468e521a0784eb186ebe1253 RMD160 (qalculate-gtk-0.9.4.tar.gz) = 3cf72bc37e04548f7174909648dcee43c1c18dff Size (qalculate-gtk-0.9.4.tar.gz) = 1546220 bytes SHA1 (patch-aa) = a8f186eb76a16d6f2b6329da50a2bbd07994414c +SHA1 (patch-ab) = 0c814667e326b0660f98dcceea6e569ccd182084 +SHA1 (patch-ac) = a28ab9767be4e7a46ac32a284c1040ee9cdaf695 diff --git a/math/qalculate-gtk/patches/patch-ab b/math/qalculate-gtk/patches/patch-ab new file mode 100644 index 00000000000..20a456a55ca --- /dev/null +++ b/math/qalculate-gtk/patches/patch-ab @@ -0,0 +1,4437 @@ +$NetBSD: patch-ab,v 1.1 2006/06/22 18:52:00 jlam Exp $ + +--- configure.orig 2006-06-01 16:56:35.000000000 -0400 ++++ configure +@@ -20089,31 +20089,184 @@ fi + + + +-echo "$as_me:$LINENO: checking for pthread_create in -lpthread" >&5 +-echo $ECHO_N "checking for pthread_create in -lpthread... $ECHO_C" >&6 +-if test "${ac_cv_lib_pthread_pthread_create+set}" = set; then ++GETTEXT_PACKAGE=qalculate-gtk ++ ++ ++cat >>confdefs.h <<_ACEOF ++#define GETTEXT_PACKAGE "$GETTEXT_PACKAGE" ++_ACEOF ++ ++ ++ALL_LINGUAS="nl sv" ++ ++ ++ ++for ac_header in locale.h ++do ++as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh` ++if eval "test \"\${$as_ac_Header+set}\" = set"; then ++ echo "$as_me:$LINENO: checking for $ac_header" >&5 ++echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6 ++if eval "test \"\${$as_ac_Header+set}\" = set"; then + echo $ECHO_N "(cached) $ECHO_C" >&6 ++fi ++echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5 ++echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6 + else +- ac_check_lib_save_LIBS=$LIBS +-LIBS="-lpthread $LIBS" ++ # Is the header compilable? ++echo "$as_me:$LINENO: checking $ac_header usability" >&5 ++echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6 + cat >conftest.$ac_ext <<_ACEOF + /* confdefs.h. */ + _ACEOF + cat confdefs.h >>conftest.$ac_ext + cat >>conftest.$ac_ext <<_ACEOF + /* end confdefs.h. */ ++$ac_includes_default ++#include <$ac_header> ++_ACEOF ++rm -f conftest.$ac_objext ++if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 ++ (eval $ac_compile) 2>conftest.er1 ++ ac_status=$? ++ grep -v '^ *+' conftest.er1 >conftest.err ++ rm -f conftest.er1 ++ cat conftest.err >&5 ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); } && ++ { ac_try='test -z "$ac_cxx_werror_flag" ++ || test ! -s conftest.err' ++ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 ++ (eval $ac_try) 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; } && ++ { ac_try='test -s conftest.$ac_objext' ++ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 ++ (eval $ac_try) 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; }; then ++ ac_header_compiler=yes ++else ++ echo "$as_me: failed program was:" >&5 ++sed 's/^/| /' conftest.$ac_ext >&5 + +-/* Override any gcc2 internal prototype to avoid an error. */ +-#ifdef __cplusplus +-extern "C" +-#endif +-/* We use char because int might match the return type of a gcc2 +- builtin and then its argument prototype would still apply. */ +-char pthread_create (); ++ac_header_compiler=no ++fi ++rm -f conftest.err conftest.$ac_objext conftest.$ac_ext ++echo "$as_me:$LINENO: result: $ac_header_compiler" >&5 ++echo "${ECHO_T}$ac_header_compiler" >&6 ++ ++# Is the header present? ++echo "$as_me:$LINENO: checking $ac_header presence" >&5 ++echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6 ++cat >conftest.$ac_ext <<_ACEOF ++/* confdefs.h. */ ++_ACEOF ++cat confdefs.h >>conftest.$ac_ext ++cat >>conftest.$ac_ext <<_ACEOF ++/* end confdefs.h. */ ++#include <$ac_header> ++_ACEOF ++if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5 ++ (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 ++ ac_status=$? ++ grep -v '^ *+' conftest.er1 >conftest.err ++ rm -f conftest.er1 ++ cat conftest.err >&5 ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); } >/dev/null; then ++ if test -s conftest.err; then ++ ac_cpp_err=$ac_cxx_preproc_warn_flag ++ ac_cpp_err=$ac_cpp_err$ac_cxx_werror_flag ++ else ++ ac_cpp_err= ++ fi ++else ++ ac_cpp_err=yes ++fi ++if test -z "$ac_cpp_err"; then ++ ac_header_preproc=yes ++else ++ echo "$as_me: failed program was:" >&5 ++sed 's/^/| /' conftest.$ac_ext >&5 ++ ++ ac_header_preproc=no ++fi ++rm -f conftest.err conftest.$ac_ext ++echo "$as_me:$LINENO: result: $ac_header_preproc" >&5 ++echo "${ECHO_T}$ac_header_preproc" >&6 ++ ++# So? What about this header? ++case $ac_header_compiler:$ac_header_preproc:$ac_cxx_preproc_warn_flag in ++ yes:no: ) ++ { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5 ++echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;} ++ { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5 ++echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;} ++ ac_header_preproc=yes ++ ;; ++ no:yes:* ) ++ { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5 ++echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;} ++ { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5 ++echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;} ++ { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5 ++echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;} ++ { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5 ++echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;} ++ { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5 ++echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;} ++ { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5 ++echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;} ++ ( ++ cat <<\_ASBOX ++## ------------------------------------------ ## ++## Report this to the AC_PACKAGE_NAME lists. ## ++## ------------------------------------------ ## ++_ASBOX ++ ) | ++ sed "s/^/$as_me: WARNING: /" >&2 ++ ;; ++esac ++echo "$as_me:$LINENO: checking for $ac_header" >&5 ++echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6 ++if eval "test \"\${$as_ac_Header+set}\" = set"; then ++ echo $ECHO_N "(cached) $ECHO_C" >&6 ++else ++ eval "$as_ac_Header=\$ac_header_preproc" ++fi ++echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5 ++echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6 ++ ++fi ++if test `eval echo '${'$as_ac_Header'}'` = yes; then ++ cat >>confdefs.h <<_ACEOF ++#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1 ++_ACEOF ++ ++fi ++ ++done ++ ++ if test $ac_cv_header_locale_h = yes; then ++ echo "$as_me:$LINENO: checking for LC_MESSAGES" >&5 ++echo $ECHO_N "checking for LC_MESSAGES... $ECHO_C" >&6 ++if test "${am_cv_val_LC_MESSAGES+set}" = set; then ++ echo $ECHO_N "(cached) $ECHO_C" >&6 ++else ++ cat >conftest.$ac_ext <<_ACEOF ++/* confdefs.h. */ ++_ACEOF ++cat confdefs.h >>conftest.$ac_ext ++cat >>conftest.$ac_ext <<_ACEOF ++/* end confdefs.h. */ ++#include + int + main () + { +-pthread_create (); ++return LC_MESSAGES + ; + return 0; + } +@@ -20127,7 +20280,7 @@ if { (eval echo "$as_me:$LINENO: \"$ac_l + cat conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } && +- { ac_try='test -z "$ac_c_werror_flag" ++ { ac_try='test -z "$ac_cxx_werror_flag" + || test ! -s conftest.err' + { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 +@@ -20140,1114 +20293,441 @@ if { (eval echo "$as_me:$LINENO: \"$ac_l + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then +- ac_cv_lib_pthread_pthread_create=yes ++ am_cv_val_LC_MESSAGES=yes + else + echo "$as_me: failed program was:" >&5 + sed 's/^/| /' conftest.$ac_ext >&5 + +-ac_cv_lib_pthread_pthread_create=no ++am_cv_val_LC_MESSAGES=no + fi + rm -f conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +-LIBS=$ac_check_lib_save_LIBS +-fi +-echo "$as_me:$LINENO: result: $ac_cv_lib_pthread_pthread_create" >&5 +-echo "${ECHO_T}$ac_cv_lib_pthread_pthread_create" >&6 +-if test $ac_cv_lib_pthread_pthread_create = yes; then +- LIBS="$LIBS -lpthread" + fi ++echo "$as_me:$LINENO: result: $am_cv_val_LC_MESSAGES" >&5 ++echo "${ECHO_T}$am_cv_val_LC_MESSAGES" >&6 ++ if test $am_cv_val_LC_MESSAGES = yes; then + ++cat >>confdefs.h <<\_ACEOF ++#define HAVE_LC_MESSAGES 1 ++_ACEOF + +-ac_ext=cc +-ac_cpp='$CXXCPP $CPPFLAGS' +-ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' +-ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +-ac_compiler_gnu=$ac_cv_cxx_compiler_gnu +- +- +- +-# Check whether --with-cln-prefix or --without-cln-prefix was given. +-if test "${with_cln_prefix+set}" = set; then +- withval="$with_cln_prefix" +- cln_config_prefix="$withval" +-else +- cln_config_prefix="" +-fi; ++ fi ++ fi ++ USE_NLS=yes + +-# Check whether --with-cln-exec-prefix or --without-cln-exec-prefix was given. +-if test "${with_cln_exec_prefix+set}" = set; then +- withval="$with_cln_exec_prefix" +- cln_config_exec_prefix="$withval" +-else +- cln_config_exec_prefix="" +-fi; +-# Check whether --enable-clntest or --disable-clntest was given. +-if test "${enable_clntest+set}" = set; then +- enableval="$enable_clntest" + +-else +- enable_clntest=yes +-fi; ++ gt_cv_have_gettext=no + +-if test x$cln_config_exec_prefix != x ; then +- cln_config_args="$cln_config_args --exec-prefix=$cln_config_exec_prefix" +- if test x${CLN_CONFIG+set} != xset ; then +- CLN_CONFIG=$cln_config_exec_prefix/bin/cln-config +- fi +-fi +-if test x$cln_config_prefix != x ; then +- cln_config_args="$cln_config_args --prefix=$cln_config_prefix" +- if test x${CLN_CONFIG+set} != xset ; then +- CLN_CONFIG=$cln_config_prefix/bin/cln-config +- fi +-fi ++ CATOBJEXT=NONE ++ XGETTEXT=: ++ INTLLIBS= + +-# Extract the first word of "cln-config", so it can be a program name with args. +-set dummy cln-config; ac_word=$2 +-echo "$as_me:$LINENO: checking for $ac_word" >&5 +-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 +-if test "${ac_cv_path_CLN_CONFIG+set}" = set; then ++ if test "${ac_cv_header_libintl_h+set}" = set; then ++ echo "$as_me:$LINENO: checking for libintl.h" >&5 ++echo $ECHO_N "checking for libintl.h... $ECHO_C" >&6 ++if test "${ac_cv_header_libintl_h+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 ++fi ++echo "$as_me:$LINENO: result: $ac_cv_header_libintl_h" >&5 ++echo "${ECHO_T}$ac_cv_header_libintl_h" >&6 + else +- case $CLN_CONFIG in +- [\\/]* | ?:[\\/]*) +- ac_cv_path_CLN_CONFIG="$CLN_CONFIG" # Let the user override the test with a path. +- ;; +- *) +- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +-for as_dir in $PATH +-do +- IFS=$as_save_IFS +- test -z "$as_dir" && as_dir=. +- for ac_exec_ext in '' $ac_executable_extensions; do +- if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then +- ac_cv_path_CLN_CONFIG="$as_dir/$ac_word$ac_exec_ext" +- echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 +- break 2 +- fi +-done +-done +- +- test -z "$ac_cv_path_CLN_CONFIG" && ac_cv_path_CLN_CONFIG="no" +- ;; +-esac +-fi +-CLN_CONFIG=$ac_cv_path_CLN_CONFIG +- +-if test -n "$CLN_CONFIG"; then +- echo "$as_me:$LINENO: result: $CLN_CONFIG" >&5 +-echo "${ECHO_T}$CLN_CONFIG" >&6 +-else +- echo "$as_me:$LINENO: result: no" >&5 +-echo "${ECHO_T}no" >&6 +-fi +- +-cln_min_version=1.1.0 +-echo "$as_me:$LINENO: checking for CLN - version >= $cln_min_version" >&5 +-echo $ECHO_N "checking for CLN - version >= $cln_min_version... $ECHO_C" >&6 +-if test "$CLN_CONFIG" = "no" ; then +- echo "$as_me:$LINENO: result: no" >&5 +-echo "${ECHO_T}no" >&6 +- echo "*** The cln-config script installed by CLN could not be found" +- echo "*** If CLN was installed in PREFIX, make sure PREFIX/bin is in" +- echo "*** your path, or set the CLN_CONFIG environment variable to the" +- echo "*** full path to cln-config." +- { { echo "$as_me:$LINENO: error: No suitable installed version of CLN could be found." >&5 +-echo "$as_me: error: No suitable installed version of CLN could be found." >&2;} +- { (exit 1); exit 1; }; } +-else +- cln_min_major_version=`echo $cln_min_version | \ +- sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\1/'` +- cln_min_minor_version=`echo $cln_min_version | \ +- sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\2/'` +- cln_min_micro_version=`echo $cln_min_version | \ +- sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\3/'` +- CLN_CPPFLAGS=`$CLN_CONFIG $cln_config_args --cppflags` +- CLN_LIBS=`$CLN_CONFIG $cln_config_args --libs` +- cln_config_version=`$CLN_CONFIG $cln_config_args --version` +- cln_config_major_version=`echo $cln_config_version | \ +- sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\1/'` +- cln_config_minor_version=`echo $cln_config_version | \ +- sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\2/'` +- cln_config_micro_version=`echo $cln_config_version | \ +- sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\3/'` +- if test \( $cln_config_major_version -lt $cln_min_major_version \) -o \ +- \( $cln_config_major_version -eq $cln_min_major_version -a $cln_config_minor_version -lt $cln_min_minor_version \) -o \ +- \( $cln_config_major_version -eq $cln_min_major_version -a $cln_config_minor_version -eq $cln_min_minor_version -a $cln_config_micro_version -lt $cln_min_micro_version \); then +- echo -e "\n*** 'cln-config --version' returned $cln_config_major_version.$cln_config_minor_version.$cln_config_micro_version, but the minimum version" +- echo "*** of CLN required is $cln_min_major_version.$cln_min_minor_version.$cln_min_micro_version. If cln-config is correct, then it is" +- echo "*** best to upgrade to the required version." +- echo "*** If cln-config was wrong, set the environment variable CLN_CONFIG" +- echo "*** to point to the correct copy of cln-config, and remove the file" +- echo "*** config.cache before re-running configure." +- { { echo "$as_me:$LINENO: error: No suitable installed version of CLN could be found." >&5 +-echo "$as_me: error: No suitable installed version of CLN could be found." >&2;} +- { (exit 1); exit 1; }; } +- else +- no_cln="" +- if test "x$enable_clntest" = "xyes" ; then +- ac_save_CPPFLAGS="$CPPFLAGS" +- ac_save_LIBS="$LIBS" +- CPPFLAGS="$CPPFLAGS $CLN_CPPFLAGS" +- LIBS="$LIBS $CLN_LIBS" +- rm -f conf.clntest +- if test "$cross_compiling" = yes; then +- echo $ac_n "cross compiling; assumed OK... $ac_c" +-else +- cat >conftest.$ac_ext <<_ACEOF ++ # Is the header compilable? ++echo "$as_me:$LINENO: checking libintl.h usability" >&5 ++echo $ECHO_N "checking libintl.h usability... $ECHO_C" >&6 ++cat >conftest.$ac_ext <<_ACEOF + /* confdefs.h. */ + _ACEOF + cat confdefs.h >>conftest.$ac_ext + cat >>conftest.$ac_ext <<_ACEOF + /* end confdefs.h. */ +- +-#include +-#include +-#include +- +-/* we do not #include because autoconf in C++ mode inserts a +- prototype for exit() that conflicts with the one in stdlib.h */ +-extern "C" int system(const char *); +- +-int main(void) +-{ +- system("touch conf.clntest"); +- +- if ((CL_VERSION_MAJOR != $cln_config_major_version) || +- (CL_VERSION_MINOR != $cln_config_minor_version) || +- (CL_VERSION_PATCHLEVEL != $cln_config_micro_version)) { +- printf("\n*** 'cln-config --version' returned %d.%d.%d, but the header file I found\n", $cln_config_major_version, $cln_config_minor_version, $cln_config_micro_version); +- printf("*** corresponds to %d.%d.%d. This mismatch suggests your installation of CLN\n", CL_VERSION_MAJOR, CL_VERSION_MINOR, CL_VERSION_PATCHLEVEL); +- printf("*** is corrupted or you have specified some wrong -I compiler flags.\n"); +- printf("*** Please inquire and consider reinstalling CLN.\n"); +- return 1; +- } +- if ((cln::version_major != $cln_config_major_version) || +- (cln::version_minor != $cln_config_minor_version) || +- (cln::version_patchlevel != $cln_config_micro_version)) { +- printf("\n*** 'cln-config --version' returned %d.%d.%d, but the library I found\n", $cln_config_major_version, $cln_config_minor_version, $cln_config_micro_version); +- printf("*** corresponds to %d.%d.%d. This mismatch suggests your installation of CLN\n", cln::version_major, cln::version_minor, cln::version_patchlevel); +- printf("*** is corrupted or you have specified some wrong -L compiler flags.\n"); +- printf("*** Please inquire and consider reinstalling CLN.\n"); +- return 1; +- } +- return 0; +-} +- ++$ac_includes_default ++#include + _ACEOF +-rm -f conftest$ac_exeext +-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 +- (eval $ac_link) 2>&5 ++rm -f conftest.$ac_objext ++if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 ++ (eval $ac_compile) 2>conftest.er1 + ac_status=$? ++ grep -v '^ *+' conftest.er1 >conftest.err ++ rm -f conftest.er1 ++ cat conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); } && { ac_try='./conftest$ac_exeext' ++ (exit $ac_status); } && ++ { ac_try='test -z "$ac_cxx_werror_flag" ++ || test ! -s conftest.err' ++ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 ++ (eval $ac_try) 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; } && ++ { ac_try='test -s conftest.$ac_objext' + { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then +- : ++ ac_header_compiler=yes + else +- echo "$as_me: program exited with status $ac_status" >&5 +-echo "$as_me: failed program was:" >&5 ++ echo "$as_me: failed program was:" >&5 + sed 's/^/| /' conftest.$ac_ext >&5 + +-( exit $ac_status ) +-no_cln=yes +-fi +-rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext ++ac_header_compiler=no + fi +- CPPFLAGS="$ac_save_CPPFLAGS" +- LIBS="$ac_save_LIBS" +- fi +- if test "x$no_cln" = x ; then +- echo "$as_me:$LINENO: result: yes, $cln_config_version" >&5 +-echo "${ECHO_T}yes, $cln_config_version" >&6 +- +- LIBS="$LIBS $CLN_LIBS" +- CPPFLAGS="$CPPFLAGS $CLN_CPPFLAGS" +- +-cat >>confdefs.h <<\_ACEOF +-#define HAVE_LIBCLN 1 +-_ACEOF +- ++rm -f conftest.err conftest.$ac_objext conftest.$ac_ext ++echo "$as_me:$LINENO: result: $ac_header_compiler" >&5 ++echo "${ECHO_T}$ac_header_compiler" >&6 + +- else +- echo "$as_me:$LINENO: result: no" >&5 +-echo "${ECHO_T}no" >&6 +- if test ! -f conf.clntest ; then +- echo "*** Could not run CLN test program, checking why..." +- CPPFLAGS="$CFLAGS $CLN_CPPFLAGS" +- LIBS="$LIBS $CLN_LIBS" +- cat >conftest.$ac_ext <<_ACEOF ++# Is the header present? ++echo "$as_me:$LINENO: checking libintl.h presence" >&5 ++echo $ECHO_N "checking libintl.h presence... $ECHO_C" >&6 ++cat >conftest.$ac_ext <<_ACEOF + /* confdefs.h. */ + _ACEOF + cat confdefs.h >>conftest.$ac_ext + cat >>conftest.$ac_ext <<_ACEOF + /* end confdefs.h. */ +- +-#include +-#include +- +-int +-main () +-{ +- return 0; +- ; +- return 0; +-} ++#include + _ACEOF +-rm -f conftest.$ac_objext conftest$ac_exeext +-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 +- (eval $ac_link) 2>conftest.er1 ++if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5 ++ (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 + ac_status=$? + grep -v '^ *+' conftest.er1 >conftest.err + rm -f conftest.er1 + cat conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); } && +- { ac_try='test -z "$ac_cxx_werror_flag" +- || test ! -s conftest.err' +- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 +- (eval $ac_try) 2>&5 +- ac_status=$? +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; } && +- { ac_try='test -s conftest$ac_exeext' +- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 +- (eval $ac_try) 2>&5 +- ac_status=$? +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; }; then +- echo "*** The test program compiled, but did not run. This usually means" +- echo "*** that the run-time linker is not finding CLN or finding the wrong" +- echo "*** version of CLN. If it is not finding CLN, you'll need to set your" +- echo "*** LD_LIBRARY_PATH environment variable, or edit /etc/ld.so.conf to point" +- echo "*** to the installed location. Also, make sure you have run ldconfig if that" +- echo "*** is required on your system." ++ (exit $ac_status); } >/dev/null; then ++ if test -s conftest.err; then ++ ac_cpp_err=$ac_cxx_preproc_warn_flag ++ ac_cpp_err=$ac_cpp_err$ac_cxx_werror_flag ++ else ++ ac_cpp_err= ++ fi ++else ++ ac_cpp_err=yes ++fi ++if test -z "$ac_cpp_err"; then ++ ac_header_preproc=yes + else + echo "$as_me: failed program was:" >&5 + sed 's/^/| /' conftest.$ac_ext >&5 + +- echo "*** The test program failed to compile or link. See the file config.log for the" +- echo "*** exact error that occured. This usually means CLN was incorrectly installed" +- echo "*** or that you have moved CLN since it was installed. In the latter case, you" +- echo "*** may want to edit the cln-config script: $CLN_CONFIG." +-fi +-rm -f conftest.err conftest.$ac_objext \ +- conftest$ac_exeext conftest.$ac_ext +- CPPFLAGS="$ac_save_CPPFLAGS" +- LIBS="$ac_save_LIBS" +- fi +- CLN_CPPFLAGS="" +- CLN_LIBS="" +- { { echo "$as_me:$LINENO: error: No suitable installed version of CLN could be found." >&5 +-echo "$as_me: error: No suitable installed version of CLN could be found." >&2;} +- { (exit 1); exit 1; }; } +- fi +- fi ++ ac_header_preproc=no + fi ++rm -f conftest.err conftest.$ac_ext ++echo "$as_me:$LINENO: result: $ac_header_preproc" >&5 ++echo "${ECHO_T}$ac_header_preproc" >&6 + +- +-rm -f conf.clntest +- +- +- +- +-if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then +- if test -n "$ac_tool_prefix"; then +- # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args. +-set dummy ${ac_tool_prefix}pkg-config; ac_word=$2 +-echo "$as_me:$LINENO: checking for $ac_word" >&5 +-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 +-if test "${ac_cv_path_PKG_CONFIG+set}" = set; then ++# So? What about this header? ++case $ac_header_compiler:$ac_header_preproc:$ac_cxx_preproc_warn_flag in ++ yes:no: ) ++ { echo "$as_me:$LINENO: WARNING: libintl.h: accepted by the compiler, rejected by the preprocessor!" >&5 ++echo "$as_me: WARNING: libintl.h: accepted by the compiler, rejected by the preprocessor!" >&2;} ++ { echo "$as_me:$LINENO: WARNING: libintl.h: proceeding with the compiler's result" >&5 ++echo "$as_me: WARNING: libintl.h: proceeding with the compiler's result" >&2;} ++ ac_header_preproc=yes ++ ;; ++ no:yes:* ) ++ { echo "$as_me:$LINENO: WARNING: libintl.h: present but cannot be compiled" >&5 ++echo "$as_me: WARNING: libintl.h: present but cannot be compiled" >&2;} ++ { echo "$as_me:$LINENO: WARNING: libintl.h: check for missing prerequisite headers?" >&5 ++echo "$as_me: WARNING: libintl.h: check for missing prerequisite headers?" >&2;} ++ { echo "$as_me:$LINENO: WARNING: libintl.h: see the Autoconf documentation" >&5 ++echo "$as_me: WARNING: libintl.h: see the Autoconf documentation" >&2;} ++ { echo "$as_me:$LINENO: WARNING: libintl.h: section \"Present But Cannot Be Compiled\"" >&5 ++echo "$as_me: WARNING: libintl.h: section \"Present But Cannot Be Compiled\"" >&2;} ++ { echo "$as_me:$LINENO: WARNING: libintl.h: proceeding with the preprocessor's result" >&5 ++echo "$as_me: WARNING: libintl.h: proceeding with the preprocessor's result" >&2;} ++ { echo "$as_me:$LINENO: WARNING: libintl.h: in the future, the compiler will take precedence" >&5 ++echo "$as_me: WARNING: libintl.h: in the future, the compiler will take precedence" >&2;} ++ ( ++ cat <<\_ASBOX ++## ------------------------------------------ ## ++## Report this to the AC_PACKAGE_NAME lists. ## ++## ------------------------------------------ ## ++_ASBOX ++ ) | ++ sed "s/^/$as_me: WARNING: /" >&2 ++ ;; ++esac ++echo "$as_me:$LINENO: checking for libintl.h" >&5 ++echo $ECHO_N "checking for libintl.h... $ECHO_C" >&6 ++if test "${ac_cv_header_libintl_h+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 + else +- case $PKG_CONFIG in +- [\\/]* | ?:[\\/]*) +- ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path. +- ;; +- *) +- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +-for as_dir in $PATH +-do +- IFS=$as_save_IFS +- test -z "$as_dir" && as_dir=. +- for ac_exec_ext in '' $ac_executable_extensions; do +- if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then +- ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" +- echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 +- break 2 +- fi +-done +-done +- +- ;; +-esac ++ ac_cv_header_libintl_h=$ac_header_preproc + fi +-PKG_CONFIG=$ac_cv_path_PKG_CONFIG ++echo "$as_me:$LINENO: result: $ac_cv_header_libintl_h" >&5 ++echo "${ECHO_T}$ac_cv_header_libintl_h" >&6 + +-if test -n "$PKG_CONFIG"; then +- echo "$as_me:$LINENO: result: $PKG_CONFIG" >&5 +-echo "${ECHO_T}$PKG_CONFIG" >&6 +-else +- echo "$as_me:$LINENO: result: no" >&5 +-echo "${ECHO_T}no" >&6 + fi ++if test $ac_cv_header_libintl_h = yes; then ++ gt_cv_func_dgettext_libintl="no" ++ libintl_extra_libs="" + +-fi +-if test -z "$ac_cv_path_PKG_CONFIG"; then +- ac_pt_PKG_CONFIG=$PKG_CONFIG +- # Extract the first word of "pkg-config", so it can be a program name with args. +-set dummy pkg-config; ac_word=$2 +-echo "$as_me:$LINENO: checking for $ac_word" >&5 +-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 +-if test "${ac_cv_path_ac_pt_PKG_CONFIG+set}" = set; then ++ # ++ # First check in libc ++ # ++ echo "$as_me:$LINENO: checking for ngettext in libc" >&5 ++echo $ECHO_N "checking for ngettext in libc... $ECHO_C" >&6 ++if test "${gt_cv_func_ngettext_libc+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 + else +- case $ac_pt_PKG_CONFIG in +- [\\/]* | ?:[\\/]*) +- ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path. +- ;; +- *) +- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +-for as_dir in $PATH +-do +- IFS=$as_save_IFS +- test -z "$as_dir" && as_dir=. +- for ac_exec_ext in '' $ac_executable_extensions; do +- if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then +- ac_cv_path_ac_pt_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" +- echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 +- break 2 +- fi +-done +-done ++ cat >conftest.$ac_ext <<_ACEOF ++/* confdefs.h. */ ++_ACEOF ++cat confdefs.h >>conftest.$ac_ext ++cat >>conftest.$ac_ext <<_ACEOF ++/* end confdefs.h. */ + +- ;; +-esac +-fi +-ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG ++#include + +-if test -n "$ac_pt_PKG_CONFIG"; then +- echo "$as_me:$LINENO: result: $ac_pt_PKG_CONFIG" >&5 +-echo "${ECHO_T}$ac_pt_PKG_CONFIG" >&6 ++int ++main () ++{ ++return !ngettext ("","", 1) ++ ; ++ return 0; ++} ++_ACEOF ++rm -f conftest.$ac_objext conftest$ac_exeext ++if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 ++ (eval $ac_link) 2>conftest.er1 ++ ac_status=$? ++ grep -v '^ *+' conftest.er1 >conftest.err ++ rm -f conftest.er1 ++ cat conftest.err >&5 ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); } && ++ { ac_try='test -z "$ac_cxx_werror_flag" ++ || test ! -s conftest.err' ++ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 ++ (eval $ac_try) 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; } && ++ { ac_try='test -s conftest$ac_exeext' ++ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 ++ (eval $ac_try) 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; }; then ++ gt_cv_func_ngettext_libc=yes + else +- echo "$as_me:$LINENO: result: no" >&5 +-echo "${ECHO_T}no" >&6 +-fi ++ echo "$as_me: failed program was:" >&5 ++sed 's/^/| /' conftest.$ac_ext >&5 + +- PKG_CONFIG=$ac_pt_PKG_CONFIG +-else +- PKG_CONFIG="$ac_cv_path_PKG_CONFIG" ++gt_cv_func_ngettext_libc=no + fi ++rm -f conftest.err conftest.$ac_objext \ ++ conftest$ac_exeext conftest.$ac_ext + + fi +-if test -n "$PKG_CONFIG"; then +- _pkg_min_version=0.9.0 +- echo "$as_me:$LINENO: checking pkg-config is at least version $_pkg_min_version" >&5 +-echo $ECHO_N "checking pkg-config is at least version $_pkg_min_version... $ECHO_C" >&6 +- if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then +- echo "$as_me:$LINENO: result: yes" >&5 +-echo "${ECHO_T}yes" >&6 +- else +- echo "$as_me:$LINENO: result: no" >&5 +-echo "${ECHO_T}no" >&6 +- PKG_CONFIG="" +- fi ++echo "$as_me:$LINENO: result: $gt_cv_func_ngettext_libc" >&5 ++echo "${ECHO_T}$gt_cv_func_ngettext_libc" >&6 + +-fi ++ if test "$gt_cv_func_ngettext_libc" = "yes" ; then ++ echo "$as_me:$LINENO: checking for dgettext in libc" >&5 ++echo $ECHO_N "checking for dgettext in libc... $ECHO_C" >&6 ++if test "${gt_cv_func_dgettext_libc+set}" = set; then ++ echo $ECHO_N "(cached) $ECHO_C" >&6 ++else ++ cat >conftest.$ac_ext <<_ACEOF ++/* confdefs.h. */ ++_ACEOF ++cat confdefs.h >>conftest.$ac_ext ++cat >>conftest.$ac_ext <<_ACEOF ++/* end confdefs.h. */ + +-pkg_failed=no +-echo "$as_me:$LINENO: checking for GLIB" >&5 +-echo $ECHO_N "checking for GLIB... $ECHO_C" >&6 ++#include + +-if test -n "$PKG_CONFIG"; then +- if test -n "$GLIB_CFLAGS"; then +- pkg_cv_GLIB_CFLAGS="$GLIB_CFLAGS" +- else +- if test -n "$PKG_CONFIG" && \ +- { (echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \" +- glib-2.0 >= 2.4 +- libxml-2.0 +- \"") >&5 +- ($PKG_CONFIG --exists --print-errors " +- glib-2.0 >= 2.4 +- libxml-2.0 +- ") 2>&5 ++int ++main () ++{ ++return !dgettext ("","") ++ ; ++ return 0; ++} ++_ACEOF ++rm -f conftest.$ac_objext conftest$ac_exeext ++if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 ++ (eval $ac_link) 2>conftest.er1 + ac_status=$? ++ grep -v '^ *+' conftest.er1 >conftest.err ++ rm -f conftest.er1 ++ cat conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; then +- pkg_cv_GLIB_CFLAGS=`$PKG_CONFIG --cflags " +- glib-2.0 >= 2.4 +- libxml-2.0 +- " 2>/dev/null` +-else +- pkg_failed=yes +-fi +- fi +-else +- pkg_failed=untried +-fi +-if test -n "$PKG_CONFIG"; then +- if test -n "$GLIB_LIBS"; then +- pkg_cv_GLIB_LIBS="$GLIB_LIBS" +- else +- if test -n "$PKG_CONFIG" && \ +- { (echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \" +- glib-2.0 >= 2.4 +- libxml-2.0 +- \"") >&5 +- ($PKG_CONFIG --exists --print-errors " +- glib-2.0 >= 2.4 +- libxml-2.0 +- ") 2>&5 ++ (exit $ac_status); } && ++ { ac_try='test -z "$ac_cxx_werror_flag" ++ || test ! -s conftest.err' ++ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 ++ (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; then +- pkg_cv_GLIB_LIBS=`$PKG_CONFIG --libs " +- glib-2.0 >= 2.4 +- libxml-2.0 +- " 2>/dev/null` +-else +- pkg_failed=yes +-fi +- fi ++ (exit $ac_status); }; } && ++ { ac_try='test -s conftest$ac_exeext' ++ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 ++ (eval $ac_try) 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; }; then ++ gt_cv_func_dgettext_libc=yes + else +- pkg_failed=untried +-fi +- +- +- +-if test $pkg_failed = yes; then ++ echo "$as_me: failed program was:" >&5 ++sed 's/^/| /' conftest.$ac_ext >&5 + +-if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then +- _pkg_short_errors_supported=yes +-else +- _pkg_short_errors_supported=no ++gt_cv_func_dgettext_libc=no + fi +- if test $_pkg_short_errors_supported = yes; then +- GLIB_PKG_ERRORS=`$PKG_CONFIG --short-errors --errors-to-stdout --print-errors " +- glib-2.0 >= 2.4 +- libxml-2.0 +- "` +- else +- GLIB_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors " +- glib-2.0 >= 2.4 +- libxml-2.0 +- "` +- fi +- # Put the nasty error message in config.log where it belongs +- echo "$GLIB_PKG_ERRORS" >&5 +- +- { { echo "$as_me:$LINENO: error: Package requirements ( +- glib-2.0 >= 2.4 +- libxml-2.0 +- ) were not met: +- +-$GLIB_PKG_ERRORS +- +-Consider adjusting the PKG_CONFIG_PATH environment variable if you +-installed software in a non-standard prefix. +- +-Alternatively, you may set the environment variables GLIB_CFLAGS +-and GLIB_LIBS to avoid the need to call pkg-config. +-See the pkg-config man page for more details. +-" >&5 +-echo "$as_me: error: Package requirements ( +- glib-2.0 >= 2.4 +- libxml-2.0 +- ) were not met: +- +-$GLIB_PKG_ERRORS +- +-Consider adjusting the PKG_CONFIG_PATH environment variable if you +-installed software in a non-standard prefix. +- +-Alternatively, you may set the environment variables GLIB_CFLAGS +-and GLIB_LIBS to avoid the need to call pkg-config. +-See the pkg-config man page for more details. +-" >&2;} +- { (exit 1); exit 1; }; } +-elif test $pkg_failed = untried; then +- { { echo "$as_me:$LINENO: error: The pkg-config script could not be found or is too old. Make sure it +-is in your PATH or set the PKG_CONFIG environment variable to the full +-path to pkg-config. +- +-Alternatively, you may set the environment variables GLIB_CFLAGS +-and GLIB_LIBS to avoid the need to call pkg-config. +-See the pkg-config man page for more details. ++rm -f conftest.err conftest.$ac_objext \ ++ conftest$ac_exeext conftest.$ac_ext + +-To get pkg-config, see . +-See \`config.log' for more details." >&5 +-echo "$as_me: error: The pkg-config script could not be found or is too old. Make sure it +-is in your PATH or set the PKG_CONFIG environment variable to the full +-path to pkg-config. ++fi ++echo "$as_me:$LINENO: result: $gt_cv_func_dgettext_libc" >&5 ++echo "${ECHO_T}$gt_cv_func_dgettext_libc" >&6 ++ fi + +-Alternatively, you may set the environment variables GLIB_CFLAGS +-and GLIB_LIBS to avoid the need to call pkg-config. +-See the pkg-config man page for more details. ++ if test "$gt_cv_func_ngettext_libc" = "yes" ; then + +-To get pkg-config, see . +-See \`config.log' for more details." >&2;} +- { (exit 1); exit 1; }; } ++for ac_func in bind_textdomain_codeset ++do ++as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh` ++echo "$as_me:$LINENO: checking for $ac_func" >&5 ++echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6 ++if eval "test \"\${$as_ac_var+set}\" = set"; then ++ echo $ECHO_N "(cached) $ECHO_C" >&6 + else +- GLIB_CFLAGS=$pkg_cv_GLIB_CFLAGS +- GLIB_LIBS=$pkg_cv_GLIB_LIBS +- echo "$as_me:$LINENO: result: yes" >&5 +-echo "${ECHO_T}yes" >&6 +- : +-fi +- ++ cat >conftest.$ac_ext <<_ACEOF ++/* confdefs.h. */ ++_ACEOF ++cat confdefs.h >>conftest.$ac_ext ++cat >>conftest.$ac_ext <<_ACEOF ++/* end confdefs.h. */ ++/* Define $ac_func to an innocuous variant, in case declares $ac_func. ++ For example, HP-UX 11i declares gettimeofday. */ ++#define $ac_func innocuous_$ac_func + ++/* System header to define __stub macros and hopefully few prototypes, ++ which can conflict with char $ac_func (); below. ++ Prefer to if __STDC__ is defined, since ++ exists even on freestanding compilers. */ + +-QALCULATE_GTK="qalculate-gtk" +-LN_QALCULATE="qalculate-gtk" ++#ifdef __STDC__ ++# include ++#else ++# include ++#endif + ++#undef $ac_func + +-pkg_failed=no +-echo "$as_me:$LINENO: checking for GTK" >&5 +-echo $ECHO_N "checking for GTK... $ECHO_C" >&6 ++/* Override any gcc2 internal prototype to avoid an error. */ ++#ifdef __cplusplus ++extern "C" ++{ ++#endif ++/* We use char because int might match the return type of a gcc2 ++ builtin and then its argument prototype would still apply. */ ++char $ac_func (); ++/* The GNU C library defines this for functions which it implements ++ to always fail with ENOSYS. Some functions are actually named ++ something starting with __ and the normal name is an alias. */ ++#if defined (__stub_$ac_func) || defined (__stub___$ac_func) ++choke me ++#else ++char (*f) () = $ac_func; ++#endif ++#ifdef __cplusplus ++} ++#endif + +-if test -n "$PKG_CONFIG"; then +- if test -n "$GTK_CFLAGS"; then +- pkg_cv_GTK_CFLAGS="$GTK_CFLAGS" +- else +- if test -n "$PKG_CONFIG" && \ +- { (echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \" +- gtk+-2.0 >= 2.4 +- gdk-pixbuf-2.0 +- libglade-2.0 +- \"") >&5 +- ($PKG_CONFIG --exists --print-errors " +- gtk+-2.0 >= 2.4 +- gdk-pixbuf-2.0 +- libglade-2.0 +- ") 2>&5 ++int ++main () ++{ ++return f != $ac_func; ++ ; ++ return 0; ++} ++_ACEOF ++rm -f conftest.$ac_objext conftest$ac_exeext ++if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 ++ (eval $ac_link) 2>conftest.er1 + ac_status=$? ++ grep -v '^ *+' conftest.er1 >conftest.err ++ rm -f conftest.er1 ++ cat conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; then +- pkg_cv_GTK_CFLAGS=`$PKG_CONFIG --cflags " +- gtk+-2.0 >= 2.4 +- gdk-pixbuf-2.0 +- libglade-2.0 +- " 2>/dev/null` +-else +- pkg_failed=yes +-fi +- fi +-else +- pkg_failed=untried +-fi +-if test -n "$PKG_CONFIG"; then +- if test -n "$GTK_LIBS"; then +- pkg_cv_GTK_LIBS="$GTK_LIBS" +- else +- if test -n "$PKG_CONFIG" && \ +- { (echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \" +- gtk+-2.0 >= 2.4 +- gdk-pixbuf-2.0 +- libglade-2.0 +- \"") >&5 +- ($PKG_CONFIG --exists --print-errors " +- gtk+-2.0 >= 2.4 +- gdk-pixbuf-2.0 +- libglade-2.0 +- ") 2>&5 ++ (exit $ac_status); } && ++ { ac_try='test -z "$ac_cxx_werror_flag" ++ || test ! -s conftest.err' ++ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 ++ (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; then +- pkg_cv_GTK_LIBS=`$PKG_CONFIG --libs " +- gtk+-2.0 >= 2.4 +- gdk-pixbuf-2.0 +- libglade-2.0 +- " 2>/dev/null` ++ (exit $ac_status); }; } && ++ { ac_try='test -s conftest$ac_exeext' ++ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 ++ (eval $ac_try) 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; }; then ++ eval "$as_ac_var=yes" + else +- pkg_failed=yes ++ echo "$as_me: failed program was:" >&5 ++sed 's/^/| /' conftest.$ac_ext >&5 ++ ++eval "$as_ac_var=no" + fi +- fi +-else +- pkg_failed=untried ++rm -f conftest.err conftest.$ac_objext \ ++ conftest$ac_exeext conftest.$ac_ext + fi ++echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5 ++echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6 ++if test `eval echo '${'$as_ac_var'}'` = yes; then ++ cat >>confdefs.h <<_ACEOF ++#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1 ++_ACEOF + ++fi ++done + ++ fi + +-if test $pkg_failed = yes; then +- +-if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then +- _pkg_short_errors_supported=yes +-else +- _pkg_short_errors_supported=no +-fi +- if test $_pkg_short_errors_supported = yes; then +- GTK_PKG_ERRORS=`$PKG_CONFIG --short-errors --errors-to-stdout --print-errors " +- gtk+-2.0 >= 2.4 +- gdk-pixbuf-2.0 +- libglade-2.0 +- "` +- else +- GTK_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors " +- gtk+-2.0 >= 2.4 +- gdk-pixbuf-2.0 +- libglade-2.0 +- "` +- fi +- # Put the nasty error message in config.log where it belongs +- echo "$GTK_PKG_ERRORS" >&5 +- +- { { echo "$as_me:$LINENO: error: Package requirements ( +- gtk+-2.0 >= 2.4 +- gdk-pixbuf-2.0 +- libglade-2.0 +- ) were not met: +- +-$GTK_PKG_ERRORS +- +-Consider adjusting the PKG_CONFIG_PATH environment variable if you +-installed software in a non-standard prefix. +- +-Alternatively, you may set the environment variables GTK_CFLAGS +-and GTK_LIBS to avoid the need to call pkg-config. +-See the pkg-config man page for more details. +-" >&5 +-echo "$as_me: error: Package requirements ( +- gtk+-2.0 >= 2.4 +- gdk-pixbuf-2.0 +- libglade-2.0 +- ) were not met: +- +-$GTK_PKG_ERRORS +- +-Consider adjusting the PKG_CONFIG_PATH environment variable if you +-installed software in a non-standard prefix. +- +-Alternatively, you may set the environment variables GTK_CFLAGS +-and GTK_LIBS to avoid the need to call pkg-config. +-See the pkg-config man page for more details. +-" >&2;} +- { (exit 1); exit 1; }; } +-elif test $pkg_failed = untried; then +- { { echo "$as_me:$LINENO: error: The pkg-config script could not be found or is too old. Make sure it +-is in your PATH or set the PKG_CONFIG environment variable to the full +-path to pkg-config. +- +-Alternatively, you may set the environment variables GTK_CFLAGS +-and GTK_LIBS to avoid the need to call pkg-config. +-See the pkg-config man page for more details. +- +-To get pkg-config, see . +-See \`config.log' for more details." >&5 +-echo "$as_me: error: The pkg-config script could not be found or is too old. Make sure it +-is in your PATH or set the PKG_CONFIG environment variable to the full +-path to pkg-config. +- +-Alternatively, you may set the environment variables GTK_CFLAGS +-and GTK_LIBS to avoid the need to call pkg-config. +-See the pkg-config man page for more details. +- +-To get pkg-config, see . +-See \`config.log' for more details." >&2;} +- { (exit 1); exit 1; }; } +-else +- GTK_CFLAGS=$pkg_cv_GTK_CFLAGS +- GTK_LIBS=$pkg_cv_GTK_LIBS +- echo "$as_me:$LINENO: result: yes" >&5 +-echo "${ECHO_T}yes" >&6 +- : +-fi +- +- +- +-GTK_LIBS="-export-dynamic $GTK_LIBS" +- +- +-pkg_failed=no +-echo "$as_me:$LINENO: checking for QALCULATE" >&5 +-echo $ECHO_N "checking for QALCULATE... $ECHO_C" >&6 +- +-if test -n "$PKG_CONFIG"; then +- if test -n "$QALCULATE_CFLAGS"; then +- pkg_cv_QALCULATE_CFLAGS="$QALCULATE_CFLAGS" +- else +- if test -n "$PKG_CONFIG" && \ +- { (echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \" +- libqalculate >= 0.9.4 +- \"") >&5 +- ($PKG_CONFIG --exists --print-errors " +- libqalculate >= 0.9.4 +- ") 2>&5 +- ac_status=$? +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; then +- pkg_cv_QALCULATE_CFLAGS=`$PKG_CONFIG --cflags " +- libqalculate >= 0.9.4 +- " 2>/dev/null` +-else +- pkg_failed=yes +-fi +- fi +-else +- pkg_failed=untried +-fi +-if test -n "$PKG_CONFIG"; then +- if test -n "$QALCULATE_LIBS"; then +- pkg_cv_QALCULATE_LIBS="$QALCULATE_LIBS" +- else +- if test -n "$PKG_CONFIG" && \ +- { (echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \" +- libqalculate >= 0.9.4 +- \"") >&5 +- ($PKG_CONFIG --exists --print-errors " +- libqalculate >= 0.9.4 +- ") 2>&5 +- ac_status=$? +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; then +- pkg_cv_QALCULATE_LIBS=`$PKG_CONFIG --libs " +- libqalculate >= 0.9.4 +- " 2>/dev/null` +-else +- pkg_failed=yes +-fi +- fi +-else +- pkg_failed=untried +-fi +- +- +- +-if test $pkg_failed = yes; then +- +-if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then +- _pkg_short_errors_supported=yes +-else +- _pkg_short_errors_supported=no +-fi +- if test $_pkg_short_errors_supported = yes; then +- QALCULATE_PKG_ERRORS=`$PKG_CONFIG --short-errors --errors-to-stdout --print-errors " +- libqalculate >= 0.9.4 +- "` +- else +- QALCULATE_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors " +- libqalculate >= 0.9.4 +- "` +- fi +- # Put the nasty error message in config.log where it belongs +- echo "$QALCULATE_PKG_ERRORS" >&5 +- +- { { echo "$as_me:$LINENO: error: Package requirements ( +- libqalculate >= 0.9.4 +- ) were not met: +- +-$QALCULATE_PKG_ERRORS +- +-Consider adjusting the PKG_CONFIG_PATH environment variable if you +-installed software in a non-standard prefix. +- +-Alternatively, you may set the environment variables QALCULATE_CFLAGS +-and QALCULATE_LIBS to avoid the need to call pkg-config. +-See the pkg-config man page for more details. +-" >&5 +-echo "$as_me: error: Package requirements ( +- libqalculate >= 0.9.4 +- ) were not met: +- +-$QALCULATE_PKG_ERRORS +- +-Consider adjusting the PKG_CONFIG_PATH environment variable if you +-installed software in a non-standard prefix. +- +-Alternatively, you may set the environment variables QALCULATE_CFLAGS +-and QALCULATE_LIBS to avoid the need to call pkg-config. +-See the pkg-config man page for more details. +-" >&2;} +- { (exit 1); exit 1; }; } +-elif test $pkg_failed = untried; then +- { { echo "$as_me:$LINENO: error: The pkg-config script could not be found or is too old. Make sure it +-is in your PATH or set the PKG_CONFIG environment variable to the full +-path to pkg-config. +- +-Alternatively, you may set the environment variables QALCULATE_CFLAGS +-and QALCULATE_LIBS to avoid the need to call pkg-config. +-See the pkg-config man page for more details. +- +-To get pkg-config, see . +-See \`config.log' for more details." >&5 +-echo "$as_me: error: The pkg-config script could not be found or is too old. Make sure it +-is in your PATH or set the PKG_CONFIG environment variable to the full +-path to pkg-config. +- +-Alternatively, you may set the environment variables QALCULATE_CFLAGS +-and QALCULATE_LIBS to avoid the need to call pkg-config. +-See the pkg-config man page for more details. +- +-To get pkg-config, see . +-See \`config.log' for more details." >&2;} +- { (exit 1); exit 1; }; } +-else +- QALCULATE_CFLAGS=$pkg_cv_QALCULATE_CFLAGS +- QALCULATE_LIBS=$pkg_cv_QALCULATE_LIBS +- echo "$as_me:$LINENO: result: yes" >&5 +-echo "${ECHO_T}yes" >&6 +- : +-fi +- +- +- +-LIBGNOME_REQUIRED=2.0.0 +-LIBGNOMEUI_REQUIRED=2.0.0 +- +- +-pkg_failed=no +-echo "$as_me:$LINENO: checking for LIBGNOME" >&5 +-echo $ECHO_N "checking for LIBGNOME... $ECHO_C" >&6 +- +-if test -n "$PKG_CONFIG"; then +- if test -n "$LIBGNOME_CFLAGS"; then +- pkg_cv_LIBGNOME_CFLAGS="$LIBGNOME_CFLAGS" +- else +- if test -n "$PKG_CONFIG" && \ +- { (echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \"libgnome-2.0 >= \$LIBGNOME_REQUIRED\"") >&5 +- ($PKG_CONFIG --exists --print-errors "libgnome-2.0 >= $LIBGNOME_REQUIRED") 2>&5 +- ac_status=$? +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; then +- pkg_cv_LIBGNOME_CFLAGS=`$PKG_CONFIG --cflags "libgnome-2.0 >= $LIBGNOME_REQUIRED" 2>/dev/null` +-else +- pkg_failed=yes +-fi +- fi +-else +- pkg_failed=untried +-fi +-if test -n "$PKG_CONFIG"; then +- if test -n "$LIBGNOME_LIBS"; then +- pkg_cv_LIBGNOME_LIBS="$LIBGNOME_LIBS" +- else +- if test -n "$PKG_CONFIG" && \ +- { (echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \"libgnome-2.0 >= \$LIBGNOME_REQUIRED\"") >&5 +- ($PKG_CONFIG --exists --print-errors "libgnome-2.0 >= $LIBGNOME_REQUIRED") 2>&5 +- ac_status=$? +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; then +- pkg_cv_LIBGNOME_LIBS=`$PKG_CONFIG --libs "libgnome-2.0 >= $LIBGNOME_REQUIRED" 2>/dev/null` +-else +- pkg_failed=yes +-fi +- fi +-else +- pkg_failed=untried +-fi +- +- +- +-if test $pkg_failed = yes; then +- +-if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then +- _pkg_short_errors_supported=yes +-else +- _pkg_short_errors_supported=no +-fi +- if test $_pkg_short_errors_supported = yes; then +- LIBGNOME_PKG_ERRORS=`$PKG_CONFIG --short-errors --errors-to-stdout --print-errors "libgnome-2.0 >= $LIBGNOME_REQUIRED"` +- else +- LIBGNOME_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "libgnome-2.0 >= $LIBGNOME_REQUIRED"` +- fi +- # Put the nasty error message in config.log where it belongs +- echo "$LIBGNOME_PKG_ERRORS" >&5 +- +- { echo "$as_me:$LINENO: WARNING: libgnome-2.0 was not found. The manual will not be accessible from within Qalculate!" >&5 +-echo "$as_me: WARNING: libgnome-2.0 was not found. The manual will not be accessible from within Qalculate!" >&2;} +-elif test $pkg_failed = untried; then +- { echo "$as_me:$LINENO: WARNING: libgnome-2.0 was not found. The manual will not be accessible from within Qalculate!" >&5 +-echo "$as_me: WARNING: libgnome-2.0 was not found. The manual will not be accessible from within Qalculate!" >&2;} +-else +- LIBGNOME_CFLAGS=$pkg_cv_LIBGNOME_CFLAGS +- LIBGNOME_LIBS=$pkg_cv_LIBGNOME_LIBS +- echo "$as_me:$LINENO: result: yes" >&5 +-echo "${ECHO_T}yes" >&6 +- +- +- +- +-cat >>confdefs.h <<\_ACEOF +-#define HAVE_LIBGNOME 1 +-_ACEOF +- +- +-fi +- +- +-pkg_failed=no +-echo "$as_me:$LINENO: checking for LIBGNOMEUI" >&5 +-echo $ECHO_N "checking for LIBGNOMEUI... $ECHO_C" >&6 +- +-if test -n "$PKG_CONFIG"; then +- if test -n "$LIBGNOMEUI_CFLAGS"; then +- pkg_cv_LIBGNOMEUI_CFLAGS="$LIBGNOMEUI_CFLAGS" +- else +- if test -n "$PKG_CONFIG" && \ +- { (echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \"libgnomeui-2.0 >= \$LIBGNOMEUI_REQUIRED\"") >&5 +- ($PKG_CONFIG --exists --print-errors "libgnomeui-2.0 >= $LIBGNOMEUI_REQUIRED") 2>&5 +- ac_status=$? +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; then +- pkg_cv_LIBGNOMEUI_CFLAGS=`$PKG_CONFIG --cflags "libgnomeui-2.0 >= $LIBGNOMEUI_REQUIRED" 2>/dev/null` +-else +- pkg_failed=yes +-fi +- fi +-else +- pkg_failed=untried +-fi +-if test -n "$PKG_CONFIG"; then +- if test -n "$LIBGNOMEUI_LIBS"; then +- pkg_cv_LIBGNOMEUI_LIBS="$LIBGNOMEUI_LIBS" +- else +- if test -n "$PKG_CONFIG" && \ +- { (echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \"libgnomeui-2.0 >= \$LIBGNOMEUI_REQUIRED\"") >&5 +- ($PKG_CONFIG --exists --print-errors "libgnomeui-2.0 >= $LIBGNOMEUI_REQUIRED") 2>&5 +- ac_status=$? +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; then +- pkg_cv_LIBGNOMEUI_LIBS=`$PKG_CONFIG --libs "libgnomeui-2.0 >= $LIBGNOMEUI_REQUIRED" 2>/dev/null` +-else +- pkg_failed=yes +-fi +- fi +-else +- pkg_failed=untried +-fi +- +- +- +-if test $pkg_failed = yes; then +- +-if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then +- _pkg_short_errors_supported=yes +-else +- _pkg_short_errors_supported=no +-fi +- if test $_pkg_short_errors_supported = yes; then +- LIBGNOMEUI_PKG_ERRORS=`$PKG_CONFIG --short-errors --errors-to-stdout --print-errors "libgnomeui-2.0 >= $LIBGNOMEUI_REQUIRED"` +- else +- LIBGNOMEUI_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "libgnomeui-2.0 >= $LIBGNOMEUI_REQUIRED"` +- fi +- # Put the nasty error message in config.log where it belongs +- echo "$LIBGNOMEUI_PKG_ERRORS" >&5 +- +- { echo "$as_me:$LINENO: WARNING: libgnomeui-2.0 was not found." >&5 +-echo "$as_me: WARNING: libgnomeui-2.0 was not found." >&2;} +-elif test $pkg_failed = untried; then +- { echo "$as_me:$LINENO: WARNING: libgnomeui-2.0 was not found." >&5 +-echo "$as_me: WARNING: libgnomeui-2.0 was not found." >&2;} +-else +- LIBGNOMEUI_CFLAGS=$pkg_cv_LIBGNOMEUI_CFLAGS +- LIBGNOMEUI_LIBS=$pkg_cv_LIBGNOMEUI_LIBS +- echo "$as_me:$LINENO: result: yes" >&5 +-echo "${ECHO_T}yes" >&6 +- +- +- +- +-cat >>confdefs.h <<\_ACEOF +-#define HAVE_LIBGNOMEUI 1 +-_ACEOF +- +- +-fi +- +- +-# Extract the first word of "scrollkeeper-config", so it can be a program name with args. +-set dummy scrollkeeper-config; ac_word=$2 +-echo "$as_me:$LINENO: checking for $ac_word" >&5 +-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 +-if test "${ac_cv_path_SCROLLKEEPER_CONFIG+set}" = set; then +- echo $ECHO_N "(cached) $ECHO_C" >&6 +-else +- case $SCROLLKEEPER_CONFIG in +- [\\/]* | ?:[\\/]*) +- ac_cv_path_SCROLLKEEPER_CONFIG="$SCROLLKEEPER_CONFIG" # Let the user override the test with a path. +- ;; +- *) +- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +-for as_dir in $PATH +-do +- IFS=$as_save_IFS +- test -z "$as_dir" && as_dir=. +- for ac_exec_ext in '' $ac_executable_extensions; do +- if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then +- ac_cv_path_SCROLLKEEPER_CONFIG="$as_dir/$ac_word$ac_exec_ext" +- echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 +- break 2 +- fi +-done +-done +- +- test -z "$ac_cv_path_SCROLLKEEPER_CONFIG" && ac_cv_path_SCROLLKEEPER_CONFIG="no" +- ;; +-esac +-fi +-SCROLLKEEPER_CONFIG=$ac_cv_path_SCROLLKEEPER_CONFIG +- +-if test -n "$SCROLLKEEPER_CONFIG"; then +- echo "$as_me:$LINENO: result: $SCROLLKEEPER_CONFIG" >&5 +-echo "${ECHO_T}$SCROLLKEEPER_CONFIG" >&6 +-else +- echo "$as_me:$LINENO: result: no" >&5 +-echo "${ECHO_T}no" >&6 +-fi +- +-if test x$SCROLLKEEPER_CONFIG = xno; then +- { { echo "$as_me:$LINENO: error: Could not find scrollkeeper-config. Please install the scrollkeeper package" >&5 +-echo "$as_me: error: Could not find scrollkeeper-config. Please install the scrollkeeper package" >&2;} +- { (exit 1); exit 1; }; } +-fi +- +- +- +- +- +- +-GETTEXT_PACKAGE=qalculate-gtk +- +- +-cat >>confdefs.h <<_ACEOF +-#define GETTEXT_PACKAGE "$GETTEXT_PACKAGE" +-_ACEOF +- +- +-ALL_LINGUAS="nl sv" +- +- ++ # ++ # If we don't have everything we want, check in libintl ++ # ++ if test "$gt_cv_func_dgettext_libc" != "yes" \ ++ || test "$gt_cv_func_ngettext_libc" != "yes" \ ++ || test "$ac_cv_func_bind_textdomain_codeset" != "yes" ; then + +-for ac_header in locale.h +-do +-as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh` +-if eval "test \"\${$as_ac_Header+set}\" = set"; then +- echo "$as_me:$LINENO: checking for $ac_header" >&5 +-echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6 +-if eval "test \"\${$as_ac_Header+set}\" = set"; then ++ echo "$as_me:$LINENO: checking for bindtextdomain in -lintl" >&5 ++echo $ECHO_N "checking for bindtextdomain in -lintl... $ECHO_C" >&6 ++if test "${ac_cv_lib_intl_bindtextdomain+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +-fi +-echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5 +-echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6 + else +- # Is the header compilable? +-echo "$as_me:$LINENO: checking $ac_header usability" >&5 +-echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6 ++ ac_check_lib_save_LIBS=$LIBS ++LIBS="-lintl $LIBS" + cat >conftest.$ac_ext <<_ACEOF + /* confdefs.h. */ + _ACEOF + cat confdefs.h >>conftest.$ac_ext + cat >>conftest.$ac_ext <<_ACEOF + /* end confdefs.h. */ +-$ac_includes_default +-#include <$ac_header> ++ ++/* Override any gcc2 internal prototype to avoid an error. */ ++#ifdef __cplusplus ++extern "C" ++#endif ++/* We use char because int might match the return type of a gcc2 ++ builtin and then its argument prototype would still apply. */ ++char bindtextdomain (); ++int ++main () ++{ ++bindtextdomain (); ++ ; ++ return 0; ++} + _ACEOF +-rm -f conftest.$ac_objext +-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 +- (eval $ac_compile) 2>conftest.er1 ++rm -f conftest.$ac_objext conftest$ac_exeext ++if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 ++ (eval $ac_link) 2>conftest.er1 + ac_status=$? + grep -v '^ *+' conftest.er1 >conftest.err + rm -f conftest.er1 +@@ -21261,132 +20741,51 @@ if { (eval echo "$as_me:$LINENO: \"$ac_c + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; } && +- { ac_try='test -s conftest.$ac_objext' ++ { ac_try='test -s conftest$ac_exeext' + { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; }; then +- ac_header_compiler=yes +-else +- echo "$as_me: failed program was:" >&5 +-sed 's/^/| /' conftest.$ac_ext >&5 +- +-ac_header_compiler=no +-fi +-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext +-echo "$as_me:$LINENO: result: $ac_header_compiler" >&5 +-echo "${ECHO_T}$ac_header_compiler" >&6 +- +-# Is the header present? +-echo "$as_me:$LINENO: checking $ac_header presence" >&5 +-echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6 +-cat >conftest.$ac_ext <<_ACEOF +-/* confdefs.h. */ +-_ACEOF +-cat confdefs.h >>conftest.$ac_ext +-cat >>conftest.$ac_ext <<_ACEOF +-/* end confdefs.h. */ +-#include <$ac_header> +-_ACEOF +-if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5 +- (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 +- ac_status=$? +- grep -v '^ *+' conftest.er1 >conftest.err +- rm -f conftest.er1 +- cat conftest.err >&5 +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); } >/dev/null; then +- if test -s conftest.err; then +- ac_cpp_err=$ac_cxx_preproc_warn_flag +- ac_cpp_err=$ac_cpp_err$ac_cxx_werror_flag +- else +- ac_cpp_err= +- fi +-else +- ac_cpp_err=yes +-fi +-if test -z "$ac_cpp_err"; then +- ac_header_preproc=yes +-else +- echo "$as_me: failed program was:" >&5 +-sed 's/^/| /' conftest.$ac_ext >&5 +- +- ac_header_preproc=no +-fi +-rm -f conftest.err conftest.$ac_ext +-echo "$as_me:$LINENO: result: $ac_header_preproc" >&5 +-echo "${ECHO_T}$ac_header_preproc" >&6 +- +-# So? What about this header? +-case $ac_header_compiler:$ac_header_preproc:$ac_cxx_preproc_warn_flag in +- yes:no: ) +- { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5 +-echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;} +- { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5 +-echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;} +- ac_header_preproc=yes +- ;; +- no:yes:* ) +- { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5 +-echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;} +- { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5 +-echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;} +- { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5 +-echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;} +- { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5 +-echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;} +- { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5 +-echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;} +- { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5 +-echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;} +- ( +- cat <<\_ASBOX +-## ------------------------------------------ ## +-## Report this to the AC_PACKAGE_NAME lists. ## +-## ------------------------------------------ ## +-_ASBOX +- ) | +- sed "s/^/$as_me: WARNING: /" >&2 +- ;; +-esac +-echo "$as_me:$LINENO: checking for $ac_header" >&5 +-echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6 +-if eval "test \"\${$as_ac_Header+set}\" = set"; then +- echo $ECHO_N "(cached) $ECHO_C" >&6 ++ (exit $ac_status); }; }; then ++ ac_cv_lib_intl_bindtextdomain=yes + else +- eval "$as_ac_Header=\$ac_header_preproc" +-fi +-echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5 +-echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6 ++ echo "$as_me: failed program was:" >&5 ++sed 's/^/| /' conftest.$ac_ext >&5 + ++ac_cv_lib_intl_bindtextdomain=no + fi +-if test `eval echo '${'$as_ac_Header'}'` = yes; then +- cat >>confdefs.h <<_ACEOF +-#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1 +-_ACEOF +- ++rm -f conftest.err conftest.$ac_objext \ ++ conftest$ac_exeext conftest.$ac_ext ++LIBS=$ac_check_lib_save_LIBS + fi +- +-done +- +- if test $ac_cv_header_locale_h = yes; then +- echo "$as_me:$LINENO: checking for LC_MESSAGES" >&5 +-echo $ECHO_N "checking for LC_MESSAGES... $ECHO_C" >&6 +-if test "${am_cv_val_LC_MESSAGES+set}" = set; then ++echo "$as_me:$LINENO: result: $ac_cv_lib_intl_bindtextdomain" >&5 ++echo "${ECHO_T}$ac_cv_lib_intl_bindtextdomain" >&6 ++if test $ac_cv_lib_intl_bindtextdomain = yes; then ++ echo "$as_me:$LINENO: checking for ngettext in -lintl" >&5 ++echo $ECHO_N "checking for ngettext in -lintl... $ECHO_C" >&6 ++if test "${ac_cv_lib_intl_ngettext+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 + else +- cat >conftest.$ac_ext <<_ACEOF ++ ac_check_lib_save_LIBS=$LIBS ++LIBS="-lintl $LIBS" ++cat >conftest.$ac_ext <<_ACEOF + /* confdefs.h. */ + _ACEOF + cat confdefs.h >>conftest.$ac_ext + cat >>conftest.$ac_ext <<_ACEOF + /* end confdefs.h. */ +-#include ++ ++/* Override any gcc2 internal prototype to avoid an error. */ ++#ifdef __cplusplus ++extern "C" ++#endif ++/* We use char because int might match the return type of a gcc2 ++ builtin and then its argument prototype would still apply. */ ++char ngettext (); + int + main () + { +-return LC_MESSAGES ++ngettext (); + ; + return 0; + } +@@ -21413,59 +20812,52 @@ if { (eval echo "$as_me:$LINENO: \"$ac_l + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then +- am_cv_val_LC_MESSAGES=yes ++ ac_cv_lib_intl_ngettext=yes + else + echo "$as_me: failed program was:" >&5 + sed 's/^/| /' conftest.$ac_ext >&5 + +-am_cv_val_LC_MESSAGES=no ++ac_cv_lib_intl_ngettext=no + fi + rm -f conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext ++LIBS=$ac_check_lib_save_LIBS + fi +-echo "$as_me:$LINENO: result: $am_cv_val_LC_MESSAGES" >&5 +-echo "${ECHO_T}$am_cv_val_LC_MESSAGES" >&6 +- if test $am_cv_val_LC_MESSAGES = yes; then +- +-cat >>confdefs.h <<\_ACEOF +-#define HAVE_LC_MESSAGES 1 +-_ACEOF +- +- fi +- fi +- USE_NLS=yes +- +- +- gt_cv_have_gettext=no +- +- CATOBJEXT=NONE +- XGETTEXT=: +- INTLLIBS= +- +- if test "${ac_cv_header_libintl_h+set}" = set; then +- echo "$as_me:$LINENO: checking for libintl.h" >&5 +-echo $ECHO_N "checking for libintl.h... $ECHO_C" >&6 +-if test "${ac_cv_header_libintl_h+set}" = set; then ++echo "$as_me:$LINENO: result: $ac_cv_lib_intl_ngettext" >&5 ++echo "${ECHO_T}$ac_cv_lib_intl_ngettext" >&6 ++if test $ac_cv_lib_intl_ngettext = yes; then ++ echo "$as_me:$LINENO: checking for dgettext in -lintl" >&5 ++echo $ECHO_N "checking for dgettext in -lintl... $ECHO_C" >&6 ++if test "${ac_cv_lib_intl_dgettext+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +-fi +-echo "$as_me:$LINENO: result: $ac_cv_header_libintl_h" >&5 +-echo "${ECHO_T}$ac_cv_header_libintl_h" >&6 + else +- # Is the header compilable? +-echo "$as_me:$LINENO: checking libintl.h usability" >&5 +-echo $ECHO_N "checking libintl.h usability... $ECHO_C" >&6 ++ ac_check_lib_save_LIBS=$LIBS ++LIBS="-lintl $LIBS" + cat >conftest.$ac_ext <<_ACEOF + /* confdefs.h. */ + _ACEOF + cat confdefs.h >>conftest.$ac_ext + cat >>conftest.$ac_ext <<_ACEOF + /* end confdefs.h. */ +-$ac_includes_default +-#include ++ ++/* Override any gcc2 internal prototype to avoid an error. */ ++#ifdef __cplusplus ++extern "C" ++#endif ++/* We use char because int might match the return type of a gcc2 ++ builtin and then its argument prototype would still apply. */ ++char dgettext (); ++int ++main () ++{ ++dgettext (); ++ ; ++ return 0; ++} + _ACEOF +-rm -f conftest.$ac_objext +-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 +- (eval $ac_compile) 2>conftest.er1 ++rm -f conftest.$ac_objext conftest$ac_exeext ++if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 ++ (eval $ac_link) 2>conftest.er1 + ac_status=$? + grep -v '^ *+' conftest.er1 >conftest.err + rm -f conftest.er1 +@@ -21479,131 +20871,129 @@ if { (eval echo "$as_me:$LINENO: \"$ac_c + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; } && +- { ac_try='test -s conftest.$ac_objext' ++ { ac_try='test -s conftest$ac_exeext' + { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then +- ac_header_compiler=yes ++ ac_cv_lib_intl_dgettext=yes + else + echo "$as_me: failed program was:" >&5 + sed 's/^/| /' conftest.$ac_ext >&5 + +-ac_header_compiler=no ++ac_cv_lib_intl_dgettext=no ++fi ++rm -f conftest.err conftest.$ac_objext \ ++ conftest$ac_exeext conftest.$ac_ext ++LIBS=$ac_check_lib_save_LIBS ++fi ++echo "$as_me:$LINENO: result: $ac_cv_lib_intl_dgettext" >&5 ++echo "${ECHO_T}$ac_cv_lib_intl_dgettext" >&6 ++if test $ac_cv_lib_intl_dgettext = yes; then ++ gt_cv_func_dgettext_libintl=yes + fi +-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext +-echo "$as_me:$LINENO: result: $ac_header_compiler" >&5 +-echo "${ECHO_T}$ac_header_compiler" >&6 + +-# Is the header present? +-echo "$as_me:$LINENO: checking libintl.h presence" >&5 +-echo $ECHO_N "checking libintl.h presence... $ECHO_C" >&6 ++fi ++ ++fi ++ ++ ++ if test "$gt_cv_func_dgettext_libintl" != "yes" ; then ++ echo "$as_me:$LINENO: checking if -liconv is needed to use gettext" >&5 ++echo $ECHO_N "checking if -liconv is needed to use gettext... $ECHO_C" >&6 ++ echo "$as_me:$LINENO: result: " >&5 ++echo "${ECHO_T}" >&6 ++ echo "$as_me:$LINENO: checking for ngettext in -lintl" >&5 ++echo $ECHO_N "checking for ngettext in -lintl... $ECHO_C" >&6 ++if test "${ac_cv_lib_intl_ngettext+set}" = set; then ++ echo $ECHO_N "(cached) $ECHO_C" >&6 ++else ++ ac_check_lib_save_LIBS=$LIBS ++LIBS="-lintl -liconv $LIBS" + cat >conftest.$ac_ext <<_ACEOF + /* confdefs.h. */ + _ACEOF + cat confdefs.h >>conftest.$ac_ext + cat >>conftest.$ac_ext <<_ACEOF + /* end confdefs.h. */ +-#include ++ ++/* Override any gcc2 internal prototype to avoid an error. */ ++#ifdef __cplusplus ++extern "C" ++#endif ++/* We use char because int might match the return type of a gcc2 ++ builtin and then its argument prototype would still apply. */ ++char ngettext (); ++int ++main () ++{ ++ngettext (); ++ ; ++ return 0; ++} + _ACEOF +-if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5 +- (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 ++rm -f conftest.$ac_objext conftest$ac_exeext ++if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 ++ (eval $ac_link) 2>conftest.er1 + ac_status=$? + grep -v '^ *+' conftest.er1 >conftest.err + rm -f conftest.er1 + cat conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); } >/dev/null; then +- if test -s conftest.err; then +- ac_cpp_err=$ac_cxx_preproc_warn_flag +- ac_cpp_err=$ac_cpp_err$ac_cxx_werror_flag +- else +- ac_cpp_err= +- fi +-else +- ac_cpp_err=yes +-fi +-if test -z "$ac_cpp_err"; then +- ac_header_preproc=yes ++ (exit $ac_status); } && ++ { ac_try='test -z "$ac_cxx_werror_flag" ++ || test ! -s conftest.err' ++ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 ++ (eval $ac_try) 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; } && ++ { ac_try='test -s conftest$ac_exeext' ++ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 ++ (eval $ac_try) 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; }; then ++ ac_cv_lib_intl_ngettext=yes + else + echo "$as_me: failed program was:" >&5 + sed 's/^/| /' conftest.$ac_ext >&5 + +- ac_header_preproc=no +-fi +-rm -f conftest.err conftest.$ac_ext +-echo "$as_me:$LINENO: result: $ac_header_preproc" >&5 +-echo "${ECHO_T}$ac_header_preproc" >&6 +- +-# So? What about this header? +-case $ac_header_compiler:$ac_header_preproc:$ac_cxx_preproc_warn_flag in +- yes:no: ) +- { echo "$as_me:$LINENO: WARNING: libintl.h: accepted by the compiler, rejected by the preprocessor!" >&5 +-echo "$as_me: WARNING: libintl.h: accepted by the compiler, rejected by the preprocessor!" >&2;} +- { echo "$as_me:$LINENO: WARNING: libintl.h: proceeding with the compiler's result" >&5 +-echo "$as_me: WARNING: libintl.h: proceeding with the compiler's result" >&2;} +- ac_header_preproc=yes +- ;; +- no:yes:* ) +- { echo "$as_me:$LINENO: WARNING: libintl.h: present but cannot be compiled" >&5 +-echo "$as_me: WARNING: libintl.h: present but cannot be compiled" >&2;} +- { echo "$as_me:$LINENO: WARNING: libintl.h: check for missing prerequisite headers?" >&5 +-echo "$as_me: WARNING: libintl.h: check for missing prerequisite headers?" >&2;} +- { echo "$as_me:$LINENO: WARNING: libintl.h: see the Autoconf documentation" >&5 +-echo "$as_me: WARNING: libintl.h: see the Autoconf documentation" >&2;} +- { echo "$as_me:$LINENO: WARNING: libintl.h: section \"Present But Cannot Be Compiled\"" >&5 +-echo "$as_me: WARNING: libintl.h: section \"Present But Cannot Be Compiled\"" >&2;} +- { echo "$as_me:$LINENO: WARNING: libintl.h: proceeding with the preprocessor's result" >&5 +-echo "$as_me: WARNING: libintl.h: proceeding with the preprocessor's result" >&2;} +- { echo "$as_me:$LINENO: WARNING: libintl.h: in the future, the compiler will take precedence" >&5 +-echo "$as_me: WARNING: libintl.h: in the future, the compiler will take precedence" >&2;} +- ( +- cat <<\_ASBOX +-## ------------------------------------------ ## +-## Report this to the AC_PACKAGE_NAME lists. ## +-## ------------------------------------------ ## +-_ASBOX +- ) | +- sed "s/^/$as_me: WARNING: /" >&2 +- ;; +-esac +-echo "$as_me:$LINENO: checking for libintl.h" >&5 +-echo $ECHO_N "checking for libintl.h... $ECHO_C" >&6 +-if test "${ac_cv_header_libintl_h+set}" = set; then +- echo $ECHO_N "(cached) $ECHO_C" >&6 +-else +- ac_cv_header_libintl_h=$ac_header_preproc +-fi +-echo "$as_me:$LINENO: result: $ac_cv_header_libintl_h" >&5 +-echo "${ECHO_T}$ac_cv_header_libintl_h" >&6 +- ++ac_cv_lib_intl_ngettext=no + fi +-if test $ac_cv_header_libintl_h = yes; then +- gt_cv_func_dgettext_libintl="no" +- libintl_extra_libs="" +- +- # +- # First check in libc +- # +- echo "$as_me:$LINENO: checking for ngettext in libc" >&5 +-echo $ECHO_N "checking for ngettext in libc... $ECHO_C" >&6 +-if test "${gt_cv_func_ngettext_libc+set}" = set; then ++rm -f conftest.err conftest.$ac_objext \ ++ conftest$ac_exeext conftest.$ac_ext ++LIBS=$ac_check_lib_save_LIBS ++fi ++echo "$as_me:$LINENO: result: $ac_cv_lib_intl_ngettext" >&5 ++echo "${ECHO_T}$ac_cv_lib_intl_ngettext" >&6 ++if test $ac_cv_lib_intl_ngettext = yes; then ++ echo "$as_me:$LINENO: checking for dcgettext in -lintl" >&5 ++echo $ECHO_N "checking for dcgettext in -lintl... $ECHO_C" >&6 ++if test "${ac_cv_lib_intl_dcgettext+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 + else +- cat >conftest.$ac_ext <<_ACEOF ++ ac_check_lib_save_LIBS=$LIBS ++LIBS="-lintl -liconv $LIBS" ++cat >conftest.$ac_ext <<_ACEOF + /* confdefs.h. */ + _ACEOF + cat confdefs.h >>conftest.$ac_ext + cat >>conftest.$ac_ext <<_ACEOF + /* end confdefs.h. */ + +-#include +- ++/* Override any gcc2 internal prototype to avoid an error. */ ++#ifdef __cplusplus ++extern "C" ++#endif ++/* We use char because int might match the return type of a gcc2 ++ builtin and then its argument prototype would still apply. */ ++char dcgettext (); + int + main () + { +-return !ngettext ("","", 1) ++dcgettext (); + ; + return 0; + } +@@ -21630,24 +21020,48 @@ if { (eval echo "$as_me:$LINENO: \"$ac_l + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then +- gt_cv_func_ngettext_libc=yes ++ ac_cv_lib_intl_dcgettext=yes + else + echo "$as_me: failed program was:" >&5 + sed 's/^/| /' conftest.$ac_ext >&5 + +-gt_cv_func_ngettext_libc=no ++ac_cv_lib_intl_dcgettext=no + fi + rm -f conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext ++LIBS=$ac_check_lib_save_LIBS ++fi ++echo "$as_me:$LINENO: result: $ac_cv_lib_intl_dcgettext" >&5 ++echo "${ECHO_T}$ac_cv_lib_intl_dcgettext" >&6 ++if test $ac_cv_lib_intl_dcgettext = yes; then ++ gt_cv_func_dgettext_libintl=yes ++ libintl_extra_libs=-liconv ++else ++ : ++fi + ++else ++ : + fi +-echo "$as_me:$LINENO: result: $gt_cv_func_ngettext_libc" >&5 +-echo "${ECHO_T}$gt_cv_func_ngettext_libc" >&6 + +- if test "$gt_cv_func_ngettext_libc" = "yes" ; then +- echo "$as_me:$LINENO: checking for dgettext in libc" >&5 +-echo $ECHO_N "checking for dgettext in libc... $ECHO_C" >&6 +-if test "${gt_cv_func_dgettext_libc+set}" = set; then ++ fi ++ ++ # ++ # If we found libintl, then check in it for bind_textdomain_codeset(); ++ # we'll prefer libc if neither have bind_textdomain_codeset(), ++ # and both have dgettext and ngettext ++ # ++ if test "$gt_cv_func_dgettext_libintl" = "yes" ; then ++ glib_save_LIBS="$LIBS" ++ LIBS="$LIBS -lintl $libintl_extra_libs" ++ unset ac_cv_func_bind_textdomain_codeset ++ ++for ac_func in bind_textdomain_codeset ++do ++as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh` ++echo "$as_me:$LINENO: checking for $ac_func" >&5 ++echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6 ++if eval "test \"\${$as_ac_var+set}\" = set"; then + echo $ECHO_N "(cached) $ECHO_C" >&6 + else + cat >conftest.$ac_ext <<_ACEOF +@@ -21656,13 +21070,47 @@ _ACEOF + cat confdefs.h >>conftest.$ac_ext + cat >>conftest.$ac_ext <<_ACEOF + /* end confdefs.h. */ ++/* Define $ac_func to an innocuous variant, in case declares $ac_func. ++ For example, HP-UX 11i declares gettimeofday. */ ++#define $ac_func innocuous_$ac_func + +-#include ++/* System header to define __stub macros and hopefully few prototypes, ++ which can conflict with char $ac_func (); below. ++ Prefer to if __STDC__ is defined, since ++ exists even on freestanding compilers. */ ++ ++#ifdef __STDC__ ++# include ++#else ++# include ++#endif ++ ++#undef $ac_func ++ ++/* Override any gcc2 internal prototype to avoid an error. */ ++#ifdef __cplusplus ++extern "C" ++{ ++#endif ++/* We use char because int might match the return type of a gcc2 ++ builtin and then its argument prototype would still apply. */ ++char $ac_func (); ++/* The GNU C library defines this for functions which it implements ++ to always fail with ENOSYS. Some functions are actually named ++ something starting with __ and the normal name is an alias. */ ++#if defined (__stub_$ac_func) || defined (__stub___$ac_func) ++choke me ++#else ++char (*f) () = $ac_func; ++#endif ++#ifdef __cplusplus ++} ++#endif + + int + main () + { +-return !dgettext ("","") ++return f != $ac_func; + ; + return 0; + } +@@ -21689,24 +21137,94 @@ if { (eval echo "$as_me:$LINENO: \"$ac_l + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then +- gt_cv_func_dgettext_libc=yes ++ eval "$as_ac_var=yes" + else + echo "$as_me: failed program was:" >&5 + sed 's/^/| /' conftest.$ac_ext >&5 + +-gt_cv_func_dgettext_libc=no ++eval "$as_ac_var=no" + fi + rm -f conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext ++fi ++echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5 ++echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6 ++if test `eval echo '${'$as_ac_var'}'` = yes; then ++ cat >>confdefs.h <<_ACEOF ++#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1 ++_ACEOF + + fi +-echo "$as_me:$LINENO: result: $gt_cv_func_dgettext_libc" >&5 +-echo "${ECHO_T}$gt_cv_func_dgettext_libc" >&6 ++done ++ ++ LIBS="$glib_save_LIBS" ++ ++ if test "$ac_cv_func_bind_textdomain_codeset" = "yes" ; then ++ gt_cv_func_dgettext_libc=no ++ else ++ if test "$gt_cv_func_dgettext_libc" = "yes" \ ++ && test "$gt_cv_func_ngettext_libc" = "yes"; then ++ gt_cv_func_dgettext_libintl=no ++ fi ++ fi ++ fi + fi + +- if test "$gt_cv_func_ngettext_libc" = "yes" ; then ++ if test "$gt_cv_func_dgettext_libc" = "yes" \ ++ || test "$gt_cv_func_dgettext_libintl" = "yes"; then ++ gt_cv_have_gettext=yes ++ fi + +-for ac_func in bind_textdomain_codeset ++ if test "$gt_cv_func_dgettext_libintl" = "yes"; then ++ INTLLIBS="-lintl $libintl_extra_libs" ++ fi ++ ++ if test "$gt_cv_have_gettext" = "yes"; then ++ ++cat >>confdefs.h <<\_ACEOF ++#define HAVE_GETTEXT 1 ++_ACEOF ++ ++ # Extract the first word of "msgfmt", so it can be a program name with args. ++set dummy msgfmt; ac_word=$2 ++echo "$as_me:$LINENO: checking for $ac_word" >&5 ++echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 ++if test "${ac_cv_path_MSGFMT+set}" = set; then ++ echo $ECHO_N "(cached) $ECHO_C" >&6 ++else ++ case "$MSGFMT" in ++ /*) ++ ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path. ++ ;; ++ *) ++ IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" ++ for ac_dir in $PATH; do ++ test -z "$ac_dir" && ac_dir=. ++ if test -f $ac_dir/$ac_word; then ++ if test -z "`$ac_dir/$ac_word -h 2>&1 | grep 'dv '`"; then ++ ac_cv_path_MSGFMT="$ac_dir/$ac_word" ++ break ++ fi ++ fi ++ done ++ IFS="$ac_save_ifs" ++ test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT="no" ++ ;; ++esac ++fi ++MSGFMT="$ac_cv_path_MSGFMT" ++if test "$MSGFMT" != "no"; then ++ echo "$as_me:$LINENO: result: $MSGFMT" >&5 ++echo "${ECHO_T}$MSGFMT" >&6 ++else ++ echo "$as_me:$LINENO: result: no" >&5 ++echo "${ECHO_T}no" >&6 ++fi ++ if test "$MSGFMT" != "no"; then ++ glib_save_LIBS="$LIBS" ++ LIBS="$LIBS $INTLLIBS" ++ ++for ac_func in dcgettext + do + as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh` + echo "$as_me:$LINENO: checking for $ac_func" >&5 +@@ -21805,42 +21323,96 @@ if test `eval echo '${'$as_ac_var'}'` = + _ACEOF + + fi +-done +- +- fi ++done ++ ++ # Extract the first word of "gmsgfmt", so it can be a program name with args. ++set dummy gmsgfmt; ac_word=$2 ++echo "$as_me:$LINENO: checking for $ac_word" >&5 ++echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 ++if test "${ac_cv_path_GMSGFMT+set}" = set; then ++ echo $ECHO_N "(cached) $ECHO_C" >&6 ++else ++ case $GMSGFMT in ++ [\\/]* | ?:[\\/]*) ++ ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path. ++ ;; ++ *) ++ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR ++for as_dir in $PATH ++do ++ IFS=$as_save_IFS ++ test -z "$as_dir" && as_dir=. ++ for ac_exec_ext in '' $ac_executable_extensions; do ++ if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ++ ac_cv_path_GMSGFMT="$as_dir/$ac_word$ac_exec_ext" ++ echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 ++ break 2 ++ fi ++done ++done ++ ++ test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT" ++ ;; ++esac ++fi ++GMSGFMT=$ac_cv_path_GMSGFMT ++ ++if test -n "$GMSGFMT"; then ++ echo "$as_me:$LINENO: result: $GMSGFMT" >&5 ++echo "${ECHO_T}$GMSGFMT" >&6 ++else ++ echo "$as_me:$LINENO: result: no" >&5 ++echo "${ECHO_T}no" >&6 ++fi ++ ++ # Extract the first word of "xgettext", so it can be a program name with args. ++set dummy xgettext; ac_word=$2 ++echo "$as_me:$LINENO: checking for $ac_word" >&5 ++echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 ++if test "${ac_cv_path_XGETTEXT+set}" = set; then ++ echo $ECHO_N "(cached) $ECHO_C" >&6 ++else ++ case "$XGETTEXT" in ++ /*) ++ ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path. ++ ;; ++ *) ++ IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" ++ for ac_dir in $PATH; do ++ test -z "$ac_dir" && ac_dir=. ++ if test -f $ac_dir/$ac_word; then ++ if test -z "`$ac_dir/$ac_word -h 2>&1 | grep '(HELP)'`"; then ++ ac_cv_path_XGETTEXT="$ac_dir/$ac_word" ++ break ++ fi ++ fi ++ done ++ IFS="$ac_save_ifs" ++ test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":" ++ ;; ++esac ++fi ++XGETTEXT="$ac_cv_path_XGETTEXT" ++if test "$XGETTEXT" != ":"; then ++ echo "$as_me:$LINENO: result: $XGETTEXT" >&5 ++echo "${ECHO_T}$XGETTEXT" >&6 ++else ++ echo "$as_me:$LINENO: result: no" >&5 ++echo "${ECHO_T}no" >&6 ++fi + +- # +- # If we don't have everything we want, check in libintl +- # +- if test "$gt_cv_func_dgettext_libc" != "yes" \ +- || test "$gt_cv_func_ngettext_libc" != "yes" \ +- || test "$ac_cv_func_bind_textdomain_codeset" != "yes" ; then +- +- echo "$as_me:$LINENO: checking for bindtextdomain in -lintl" >&5 +-echo $ECHO_N "checking for bindtextdomain in -lintl... $ECHO_C" >&6 +-if test "${ac_cv_lib_intl_bindtextdomain+set}" = set; then +- echo $ECHO_N "(cached) $ECHO_C" >&6 +-else +- ac_check_lib_save_LIBS=$LIBS +-LIBS="-lintl $LIBS" +-cat >conftest.$ac_ext <<_ACEOF ++ cat >conftest.$ac_ext <<_ACEOF + /* confdefs.h. */ + _ACEOF + cat confdefs.h >>conftest.$ac_ext + cat >>conftest.$ac_ext <<_ACEOF + /* end confdefs.h. */ + +-/* Override any gcc2 internal prototype to avoid an error. */ +-#ifdef __cplusplus +-extern "C" +-#endif +-/* We use char because int might match the return type of a gcc2 +- builtin and then its argument prototype would still apply. */ +-char bindtextdomain (); + int + main () + { +-bindtextdomain (); ++extern int _nl_msg_cat_cntr; ++ return _nl_msg_cat_cntr + ; + return 0; + } +@@ -21867,45 +21439,66 @@ if { (eval echo "$as_me:$LINENO: \"$ac_l + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then +- ac_cv_lib_intl_bindtextdomain=yes ++ CATOBJEXT=.gmo ++ DATADIRNAME=share + else + echo "$as_me: failed program was:" >&5 + sed 's/^/| /' conftest.$ac_ext >&5 + +-ac_cv_lib_intl_bindtextdomain=no +-fi +-rm -f conftest.err conftest.$ac_objext \ +- conftest$ac_exeext conftest.$ac_ext +-LIBS=$ac_check_lib_save_LIBS +-fi +-echo "$as_me:$LINENO: result: $ac_cv_lib_intl_bindtextdomain" >&5 +-echo "${ECHO_T}$ac_cv_lib_intl_bindtextdomain" >&6 +-if test $ac_cv_lib_intl_bindtextdomain = yes; then +- echo "$as_me:$LINENO: checking for ngettext in -lintl" >&5 +-echo $ECHO_N "checking for ngettext in -lintl... $ECHO_C" >&6 +-if test "${ac_cv_lib_intl_ngettext+set}" = set; then ++case $host in ++ *-*-solaris*) ++ echo "$as_me:$LINENO: checking for bind_textdomain_codeset" >&5 ++echo $ECHO_N "checking for bind_textdomain_codeset... $ECHO_C" >&6 ++if test "${ac_cv_func_bind_textdomain_codeset+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 + else +- ac_check_lib_save_LIBS=$LIBS +-LIBS="-lintl $LIBS" +-cat >conftest.$ac_ext <<_ACEOF ++ cat >conftest.$ac_ext <<_ACEOF + /* confdefs.h. */ + _ACEOF + cat confdefs.h >>conftest.$ac_ext + cat >>conftest.$ac_ext <<_ACEOF + /* end confdefs.h. */ ++/* Define bind_textdomain_codeset to an innocuous variant, in case declares bind_textdomain_codeset. ++ For example, HP-UX 11i declares gettimeofday. */ ++#define bind_textdomain_codeset innocuous_bind_textdomain_codeset ++ ++/* System header to define __stub macros and hopefully few prototypes, ++ which can conflict with char bind_textdomain_codeset (); below. ++ Prefer to if __STDC__ is defined, since ++ exists even on freestanding compilers. */ ++ ++#ifdef __STDC__ ++# include ++#else ++# include ++#endif ++ ++#undef bind_textdomain_codeset + + /* Override any gcc2 internal prototype to avoid an error. */ + #ifdef __cplusplus + extern "C" ++{ + #endif + /* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +-char ngettext (); ++char bind_textdomain_codeset (); ++/* The GNU C library defines this for functions which it implements ++ to always fail with ENOSYS. Some functions are actually named ++ something starting with __ and the normal name is an alias. */ ++#if defined (__stub_bind_textdomain_codeset) || defined (__stub___bind_textdomain_codeset) ++choke me ++#else ++char (*f) () = bind_textdomain_codeset; ++#endif ++#ifdef __cplusplus ++} ++#endif ++ + int + main () + { +-ngettext (); ++return f != bind_textdomain_codeset; + ; + return 0; + } +@@ -21932,27 +21525,178 @@ if { (eval echo "$as_me:$LINENO: \"$ac_l + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then +- ac_cv_lib_intl_ngettext=yes ++ ac_cv_func_bind_textdomain_codeset=yes + else + echo "$as_me: failed program was:" >&5 + sed 's/^/| /' conftest.$ac_ext >&5 + +-ac_cv_lib_intl_ngettext=no ++ac_cv_func_bind_textdomain_codeset=no + fi + rm -f conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +-LIBS=$ac_check_lib_save_LIBS + fi +-echo "$as_me:$LINENO: result: $ac_cv_lib_intl_ngettext" >&5 +-echo "${ECHO_T}$ac_cv_lib_intl_ngettext" >&6 +-if test $ac_cv_lib_intl_ngettext = yes; then +- echo "$as_me:$LINENO: checking for dgettext in -lintl" >&5 +-echo $ECHO_N "checking for dgettext in -lintl... $ECHO_C" >&6 +-if test "${ac_cv_lib_intl_dgettext+set}" = set; then ++echo "$as_me:$LINENO: result: $ac_cv_func_bind_textdomain_codeset" >&5 ++echo "${ECHO_T}$ac_cv_func_bind_textdomain_codeset" >&6 ++if test $ac_cv_func_bind_textdomain_codeset = yes; then ++ CATOBJEXT=.gmo ++ DATADIRNAME=share ++else ++ CATOBJEXT=.mo ++ DATADIRNAME=lib ++fi ++ ++ ;; ++ *) ++ CATOBJEXT=.mo ++ DATADIRNAME=lib ++ ;; ++ esac ++fi ++rm -f conftest.err conftest.$ac_objext \ ++ conftest$ac_exeext conftest.$ac_ext ++ LIBS="$glib_save_LIBS" ++ INSTOBJEXT=.mo ++ else ++ gt_cv_have_gettext=no ++ fi ++ fi ++ ++fi ++ ++ ++ ++ if test "$gt_cv_have_gettext" = "yes" ; then ++ ++cat >>confdefs.h <<\_ACEOF ++#define ENABLE_NLS 1 ++_ACEOF ++ ++ fi ++ ++ if test "$XGETTEXT" != ":"; then ++ if $XGETTEXT --omit-header /dev/null 2> /dev/null; then ++ : ; ++ else ++ echo "$as_me:$LINENO: result: found xgettext program is not GNU xgettext; ignore it" >&5 ++echo "${ECHO_T}found xgettext program is not GNU xgettext; ignore it" >&6 ++ XGETTEXT=":" ++ fi ++ fi ++ ++ # We need to process the po/ directory. ++ POSUB=po ++ ++ ac_config_commands="$ac_config_commands default-1" ++ ++ ++ for lang in $ALL_LINGUAS; do ++ GMOFILES="$GMOFILES $lang.gmo" ++ POFILES="$POFILES $lang.po" ++ done ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ if test "$gt_cv_have_gettext" = "yes"; then ++ if test "x$ALL_LINGUAS" = "x"; then ++ LINGUAS= ++ else ++ echo "$as_me:$LINENO: checking for catalogs to be installed" >&5 ++echo $ECHO_N "checking for catalogs to be installed... $ECHO_C" >&6 ++ NEW_LINGUAS= ++ for presentlang in $ALL_LINGUAS; do ++ useit=no ++ if test "%UNSET%" != "${LINGUAS-%UNSET%}"; then ++ desiredlanguages="$LINGUAS" ++ else ++ desiredlanguages="$ALL_LINGUAS" ++ fi ++ for desiredlang in $desiredlanguages; do ++ # Use the presentlang catalog if desiredlang is ++ # a. equal to presentlang, or ++ # b. a variant of presentlang (because in this case, ++ # presentlang can be used as a fallback for messages ++ # which are not translated in the desiredlang catalog). ++ case "$desiredlang" in ++ "$presentlang"*) useit=yes;; ++ esac ++ done ++ if test $useit = yes; then ++ NEW_LINGUAS="$NEW_LINGUAS $presentlang" ++ fi ++ done ++ LINGUAS=$NEW_LINGUAS ++ echo "$as_me:$LINENO: result: $LINGUAS" >&5 ++echo "${ECHO_T}$LINGUAS" >&6 ++ fi ++ ++ if test -n "$LINGUAS"; then ++ for lang in $LINGUAS; do CATALOGS="$CATALOGS $lang$CATOBJEXT"; done ++ fi ++ fi ++ ++ MKINSTALLDIRS= ++ if test -n "$ac_aux_dir"; then ++ MKINSTALLDIRS="$ac_aux_dir/mkinstalldirs" ++ fi ++ if test -z "$MKINSTALLDIRS"; then ++ MKINSTALLDIRS="\$(top_srcdir)/mkinstalldirs" ++ fi ++ ++ ++ test -d po || mkdir po ++ if test "x$srcdir" != "x."; then ++ if test "x`echo $srcdir | sed 's@/.*@@'`" = "x"; then ++ posrcprefix="$srcdir/" ++ else ++ posrcprefix="../$srcdir/" ++ fi ++ else ++ posrcprefix="../" ++ fi ++ rm -f po/POTFILES ++ sed -e "/^#/d" -e "/^\$/d" -e "s,.*, $posrcprefix& \\\\," -e "\$s/\(.*\) \\\\/\1/" \ ++ < $srcdir/po/POTFILES.in > po/POTFILES ++ ++ ++echo "$as_me:$LINENO: checking locale directory" >&5 ++echo $ECHO_N "checking locale directory... $ECHO_C" >&6 ++if test "x$prefix" = "xNONE"; then ++ PACKAGE_LOCALE_DIR=$ac_default_prefix/share/locale ++else ++ PACKAGE_LOCALE_DIR=$prefix/share/locale ++fi ++ ++ ++cat >>confdefs.h <<_ACEOF ++#define PACKAGE_LOCALE_DIR "$PACKAGE_LOCALE_DIR" ++_ACEOF ++ ++ echo "$as_me:$LINENO: result: \"$PACKAGE_LOCALE_DIR\"" >&5 ++echo "${ECHO_T}\"$PACKAGE_LOCALE_DIR\"" >&6 ++ ++ ++ ++INTLTOOL_QALCULATE_DEFINITIONS_RULE='%.xml: %.xml.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po-defs/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -x -u -c $(top_builddir)/po-defs/.intltool-merge-cache $(top_srcdir)/po-defs $< $@' ++ ++ ++ ++echo "$as_me:$LINENO: checking for pthread_create in -lpthread" >&5 ++echo $ECHO_N "checking for pthread_create in -lpthread... $ECHO_C" >&6 ++if test "${ac_cv_lib_pthread_pthread_create+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 + else + ac_check_lib_save_LIBS=$LIBS +-LIBS="-lintl $LIBS" ++LIBS="-lpthread $LIBS" + cat >conftest.$ac_ext <<_ACEOF + /* confdefs.h. */ + _ACEOF +@@ -21966,11 +21710,11 @@ extern "C" + #endif + /* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +-char dgettext (); ++char pthread_create (); + int + main () + { +-dgettext (); ++pthread_create (); + ; + return 0; + } +@@ -21984,7 +21728,7 @@ if { (eval echo "$as_me:$LINENO: \"$ac_l + cat conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } && +- { ac_try='test -z "$ac_cxx_werror_flag" ++ { ac_try='test -z "$ac_c_werror_flag" + || test ! -s conftest.err' + { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 +@@ -21997,123 +21741,259 @@ if { (eval echo "$as_me:$LINENO: \"$ac_l + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then +- ac_cv_lib_intl_dgettext=yes ++ ac_cv_lib_pthread_pthread_create=yes + else + echo "$as_me: failed program was:" >&5 + sed 's/^/| /' conftest.$ac_ext >&5 + +-ac_cv_lib_intl_dgettext=no ++ac_cv_lib_pthread_pthread_create=no + fi + rm -f conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + LIBS=$ac_check_lib_save_LIBS + fi +-echo "$as_me:$LINENO: result: $ac_cv_lib_intl_dgettext" >&5 +-echo "${ECHO_T}$ac_cv_lib_intl_dgettext" >&6 +-if test $ac_cv_lib_intl_dgettext = yes; then +- gt_cv_func_dgettext_libintl=yes ++echo "$as_me:$LINENO: result: $ac_cv_lib_pthread_pthread_create" >&5 ++echo "${ECHO_T}$ac_cv_lib_pthread_pthread_create" >&6 ++if test $ac_cv_lib_pthread_pthread_create = yes; then ++ LIBS="$LIBS -lpthread" + fi + ++ ++ac_ext=cc ++ac_cpp='$CXXCPP $CPPFLAGS' ++ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' ++ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ++ac_compiler_gnu=$ac_cv_cxx_compiler_gnu ++ ++ ++ ++# Check whether --with-cln-prefix or --without-cln-prefix was given. ++if test "${with_cln_prefix+set}" = set; then ++ withval="$with_cln_prefix" ++ cln_config_prefix="$withval" ++else ++ cln_config_prefix="" ++fi; ++ ++# Check whether --with-cln-exec-prefix or --without-cln-exec-prefix was given. ++if test "${with_cln_exec_prefix+set}" = set; then ++ withval="$with_cln_exec_prefix" ++ cln_config_exec_prefix="$withval" ++else ++ cln_config_exec_prefix="" ++fi; ++# Check whether --enable-clntest or --disable-clntest was given. ++if test "${enable_clntest+set}" = set; then ++ enableval="$enable_clntest" ++ ++else ++ enable_clntest=yes ++fi; ++ ++if test x$cln_config_exec_prefix != x ; then ++ cln_config_args="$cln_config_args --exec-prefix=$cln_config_exec_prefix" ++ if test x${CLN_CONFIG+set} != xset ; then ++ CLN_CONFIG=$cln_config_exec_prefix/bin/cln-config ++ fi ++fi ++if test x$cln_config_prefix != x ; then ++ cln_config_args="$cln_config_args --prefix=$cln_config_prefix" ++ if test x${CLN_CONFIG+set} != xset ; then ++ CLN_CONFIG=$cln_config_prefix/bin/cln-config ++ fi + fi + ++# Extract the first word of "cln-config", so it can be a program name with args. ++set dummy cln-config; ac_word=$2 ++echo "$as_me:$LINENO: checking for $ac_word" >&5 ++echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 ++if test "${ac_cv_path_CLN_CONFIG+set}" = set; then ++ echo $ECHO_N "(cached) $ECHO_C" >&6 ++else ++ case $CLN_CONFIG in ++ [\\/]* | ?:[\\/]*) ++ ac_cv_path_CLN_CONFIG="$CLN_CONFIG" # Let the user override the test with a path. ++ ;; ++ *) ++ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR ++for as_dir in $PATH ++do ++ IFS=$as_save_IFS ++ test -z "$as_dir" && as_dir=. ++ for ac_exec_ext in '' $ac_executable_extensions; do ++ if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ++ ac_cv_path_CLN_CONFIG="$as_dir/$ac_word$ac_exec_ext" ++ echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 ++ break 2 ++ fi ++done ++done ++ ++ test -z "$ac_cv_path_CLN_CONFIG" && ac_cv_path_CLN_CONFIG="no" ++ ;; ++esac + fi ++CLN_CONFIG=$ac_cv_path_CLN_CONFIG + ++if test -n "$CLN_CONFIG"; then ++ echo "$as_me:$LINENO: result: $CLN_CONFIG" >&5 ++echo "${ECHO_T}$CLN_CONFIG" >&6 ++else ++ echo "$as_me:$LINENO: result: no" >&5 ++echo "${ECHO_T}no" >&6 ++fi + +- if test "$gt_cv_func_dgettext_libintl" != "yes" ; then +- echo "$as_me:$LINENO: checking if -liconv is needed to use gettext" >&5 +-echo $ECHO_N "checking if -liconv is needed to use gettext... $ECHO_C" >&6 +- echo "$as_me:$LINENO: result: " >&5 +-echo "${ECHO_T}" >&6 +- echo "$as_me:$LINENO: checking for ngettext in -lintl" >&5 +-echo $ECHO_N "checking for ngettext in -lintl... $ECHO_C" >&6 +-if test "${ac_cv_lib_intl_ngettext+set}" = set; then +- echo $ECHO_N "(cached) $ECHO_C" >&6 ++cln_min_version=1.1.0 ++echo "$as_me:$LINENO: checking for CLN - version >= $cln_min_version" >&5 ++echo $ECHO_N "checking for CLN - version >= $cln_min_version... $ECHO_C" >&6 ++if test "$CLN_CONFIG" = "no" ; then ++ echo "$as_me:$LINENO: result: no" >&5 ++echo "${ECHO_T}no" >&6 ++ echo "*** The cln-config script installed by CLN could not be found" ++ echo "*** If CLN was installed in PREFIX, make sure PREFIX/bin is in" ++ echo "*** your path, or set the CLN_CONFIG environment variable to the" ++ echo "*** full path to cln-config." ++ { { echo "$as_me:$LINENO: error: No suitable installed version of CLN could be found." >&5 ++echo "$as_me: error: No suitable installed version of CLN could be found." >&2;} ++ { (exit 1); exit 1; }; } + else +- ac_check_lib_save_LIBS=$LIBS +-LIBS="-lintl -liconv $LIBS" +-cat >conftest.$ac_ext <<_ACEOF ++ cln_min_major_version=`echo $cln_min_version | \ ++ sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\1/'` ++ cln_min_minor_version=`echo $cln_min_version | \ ++ sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\2/'` ++ cln_min_micro_version=`echo $cln_min_version | \ ++ sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\3/'` ++ CLN_CPPFLAGS=`$CLN_CONFIG $cln_config_args --cppflags` ++ CLN_LIBS=`$CLN_CONFIG $cln_config_args --libs` ++ cln_config_version=`$CLN_CONFIG $cln_config_args --version` ++ cln_config_major_version=`echo $cln_config_version | \ ++ sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\1/'` ++ cln_config_minor_version=`echo $cln_config_version | \ ++ sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\2/'` ++ cln_config_micro_version=`echo $cln_config_version | \ ++ sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\3/'` ++ if test \( $cln_config_major_version -lt $cln_min_major_version \) -o \ ++ \( $cln_config_major_version -eq $cln_min_major_version -a $cln_config_minor_version -lt $cln_min_minor_version \) -o \ ++ \( $cln_config_major_version -eq $cln_min_major_version -a $cln_config_minor_version -eq $cln_min_minor_version -a $cln_config_micro_version -lt $cln_min_micro_version \); then ++ echo -e "\n*** 'cln-config --version' returned $cln_config_major_version.$cln_config_minor_version.$cln_config_micro_version, but the minimum version" ++ echo "*** of CLN required is $cln_min_major_version.$cln_min_minor_version.$cln_min_micro_version. If cln-config is correct, then it is" ++ echo "*** best to upgrade to the required version." ++ echo "*** If cln-config was wrong, set the environment variable CLN_CONFIG" ++ echo "*** to point to the correct copy of cln-config, and remove the file" ++ echo "*** config.cache before re-running configure." ++ { { echo "$as_me:$LINENO: error: No suitable installed version of CLN could be found." >&5 ++echo "$as_me: error: No suitable installed version of CLN could be found." >&2;} ++ { (exit 1); exit 1; }; } ++ else ++ no_cln="" ++ if test "x$enable_clntest" = "xyes" ; then ++ ac_save_CPPFLAGS="$CPPFLAGS" ++ ac_save_LIBS="$LIBS" ++ CPPFLAGS="$CPPFLAGS $CLN_CPPFLAGS" ++ LIBS="$LIBS $CLN_LIBS" ++ rm -f conf.clntest ++ if test "$cross_compiling" = yes; then ++ echo $ac_n "cross compiling; assumed OK... $ac_c" ++else ++ cat >conftest.$ac_ext <<_ACEOF + /* confdefs.h. */ + _ACEOF + cat confdefs.h >>conftest.$ac_ext + cat >>conftest.$ac_ext <<_ACEOF + /* end confdefs.h. */ + +-/* Override any gcc2 internal prototype to avoid an error. */ +-#ifdef __cplusplus +-extern "C" +-#endif +-/* We use char because int might match the return type of a gcc2 +- builtin and then its argument prototype would still apply. */ +-char ngettext (); +-int +-main () ++#include ++#include ++#include ++ ++/* we do not #include because autoconf in C++ mode inserts a ++ prototype for exit() that conflicts with the one in stdlib.h */ ++extern "C" int system(const char *); ++ ++int main(void) + { +-ngettext (); +- ; +- return 0; ++ system("touch conf.clntest"); ++ ++ if ((CL_VERSION_MAJOR != $cln_config_major_version) || ++ (CL_VERSION_MINOR != $cln_config_minor_version) || ++ (CL_VERSION_PATCHLEVEL != $cln_config_micro_version)) { ++ printf("\n*** 'cln-config --version' returned %d.%d.%d, but the header file I found\n", $cln_config_major_version, $cln_config_minor_version, $cln_config_micro_version); ++ printf("*** corresponds to %d.%d.%d. This mismatch suggests your installation of CLN\n", CL_VERSION_MAJOR, CL_VERSION_MINOR, CL_VERSION_PATCHLEVEL); ++ printf("*** is corrupted or you have specified some wrong -I compiler flags.\n"); ++ printf("*** Please inquire and consider reinstalling CLN.\n"); ++ return 1; ++ } ++ if ((cln::version_major != $cln_config_major_version) || ++ (cln::version_minor != $cln_config_minor_version) || ++ (cln::version_patchlevel != $cln_config_micro_version)) { ++ printf("\n*** 'cln-config --version' returned %d.%d.%d, but the library I found\n", $cln_config_major_version, $cln_config_minor_version, $cln_config_micro_version); ++ printf("*** corresponds to %d.%d.%d. This mismatch suggests your installation of CLN\n", cln::version_major, cln::version_minor, cln::version_patchlevel); ++ printf("*** is corrupted or you have specified some wrong -L compiler flags.\n"); ++ printf("*** Please inquire and consider reinstalling CLN.\n"); ++ return 1; ++ } ++ return 0; + } ++ + _ACEOF +-rm -f conftest.$ac_objext conftest$ac_exeext ++rm -f conftest$ac_exeext + if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 +- (eval $ac_link) 2>conftest.er1 +- ac_status=$? +- grep -v '^ *+' conftest.er1 >conftest.err +- rm -f conftest.er1 +- cat conftest.err >&5 +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); } && +- { ac_try='test -z "$ac_cxx_werror_flag" +- || test ! -s conftest.err' +- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 +- (eval $ac_try) 2>&5 ++ (eval $ac_link) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; } && +- { ac_try='test -s conftest$ac_exeext' ++ (exit $ac_status); } && { ac_try='./conftest$ac_exeext' + { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then +- ac_cv_lib_intl_ngettext=yes ++ : + else +- echo "$as_me: failed program was:" >&5 ++ echo "$as_me: program exited with status $ac_status" >&5 ++echo "$as_me: failed program was:" >&5 + sed 's/^/| /' conftest.$ac_ext >&5 + +-ac_cv_lib_intl_ngettext=no ++( exit $ac_status ) ++no_cln=yes + fi +-rm -f conftest.err conftest.$ac_objext \ +- conftest$ac_exeext conftest.$ac_ext +-LIBS=$ac_check_lib_save_LIBS ++rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext + fi +-echo "$as_me:$LINENO: result: $ac_cv_lib_intl_ngettext" >&5 +-echo "${ECHO_T}$ac_cv_lib_intl_ngettext" >&6 +-if test $ac_cv_lib_intl_ngettext = yes; then +- echo "$as_me:$LINENO: checking for dcgettext in -lintl" >&5 +-echo $ECHO_N "checking for dcgettext in -lintl... $ECHO_C" >&6 +-if test "${ac_cv_lib_intl_dcgettext+set}" = set; then +- echo $ECHO_N "(cached) $ECHO_C" >&6 +-else +- ac_check_lib_save_LIBS=$LIBS +-LIBS="-lintl -liconv $LIBS" +-cat >conftest.$ac_ext <<_ACEOF ++ CPPFLAGS="$ac_save_CPPFLAGS" ++ LIBS="$ac_save_LIBS" ++ fi ++ if test "x$no_cln" = x ; then ++ echo "$as_me:$LINENO: result: yes, $cln_config_version" >&5 ++echo "${ECHO_T}yes, $cln_config_version" >&6 ++ ++ LIBS="$LIBS $CLN_LIBS" ++ CPPFLAGS="$CPPFLAGS $CLN_CPPFLAGS" ++ ++cat >>confdefs.h <<\_ACEOF ++#define HAVE_LIBCLN 1 ++_ACEOF ++ ++ ++ else ++ echo "$as_me:$LINENO: result: no" >&5 ++echo "${ECHO_T}no" >&6 ++ if test ! -f conf.clntest ; then ++ echo "*** Could not run CLN test program, checking why..." ++ CPPFLAGS="$CFLAGS $CLN_CPPFLAGS" ++ LIBS="$LIBS $CLN_LIBS" ++ cat >conftest.$ac_ext <<_ACEOF + /* confdefs.h. */ + _ACEOF + cat confdefs.h >>conftest.$ac_ext + cat >>conftest.$ac_ext <<_ACEOF + /* end confdefs.h. */ + +-/* Override any gcc2 internal prototype to avoid an error. */ +-#ifdef __cplusplus +-extern "C" +-#endif +-/* We use char because int might match the return type of a gcc2 +- builtin and then its argument prototype would still apply. */ +-char dcgettext (); ++#include ++#include ++ + int + main () + { +-dcgettext (); ++ return 0; + ; + return 0; + } +@@ -22140,673 +22020,793 @@ if { (eval echo "$as_me:$LINENO: \"$ac_l + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then +- ac_cv_lib_intl_dcgettext=yes ++ echo "*** The test program compiled, but did not run. This usually means" ++ echo "*** that the run-time linker is not finding CLN or finding the wrong" ++ echo "*** version of CLN. If it is not finding CLN, you'll need to set your" ++ echo "*** LD_LIBRARY_PATH environment variable, or edit /etc/ld.so.conf to point" ++ echo "*** to the installed location. Also, make sure you have run ldconfig if that" ++ echo "*** is required on your system." + else + echo "$as_me: failed program was:" >&5 + sed 's/^/| /' conftest.$ac_ext >&5 + +-ac_cv_lib_intl_dcgettext=no +-fi +-rm -f conftest.err conftest.$ac_objext \ +- conftest$ac_exeext conftest.$ac_ext +-LIBS=$ac_check_lib_save_LIBS +-fi +-echo "$as_me:$LINENO: result: $ac_cv_lib_intl_dcgettext" >&5 +-echo "${ECHO_T}$ac_cv_lib_intl_dcgettext" >&6 +-if test $ac_cv_lib_intl_dcgettext = yes; then +- gt_cv_func_dgettext_libintl=yes +- libintl_extra_libs=-liconv +-else +- : +-fi ++ echo "*** The test program failed to compile or link. See the file config.log for the" ++ echo "*** exact error that occured. This usually means CLN was incorrectly installed" ++ echo "*** or that you have moved CLN since it was installed. In the latter case, you" ++ echo "*** may want to edit the cln-config script: $CLN_CONFIG." ++fi ++rm -f conftest.err conftest.$ac_objext \ ++ conftest$ac_exeext conftest.$ac_ext ++ CPPFLAGS="$ac_save_CPPFLAGS" ++ LIBS="$ac_save_LIBS" ++ fi ++ CLN_CPPFLAGS="" ++ CLN_LIBS="" ++ { { echo "$as_me:$LINENO: error: No suitable installed version of CLN could be found." >&5 ++echo "$as_me: error: No suitable installed version of CLN could be found." >&2;} ++ { (exit 1); exit 1; }; } ++ fi ++ fi ++fi ++ ++ ++rm -f conf.clntest ++ ++ ++ ++ ++if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then ++ if test -n "$ac_tool_prefix"; then ++ # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args. ++set dummy ${ac_tool_prefix}pkg-config; ac_word=$2 ++echo "$as_me:$LINENO: checking for $ac_word" >&5 ++echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 ++if test "${ac_cv_path_PKG_CONFIG+set}" = set; then ++ echo $ECHO_N "(cached) $ECHO_C" >&6 ++else ++ case $PKG_CONFIG in ++ [\\/]* | ?:[\\/]*) ++ ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path. ++ ;; ++ *) ++ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR ++for as_dir in $PATH ++do ++ IFS=$as_save_IFS ++ test -z "$as_dir" && as_dir=. ++ for ac_exec_ext in '' $ac_executable_extensions; do ++ if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ++ ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" ++ echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 ++ break 2 ++ fi ++done ++done ++ ++ ;; ++esac ++fi ++PKG_CONFIG=$ac_cv_path_PKG_CONFIG ++ ++if test -n "$PKG_CONFIG"; then ++ echo "$as_me:$LINENO: result: $PKG_CONFIG" >&5 ++echo "${ECHO_T}$PKG_CONFIG" >&6 ++else ++ echo "$as_me:$LINENO: result: no" >&5 ++echo "${ECHO_T}no" >&6 ++fi ++ ++fi ++if test -z "$ac_cv_path_PKG_CONFIG"; then ++ ac_pt_PKG_CONFIG=$PKG_CONFIG ++ # Extract the first word of "pkg-config", so it can be a program name with args. ++set dummy pkg-config; ac_word=$2 ++echo "$as_me:$LINENO: checking for $ac_word" >&5 ++echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 ++if test "${ac_cv_path_ac_pt_PKG_CONFIG+set}" = set; then ++ echo $ECHO_N "(cached) $ECHO_C" >&6 ++else ++ case $ac_pt_PKG_CONFIG in ++ [\\/]* | ?:[\\/]*) ++ ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path. ++ ;; ++ *) ++ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR ++for as_dir in $PATH ++do ++ IFS=$as_save_IFS ++ test -z "$as_dir" && as_dir=. ++ for ac_exec_ext in '' $ac_executable_extensions; do ++ if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ++ ac_cv_path_ac_pt_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" ++ echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 ++ break 2 ++ fi ++done ++done ++ ++ ;; ++esac ++fi ++ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG ++ ++if test -n "$ac_pt_PKG_CONFIG"; then ++ echo "$as_me:$LINENO: result: $ac_pt_PKG_CONFIG" >&5 ++echo "${ECHO_T}$ac_pt_PKG_CONFIG" >&6 ++else ++ echo "$as_me:$LINENO: result: no" >&5 ++echo "${ECHO_T}no" >&6 ++fi ++ ++ PKG_CONFIG=$ac_pt_PKG_CONFIG ++else ++ PKG_CONFIG="$ac_cv_path_PKG_CONFIG" ++fi ++ ++fi ++if test -n "$PKG_CONFIG"; then ++ _pkg_min_version=0.9.0 ++ echo "$as_me:$LINENO: checking pkg-config is at least version $_pkg_min_version" >&5 ++echo $ECHO_N "checking pkg-config is at least version $_pkg_min_version... $ECHO_C" >&6 ++ if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then ++ echo "$as_me:$LINENO: result: yes" >&5 ++echo "${ECHO_T}yes" >&6 ++ else ++ echo "$as_me:$LINENO: result: no" >&5 ++echo "${ECHO_T}no" >&6 ++ PKG_CONFIG="" ++ fi ++ ++fi ++ ++pkg_failed=no ++echo "$as_me:$LINENO: checking for GLIB" >&5 ++echo $ECHO_N "checking for GLIB... $ECHO_C" >&6 ++ ++if test -n "$PKG_CONFIG"; then ++ if test -n "$GLIB_CFLAGS"; then ++ pkg_cv_GLIB_CFLAGS="$GLIB_CFLAGS" ++ else ++ if test -n "$PKG_CONFIG" && \ ++ { (echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \" ++ glib-2.0 >= 2.4 ++ libxml-2.0 ++ \"") >&5 ++ ($PKG_CONFIG --exists --print-errors " ++ glib-2.0 >= 2.4 ++ libxml-2.0 ++ ") 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; then ++ pkg_cv_GLIB_CFLAGS=`$PKG_CONFIG --cflags " ++ glib-2.0 >= 2.4 ++ libxml-2.0 ++ " 2>/dev/null` ++else ++ pkg_failed=yes ++fi ++ fi ++else ++ pkg_failed=untried ++fi ++if test -n "$PKG_CONFIG"; then ++ if test -n "$GLIB_LIBS"; then ++ pkg_cv_GLIB_LIBS="$GLIB_LIBS" ++ else ++ if test -n "$PKG_CONFIG" && \ ++ { (echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \" ++ glib-2.0 >= 2.4 ++ libxml-2.0 ++ \"") >&5 ++ ($PKG_CONFIG --exists --print-errors " ++ glib-2.0 >= 2.4 ++ libxml-2.0 ++ ") 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; then ++ pkg_cv_GLIB_LIBS=`$PKG_CONFIG --libs " ++ glib-2.0 >= 2.4 ++ libxml-2.0 ++ " 2>/dev/null` ++else ++ pkg_failed=yes ++fi ++ fi ++else ++ pkg_failed=untried ++fi ++ ++ ++ ++if test $pkg_failed = yes; then ++ ++if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then ++ _pkg_short_errors_supported=yes ++else ++ _pkg_short_errors_supported=no ++fi ++ if test $_pkg_short_errors_supported = yes; then ++ GLIB_PKG_ERRORS=`$PKG_CONFIG --short-errors --errors-to-stdout --print-errors " ++ glib-2.0 >= 2.4 ++ libxml-2.0 ++ "` ++ else ++ GLIB_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors " ++ glib-2.0 >= 2.4 ++ libxml-2.0 ++ "` ++ fi ++ # Put the nasty error message in config.log where it belongs ++ echo "$GLIB_PKG_ERRORS" >&5 ++ ++ { { echo "$as_me:$LINENO: error: Package requirements ( ++ glib-2.0 >= 2.4 ++ libxml-2.0 ++ ) were not met: ++ ++$GLIB_PKG_ERRORS ++ ++Consider adjusting the PKG_CONFIG_PATH environment variable if you ++installed software in a non-standard prefix. ++ ++Alternatively, you may set the environment variables GLIB_CFLAGS ++and GLIB_LIBS to avoid the need to call pkg-config. ++See the pkg-config man page for more details. ++" >&5 ++echo "$as_me: error: Package requirements ( ++ glib-2.0 >= 2.4 ++ libxml-2.0 ++ ) were not met: + +-else +- : +-fi ++$GLIB_PKG_ERRORS + +- fi ++Consider adjusting the PKG_CONFIG_PATH environment variable if you ++installed software in a non-standard prefix. + +- # +- # If we found libintl, then check in it for bind_textdomain_codeset(); +- # we'll prefer libc if neither have bind_textdomain_codeset(), +- # and both have dgettext and ngettext +- # +- if test "$gt_cv_func_dgettext_libintl" = "yes" ; then +- glib_save_LIBS="$LIBS" +- LIBS="$LIBS -lintl $libintl_extra_libs" +- unset ac_cv_func_bind_textdomain_codeset ++Alternatively, you may set the environment variables GLIB_CFLAGS ++and GLIB_LIBS to avoid the need to call pkg-config. ++See the pkg-config man page for more details. ++" >&2;} ++ { (exit 1); exit 1; }; } ++elif test $pkg_failed = untried; then ++ { { echo "$as_me:$LINENO: error: The pkg-config script could not be found or is too old. Make sure it ++is in your PATH or set the PKG_CONFIG environment variable to the full ++path to pkg-config. + +-for ac_func in bind_textdomain_codeset +-do +-as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh` +-echo "$as_me:$LINENO: checking for $ac_func" >&5 +-echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6 +-if eval "test \"\${$as_ac_var+set}\" = set"; then +- echo $ECHO_N "(cached) $ECHO_C" >&6 ++Alternatively, you may set the environment variables GLIB_CFLAGS ++and GLIB_LIBS to avoid the need to call pkg-config. ++See the pkg-config man page for more details. ++ ++To get pkg-config, see . ++See \`config.log' for more details." >&5 ++echo "$as_me: error: The pkg-config script could not be found or is too old. Make sure it ++is in your PATH or set the PKG_CONFIG environment variable to the full ++path to pkg-config. ++ ++Alternatively, you may set the environment variables GLIB_CFLAGS ++and GLIB_LIBS to avoid the need to call pkg-config. ++See the pkg-config man page for more details. ++ ++To get pkg-config, see . ++See \`config.log' for more details." >&2;} ++ { (exit 1); exit 1; }; } + else +- cat >conftest.$ac_ext <<_ACEOF +-/* confdefs.h. */ +-_ACEOF +-cat confdefs.h >>conftest.$ac_ext +-cat >>conftest.$ac_ext <<_ACEOF +-/* end confdefs.h. */ +-/* Define $ac_func to an innocuous variant, in case declares $ac_func. +- For example, HP-UX 11i declares gettimeofday. */ +-#define $ac_func innocuous_$ac_func ++ GLIB_CFLAGS=$pkg_cv_GLIB_CFLAGS ++ GLIB_LIBS=$pkg_cv_GLIB_LIBS ++ echo "$as_me:$LINENO: result: yes" >&5 ++echo "${ECHO_T}yes" >&6 ++ : ++fi + +-/* System header to define __stub macros and hopefully few prototypes, +- which can conflict with char $ac_func (); below. +- Prefer to if __STDC__ is defined, since +- exists even on freestanding compilers. */ + +-#ifdef __STDC__ +-# include +-#else +-# include +-#endif + +-#undef $ac_func ++QALCULATE_GTK="qalculate-gtk" ++LN_QALCULATE="qalculate-gtk" + +-/* Override any gcc2 internal prototype to avoid an error. */ +-#ifdef __cplusplus +-extern "C" +-{ +-#endif +-/* We use char because int might match the return type of a gcc2 +- builtin and then its argument prototype would still apply. */ +-char $ac_func (); +-/* The GNU C library defines this for functions which it implements +- to always fail with ENOSYS. Some functions are actually named +- something starting with __ and the normal name is an alias. */ +-#if defined (__stub_$ac_func) || defined (__stub___$ac_func) +-choke me +-#else +-char (*f) () = $ac_func; +-#endif +-#ifdef __cplusplus +-} +-#endif + +-int +-main () +-{ +-return f != $ac_func; +- ; +- return 0; +-} +-_ACEOF +-rm -f conftest.$ac_objext conftest$ac_exeext +-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 +- (eval $ac_link) 2>conftest.er1 +- ac_status=$? +- grep -v '^ *+' conftest.er1 >conftest.err +- rm -f conftest.er1 +- cat conftest.err >&5 +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); } && +- { ac_try='test -z "$ac_cxx_werror_flag" +- || test ! -s conftest.err' +- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 +- (eval $ac_try) 2>&5 ++pkg_failed=no ++echo "$as_me:$LINENO: checking for GTK" >&5 ++echo $ECHO_N "checking for GTK... $ECHO_C" >&6 ++ ++if test -n "$PKG_CONFIG"; then ++ if test -n "$GTK_CFLAGS"; then ++ pkg_cv_GTK_CFLAGS="$GTK_CFLAGS" ++ else ++ if test -n "$PKG_CONFIG" && \ ++ { (echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \" ++ gtk+-2.0 >= 2.4 ++ gdk-pixbuf-2.0 ++ libglade-2.0 ++ \"") >&5 ++ ($PKG_CONFIG --exists --print-errors " ++ gtk+-2.0 >= 2.4 ++ gdk-pixbuf-2.0 ++ libglade-2.0 ++ ") 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; } && +- { ac_try='test -s conftest$ac_exeext' +- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 +- (eval $ac_try) 2>&5 ++ (exit $ac_status); }; then ++ pkg_cv_GTK_CFLAGS=`$PKG_CONFIG --cflags " ++ gtk+-2.0 >= 2.4 ++ gdk-pixbuf-2.0 ++ libglade-2.0 ++ " 2>/dev/null` ++else ++ pkg_failed=yes ++fi ++ fi ++else ++ pkg_failed=untried ++fi ++if test -n "$PKG_CONFIG"; then ++ if test -n "$GTK_LIBS"; then ++ pkg_cv_GTK_LIBS="$GTK_LIBS" ++ else ++ if test -n "$PKG_CONFIG" && \ ++ { (echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \" ++ gtk+-2.0 >= 2.4 ++ gdk-pixbuf-2.0 ++ libglade-2.0 ++ \"") >&5 ++ ($PKG_CONFIG --exists --print-errors " ++ gtk+-2.0 >= 2.4 ++ gdk-pixbuf-2.0 ++ libglade-2.0 ++ ") 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; }; then +- eval "$as_ac_var=yes" ++ (exit $ac_status); }; then ++ pkg_cv_GTK_LIBS=`$PKG_CONFIG --libs " ++ gtk+-2.0 >= 2.4 ++ gdk-pixbuf-2.0 ++ libglade-2.0 ++ " 2>/dev/null` + else +- echo "$as_me: failed program was:" >&5 +-sed 's/^/| /' conftest.$ac_ext >&5 +- +-eval "$as_ac_var=no" ++ pkg_failed=yes + fi +-rm -f conftest.err conftest.$ac_objext \ +- conftest$ac_exeext conftest.$ac_ext ++ fi ++else ++ pkg_failed=untried + fi +-echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5 +-echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6 +-if test `eval echo '${'$as_ac_var'}'` = yes; then +- cat >>confdefs.h <<_ACEOF +-#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1 +-_ACEOF + ++ ++ ++if test $pkg_failed = yes; then ++ ++if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then ++ _pkg_short_errors_supported=yes ++else ++ _pkg_short_errors_supported=no + fi +-done ++ if test $_pkg_short_errors_supported = yes; then ++ GTK_PKG_ERRORS=`$PKG_CONFIG --short-errors --errors-to-stdout --print-errors " ++ gtk+-2.0 >= 2.4 ++ gdk-pixbuf-2.0 ++ libglade-2.0 ++ "` ++ else ++ GTK_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors " ++ gtk+-2.0 >= 2.4 ++ gdk-pixbuf-2.0 ++ libglade-2.0 ++ "` ++ fi ++ # Put the nasty error message in config.log where it belongs ++ echo "$GTK_PKG_ERRORS" >&5 ++ ++ { { echo "$as_me:$LINENO: error: Package requirements ( ++ gtk+-2.0 >= 2.4 ++ gdk-pixbuf-2.0 ++ libglade-2.0 ++ ) were not met: ++ ++$GTK_PKG_ERRORS ++ ++Consider adjusting the PKG_CONFIG_PATH environment variable if you ++installed software in a non-standard prefix. ++ ++Alternatively, you may set the environment variables GTK_CFLAGS ++and GTK_LIBS to avoid the need to call pkg-config. ++See the pkg-config man page for more details. ++" >&5 ++echo "$as_me: error: Package requirements ( ++ gtk+-2.0 >= 2.4 ++ gdk-pixbuf-2.0 ++ libglade-2.0 ++ ) were not met: + +- LIBS="$glib_save_LIBS" ++$GTK_PKG_ERRORS + +- if test "$ac_cv_func_bind_textdomain_codeset" = "yes" ; then +- gt_cv_func_dgettext_libc=no +- else +- if test "$gt_cv_func_dgettext_libc" = "yes" \ +- && test "$gt_cv_func_ngettext_libc" = "yes"; then +- gt_cv_func_dgettext_libintl=no +- fi +- fi +- fi +- fi ++Consider adjusting the PKG_CONFIG_PATH environment variable if you ++installed software in a non-standard prefix. + +- if test "$gt_cv_func_dgettext_libc" = "yes" \ +- || test "$gt_cv_func_dgettext_libintl" = "yes"; then +- gt_cv_have_gettext=yes +- fi ++Alternatively, you may set the environment variables GTK_CFLAGS ++and GTK_LIBS to avoid the need to call pkg-config. ++See the pkg-config man page for more details. ++" >&2;} ++ { (exit 1); exit 1; }; } ++elif test $pkg_failed = untried; then ++ { { echo "$as_me:$LINENO: error: The pkg-config script could not be found or is too old. Make sure it ++is in your PATH or set the PKG_CONFIG environment variable to the full ++path to pkg-config. + +- if test "$gt_cv_func_dgettext_libintl" = "yes"; then +- INTLLIBS="-lintl $libintl_extra_libs" +- fi ++Alternatively, you may set the environment variables GTK_CFLAGS ++and GTK_LIBS to avoid the need to call pkg-config. ++See the pkg-config man page for more details. + +- if test "$gt_cv_have_gettext" = "yes"; then ++To get pkg-config, see . ++See \`config.log' for more details." >&5 ++echo "$as_me: error: The pkg-config script could not be found or is too old. Make sure it ++is in your PATH or set the PKG_CONFIG environment variable to the full ++path to pkg-config. + +-cat >>confdefs.h <<\_ACEOF +-#define HAVE_GETTEXT 1 +-_ACEOF ++Alternatively, you may set the environment variables GTK_CFLAGS ++and GTK_LIBS to avoid the need to call pkg-config. ++See the pkg-config man page for more details. + +- # Extract the first word of "msgfmt", so it can be a program name with args. +-set dummy msgfmt; ac_word=$2 +-echo "$as_me:$LINENO: checking for $ac_word" >&5 +-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 +-if test "${ac_cv_path_MSGFMT+set}" = set; then +- echo $ECHO_N "(cached) $ECHO_C" >&6 +-else +- case "$MSGFMT" in +- /*) +- ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path. +- ;; +- *) +- IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" +- for ac_dir in $PATH; do +- test -z "$ac_dir" && ac_dir=. +- if test -f $ac_dir/$ac_word; then +- if test -z "`$ac_dir/$ac_word -h 2>&1 | grep 'dv '`"; then +- ac_cv_path_MSGFMT="$ac_dir/$ac_word" +- break +- fi +- fi +- done +- IFS="$ac_save_ifs" +- test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT="no" +- ;; +-esac +-fi +-MSGFMT="$ac_cv_path_MSGFMT" +-if test "$MSGFMT" != "no"; then +- echo "$as_me:$LINENO: result: $MSGFMT" >&5 +-echo "${ECHO_T}$MSGFMT" >&6 ++To get pkg-config, see . ++See \`config.log' for more details." >&2;} ++ { (exit 1); exit 1; }; } + else +- echo "$as_me:$LINENO: result: no" >&5 +-echo "${ECHO_T}no" >&6 ++ GTK_CFLAGS=$pkg_cv_GTK_CFLAGS ++ GTK_LIBS=$pkg_cv_GTK_LIBS ++ echo "$as_me:$LINENO: result: yes" >&5 ++echo "${ECHO_T}yes" >&6 ++ : + fi +- if test "$MSGFMT" != "no"; then +- glib_save_LIBS="$LIBS" +- LIBS="$LIBS $INTLLIBS" + +-for ac_func in dcgettext +-do +-as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh` +-echo "$as_me:$LINENO: checking for $ac_func" >&5 +-echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6 +-if eval "test \"\${$as_ac_var+set}\" = set"; then +- echo $ECHO_N "(cached) $ECHO_C" >&6 +-else +- cat >conftest.$ac_ext <<_ACEOF +-/* confdefs.h. */ +-_ACEOF +-cat confdefs.h >>conftest.$ac_ext +-cat >>conftest.$ac_ext <<_ACEOF +-/* end confdefs.h. */ +-/* Define $ac_func to an innocuous variant, in case declares $ac_func. +- For example, HP-UX 11i declares gettimeofday. */ +-#define $ac_func innocuous_$ac_func + +-/* System header to define __stub macros and hopefully few prototypes, +- which can conflict with char $ac_func (); below. +- Prefer to if __STDC__ is defined, since +- exists even on freestanding compilers. */ + +-#ifdef __STDC__ +-# include +-#else +-# include +-#endif ++GTK_LIBS="-export-dynamic $GTK_LIBS" + +-#undef $ac_func + +-/* Override any gcc2 internal prototype to avoid an error. */ +-#ifdef __cplusplus +-extern "C" +-{ +-#endif +-/* We use char because int might match the return type of a gcc2 +- builtin and then its argument prototype would still apply. */ +-char $ac_func (); +-/* The GNU C library defines this for functions which it implements +- to always fail with ENOSYS. Some functions are actually named +- something starting with __ and the normal name is an alias. */ +-#if defined (__stub_$ac_func) || defined (__stub___$ac_func) +-choke me +-#else +-char (*f) () = $ac_func; +-#endif +-#ifdef __cplusplus +-} +-#endif ++pkg_failed=no ++echo "$as_me:$LINENO: checking for QALCULATE" >&5 ++echo $ECHO_N "checking for QALCULATE... $ECHO_C" >&6 + +-int +-main () +-{ +-return f != $ac_func; +- ; +- return 0; +-} +-_ACEOF +-rm -f conftest.$ac_objext conftest$ac_exeext +-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 +- (eval $ac_link) 2>conftest.er1 +- ac_status=$? +- grep -v '^ *+' conftest.er1 >conftest.err +- rm -f conftest.er1 +- cat conftest.err >&5 +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); } && +- { ac_try='test -z "$ac_cxx_werror_flag" +- || test ! -s conftest.err' +- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 +- (eval $ac_try) 2>&5 +- ac_status=$? +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; } && +- { ac_try='test -s conftest$ac_exeext' +- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 +- (eval $ac_try) 2>&5 ++if test -n "$PKG_CONFIG"; then ++ if test -n "$QALCULATE_CFLAGS"; then ++ pkg_cv_QALCULATE_CFLAGS="$QALCULATE_CFLAGS" ++ else ++ if test -n "$PKG_CONFIG" && \ ++ { (echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \" ++ libqalculate >= 0.9.4 ++ \"") >&5 ++ ($PKG_CONFIG --exists --print-errors " ++ libqalculate >= 0.9.4 ++ ") 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; }; then +- eval "$as_ac_var=yes" ++ (exit $ac_status); }; then ++ pkg_cv_QALCULATE_CFLAGS=`$PKG_CONFIG --cflags " ++ libqalculate >= 0.9.4 ++ " 2>/dev/null` + else +- echo "$as_me: failed program was:" >&5 +-sed 's/^/| /' conftest.$ac_ext >&5 +- +-eval "$as_ac_var=no" +-fi +-rm -f conftest.err conftest.$ac_objext \ +- conftest$ac_exeext conftest.$ac_ext +-fi +-echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5 +-echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6 +-if test `eval echo '${'$as_ac_var'}'` = yes; then +- cat >>confdefs.h <<_ACEOF +-#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1 +-_ACEOF +- ++ pkg_failed=yes + fi +-done +- +- # Extract the first word of "gmsgfmt", so it can be a program name with args. +-set dummy gmsgfmt; ac_word=$2 +-echo "$as_me:$LINENO: checking for $ac_word" >&5 +-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 +-if test "${ac_cv_path_GMSGFMT+set}" = set; then +- echo $ECHO_N "(cached) $ECHO_C" >&6 ++ fi + else +- case $GMSGFMT in +- [\\/]* | ?:[\\/]*) +- ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path. +- ;; +- *) +- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +-for as_dir in $PATH +-do +- IFS=$as_save_IFS +- test -z "$as_dir" && as_dir=. +- for ac_exec_ext in '' $ac_executable_extensions; do +- if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then +- ac_cv_path_GMSGFMT="$as_dir/$ac_word$ac_exec_ext" +- echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 +- break 2 +- fi +-done +-done +- +- test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT" +- ;; +-esac ++ pkg_failed=untried + fi +-GMSGFMT=$ac_cv_path_GMSGFMT +- +-if test -n "$GMSGFMT"; then +- echo "$as_me:$LINENO: result: $GMSGFMT" >&5 +-echo "${ECHO_T}$GMSGFMT" >&6 ++if test -n "$PKG_CONFIG"; then ++ if test -n "$QALCULATE_LIBS"; then ++ pkg_cv_QALCULATE_LIBS="$QALCULATE_LIBS" ++ else ++ if test -n "$PKG_CONFIG" && \ ++ { (echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \" ++ libqalculate >= 0.9.4 ++ \"") >&5 ++ ($PKG_CONFIG --exists --print-errors " ++ libqalculate >= 0.9.4 ++ ") 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; then ++ pkg_cv_QALCULATE_LIBS=`$PKG_CONFIG --libs " ++ libqalculate >= 0.9.4 ++ " 2>/dev/null` + else +- echo "$as_me:$LINENO: result: no" >&5 +-echo "${ECHO_T}no" >&6 ++ pkg_failed=yes + fi +- +- # Extract the first word of "xgettext", so it can be a program name with args. +-set dummy xgettext; ac_word=$2 +-echo "$as_me:$LINENO: checking for $ac_word" >&5 +-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 +-if test "${ac_cv_path_XGETTEXT+set}" = set; then +- echo $ECHO_N "(cached) $ECHO_C" >&6 +-else +- case "$XGETTEXT" in +- /*) +- ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path. +- ;; +- *) +- IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" +- for ac_dir in $PATH; do +- test -z "$ac_dir" && ac_dir=. +- if test -f $ac_dir/$ac_word; then +- if test -z "`$ac_dir/$ac_word -h 2>&1 | grep '(HELP)'`"; then +- ac_cv_path_XGETTEXT="$ac_dir/$ac_word" +- break +- fi + fi +- done +- IFS="$ac_save_ifs" +- test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":" +- ;; +-esac +-fi +-XGETTEXT="$ac_cv_path_XGETTEXT" +-if test "$XGETTEXT" != ":"; then +- echo "$as_me:$LINENO: result: $XGETTEXT" >&5 +-echo "${ECHO_T}$XGETTEXT" >&6 + else +- echo "$as_me:$LINENO: result: no" >&5 +-echo "${ECHO_T}no" >&6 ++ pkg_failed=untried + fi + +- cat >conftest.$ac_ext <<_ACEOF +-/* confdefs.h. */ +-_ACEOF +-cat confdefs.h >>conftest.$ac_ext +-cat >>conftest.$ac_ext <<_ACEOF +-/* end confdefs.h. */ + +-int +-main () +-{ +-extern int _nl_msg_cat_cntr; +- return _nl_msg_cat_cntr +- ; +- return 0; +-} +-_ACEOF +-rm -f conftest.$ac_objext conftest$ac_exeext +-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 +- (eval $ac_link) 2>conftest.er1 +- ac_status=$? +- grep -v '^ *+' conftest.er1 >conftest.err +- rm -f conftest.er1 +- cat conftest.err >&5 +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); } && +- { ac_try='test -z "$ac_cxx_werror_flag" +- || test ! -s conftest.err' +- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 +- (eval $ac_try) 2>&5 +- ac_status=$? +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; } && +- { ac_try='test -s conftest$ac_exeext' +- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 +- (eval $ac_try) 2>&5 +- ac_status=$? +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; }; then +- CATOBJEXT=.gmo +- DATADIRNAME=share ++ ++if test $pkg_failed = yes; then ++ ++if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then ++ _pkg_short_errors_supported=yes + else +- echo "$as_me: failed program was:" >&5 +-sed 's/^/| /' conftest.$ac_ext >&5 ++ _pkg_short_errors_supported=no ++fi ++ if test $_pkg_short_errors_supported = yes; then ++ QALCULATE_PKG_ERRORS=`$PKG_CONFIG --short-errors --errors-to-stdout --print-errors " ++ libqalculate >= 0.9.4 ++ "` ++ else ++ QALCULATE_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors " ++ libqalculate >= 0.9.4 ++ "` ++ fi ++ # Put the nasty error message in config.log where it belongs ++ echo "$QALCULATE_PKG_ERRORS" >&5 + +-case $host in +- *-*-solaris*) +- echo "$as_me:$LINENO: checking for bind_textdomain_codeset" >&5 +-echo $ECHO_N "checking for bind_textdomain_codeset... $ECHO_C" >&6 +-if test "${ac_cv_func_bind_textdomain_codeset+set}" = set; then +- echo $ECHO_N "(cached) $ECHO_C" >&6 ++ { { echo "$as_me:$LINENO: error: Package requirements ( ++ libqalculate >= 0.9.4 ++ ) were not met: ++ ++$QALCULATE_PKG_ERRORS ++ ++Consider adjusting the PKG_CONFIG_PATH environment variable if you ++installed software in a non-standard prefix. ++ ++Alternatively, you may set the environment variables QALCULATE_CFLAGS ++and QALCULATE_LIBS to avoid the need to call pkg-config. ++See the pkg-config man page for more details. ++" >&5 ++echo "$as_me: error: Package requirements ( ++ libqalculate >= 0.9.4 ++ ) were not met: ++ ++$QALCULATE_PKG_ERRORS ++ ++Consider adjusting the PKG_CONFIG_PATH environment variable if you ++installed software in a non-standard prefix. ++ ++Alternatively, you may set the environment variables QALCULATE_CFLAGS ++and QALCULATE_LIBS to avoid the need to call pkg-config. ++See the pkg-config man page for more details. ++" >&2;} ++ { (exit 1); exit 1; }; } ++elif test $pkg_failed = untried; then ++ { { echo "$as_me:$LINENO: error: The pkg-config script could not be found or is too old. Make sure it ++is in your PATH or set the PKG_CONFIG environment variable to the full ++path to pkg-config. ++ ++Alternatively, you may set the environment variables QALCULATE_CFLAGS ++and QALCULATE_LIBS to avoid the need to call pkg-config. ++See the pkg-config man page for more details. ++ ++To get pkg-config, see . ++See \`config.log' for more details." >&5 ++echo "$as_me: error: The pkg-config script could not be found or is too old. Make sure it ++is in your PATH or set the PKG_CONFIG environment variable to the full ++path to pkg-config. ++ ++Alternatively, you may set the environment variables QALCULATE_CFLAGS ++and QALCULATE_LIBS to avoid the need to call pkg-config. ++See the pkg-config man page for more details. ++ ++To get pkg-config, see . ++See \`config.log' for more details." >&2;} ++ { (exit 1); exit 1; }; } + else +- cat >conftest.$ac_ext <<_ACEOF +-/* confdefs.h. */ +-_ACEOF +-cat confdefs.h >>conftest.$ac_ext +-cat >>conftest.$ac_ext <<_ACEOF +-/* end confdefs.h. */ +-/* Define bind_textdomain_codeset to an innocuous variant, in case declares bind_textdomain_codeset. +- For example, HP-UX 11i declares gettimeofday. */ +-#define bind_textdomain_codeset innocuous_bind_textdomain_codeset ++ QALCULATE_CFLAGS=$pkg_cv_QALCULATE_CFLAGS ++ QALCULATE_LIBS=$pkg_cv_QALCULATE_LIBS ++ echo "$as_me:$LINENO: result: yes" >&5 ++echo "${ECHO_T}yes" >&6 ++ : ++fi + +-/* System header to define __stub macros and hopefully few prototypes, +- which can conflict with char bind_textdomain_codeset (); below. +- Prefer to if __STDC__ is defined, since +- exists even on freestanding compilers. */ + +-#ifdef __STDC__ +-# include +-#else +-# include +-#endif + +-#undef bind_textdomain_codeset ++LIBGNOME_REQUIRED=2.0.0 ++LIBGNOMEUI_REQUIRED=2.0.0 + +-/* Override any gcc2 internal prototype to avoid an error. */ +-#ifdef __cplusplus +-extern "C" +-{ +-#endif +-/* We use char because int might match the return type of a gcc2 +- builtin and then its argument prototype would still apply. */ +-char bind_textdomain_codeset (); +-/* The GNU C library defines this for functions which it implements +- to always fail with ENOSYS. Some functions are actually named +- something starting with __ and the normal name is an alias. */ +-#if defined (__stub_bind_textdomain_codeset) || defined (__stub___bind_textdomain_codeset) +-choke me +-#else +-char (*f) () = bind_textdomain_codeset; +-#endif +-#ifdef __cplusplus +-} +-#endif + +-int +-main () +-{ +-return f != bind_textdomain_codeset; +- ; +- return 0; +-} +-_ACEOF +-rm -f conftest.$ac_objext conftest$ac_exeext +-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 +- (eval $ac_link) 2>conftest.er1 +- ac_status=$? +- grep -v '^ *+' conftest.er1 >conftest.err +- rm -f conftest.er1 +- cat conftest.err >&5 +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); } && +- { ac_try='test -z "$ac_cxx_werror_flag" +- || test ! -s conftest.err' +- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 +- (eval $ac_try) 2>&5 +- ac_status=$? +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; } && +- { ac_try='test -s conftest$ac_exeext' +- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 +- (eval $ac_try) 2>&5 ++pkg_failed=no ++echo "$as_me:$LINENO: checking for LIBGNOME" >&5 ++echo $ECHO_N "checking for LIBGNOME... $ECHO_C" >&6 ++ ++if test -n "$PKG_CONFIG"; then ++ if test -n "$LIBGNOME_CFLAGS"; then ++ pkg_cv_LIBGNOME_CFLAGS="$LIBGNOME_CFLAGS" ++ else ++ if test -n "$PKG_CONFIG" && \ ++ { (echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \"libgnome-2.0 >= \$LIBGNOME_REQUIRED\"") >&5 ++ ($PKG_CONFIG --exists --print-errors "libgnome-2.0 >= $LIBGNOME_REQUIRED") 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; }; then +- ac_cv_func_bind_textdomain_codeset=yes ++ (exit $ac_status); }; then ++ pkg_cv_LIBGNOME_CFLAGS=`$PKG_CONFIG --cflags "libgnome-2.0 >= $LIBGNOME_REQUIRED" 2>/dev/null` + else +- echo "$as_me: failed program was:" >&5 +-sed 's/^/| /' conftest.$ac_ext >&5 +- +-ac_cv_func_bind_textdomain_codeset=no +-fi +-rm -f conftest.err conftest.$ac_objext \ +- conftest$ac_exeext conftest.$ac_ext ++ pkg_failed=yes + fi +-echo "$as_me:$LINENO: result: $ac_cv_func_bind_textdomain_codeset" >&5 +-echo "${ECHO_T}$ac_cv_func_bind_textdomain_codeset" >&6 +-if test $ac_cv_func_bind_textdomain_codeset = yes; then +- CATOBJEXT=.gmo +- DATADIRNAME=share ++ fi + else +- CATOBJEXT=.mo +- DATADIRNAME=lib ++ pkg_failed=untried + fi +- +- ;; +- *) +- CATOBJEXT=.mo +- DATADIRNAME=lib +- ;; +- esac ++if test -n "$PKG_CONFIG"; then ++ if test -n "$LIBGNOME_LIBS"; then ++ pkg_cv_LIBGNOME_LIBS="$LIBGNOME_LIBS" ++ else ++ if test -n "$PKG_CONFIG" && \ ++ { (echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \"libgnome-2.0 >= \$LIBGNOME_REQUIRED\"") >&5 ++ ($PKG_CONFIG --exists --print-errors "libgnome-2.0 >= $LIBGNOME_REQUIRED") 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; then ++ pkg_cv_LIBGNOME_LIBS=`$PKG_CONFIG --libs "libgnome-2.0 >= $LIBGNOME_REQUIRED" 2>/dev/null` ++else ++ pkg_failed=yes + fi +-rm -f conftest.err conftest.$ac_objext \ +- conftest$ac_exeext conftest.$ac_ext +- LIBS="$glib_save_LIBS" +- INSTOBJEXT=.mo +- else +- gt_cv_have_gettext=no +- fi +- fi +- ++ fi ++else ++ pkg_failed=untried + fi + + + +- if test "$gt_cv_have_gettext" = "yes" ; then ++if test $pkg_failed = yes; then + +-cat >>confdefs.h <<\_ACEOF +-#define ENABLE_NLS 1 +-_ACEOF ++if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then ++ _pkg_short_errors_supported=yes ++else ++ _pkg_short_errors_supported=no ++fi ++ if test $_pkg_short_errors_supported = yes; then ++ LIBGNOME_PKG_ERRORS=`$PKG_CONFIG --short-errors --errors-to-stdout --print-errors "libgnome-2.0 >= $LIBGNOME_REQUIRED"` ++ else ++ LIBGNOME_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "libgnome-2.0 >= $LIBGNOME_REQUIRED"` ++ fi ++ # Put the nasty error message in config.log where it belongs ++ echo "$LIBGNOME_PKG_ERRORS" >&5 + +- fi ++ { echo "$as_me:$LINENO: WARNING: libgnome-2.0 was not found. The manual will not be accessible from within Qalculate!" >&5 ++echo "$as_me: WARNING: libgnome-2.0 was not found. The manual will not be accessible from within Qalculate!" >&2;} ++elif test $pkg_failed = untried; then ++ { echo "$as_me:$LINENO: WARNING: libgnome-2.0 was not found. The manual will not be accessible from within Qalculate!" >&5 ++echo "$as_me: WARNING: libgnome-2.0 was not found. The manual will not be accessible from within Qalculate!" >&2;} ++else ++ LIBGNOME_CFLAGS=$pkg_cv_LIBGNOME_CFLAGS ++ LIBGNOME_LIBS=$pkg_cv_LIBGNOME_LIBS ++ echo "$as_me:$LINENO: result: yes" >&5 ++echo "${ECHO_T}yes" >&6 + +- if test "$XGETTEXT" != ":"; then +- if $XGETTEXT --omit-header /dev/null 2> /dev/null; then +- : ; +- else +- echo "$as_me:$LINENO: result: found xgettext program is not GNU xgettext; ignore it" >&5 +-echo "${ECHO_T}found xgettext program is not GNU xgettext; ignore it" >&6 +- XGETTEXT=":" +- fi +- fi + +- # We need to process the po/ directory. +- POSUB=po + +- ac_config_commands="$ac_config_commands default-1" + ++cat >>confdefs.h <<\_ACEOF ++#define HAVE_LIBGNOME 1 ++_ACEOF + +- for lang in $ALL_LINGUAS; do +- GMOFILES="$GMOFILES $lang.gmo" +- POFILES="$POFILES $lang.po" +- done + ++fi + + ++pkg_failed=no ++echo "$as_me:$LINENO: checking for LIBGNOMEUI" >&5 ++echo $ECHO_N "checking for LIBGNOMEUI... $ECHO_C" >&6 + ++if test -n "$PKG_CONFIG"; then ++ if test -n "$LIBGNOMEUI_CFLAGS"; then ++ pkg_cv_LIBGNOMEUI_CFLAGS="$LIBGNOMEUI_CFLAGS" ++ else ++ if test -n "$PKG_CONFIG" && \ ++ { (echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \"libgnomeui-2.0 >= \$LIBGNOMEUI_REQUIRED\"") >&5 ++ ($PKG_CONFIG --exists --print-errors "libgnomeui-2.0 >= $LIBGNOMEUI_REQUIRED") 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; then ++ pkg_cv_LIBGNOMEUI_CFLAGS=`$PKG_CONFIG --cflags "libgnomeui-2.0 >= $LIBGNOMEUI_REQUIRED" 2>/dev/null` ++else ++ pkg_failed=yes ++fi ++ fi ++else ++ pkg_failed=untried ++fi ++if test -n "$PKG_CONFIG"; then ++ if test -n "$LIBGNOMEUI_LIBS"; then ++ pkg_cv_LIBGNOMEUI_LIBS="$LIBGNOMEUI_LIBS" ++ else ++ if test -n "$PKG_CONFIG" && \ ++ { (echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \"libgnomeui-2.0 >= \$LIBGNOMEUI_REQUIRED\"") >&5 ++ ($PKG_CONFIG --exists --print-errors "libgnomeui-2.0 >= $LIBGNOMEUI_REQUIRED") 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; then ++ pkg_cv_LIBGNOMEUI_LIBS=`$PKG_CONFIG --libs "libgnomeui-2.0 >= $LIBGNOMEUI_REQUIRED" 2>/dev/null` ++else ++ pkg_failed=yes ++fi ++ fi ++else ++ pkg_failed=untried ++fi + + + ++if test $pkg_failed = yes; then + ++if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then ++ _pkg_short_errors_supported=yes ++else ++ _pkg_short_errors_supported=no ++fi ++ if test $_pkg_short_errors_supported = yes; then ++ LIBGNOMEUI_PKG_ERRORS=`$PKG_CONFIG --short-errors --errors-to-stdout --print-errors "libgnomeui-2.0 >= $LIBGNOMEUI_REQUIRED"` ++ else ++ LIBGNOMEUI_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "libgnomeui-2.0 >= $LIBGNOMEUI_REQUIRED"` ++ fi ++ # Put the nasty error message in config.log where it belongs ++ echo "$LIBGNOMEUI_PKG_ERRORS" >&5 + ++ { echo "$as_me:$LINENO: WARNING: libgnomeui-2.0 was not found." >&5 ++echo "$as_me: WARNING: libgnomeui-2.0 was not found." >&2;} ++elif test $pkg_failed = untried; then ++ { echo "$as_me:$LINENO: WARNING: libgnomeui-2.0 was not found." >&5 ++echo "$as_me: WARNING: libgnomeui-2.0 was not found." >&2;} ++else ++ LIBGNOMEUI_CFLAGS=$pkg_cv_LIBGNOMEUI_CFLAGS ++ LIBGNOMEUI_LIBS=$pkg_cv_LIBGNOMEUI_LIBS ++ echo "$as_me:$LINENO: result: yes" >&5 ++echo "${ECHO_T}yes" >&6 + + + + +- if test "$gt_cv_have_gettext" = "yes"; then +- if test "x$ALL_LINGUAS" = "x"; then +- LINGUAS= +- else +- echo "$as_me:$LINENO: checking for catalogs to be installed" >&5 +-echo $ECHO_N "checking for catalogs to be installed... $ECHO_C" >&6 +- NEW_LINGUAS= +- for presentlang in $ALL_LINGUAS; do +- useit=no +- if test "%UNSET%" != "${LINGUAS-%UNSET%}"; then +- desiredlanguages="$LINGUAS" +- else +- desiredlanguages="$ALL_LINGUAS" +- fi +- for desiredlang in $desiredlanguages; do +- # Use the presentlang catalog if desiredlang is +- # a. equal to presentlang, or +- # b. a variant of presentlang (because in this case, +- # presentlang can be used as a fallback for messages +- # which are not translated in the desiredlang catalog). +- case "$desiredlang" in +- "$presentlang"*) useit=yes;; +- esac +- done +- if test $useit = yes; then +- NEW_LINGUAS="$NEW_LINGUAS $presentlang" +- fi +- done +- LINGUAS=$NEW_LINGUAS +- echo "$as_me:$LINENO: result: $LINGUAS" >&5 +-echo "${ECHO_T}$LINGUAS" >&6 +- fi ++cat >>confdefs.h <<\_ACEOF ++#define HAVE_LIBGNOMEUI 1 ++_ACEOF + +- if test -n "$LINGUAS"; then +- for lang in $LINGUAS; do CATALOGS="$CATALOGS $lang$CATOBJEXT"; done +- fi +- fi + +- MKINSTALLDIRS= +- if test -n "$ac_aux_dir"; then +- MKINSTALLDIRS="$ac_aux_dir/mkinstalldirs" +- fi +- if test -z "$MKINSTALLDIRS"; then +- MKINSTALLDIRS="\$(top_srcdir)/mkinstalldirs" +- fi ++fi + + +- test -d po || mkdir po +- if test "x$srcdir" != "x."; then +- if test "x`echo $srcdir | sed 's@/.*@@'`" = "x"; then +- posrcprefix="$srcdir/" +- else +- posrcprefix="../$srcdir/" +- fi +- else +- posrcprefix="../" +- fi +- rm -f po/POTFILES +- sed -e "/^#/d" -e "/^\$/d" -e "s,.*, $posrcprefix& \\\\," -e "\$s/\(.*\) \\\\/\1/" \ +- < $srcdir/po/POTFILES.in > po/POTFILES ++# Extract the first word of "scrollkeeper-config", so it can be a program name with args. ++set dummy scrollkeeper-config; ac_word=$2 ++echo "$as_me:$LINENO: checking for $ac_word" >&5 ++echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 ++if test "${ac_cv_path_SCROLLKEEPER_CONFIG+set}" = set; then ++ echo $ECHO_N "(cached) $ECHO_C" >&6 ++else ++ case $SCROLLKEEPER_CONFIG in ++ [\\/]* | ?:[\\/]*) ++ ac_cv_path_SCROLLKEEPER_CONFIG="$SCROLLKEEPER_CONFIG" # Let the user override the test with a path. ++ ;; ++ *) ++ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR ++for as_dir in $PATH ++do ++ IFS=$as_save_IFS ++ test -z "$as_dir" && as_dir=. ++ for ac_exec_ext in '' $ac_executable_extensions; do ++ if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ++ ac_cv_path_SCROLLKEEPER_CONFIG="$as_dir/$ac_word$ac_exec_ext" ++ echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 ++ break 2 ++ fi ++done ++done + ++ test -z "$ac_cv_path_SCROLLKEEPER_CONFIG" && ac_cv_path_SCROLLKEEPER_CONFIG="no" ++ ;; ++esac ++fi ++SCROLLKEEPER_CONFIG=$ac_cv_path_SCROLLKEEPER_CONFIG + +-echo "$as_me:$LINENO: checking locale directory" >&5 +-echo $ECHO_N "checking locale directory... $ECHO_C" >&6 +-if test "x$prefix" = "xNONE"; then +- PACKAGE_LOCALE_DIR=$ac_default_prefix/share/locale ++if test -n "$SCROLLKEEPER_CONFIG"; then ++ echo "$as_me:$LINENO: result: $SCROLLKEEPER_CONFIG" >&5 ++echo "${ECHO_T}$SCROLLKEEPER_CONFIG" >&6 + else +- PACKAGE_LOCALE_DIR=$prefix/share/locale ++ echo "$as_me:$LINENO: result: no" >&5 ++echo "${ECHO_T}no" >&6 + fi + +- +-cat >>confdefs.h <<_ACEOF +-#define PACKAGE_LOCALE_DIR "$PACKAGE_LOCALE_DIR" +-_ACEOF +- +- echo "$as_me:$LINENO: result: \"$PACKAGE_LOCALE_DIR\"" >&5 +-echo "${ECHO_T}\"$PACKAGE_LOCALE_DIR\"" >&6 ++if test x$SCROLLKEEPER_CONFIG = xno; then ++ { { echo "$as_me:$LINENO: error: Could not find scrollkeeper-config. Please install the scrollkeeper package" >&5 ++echo "$as_me: error: Could not find scrollkeeper-config. Please install the scrollkeeper package" >&2;} ++ { (exit 1); exit 1; }; } ++fi + + + +-INTLTOOL_QALCULATE_DEFINITIONS_RULE='%.xml: %.xml.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po-defs/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -x -u -c $(top_builddir)/po-defs/.intltool-merge-cache $(top_srcdir)/po-defs $< $@' + + + diff --git a/math/qalculate-gtk/patches/patch-ac b/math/qalculate-gtk/patches/patch-ac new file mode 100644 index 00000000000..32439d90aef --- /dev/null +++ b/math/qalculate-gtk/patches/patch-ac @@ -0,0 +1,76 @@ +$NetBSD: patch-ac,v 1.1 2006/06/22 18:52:00 jlam Exp $ + +--- configure.in.orig 2006-04-13 06:27:37.000000000 -0400 ++++ configure.in +@@ -55,6 +55,35 @@ fi + changequote([,])dnl + + ++dnl ------------------------------------- ++dnl | internationalization (i18n) support |------------------------------------ ++dnl ------------------------------------- ++ ++GETTEXT_PACKAGE=qalculate-gtk ++AC_SUBST(GETTEXT_PACKAGE) ++AC_DEFINE_UNQUOTED(GETTEXT_PACKAGE,"$GETTEXT_PACKAGE",[The package name for gettext]) ++ ++dnl Please keep this in alphabetical order ++ALL_LINGUAS="nl sv" ++AM_GLIB_GNU_GETTEXT ++ ++dnl AM_GLIB_GNU_GETTEXT sets $DATADIRNAME ++AC_MSG_CHECKING(locale directory) ++if test "x$prefix" = "xNONE"; then ++ PACKAGE_LOCALE_DIR=$ac_default_prefix/share/locale ++else ++ PACKAGE_LOCALE_DIR=$prefix/share/locale ++fi ++ ++AC_DEFINE_UNQUOTED(PACKAGE_LOCALE_DIR, "$PACKAGE_LOCALE_DIR", ++ [The directory in which qalculate's locale data will be stored]) ++ AC_MSG_RESULT("$PACKAGE_LOCALE_DIR") ++ ++ ++ ++INTLTOOL_QALCULATE_DEFINITIONS_RULE='%.xml: %.xml.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po-defs/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -x -u -c $(top_builddir)/po-defs/.intltool-merge-cache $(top_srcdir)/po-defs $< [$]@' ++AC_SUBST(INTLTOOL_QALCULATE_DEFINITIONS_RULE) ++ + dnl -------------------------------- + dnl | check for neccessary libraries |----------------------------------------- + dnl -------------------------------- +@@ -123,35 +152,6 @@ AC_SUBST(QALCULATE_GTK) + + AC_SUBST(LN_QALCULATE) + +-dnl ------------------------------------- +-dnl | internationalization (i18n) support |------------------------------------ +-dnl ------------------------------------- +- +-GETTEXT_PACKAGE=qalculate-gtk +-AC_SUBST(GETTEXT_PACKAGE) +-AC_DEFINE_UNQUOTED(GETTEXT_PACKAGE,"$GETTEXT_PACKAGE",[The package name for gettext]) +- +-dnl Please keep this in alphabetical order +-ALL_LINGUAS="nl sv" +-AM_GLIB_GNU_GETTEXT +- +-dnl AM_GLIB_GNU_GETTEXT sets $DATADIRNAME +-AC_MSG_CHECKING(locale directory) +-if test "x$prefix" = "xNONE"; then +- PACKAGE_LOCALE_DIR=$ac_default_prefix/share/locale +-else +- PACKAGE_LOCALE_DIR=$prefix/share/locale +-fi +- +-AC_DEFINE_UNQUOTED(PACKAGE_LOCALE_DIR, "$PACKAGE_LOCALE_DIR", +- [The directory in which qalculate's locale data will be stored]) +- AC_MSG_RESULT("$PACKAGE_LOCALE_DIR") +- +- +- +-INTLTOOL_QALCULATE_DEFINITIONS_RULE='%.xml: %.xml.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po-defs/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -x -u -c $(top_builddir)/po-defs/.intltool-merge-cache $(top_srcdir)/po-defs $< [$]@' +-AC_SUBST(INTLTOOL_QALCULATE_DEFINITIONS_RULE) +- + dnl -------- + dnl | output |----------------------------------------------------------------- + dnl -------- diff --git a/math/qalculate-units/distinfo b/math/qalculate-units/distinfo index 839fdd32daf..a3b08ea576a 100644 --- a/math/qalculate-units/distinfo +++ b/math/qalculate-units/distinfo @@ -1,5 +1,7 @@ -$NetBSD: distinfo,v 1.4 2006/06/14 20:14:21 adam Exp $ +$NetBSD: distinfo,v 1.5 2006/06/22 18:52:00 jlam Exp $ SHA1 (qalculate-units-0.9.4.tar.gz) = 1a6c124e572671973be9d249aba682e745f01f91 RMD160 (qalculate-units-0.9.4.tar.gz) = 621636ecc487b71a85f7e6f9785e275ed2ac2e17 Size (qalculate-units-0.9.4.tar.gz) = 375642 bytes +SHA1 (patch-aa) = b345c2bfdee5c3000ae23f6f77b7ef7e491fa385 +SHA1 (patch-ab) = a5500e60ffd51c40ed266ae7c26faf7b6e441234 diff --git a/math/qalculate-units/patches/patch-aa b/math/qalculate-units/patches/patch-aa new file mode 100644 index 00000000000..9a003b6a3aa --- /dev/null +++ b/math/qalculate-units/patches/patch-aa @@ -0,0 +1,3972 @@ +$NetBSD: patch-aa,v 1.1 2006/06/22 18:52:01 jlam Exp $ + +--- configure.orig 2006-06-02 01:58:40.000000000 -0400 ++++ configure +@@ -20065,31 +20065,184 @@ fi + + + +-echo "$as_me:$LINENO: checking for pthread_create in -lpthread" >&5 +-echo $ECHO_N "checking for pthread_create in -lpthread... $ECHO_C" >&6 +-if test "${ac_cv_lib_pthread_pthread_create+set}" = set; then ++GETTEXT_PACKAGE=qalculate-units ++ ++ ++cat >>confdefs.h <<_ACEOF ++#define GETTEXT_PACKAGE "$GETTEXT_PACKAGE" ++_ACEOF ++ ++ ++ALL_LINGUAS="nl sv" ++ ++ ++ ++for ac_header in locale.h ++do ++as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh` ++if eval "test \"\${$as_ac_Header+set}\" = set"; then ++ echo "$as_me:$LINENO: checking for $ac_header" >&5 ++echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6 ++if eval "test \"\${$as_ac_Header+set}\" = set"; then + echo $ECHO_N "(cached) $ECHO_C" >&6 ++fi ++echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5 ++echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6 + else +- ac_check_lib_save_LIBS=$LIBS +-LIBS="-lpthread $LIBS" ++ # Is the header compilable? ++echo "$as_me:$LINENO: checking $ac_header usability" >&5 ++echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6 + cat >conftest.$ac_ext <<_ACEOF + /* confdefs.h. */ + _ACEOF + cat confdefs.h >>conftest.$ac_ext + cat >>conftest.$ac_ext <<_ACEOF + /* end confdefs.h. */ ++$ac_includes_default ++#include <$ac_header> ++_ACEOF ++rm -f conftest.$ac_objext ++if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 ++ (eval $ac_compile) 2>conftest.er1 ++ ac_status=$? ++ grep -v '^ *+' conftest.er1 >conftest.err ++ rm -f conftest.er1 ++ cat conftest.err >&5 ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); } && ++ { ac_try='test -z "$ac_cxx_werror_flag" ++ || test ! -s conftest.err' ++ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 ++ (eval $ac_try) 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; } && ++ { ac_try='test -s conftest.$ac_objext' ++ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 ++ (eval $ac_try) 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; }; then ++ ac_header_compiler=yes ++else ++ echo "$as_me: failed program was:" >&5 ++sed 's/^/| /' conftest.$ac_ext >&5 + +-/* Override any gcc2 internal prototype to avoid an error. */ +-#ifdef __cplusplus +-extern "C" +-#endif +-/* We use char because int might match the return type of a gcc2 +- builtin and then its argument prototype would still apply. */ +-char pthread_create (); ++ac_header_compiler=no ++fi ++rm -f conftest.err conftest.$ac_objext conftest.$ac_ext ++echo "$as_me:$LINENO: result: $ac_header_compiler" >&5 ++echo "${ECHO_T}$ac_header_compiler" >&6 ++ ++# Is the header present? ++echo "$as_me:$LINENO: checking $ac_header presence" >&5 ++echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6 ++cat >conftest.$ac_ext <<_ACEOF ++/* confdefs.h. */ ++_ACEOF ++cat confdefs.h >>conftest.$ac_ext ++cat >>conftest.$ac_ext <<_ACEOF ++/* end confdefs.h. */ ++#include <$ac_header> ++_ACEOF ++if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5 ++ (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 ++ ac_status=$? ++ grep -v '^ *+' conftest.er1 >conftest.err ++ rm -f conftest.er1 ++ cat conftest.err >&5 ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); } >/dev/null; then ++ if test -s conftest.err; then ++ ac_cpp_err=$ac_cxx_preproc_warn_flag ++ ac_cpp_err=$ac_cpp_err$ac_cxx_werror_flag ++ else ++ ac_cpp_err= ++ fi ++else ++ ac_cpp_err=yes ++fi ++if test -z "$ac_cpp_err"; then ++ ac_header_preproc=yes ++else ++ echo "$as_me: failed program was:" >&5 ++sed 's/^/| /' conftest.$ac_ext >&5 ++ ++ ac_header_preproc=no ++fi ++rm -f conftest.err conftest.$ac_ext ++echo "$as_me:$LINENO: result: $ac_header_preproc" >&5 ++echo "${ECHO_T}$ac_header_preproc" >&6 ++ ++# So? What about this header? ++case $ac_header_compiler:$ac_header_preproc:$ac_cxx_preproc_warn_flag in ++ yes:no: ) ++ { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5 ++echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;} ++ { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5 ++echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;} ++ ac_header_preproc=yes ++ ;; ++ no:yes:* ) ++ { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5 ++echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;} ++ { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5 ++echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;} ++ { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5 ++echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;} ++ { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5 ++echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;} ++ { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5 ++echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;} ++ { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5 ++echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;} ++ ( ++ cat <<\_ASBOX ++## ------------------------------------------ ## ++## Report this to the AC_PACKAGE_NAME lists. ## ++## ------------------------------------------ ## ++_ASBOX ++ ) | ++ sed "s/^/$as_me: WARNING: /" >&2 ++ ;; ++esac ++echo "$as_me:$LINENO: checking for $ac_header" >&5 ++echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6 ++if eval "test \"\${$as_ac_Header+set}\" = set"; then ++ echo $ECHO_N "(cached) $ECHO_C" >&6 ++else ++ eval "$as_ac_Header=\$ac_header_preproc" ++fi ++echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5 ++echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6 ++ ++fi ++if test `eval echo '${'$as_ac_Header'}'` = yes; then ++ cat >>confdefs.h <<_ACEOF ++#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1 ++_ACEOF ++ ++fi ++ ++done ++ ++ if test $ac_cv_header_locale_h = yes; then ++ echo "$as_me:$LINENO: checking for LC_MESSAGES" >&5 ++echo $ECHO_N "checking for LC_MESSAGES... $ECHO_C" >&6 ++if test "${am_cv_val_LC_MESSAGES+set}" = set; then ++ echo $ECHO_N "(cached) $ECHO_C" >&6 ++else ++ cat >conftest.$ac_ext <<_ACEOF ++/* confdefs.h. */ ++_ACEOF ++cat confdefs.h >>conftest.$ac_ext ++cat >>conftest.$ac_ext <<_ACEOF ++/* end confdefs.h. */ ++#include + int + main () + { +-pthread_create (); ++return LC_MESSAGES + ; + return 0; + } +@@ -20103,7 +20256,7 @@ if { (eval echo "$as_me:$LINENO: \"$ac_l + cat conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } && +- { ac_try='test -z "$ac_c_werror_flag" ++ { ac_try='test -z "$ac_cxx_werror_flag" + || test ! -s conftest.err' + { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 +@@ -20116,885 +20269,441 @@ if { (eval echo "$as_me:$LINENO: \"$ac_l + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then +- ac_cv_lib_pthread_pthread_create=yes ++ am_cv_val_LC_MESSAGES=yes + else + echo "$as_me: failed program was:" >&5 + sed 's/^/| /' conftest.$ac_ext >&5 + +-ac_cv_lib_pthread_pthread_create=no ++am_cv_val_LC_MESSAGES=no + fi + rm -f conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +-LIBS=$ac_check_lib_save_LIBS +-fi +-echo "$as_me:$LINENO: result: $ac_cv_lib_pthread_pthread_create" >&5 +-echo "${ECHO_T}$ac_cv_lib_pthread_pthread_create" >&6 +-if test $ac_cv_lib_pthread_pthread_create = yes; then +- LIBS="$LIBS -lpthread" + fi ++echo "$as_me:$LINENO: result: $am_cv_val_LC_MESSAGES" >&5 ++echo "${ECHO_T}$am_cv_val_LC_MESSAGES" >&6 ++ if test $am_cv_val_LC_MESSAGES = yes; then + ++cat >>confdefs.h <<\_ACEOF ++#define HAVE_LC_MESSAGES 1 ++_ACEOF + +-ac_ext=cc +-ac_cpp='$CXXCPP $CPPFLAGS' +-ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' +-ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +-ac_compiler_gnu=$ac_cv_cxx_compiler_gnu +- +- +- +-# Check whether --with-cln-prefix or --without-cln-prefix was given. +-if test "${with_cln_prefix+set}" = set; then +- withval="$with_cln_prefix" +- cln_config_prefix="$withval" +-else +- cln_config_prefix="" +-fi; ++ fi ++ fi ++ USE_NLS=yes + +-# Check whether --with-cln-exec-prefix or --without-cln-exec-prefix was given. +-if test "${with_cln_exec_prefix+set}" = set; then +- withval="$with_cln_exec_prefix" +- cln_config_exec_prefix="$withval" +-else +- cln_config_exec_prefix="" +-fi; +-# Check whether --enable-clntest or --disable-clntest was given. +-if test "${enable_clntest+set}" = set; then +- enableval="$enable_clntest" + +-else +- enable_clntest=yes +-fi; ++ gt_cv_have_gettext=no + +-if test x$cln_config_exec_prefix != x ; then +- cln_config_args="$cln_config_args --exec-prefix=$cln_config_exec_prefix" +- if test x${CLN_CONFIG+set} != xset ; then +- CLN_CONFIG=$cln_config_exec_prefix/bin/cln-config +- fi +-fi +-if test x$cln_config_prefix != x ; then +- cln_config_args="$cln_config_args --prefix=$cln_config_prefix" +- if test x${CLN_CONFIG+set} != xset ; then +- CLN_CONFIG=$cln_config_prefix/bin/cln-config +- fi +-fi ++ CATOBJEXT=NONE ++ XGETTEXT=: ++ INTLLIBS= + +-# Extract the first word of "cln-config", so it can be a program name with args. +-set dummy cln-config; ac_word=$2 +-echo "$as_me:$LINENO: checking for $ac_word" >&5 +-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 +-if test "${ac_cv_path_CLN_CONFIG+set}" = set; then ++ if test "${ac_cv_header_libintl_h+set}" = set; then ++ echo "$as_me:$LINENO: checking for libintl.h" >&5 ++echo $ECHO_N "checking for libintl.h... $ECHO_C" >&6 ++if test "${ac_cv_header_libintl_h+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 ++fi ++echo "$as_me:$LINENO: result: $ac_cv_header_libintl_h" >&5 ++echo "${ECHO_T}$ac_cv_header_libintl_h" >&6 + else +- case $CLN_CONFIG in +- [\\/]* | ?:[\\/]*) +- ac_cv_path_CLN_CONFIG="$CLN_CONFIG" # Let the user override the test with a path. +- ;; +- *) +- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +-for as_dir in $PATH +-do +- IFS=$as_save_IFS +- test -z "$as_dir" && as_dir=. +- for ac_exec_ext in '' $ac_executable_extensions; do +- if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then +- ac_cv_path_CLN_CONFIG="$as_dir/$ac_word$ac_exec_ext" +- echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 +- break 2 +- fi +-done +-done +- +- test -z "$ac_cv_path_CLN_CONFIG" && ac_cv_path_CLN_CONFIG="no" +- ;; +-esac +-fi +-CLN_CONFIG=$ac_cv_path_CLN_CONFIG +- +-if test -n "$CLN_CONFIG"; then +- echo "$as_me:$LINENO: result: $CLN_CONFIG" >&5 +-echo "${ECHO_T}$CLN_CONFIG" >&6 +-else +- echo "$as_me:$LINENO: result: no" >&5 +-echo "${ECHO_T}no" >&6 +-fi +- +-cln_min_version=1.1.0 +-echo "$as_me:$LINENO: checking for CLN - version >= $cln_min_version" >&5 +-echo $ECHO_N "checking for CLN - version >= $cln_min_version... $ECHO_C" >&6 +-if test "$CLN_CONFIG" = "no" ; then +- echo "$as_me:$LINENO: result: no" >&5 +-echo "${ECHO_T}no" >&6 +- echo "*** The cln-config script installed by CLN could not be found" +- echo "*** If CLN was installed in PREFIX, make sure PREFIX/bin is in" +- echo "*** your path, or set the CLN_CONFIG environment variable to the" +- echo "*** full path to cln-config." +- { { echo "$as_me:$LINENO: error: No suitable installed version of CLN could be found." >&5 +-echo "$as_me: error: No suitable installed version of CLN could be found." >&2;} +- { (exit 1); exit 1; }; } +-else +- cln_min_major_version=`echo $cln_min_version | \ +- sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\1/'` +- cln_min_minor_version=`echo $cln_min_version | \ +- sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\2/'` +- cln_min_micro_version=`echo $cln_min_version | \ +- sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\3/'` +- CLN_CPPFLAGS=`$CLN_CONFIG $cln_config_args --cppflags` +- CLN_LIBS=`$CLN_CONFIG $cln_config_args --libs` +- cln_config_version=`$CLN_CONFIG $cln_config_args --version` +- cln_config_major_version=`echo $cln_config_version | \ +- sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\1/'` +- cln_config_minor_version=`echo $cln_config_version | \ +- sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\2/'` +- cln_config_micro_version=`echo $cln_config_version | \ +- sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\3/'` +- if test \( $cln_config_major_version -lt $cln_min_major_version \) -o \ +- \( $cln_config_major_version -eq $cln_min_major_version -a $cln_config_minor_version -lt $cln_min_minor_version \) -o \ +- \( $cln_config_major_version -eq $cln_min_major_version -a $cln_config_minor_version -eq $cln_min_minor_version -a $cln_config_micro_version -lt $cln_min_micro_version \); then +- echo -e "\n*** 'cln-config --version' returned $cln_config_major_version.$cln_config_minor_version.$cln_config_micro_version, but the minimum version" +- echo "*** of CLN required is $cln_min_major_version.$cln_min_minor_version.$cln_min_micro_version. If cln-config is correct, then it is" +- echo "*** best to upgrade to the required version." +- echo "*** If cln-config was wrong, set the environment variable CLN_CONFIG" +- echo "*** to point to the correct copy of cln-config, and remove the file" +- echo "*** config.cache before re-running configure." +- { { echo "$as_me:$LINENO: error: No suitable installed version of CLN could be found." >&5 +-echo "$as_me: error: No suitable installed version of CLN could be found." >&2;} +- { (exit 1); exit 1; }; } +- else +- no_cln="" +- if test "x$enable_clntest" = "xyes" ; then +- ac_save_CPPFLAGS="$CPPFLAGS" +- ac_save_LIBS="$LIBS" +- CPPFLAGS="$CPPFLAGS $CLN_CPPFLAGS" +- LIBS="$LIBS $CLN_LIBS" +- rm -f conf.clntest +- if test "$cross_compiling" = yes; then +- echo $ac_n "cross compiling; assumed OK... $ac_c" +-else +- cat >conftest.$ac_ext <<_ACEOF ++ # Is the header compilable? ++echo "$as_me:$LINENO: checking libintl.h usability" >&5 ++echo $ECHO_N "checking libintl.h usability... $ECHO_C" >&6 ++cat >conftest.$ac_ext <<_ACEOF + /* confdefs.h. */ + _ACEOF + cat confdefs.h >>conftest.$ac_ext + cat >>conftest.$ac_ext <<_ACEOF + /* end confdefs.h. */ +- +-#include +-#include +-#include +- +-/* we do not #include because autoconf in C++ mode inserts a +- prototype for exit() that conflicts with the one in stdlib.h */ +-extern "C" int system(const char *); +- +-int main(void) +-{ +- system("touch conf.clntest"); +- +- if ((CL_VERSION_MAJOR != $cln_config_major_version) || +- (CL_VERSION_MINOR != $cln_config_minor_version) || +- (CL_VERSION_PATCHLEVEL != $cln_config_micro_version)) { +- printf("\n*** 'cln-config --version' returned %d.%d.%d, but the header file I found\n", $cln_config_major_version, $cln_config_minor_version, $cln_config_micro_version); +- printf("*** corresponds to %d.%d.%d. This mismatch suggests your installation of CLN\n", CL_VERSION_MAJOR, CL_VERSION_MINOR, CL_VERSION_PATCHLEVEL); +- printf("*** is corrupted or you have specified some wrong -I compiler flags.\n"); +- printf("*** Please inquire and consider reinstalling CLN.\n"); +- return 1; +- } +- if ((cln::version_major != $cln_config_major_version) || +- (cln::version_minor != $cln_config_minor_version) || +- (cln::version_patchlevel != $cln_config_micro_version)) { +- printf("\n*** 'cln-config --version' returned %d.%d.%d, but the library I found\n", $cln_config_major_version, $cln_config_minor_version, $cln_config_micro_version); +- printf("*** corresponds to %d.%d.%d. This mismatch suggests your installation of CLN\n", cln::version_major, cln::version_minor, cln::version_patchlevel); +- printf("*** is corrupted or you have specified some wrong -L compiler flags.\n"); +- printf("*** Please inquire and consider reinstalling CLN.\n"); +- return 1; +- } +- return 0; +-} +- ++$ac_includes_default ++#include + _ACEOF +-rm -f conftest$ac_exeext +-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 +- (eval $ac_link) 2>&5 ++rm -f conftest.$ac_objext ++if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 ++ (eval $ac_compile) 2>conftest.er1 + ac_status=$? ++ grep -v '^ *+' conftest.er1 >conftest.err ++ rm -f conftest.er1 ++ cat conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); } && { ac_try='./conftest$ac_exeext' ++ (exit $ac_status); } && ++ { ac_try='test -z "$ac_cxx_werror_flag" ++ || test ! -s conftest.err' ++ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 ++ (eval $ac_try) 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; } && ++ { ac_try='test -s conftest.$ac_objext' + { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then +- : ++ ac_header_compiler=yes + else +- echo "$as_me: program exited with status $ac_status" >&5 +-echo "$as_me: failed program was:" >&5 ++ echo "$as_me: failed program was:" >&5 + sed 's/^/| /' conftest.$ac_ext >&5 + +-( exit $ac_status ) +-no_cln=yes +-fi +-rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext ++ac_header_compiler=no + fi +- CPPFLAGS="$ac_save_CPPFLAGS" +- LIBS="$ac_save_LIBS" +- fi +- if test "x$no_cln" = x ; then +- echo "$as_me:$LINENO: result: yes, $cln_config_version" >&5 +-echo "${ECHO_T}yes, $cln_config_version" >&6 +- +- LIBS="$LIBS $CLN_LIBS" +- CPPFLAGS="$CPPFLAGS $CLN_CPPFLAGS" +- +-cat >>confdefs.h <<\_ACEOF +-#define HAVE_LIBCLN 1 +-_ACEOF +- ++rm -f conftest.err conftest.$ac_objext conftest.$ac_ext ++echo "$as_me:$LINENO: result: $ac_header_compiler" >&5 ++echo "${ECHO_T}$ac_header_compiler" >&6 + +- else +- echo "$as_me:$LINENO: result: no" >&5 +-echo "${ECHO_T}no" >&6 +- if test ! -f conf.clntest ; then +- echo "*** Could not run CLN test program, checking why..." +- CPPFLAGS="$CFLAGS $CLN_CPPFLAGS" +- LIBS="$LIBS $CLN_LIBS" +- cat >conftest.$ac_ext <<_ACEOF ++# Is the header present? ++echo "$as_me:$LINENO: checking libintl.h presence" >&5 ++echo $ECHO_N "checking libintl.h presence... $ECHO_C" >&6 ++cat >conftest.$ac_ext <<_ACEOF + /* confdefs.h. */ + _ACEOF + cat confdefs.h >>conftest.$ac_ext + cat >>conftest.$ac_ext <<_ACEOF + /* end confdefs.h. */ +- +-#include +-#include +- +-int +-main () +-{ +- return 0; +- ; +- return 0; +-} ++#include + _ACEOF +-rm -f conftest.$ac_objext conftest$ac_exeext +-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 +- (eval $ac_link) 2>conftest.er1 ++if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5 ++ (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 + ac_status=$? + grep -v '^ *+' conftest.er1 >conftest.err + rm -f conftest.er1 + cat conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); } && +- { ac_try='test -z "$ac_cxx_werror_flag" +- || test ! -s conftest.err' +- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 +- (eval $ac_try) 2>&5 +- ac_status=$? +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; } && +- { ac_try='test -s conftest$ac_exeext' +- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 +- (eval $ac_try) 2>&5 +- ac_status=$? +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; }; then +- echo "*** The test program compiled, but did not run. This usually means" +- echo "*** that the run-time linker is not finding CLN or finding the wrong" +- echo "*** version of CLN. If it is not finding CLN, you'll need to set your" +- echo "*** LD_LIBRARY_PATH environment variable, or edit /etc/ld.so.conf to point" +- echo "*** to the installed location. Also, make sure you have run ldconfig if that" +- echo "*** is required on your system." ++ (exit $ac_status); } >/dev/null; then ++ if test -s conftest.err; then ++ ac_cpp_err=$ac_cxx_preproc_warn_flag ++ ac_cpp_err=$ac_cpp_err$ac_cxx_werror_flag ++ else ++ ac_cpp_err= ++ fi ++else ++ ac_cpp_err=yes ++fi ++if test -z "$ac_cpp_err"; then ++ ac_header_preproc=yes + else + echo "$as_me: failed program was:" >&5 + sed 's/^/| /' conftest.$ac_ext >&5 + +- echo "*** The test program failed to compile or link. See the file config.log for the" +- echo "*** exact error that occured. This usually means CLN was incorrectly installed" +- echo "*** or that you have moved CLN since it was installed. In the latter case, you" +- echo "*** may want to edit the cln-config script: $CLN_CONFIG." +-fi +-rm -f conftest.err conftest.$ac_objext \ +- conftest$ac_exeext conftest.$ac_ext +- CPPFLAGS="$ac_save_CPPFLAGS" +- LIBS="$ac_save_LIBS" +- fi +- CLN_CPPFLAGS="" +- CLN_LIBS="" +- { { echo "$as_me:$LINENO: error: No suitable installed version of CLN could be found." >&5 +-echo "$as_me: error: No suitable installed version of CLN could be found." >&2;} +- { (exit 1); exit 1; }; } +- fi +- fi ++ ac_header_preproc=no + fi ++rm -f conftest.err conftest.$ac_ext ++echo "$as_me:$LINENO: result: $ac_header_preproc" >&5 ++echo "${ECHO_T}$ac_header_preproc" >&6 + +- +-rm -f conf.clntest +- +- +- +- +-if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then +- if test -n "$ac_tool_prefix"; then +- # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args. +-set dummy ${ac_tool_prefix}pkg-config; ac_word=$2 +-echo "$as_me:$LINENO: checking for $ac_word" >&5 +-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 +-if test "${ac_cv_path_PKG_CONFIG+set}" = set; then ++# So? What about this header? ++case $ac_header_compiler:$ac_header_preproc:$ac_cxx_preproc_warn_flag in ++ yes:no: ) ++ { echo "$as_me:$LINENO: WARNING: libintl.h: accepted by the compiler, rejected by the preprocessor!" >&5 ++echo "$as_me: WARNING: libintl.h: accepted by the compiler, rejected by the preprocessor!" >&2;} ++ { echo "$as_me:$LINENO: WARNING: libintl.h: proceeding with the compiler's result" >&5 ++echo "$as_me: WARNING: libintl.h: proceeding with the compiler's result" >&2;} ++ ac_header_preproc=yes ++ ;; ++ no:yes:* ) ++ { echo "$as_me:$LINENO: WARNING: libintl.h: present but cannot be compiled" >&5 ++echo "$as_me: WARNING: libintl.h: present but cannot be compiled" >&2;} ++ { echo "$as_me:$LINENO: WARNING: libintl.h: check for missing prerequisite headers?" >&5 ++echo "$as_me: WARNING: libintl.h: check for missing prerequisite headers?" >&2;} ++ { echo "$as_me:$LINENO: WARNING: libintl.h: see the Autoconf documentation" >&5 ++echo "$as_me: WARNING: libintl.h: see the Autoconf documentation" >&2;} ++ { echo "$as_me:$LINENO: WARNING: libintl.h: section \"Present But Cannot Be Compiled\"" >&5 ++echo "$as_me: WARNING: libintl.h: section \"Present But Cannot Be Compiled\"" >&2;} ++ { echo "$as_me:$LINENO: WARNING: libintl.h: proceeding with the preprocessor's result" >&5 ++echo "$as_me: WARNING: libintl.h: proceeding with the preprocessor's result" >&2;} ++ { echo "$as_me:$LINENO: WARNING: libintl.h: in the future, the compiler will take precedence" >&5 ++echo "$as_me: WARNING: libintl.h: in the future, the compiler will take precedence" >&2;} ++ ( ++ cat <<\_ASBOX ++## ------------------------------------------ ## ++## Report this to the AC_PACKAGE_NAME lists. ## ++## ------------------------------------------ ## ++_ASBOX ++ ) | ++ sed "s/^/$as_me: WARNING: /" >&2 ++ ;; ++esac ++echo "$as_me:$LINENO: checking for libintl.h" >&5 ++echo $ECHO_N "checking for libintl.h... $ECHO_C" >&6 ++if test "${ac_cv_header_libintl_h+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 + else +- case $PKG_CONFIG in +- [\\/]* | ?:[\\/]*) +- ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path. +- ;; +- *) +- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +-for as_dir in $PATH +-do +- IFS=$as_save_IFS +- test -z "$as_dir" && as_dir=. +- for ac_exec_ext in '' $ac_executable_extensions; do +- if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then +- ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" +- echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 +- break 2 +- fi +-done +-done +- +- ;; +-esac ++ ac_cv_header_libintl_h=$ac_header_preproc + fi +-PKG_CONFIG=$ac_cv_path_PKG_CONFIG ++echo "$as_me:$LINENO: result: $ac_cv_header_libintl_h" >&5 ++echo "${ECHO_T}$ac_cv_header_libintl_h" >&6 + +-if test -n "$PKG_CONFIG"; then +- echo "$as_me:$LINENO: result: $PKG_CONFIG" >&5 +-echo "${ECHO_T}$PKG_CONFIG" >&6 +-else +- echo "$as_me:$LINENO: result: no" >&5 +-echo "${ECHO_T}no" >&6 + fi ++if test $ac_cv_header_libintl_h = yes; then ++ gt_cv_func_dgettext_libintl="no" ++ libintl_extra_libs="" + +-fi +-if test -z "$ac_cv_path_PKG_CONFIG"; then +- ac_pt_PKG_CONFIG=$PKG_CONFIG +- # Extract the first word of "pkg-config", so it can be a program name with args. +-set dummy pkg-config; ac_word=$2 +-echo "$as_me:$LINENO: checking for $ac_word" >&5 +-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 +-if test "${ac_cv_path_ac_pt_PKG_CONFIG+set}" = set; then ++ # ++ # First check in libc ++ # ++ echo "$as_me:$LINENO: checking for ngettext in libc" >&5 ++echo $ECHO_N "checking for ngettext in libc... $ECHO_C" >&6 ++if test "${gt_cv_func_ngettext_libc+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 + else +- case $ac_pt_PKG_CONFIG in +- [\\/]* | ?:[\\/]*) +- ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path. +- ;; +- *) +- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +-for as_dir in $PATH +-do +- IFS=$as_save_IFS +- test -z "$as_dir" && as_dir=. +- for ac_exec_ext in '' $ac_executable_extensions; do +- if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then +- ac_cv_path_ac_pt_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" +- echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 +- break 2 +- fi +-done +-done ++ cat >conftest.$ac_ext <<_ACEOF ++/* confdefs.h. */ ++_ACEOF ++cat confdefs.h >>conftest.$ac_ext ++cat >>conftest.$ac_ext <<_ACEOF ++/* end confdefs.h. */ + +- ;; +-esac +-fi +-ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG ++#include + +-if test -n "$ac_pt_PKG_CONFIG"; then +- echo "$as_me:$LINENO: result: $ac_pt_PKG_CONFIG" >&5 +-echo "${ECHO_T}$ac_pt_PKG_CONFIG" >&6 ++int ++main () ++{ ++return !ngettext ("","", 1) ++ ; ++ return 0; ++} ++_ACEOF ++rm -f conftest.$ac_objext conftest$ac_exeext ++if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 ++ (eval $ac_link) 2>conftest.er1 ++ ac_status=$? ++ grep -v '^ *+' conftest.er1 >conftest.err ++ rm -f conftest.er1 ++ cat conftest.err >&5 ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); } && ++ { ac_try='test -z "$ac_cxx_werror_flag" ++ || test ! -s conftest.err' ++ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 ++ (eval $ac_try) 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; } && ++ { ac_try='test -s conftest$ac_exeext' ++ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 ++ (eval $ac_try) 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; }; then ++ gt_cv_func_ngettext_libc=yes + else +- echo "$as_me:$LINENO: result: no" >&5 +-echo "${ECHO_T}no" >&6 +-fi ++ echo "$as_me: failed program was:" >&5 ++sed 's/^/| /' conftest.$ac_ext >&5 + +- PKG_CONFIG=$ac_pt_PKG_CONFIG +-else +- PKG_CONFIG="$ac_cv_path_PKG_CONFIG" ++gt_cv_func_ngettext_libc=no + fi ++rm -f conftest.err conftest.$ac_objext \ ++ conftest$ac_exeext conftest.$ac_ext + + fi +-if test -n "$PKG_CONFIG"; then +- _pkg_min_version=0.9.0 +- echo "$as_me:$LINENO: checking pkg-config is at least version $_pkg_min_version" >&5 +-echo $ECHO_N "checking pkg-config is at least version $_pkg_min_version... $ECHO_C" >&6 +- if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then +- echo "$as_me:$LINENO: result: yes" >&5 +-echo "${ECHO_T}yes" >&6 +- else +- echo "$as_me:$LINENO: result: no" >&5 +-echo "${ECHO_T}no" >&6 +- PKG_CONFIG="" +- fi ++echo "$as_me:$LINENO: result: $gt_cv_func_ngettext_libc" >&5 ++echo "${ECHO_T}$gt_cv_func_ngettext_libc" >&6 + +-fi ++ if test "$gt_cv_func_ngettext_libc" = "yes" ; then ++ echo "$as_me:$LINENO: checking for dgettext in libc" >&5 ++echo $ECHO_N "checking for dgettext in libc... $ECHO_C" >&6 ++if test "${gt_cv_func_dgettext_libc+set}" = set; then ++ echo $ECHO_N "(cached) $ECHO_C" >&6 ++else ++ cat >conftest.$ac_ext <<_ACEOF ++/* confdefs.h. */ ++_ACEOF ++cat confdefs.h >>conftest.$ac_ext ++cat >>conftest.$ac_ext <<_ACEOF ++/* end confdefs.h. */ + +-pkg_failed=no +-echo "$as_me:$LINENO: checking for GLIB" >&5 +-echo $ECHO_N "checking for GLIB... $ECHO_C" >&6 ++#include + +-if test -n "$PKG_CONFIG"; then +- if test -n "$GLIB_CFLAGS"; then +- pkg_cv_GLIB_CFLAGS="$GLIB_CFLAGS" +- else +- if test -n "$PKG_CONFIG" && \ +- { (echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \" +- glib-2.0 >= 2.4 +- libxml-2.0 +- \"") >&5 +- ($PKG_CONFIG --exists --print-errors " +- glib-2.0 >= 2.4 +- libxml-2.0 +- ") 2>&5 ++int ++main () ++{ ++return !dgettext ("","") ++ ; ++ return 0; ++} ++_ACEOF ++rm -f conftest.$ac_objext conftest$ac_exeext ++if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 ++ (eval $ac_link) 2>conftest.er1 + ac_status=$? ++ grep -v '^ *+' conftest.er1 >conftest.err ++ rm -f conftest.er1 ++ cat conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; then +- pkg_cv_GLIB_CFLAGS=`$PKG_CONFIG --cflags " +- glib-2.0 >= 2.4 +- libxml-2.0 +- " 2>/dev/null` +-else +- pkg_failed=yes +-fi +- fi +-else +- pkg_failed=untried +-fi +-if test -n "$PKG_CONFIG"; then +- if test -n "$GLIB_LIBS"; then +- pkg_cv_GLIB_LIBS="$GLIB_LIBS" +- else +- if test -n "$PKG_CONFIG" && \ +- { (echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \" +- glib-2.0 >= 2.4 +- libxml-2.0 +- \"") >&5 +- ($PKG_CONFIG --exists --print-errors " +- glib-2.0 >= 2.4 +- libxml-2.0 +- ") 2>&5 ++ (exit $ac_status); } && ++ { ac_try='test -z "$ac_cxx_werror_flag" ++ || test ! -s conftest.err' ++ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 ++ (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; then +- pkg_cv_GLIB_LIBS=`$PKG_CONFIG --libs " +- glib-2.0 >= 2.4 +- libxml-2.0 +- " 2>/dev/null` +-else +- pkg_failed=yes +-fi +- fi ++ (exit $ac_status); }; } && ++ { ac_try='test -s conftest$ac_exeext' ++ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 ++ (eval $ac_try) 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; }; then ++ gt_cv_func_dgettext_libc=yes + else +- pkg_failed=untried +-fi +- +- +- +-if test $pkg_failed = yes; then ++ echo "$as_me: failed program was:" >&5 ++sed 's/^/| /' conftest.$ac_ext >&5 + +-if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then +- _pkg_short_errors_supported=yes +-else +- _pkg_short_errors_supported=no ++gt_cv_func_dgettext_libc=no + fi +- if test $_pkg_short_errors_supported = yes; then +- GLIB_PKG_ERRORS=`$PKG_CONFIG --short-errors --errors-to-stdout --print-errors " +- glib-2.0 >= 2.4 +- libxml-2.0 +- "` +- else +- GLIB_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors " +- glib-2.0 >= 2.4 +- libxml-2.0 +- "` +- fi +- # Put the nasty error message in config.log where it belongs +- echo "$GLIB_PKG_ERRORS" >&5 +- +- { { echo "$as_me:$LINENO: error: Package requirements ( +- glib-2.0 >= 2.4 +- libxml-2.0 +- ) were not met: +- +-$GLIB_PKG_ERRORS +- +-Consider adjusting the PKG_CONFIG_PATH environment variable if you +-installed software in a non-standard prefix. +- +-Alternatively, you may set the environment variables GLIB_CFLAGS +-and GLIB_LIBS to avoid the need to call pkg-config. +-See the pkg-config man page for more details. +-" >&5 +-echo "$as_me: error: Package requirements ( +- glib-2.0 >= 2.4 +- libxml-2.0 +- ) were not met: +- +-$GLIB_PKG_ERRORS +- +-Consider adjusting the PKG_CONFIG_PATH environment variable if you +-installed software in a non-standard prefix. +- +-Alternatively, you may set the environment variables GLIB_CFLAGS +-and GLIB_LIBS to avoid the need to call pkg-config. +-See the pkg-config man page for more details. +-" >&2;} +- { (exit 1); exit 1; }; } +-elif test $pkg_failed = untried; then +- { { echo "$as_me:$LINENO: error: The pkg-config script could not be found or is too old. Make sure it +-is in your PATH or set the PKG_CONFIG environment variable to the full +-path to pkg-config. +- +-Alternatively, you may set the environment variables GLIB_CFLAGS +-and GLIB_LIBS to avoid the need to call pkg-config. +-See the pkg-config man page for more details. ++rm -f conftest.err conftest.$ac_objext \ ++ conftest$ac_exeext conftest.$ac_ext + +-To get pkg-config, see . +-See \`config.log' for more details." >&5 +-echo "$as_me: error: The pkg-config script could not be found or is too old. Make sure it +-is in your PATH or set the PKG_CONFIG environment variable to the full +-path to pkg-config. ++fi ++echo "$as_me:$LINENO: result: $gt_cv_func_dgettext_libc" >&5 ++echo "${ECHO_T}$gt_cv_func_dgettext_libc" >&6 ++ fi + +-Alternatively, you may set the environment variables GLIB_CFLAGS +-and GLIB_LIBS to avoid the need to call pkg-config. +-See the pkg-config man page for more details. ++ if test "$gt_cv_func_ngettext_libc" = "yes" ; then + +-To get pkg-config, see . +-See \`config.log' for more details." >&2;} +- { (exit 1); exit 1; }; } ++for ac_func in bind_textdomain_codeset ++do ++as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh` ++echo "$as_me:$LINENO: checking for $ac_func" >&5 ++echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6 ++if eval "test \"\${$as_ac_var+set}\" = set"; then ++ echo $ECHO_N "(cached) $ECHO_C" >&6 + else +- GLIB_CFLAGS=$pkg_cv_GLIB_CFLAGS +- GLIB_LIBS=$pkg_cv_GLIB_LIBS +- echo "$as_me:$LINENO: result: yes" >&5 +-echo "${ECHO_T}yes" >&6 +- : +-fi ++ cat >conftest.$ac_ext <<_ACEOF ++/* confdefs.h. */ ++_ACEOF ++cat confdefs.h >>conftest.$ac_ext ++cat >>conftest.$ac_ext <<_ACEOF ++/* end confdefs.h. */ ++/* Define $ac_func to an innocuous variant, in case declares $ac_func. ++ For example, HP-UX 11i declares gettimeofday. */ ++#define $ac_func innocuous_$ac_func + ++/* System header to define __stub macros and hopefully few prototypes, ++ which can conflict with char $ac_func (); below. ++ Prefer to if __STDC__ is defined, since ++ exists even on freestanding compilers. */ + ++#ifdef __STDC__ ++# include ++#else ++# include ++#endif + ++#undef $ac_func + +-pkg_failed=no +-echo "$as_me:$LINENO: checking for GTK" >&5 +-echo $ECHO_N "checking for GTK... $ECHO_C" >&6 ++/* Override any gcc2 internal prototype to avoid an error. */ ++#ifdef __cplusplus ++extern "C" ++{ ++#endif ++/* We use char because int might match the return type of a gcc2 ++ builtin and then its argument prototype would still apply. */ ++char $ac_func (); ++/* The GNU C library defines this for functions which it implements ++ to always fail with ENOSYS. Some functions are actually named ++ something starting with __ and the normal name is an alias. */ ++#if defined (__stub_$ac_func) || defined (__stub___$ac_func) ++choke me ++#else ++char (*f) () = $ac_func; ++#endif ++#ifdef __cplusplus ++} ++#endif + +-if test -n "$PKG_CONFIG"; then +- if test -n "$GTK_CFLAGS"; then +- pkg_cv_GTK_CFLAGS="$GTK_CFLAGS" +- else +- if test -n "$PKG_CONFIG" && \ +- { (echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \" +- gtk+-2.0 >= 2.4 +- gdk-pixbuf-2.0 +- \"") >&5 +- ($PKG_CONFIG --exists --print-errors " +- gtk+-2.0 >= 2.4 +- gdk-pixbuf-2.0 +- ") 2>&5 ++int ++main () ++{ ++return f != $ac_func; ++ ; ++ return 0; ++} ++_ACEOF ++rm -f conftest.$ac_objext conftest$ac_exeext ++if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 ++ (eval $ac_link) 2>conftest.er1 + ac_status=$? ++ grep -v '^ *+' conftest.er1 >conftest.err ++ rm -f conftest.er1 ++ cat conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; then +- pkg_cv_GTK_CFLAGS=`$PKG_CONFIG --cflags " +- gtk+-2.0 >= 2.4 +- gdk-pixbuf-2.0 +- " 2>/dev/null` +-else +- pkg_failed=yes +-fi +- fi +-else +- pkg_failed=untried +-fi +-if test -n "$PKG_CONFIG"; then +- if test -n "$GTK_LIBS"; then +- pkg_cv_GTK_LIBS="$GTK_LIBS" +- else +- if test -n "$PKG_CONFIG" && \ +- { (echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \" +- gtk+-2.0 >= 2.4 +- gdk-pixbuf-2.0 +- \"") >&5 +- ($PKG_CONFIG --exists --print-errors " +- gtk+-2.0 >= 2.4 +- gdk-pixbuf-2.0 +- ") 2>&5 ++ (exit $ac_status); } && ++ { ac_try='test -z "$ac_cxx_werror_flag" ++ || test ! -s conftest.err' ++ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 ++ (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; then +- pkg_cv_GTK_LIBS=`$PKG_CONFIG --libs " +- gtk+-2.0 >= 2.4 +- gdk-pixbuf-2.0 +- " 2>/dev/null` ++ (exit $ac_status); }; } && ++ { ac_try='test -s conftest$ac_exeext' ++ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 ++ (eval $ac_try) 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; }; then ++ eval "$as_ac_var=yes" + else +- pkg_failed=yes ++ echo "$as_me: failed program was:" >&5 ++sed 's/^/| /' conftest.$ac_ext >&5 ++ ++eval "$as_ac_var=no" + fi +- fi +-else +- pkg_failed=untried ++rm -f conftest.err conftest.$ac_objext \ ++ conftest$ac_exeext conftest.$ac_ext + fi ++echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5 ++echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6 ++if test `eval echo '${'$as_ac_var'}'` = yes; then ++ cat >>confdefs.h <<_ACEOF ++#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1 ++_ACEOF + ++fi ++done + ++ fi + +-if test $pkg_failed = yes; then ++ # ++ # If we don't have everything we want, check in libintl ++ # ++ if test "$gt_cv_func_dgettext_libc" != "yes" \ ++ || test "$gt_cv_func_ngettext_libc" != "yes" \ ++ || test "$ac_cv_func_bind_textdomain_codeset" != "yes" ; then + +-if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then +- _pkg_short_errors_supported=yes ++ echo "$as_me:$LINENO: checking for bindtextdomain in -lintl" >&5 ++echo $ECHO_N "checking for bindtextdomain in -lintl... $ECHO_C" >&6 ++if test "${ac_cv_lib_intl_bindtextdomain+set}" = set; then ++ echo $ECHO_N "(cached) $ECHO_C" >&6 + else +- _pkg_short_errors_supported=no +-fi +- if test $_pkg_short_errors_supported = yes; then +- GTK_PKG_ERRORS=`$PKG_CONFIG --short-errors --errors-to-stdout --print-errors " +- gtk+-2.0 >= 2.4 +- gdk-pixbuf-2.0 +- "` +- else +- GTK_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors " +- gtk+-2.0 >= 2.4 +- gdk-pixbuf-2.0 +- "` +- fi +- # Put the nasty error message in config.log where it belongs +- echo "$GTK_PKG_ERRORS" >&5 +- +- { { echo "$as_me:$LINENO: error: Package requirements ( +- gtk+-2.0 >= 2.4 +- gdk-pixbuf-2.0 +- ) were not met: +- +-$GTK_PKG_ERRORS +- +-Consider adjusting the PKG_CONFIG_PATH environment variable if you +-installed software in a non-standard prefix. +- +-Alternatively, you may set the environment variables GTK_CFLAGS +-and GTK_LIBS to avoid the need to call pkg-config. +-See the pkg-config man page for more details. +-" >&5 +-echo "$as_me: error: Package requirements ( +- gtk+-2.0 >= 2.4 +- gdk-pixbuf-2.0 +- ) were not met: +- +-$GTK_PKG_ERRORS +- +-Consider adjusting the PKG_CONFIG_PATH environment variable if you +-installed software in a non-standard prefix. +- +-Alternatively, you may set the environment variables GTK_CFLAGS +-and GTK_LIBS to avoid the need to call pkg-config. +-See the pkg-config man page for more details. +-" >&2;} +- { (exit 1); exit 1; }; } +-elif test $pkg_failed = untried; then +- { { echo "$as_me:$LINENO: error: The pkg-config script could not be found or is too old. Make sure it +-is in your PATH or set the PKG_CONFIG environment variable to the full +-path to pkg-config. +- +-Alternatively, you may set the environment variables GTK_CFLAGS +-and GTK_LIBS to avoid the need to call pkg-config. +-See the pkg-config man page for more details. +- +-To get pkg-config, see . +-See \`config.log' for more details." >&5 +-echo "$as_me: error: The pkg-config script could not be found or is too old. Make sure it +-is in your PATH or set the PKG_CONFIG environment variable to the full +-path to pkg-config. +- +-Alternatively, you may set the environment variables GTK_CFLAGS +-and GTK_LIBS to avoid the need to call pkg-config. +-See the pkg-config man page for more details. +- +-To get pkg-config, see . +-See \`config.log' for more details." >&2;} +- { (exit 1); exit 1; }; } +-else +- GTK_CFLAGS=$pkg_cv_GTK_CFLAGS +- GTK_LIBS=$pkg_cv_GTK_LIBS +- echo "$as_me:$LINENO: result: yes" >&5 +-echo "${ECHO_T}yes" >&6 +- : +-fi +- +- +- +- +-pkg_failed=no +-echo "$as_me:$LINENO: checking for QALCULATE" >&5 +-echo $ECHO_N "checking for QALCULATE... $ECHO_C" >&6 +- +-if test -n "$PKG_CONFIG"; then +- if test -n "$QALCULATE_CFLAGS"; then +- pkg_cv_QALCULATE_CFLAGS="$QALCULATE_CFLAGS" +- else +- if test -n "$PKG_CONFIG" && \ +- { (echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \" +- libqalculate >= 0.9.4 +- \"") >&5 +- ($PKG_CONFIG --exists --print-errors " +- libqalculate >= 0.9.4 +- ") 2>&5 +- ac_status=$? +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; then +- pkg_cv_QALCULATE_CFLAGS=`$PKG_CONFIG --cflags " +- libqalculate >= 0.9.4 +- " 2>/dev/null` +-else +- pkg_failed=yes +-fi +- fi +-else +- pkg_failed=untried +-fi +-if test -n "$PKG_CONFIG"; then +- if test -n "$QALCULATE_LIBS"; then +- pkg_cv_QALCULATE_LIBS="$QALCULATE_LIBS" +- else +- if test -n "$PKG_CONFIG" && \ +- { (echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \" +- libqalculate >= 0.9.4 +- \"") >&5 +- ($PKG_CONFIG --exists --print-errors " +- libqalculate >= 0.9.4 +- ") 2>&5 +- ac_status=$? +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; then +- pkg_cv_QALCULATE_LIBS=`$PKG_CONFIG --libs " +- libqalculate >= 0.9.4 +- " 2>/dev/null` +-else +- pkg_failed=yes +-fi +- fi +-else +- pkg_failed=untried +-fi +- +- +- +-if test $pkg_failed = yes; then +- +-if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then +- _pkg_short_errors_supported=yes +-else +- _pkg_short_errors_supported=no +-fi +- if test $_pkg_short_errors_supported = yes; then +- QALCULATE_PKG_ERRORS=`$PKG_CONFIG --short-errors --errors-to-stdout --print-errors " +- libqalculate >= 0.9.4 +- "` +- else +- QALCULATE_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors " +- libqalculate >= 0.9.4 +- "` +- fi +- # Put the nasty error message in config.log where it belongs +- echo "$QALCULATE_PKG_ERRORS" >&5 +- +- { { echo "$as_me:$LINENO: error: Package requirements ( +- libqalculate >= 0.9.4 +- ) were not met: +- +-$QALCULATE_PKG_ERRORS +- +-Consider adjusting the PKG_CONFIG_PATH environment variable if you +-installed software in a non-standard prefix. +- +-Alternatively, you may set the environment variables QALCULATE_CFLAGS +-and QALCULATE_LIBS to avoid the need to call pkg-config. +-See the pkg-config man page for more details. +-" >&5 +-echo "$as_me: error: Package requirements ( +- libqalculate >= 0.9.4 +- ) were not met: +- +-$QALCULATE_PKG_ERRORS +- +-Consider adjusting the PKG_CONFIG_PATH environment variable if you +-installed software in a non-standard prefix. +- +-Alternatively, you may set the environment variables QALCULATE_CFLAGS +-and QALCULATE_LIBS to avoid the need to call pkg-config. +-See the pkg-config man page for more details. +-" >&2;} +- { (exit 1); exit 1; }; } +-elif test $pkg_failed = untried; then +- { { echo "$as_me:$LINENO: error: The pkg-config script could not be found or is too old. Make sure it +-is in your PATH or set the PKG_CONFIG environment variable to the full +-path to pkg-config. +- +-Alternatively, you may set the environment variables QALCULATE_CFLAGS +-and QALCULATE_LIBS to avoid the need to call pkg-config. +-See the pkg-config man page for more details. +- +-To get pkg-config, see . +-See \`config.log' for more details." >&5 +-echo "$as_me: error: The pkg-config script could not be found or is too old. Make sure it +-is in your PATH or set the PKG_CONFIG environment variable to the full +-path to pkg-config. +- +-Alternatively, you may set the environment variables QALCULATE_CFLAGS +-and QALCULATE_LIBS to avoid the need to call pkg-config. +-See the pkg-config man page for more details. +- +-To get pkg-config, see . +-See \`config.log' for more details." >&2;} +- { (exit 1); exit 1; }; } +-else +- QALCULATE_CFLAGS=$pkg_cv_QALCULATE_CFLAGS +- QALCULATE_LIBS=$pkg_cv_QALCULATE_LIBS +- echo "$as_me:$LINENO: result: yes" >&5 +-echo "${ECHO_T}yes" >&6 +- : +-fi +- +- +- +- +-GETTEXT_PACKAGE=qalculate-units +- +- +-cat >>confdefs.h <<_ACEOF +-#define GETTEXT_PACKAGE "$GETTEXT_PACKAGE" +-_ACEOF +- +- +-ALL_LINGUAS="nl sv" +- +- +- +-for ac_header in locale.h +-do +-as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh` +-if eval "test \"\${$as_ac_Header+set}\" = set"; then +- echo "$as_me:$LINENO: checking for $ac_header" >&5 +-echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6 +-if eval "test \"\${$as_ac_Header+set}\" = set"; then +- echo $ECHO_N "(cached) $ECHO_C" >&6 +-fi +-echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5 +-echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6 +-else +- # Is the header compilable? +-echo "$as_me:$LINENO: checking $ac_header usability" >&5 +-echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6 ++ ac_check_lib_save_LIBS=$LIBS ++LIBS="-lintl $LIBS" + cat >conftest.$ac_ext <<_ACEOF + /* confdefs.h. */ + _ACEOF + cat confdefs.h >>conftest.$ac_ext + cat >>conftest.$ac_ext <<_ACEOF + /* end confdefs.h. */ +-$ac_includes_default +-#include <$ac_header> ++ ++/* Override any gcc2 internal prototype to avoid an error. */ ++#ifdef __cplusplus ++extern "C" ++#endif ++/* We use char because int might match the return type of a gcc2 ++ builtin and then its argument prototype would still apply. */ ++char bindtextdomain (); ++int ++main () ++{ ++bindtextdomain (); ++ ; ++ return 0; ++} + _ACEOF +-rm -f conftest.$ac_objext +-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 +- (eval $ac_compile) 2>conftest.er1 ++rm -f conftest.$ac_objext conftest$ac_exeext ++if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 ++ (eval $ac_link) 2>conftest.er1 + ac_status=$? + grep -v '^ *+' conftest.er1 >conftest.err + rm -f conftest.er1 +@@ -21002,138 +20711,57 @@ if { (eval echo "$as_me:$LINENO: \"$ac_c + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } && + { ac_try='test -z "$ac_cxx_werror_flag" +- || test ! -s conftest.err' +- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 +- (eval $ac_try) 2>&5 +- ac_status=$? +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; } && +- { ac_try='test -s conftest.$ac_objext' +- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 +- (eval $ac_try) 2>&5 +- ac_status=$? +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; }; then +- ac_header_compiler=yes +-else +- echo "$as_me: failed program was:" >&5 +-sed 's/^/| /' conftest.$ac_ext >&5 +- +-ac_header_compiler=no +-fi +-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext +-echo "$as_me:$LINENO: result: $ac_header_compiler" >&5 +-echo "${ECHO_T}$ac_header_compiler" >&6 +- +-# Is the header present? +-echo "$as_me:$LINENO: checking $ac_header presence" >&5 +-echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6 +-cat >conftest.$ac_ext <<_ACEOF +-/* confdefs.h. */ +-_ACEOF +-cat confdefs.h >>conftest.$ac_ext +-cat >>conftest.$ac_ext <<_ACEOF +-/* end confdefs.h. */ +-#include <$ac_header> +-_ACEOF +-if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5 +- (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 +- ac_status=$? +- grep -v '^ *+' conftest.er1 >conftest.err +- rm -f conftest.er1 +- cat conftest.err >&5 +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); } >/dev/null; then +- if test -s conftest.err; then +- ac_cpp_err=$ac_cxx_preproc_warn_flag +- ac_cpp_err=$ac_cpp_err$ac_cxx_werror_flag +- else +- ac_cpp_err= +- fi +-else +- ac_cpp_err=yes +-fi +-if test -z "$ac_cpp_err"; then +- ac_header_preproc=yes +-else +- echo "$as_me: failed program was:" >&5 +-sed 's/^/| /' conftest.$ac_ext >&5 +- +- ac_header_preproc=no +-fi +-rm -f conftest.err conftest.$ac_ext +-echo "$as_me:$LINENO: result: $ac_header_preproc" >&5 +-echo "${ECHO_T}$ac_header_preproc" >&6 +- +-# So? What about this header? +-case $ac_header_compiler:$ac_header_preproc:$ac_cxx_preproc_warn_flag in +- yes:no: ) +- { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5 +-echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;} +- { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5 +-echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;} +- ac_header_preproc=yes +- ;; +- no:yes:* ) +- { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5 +-echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;} +- { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5 +-echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;} +- { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5 +-echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;} +- { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5 +-echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;} +- { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5 +-echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;} +- { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5 +-echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;} +- ( +- cat <<\_ASBOX +-## ------------------------------------------ ## +-## Report this to the AC_PACKAGE_NAME lists. ## +-## ------------------------------------------ ## +-_ASBOX +- ) | +- sed "s/^/$as_me: WARNING: /" >&2 +- ;; +-esac +-echo "$as_me:$LINENO: checking for $ac_header" >&5 +-echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6 +-if eval "test \"\${$as_ac_Header+set}\" = set"; then +- echo $ECHO_N "(cached) $ECHO_C" >&6 ++ || test ! -s conftest.err' ++ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 ++ (eval $ac_try) 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; } && ++ { ac_try='test -s conftest$ac_exeext' ++ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 ++ (eval $ac_try) 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; }; then ++ ac_cv_lib_intl_bindtextdomain=yes + else +- eval "$as_ac_Header=\$ac_header_preproc" +-fi +-echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5 +-echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6 ++ echo "$as_me: failed program was:" >&5 ++sed 's/^/| /' conftest.$ac_ext >&5 + ++ac_cv_lib_intl_bindtextdomain=no + fi +-if test `eval echo '${'$as_ac_Header'}'` = yes; then +- cat >>confdefs.h <<_ACEOF +-#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1 +-_ACEOF +- ++rm -f conftest.err conftest.$ac_objext \ ++ conftest$ac_exeext conftest.$ac_ext ++LIBS=$ac_check_lib_save_LIBS + fi +- +-done +- +- if test $ac_cv_header_locale_h = yes; then +- echo "$as_me:$LINENO: checking for LC_MESSAGES" >&5 +-echo $ECHO_N "checking for LC_MESSAGES... $ECHO_C" >&6 +-if test "${am_cv_val_LC_MESSAGES+set}" = set; then ++echo "$as_me:$LINENO: result: $ac_cv_lib_intl_bindtextdomain" >&5 ++echo "${ECHO_T}$ac_cv_lib_intl_bindtextdomain" >&6 ++if test $ac_cv_lib_intl_bindtextdomain = yes; then ++ echo "$as_me:$LINENO: checking for ngettext in -lintl" >&5 ++echo $ECHO_N "checking for ngettext in -lintl... $ECHO_C" >&6 ++if test "${ac_cv_lib_intl_ngettext+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 + else +- cat >conftest.$ac_ext <<_ACEOF ++ ac_check_lib_save_LIBS=$LIBS ++LIBS="-lintl $LIBS" ++cat >conftest.$ac_ext <<_ACEOF + /* confdefs.h. */ + _ACEOF + cat confdefs.h >>conftest.$ac_ext + cat >>conftest.$ac_ext <<_ACEOF + /* end confdefs.h. */ +-#include ++ ++/* Override any gcc2 internal prototype to avoid an error. */ ++#ifdef __cplusplus ++extern "C" ++#endif ++/* We use char because int might match the return type of a gcc2 ++ builtin and then its argument prototype would still apply. */ ++char ngettext (); + int + main () + { +-return LC_MESSAGES ++ngettext (); + ; + return 0; + } +@@ -21160,59 +20788,52 @@ if { (eval echo "$as_me:$LINENO: \"$ac_l + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then +- am_cv_val_LC_MESSAGES=yes ++ ac_cv_lib_intl_ngettext=yes + else + echo "$as_me: failed program was:" >&5 + sed 's/^/| /' conftest.$ac_ext >&5 + +-am_cv_val_LC_MESSAGES=no ++ac_cv_lib_intl_ngettext=no + fi + rm -f conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext ++LIBS=$ac_check_lib_save_LIBS + fi +-echo "$as_me:$LINENO: result: $am_cv_val_LC_MESSAGES" >&5 +-echo "${ECHO_T}$am_cv_val_LC_MESSAGES" >&6 +- if test $am_cv_val_LC_MESSAGES = yes; then +- +-cat >>confdefs.h <<\_ACEOF +-#define HAVE_LC_MESSAGES 1 +-_ACEOF +- +- fi +- fi +- USE_NLS=yes +- +- +- gt_cv_have_gettext=no +- +- CATOBJEXT=NONE +- XGETTEXT=: +- INTLLIBS= +- +- if test "${ac_cv_header_libintl_h+set}" = set; then +- echo "$as_me:$LINENO: checking for libintl.h" >&5 +-echo $ECHO_N "checking for libintl.h... $ECHO_C" >&6 +-if test "${ac_cv_header_libintl_h+set}" = set; then ++echo "$as_me:$LINENO: result: $ac_cv_lib_intl_ngettext" >&5 ++echo "${ECHO_T}$ac_cv_lib_intl_ngettext" >&6 ++if test $ac_cv_lib_intl_ngettext = yes; then ++ echo "$as_me:$LINENO: checking for dgettext in -lintl" >&5 ++echo $ECHO_N "checking for dgettext in -lintl... $ECHO_C" >&6 ++if test "${ac_cv_lib_intl_dgettext+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +-fi +-echo "$as_me:$LINENO: result: $ac_cv_header_libintl_h" >&5 +-echo "${ECHO_T}$ac_cv_header_libintl_h" >&6 + else +- # Is the header compilable? +-echo "$as_me:$LINENO: checking libintl.h usability" >&5 +-echo $ECHO_N "checking libintl.h usability... $ECHO_C" >&6 ++ ac_check_lib_save_LIBS=$LIBS ++LIBS="-lintl $LIBS" + cat >conftest.$ac_ext <<_ACEOF + /* confdefs.h. */ + _ACEOF + cat confdefs.h >>conftest.$ac_ext + cat >>conftest.$ac_ext <<_ACEOF + /* end confdefs.h. */ +-$ac_includes_default +-#include ++ ++/* Override any gcc2 internal prototype to avoid an error. */ ++#ifdef __cplusplus ++extern "C" ++#endif ++/* We use char because int might match the return type of a gcc2 ++ builtin and then its argument prototype would still apply. */ ++char dgettext (); ++int ++main () ++{ ++dgettext (); ++ ; ++ return 0; ++} + _ACEOF +-rm -f conftest.$ac_objext +-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 +- (eval $ac_compile) 2>conftest.er1 ++rm -f conftest.$ac_objext conftest$ac_exeext ++if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 ++ (eval $ac_link) 2>conftest.er1 + ac_status=$? + grep -v '^ *+' conftest.er1 >conftest.err + rm -f conftest.er1 +@@ -21226,131 +20847,129 @@ if { (eval echo "$as_me:$LINENO: \"$ac_c + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; } && +- { ac_try='test -s conftest.$ac_objext' ++ { ac_try='test -s conftest$ac_exeext' + { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then +- ac_header_compiler=yes ++ ac_cv_lib_intl_dgettext=yes + else + echo "$as_me: failed program was:" >&5 + sed 's/^/| /' conftest.$ac_ext >&5 + +-ac_header_compiler=no ++ac_cv_lib_intl_dgettext=no ++fi ++rm -f conftest.err conftest.$ac_objext \ ++ conftest$ac_exeext conftest.$ac_ext ++LIBS=$ac_check_lib_save_LIBS ++fi ++echo "$as_me:$LINENO: result: $ac_cv_lib_intl_dgettext" >&5 ++echo "${ECHO_T}$ac_cv_lib_intl_dgettext" >&6 ++if test $ac_cv_lib_intl_dgettext = yes; then ++ gt_cv_func_dgettext_libintl=yes + fi +-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext +-echo "$as_me:$LINENO: result: $ac_header_compiler" >&5 +-echo "${ECHO_T}$ac_header_compiler" >&6 + +-# Is the header present? +-echo "$as_me:$LINENO: checking libintl.h presence" >&5 +-echo $ECHO_N "checking libintl.h presence... $ECHO_C" >&6 ++fi ++ ++fi ++ ++ ++ if test "$gt_cv_func_dgettext_libintl" != "yes" ; then ++ echo "$as_me:$LINENO: checking if -liconv is needed to use gettext" >&5 ++echo $ECHO_N "checking if -liconv is needed to use gettext... $ECHO_C" >&6 ++ echo "$as_me:$LINENO: result: " >&5 ++echo "${ECHO_T}" >&6 ++ echo "$as_me:$LINENO: checking for ngettext in -lintl" >&5 ++echo $ECHO_N "checking for ngettext in -lintl... $ECHO_C" >&6 ++if test "${ac_cv_lib_intl_ngettext+set}" = set; then ++ echo $ECHO_N "(cached) $ECHO_C" >&6 ++else ++ ac_check_lib_save_LIBS=$LIBS ++LIBS="-lintl -liconv $LIBS" + cat >conftest.$ac_ext <<_ACEOF + /* confdefs.h. */ + _ACEOF + cat confdefs.h >>conftest.$ac_ext + cat >>conftest.$ac_ext <<_ACEOF + /* end confdefs.h. */ +-#include ++ ++/* Override any gcc2 internal prototype to avoid an error. */ ++#ifdef __cplusplus ++extern "C" ++#endif ++/* We use char because int might match the return type of a gcc2 ++ builtin and then its argument prototype would still apply. */ ++char ngettext (); ++int ++main () ++{ ++ngettext (); ++ ; ++ return 0; ++} + _ACEOF +-if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5 +- (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 ++rm -f conftest.$ac_objext conftest$ac_exeext ++if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 ++ (eval $ac_link) 2>conftest.er1 + ac_status=$? + grep -v '^ *+' conftest.er1 >conftest.err + rm -f conftest.er1 + cat conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); } >/dev/null; then +- if test -s conftest.err; then +- ac_cpp_err=$ac_cxx_preproc_warn_flag +- ac_cpp_err=$ac_cpp_err$ac_cxx_werror_flag +- else +- ac_cpp_err= +- fi +-else +- ac_cpp_err=yes +-fi +-if test -z "$ac_cpp_err"; then +- ac_header_preproc=yes ++ (exit $ac_status); } && ++ { ac_try='test -z "$ac_cxx_werror_flag" ++ || test ! -s conftest.err' ++ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 ++ (eval $ac_try) 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; } && ++ { ac_try='test -s conftest$ac_exeext' ++ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 ++ (eval $ac_try) 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; }; then ++ ac_cv_lib_intl_ngettext=yes + else + echo "$as_me: failed program was:" >&5 +-sed 's/^/| /' conftest.$ac_ext >&5 +- +- ac_header_preproc=no +-fi +-rm -f conftest.err conftest.$ac_ext +-echo "$as_me:$LINENO: result: $ac_header_preproc" >&5 +-echo "${ECHO_T}$ac_header_preproc" >&6 +- +-# So? What about this header? +-case $ac_header_compiler:$ac_header_preproc:$ac_cxx_preproc_warn_flag in +- yes:no: ) +- { echo "$as_me:$LINENO: WARNING: libintl.h: accepted by the compiler, rejected by the preprocessor!" >&5 +-echo "$as_me: WARNING: libintl.h: accepted by the compiler, rejected by the preprocessor!" >&2;} +- { echo "$as_me:$LINENO: WARNING: libintl.h: proceeding with the compiler's result" >&5 +-echo "$as_me: WARNING: libintl.h: proceeding with the compiler's result" >&2;} +- ac_header_preproc=yes +- ;; +- no:yes:* ) +- { echo "$as_me:$LINENO: WARNING: libintl.h: present but cannot be compiled" >&5 +-echo "$as_me: WARNING: libintl.h: present but cannot be compiled" >&2;} +- { echo "$as_me:$LINENO: WARNING: libintl.h: check for missing prerequisite headers?" >&5 +-echo "$as_me: WARNING: libintl.h: check for missing prerequisite headers?" >&2;} +- { echo "$as_me:$LINENO: WARNING: libintl.h: see the Autoconf documentation" >&5 +-echo "$as_me: WARNING: libintl.h: see the Autoconf documentation" >&2;} +- { echo "$as_me:$LINENO: WARNING: libintl.h: section \"Present But Cannot Be Compiled\"" >&5 +-echo "$as_me: WARNING: libintl.h: section \"Present But Cannot Be Compiled\"" >&2;} +- { echo "$as_me:$LINENO: WARNING: libintl.h: proceeding with the preprocessor's result" >&5 +-echo "$as_me: WARNING: libintl.h: proceeding with the preprocessor's result" >&2;} +- { echo "$as_me:$LINENO: WARNING: libintl.h: in the future, the compiler will take precedence" >&5 +-echo "$as_me: WARNING: libintl.h: in the future, the compiler will take precedence" >&2;} +- ( +- cat <<\_ASBOX +-## ------------------------------------------ ## +-## Report this to the AC_PACKAGE_NAME lists. ## +-## ------------------------------------------ ## +-_ASBOX +- ) | +- sed "s/^/$as_me: WARNING: /" >&2 +- ;; +-esac +-echo "$as_me:$LINENO: checking for libintl.h" >&5 +-echo $ECHO_N "checking for libintl.h... $ECHO_C" >&6 +-if test "${ac_cv_header_libintl_h+set}" = set; then +- echo $ECHO_N "(cached) $ECHO_C" >&6 +-else +- ac_cv_header_libintl_h=$ac_header_preproc +-fi +-echo "$as_me:$LINENO: result: $ac_cv_header_libintl_h" >&5 +-echo "${ECHO_T}$ac_cv_header_libintl_h" >&6 ++sed 's/^/| /' conftest.$ac_ext >&5 + ++ac_cv_lib_intl_ngettext=no + fi +-if test $ac_cv_header_libintl_h = yes; then +- gt_cv_func_dgettext_libintl="no" +- libintl_extra_libs="" +- +- # +- # First check in libc +- # +- echo "$as_me:$LINENO: checking for ngettext in libc" >&5 +-echo $ECHO_N "checking for ngettext in libc... $ECHO_C" >&6 +-if test "${gt_cv_func_ngettext_libc+set}" = set; then ++rm -f conftest.err conftest.$ac_objext \ ++ conftest$ac_exeext conftest.$ac_ext ++LIBS=$ac_check_lib_save_LIBS ++fi ++echo "$as_me:$LINENO: result: $ac_cv_lib_intl_ngettext" >&5 ++echo "${ECHO_T}$ac_cv_lib_intl_ngettext" >&6 ++if test $ac_cv_lib_intl_ngettext = yes; then ++ echo "$as_me:$LINENO: checking for dcgettext in -lintl" >&5 ++echo $ECHO_N "checking for dcgettext in -lintl... $ECHO_C" >&6 ++if test "${ac_cv_lib_intl_dcgettext+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 + else +- cat >conftest.$ac_ext <<_ACEOF ++ ac_check_lib_save_LIBS=$LIBS ++LIBS="-lintl -liconv $LIBS" ++cat >conftest.$ac_ext <<_ACEOF + /* confdefs.h. */ + _ACEOF + cat confdefs.h >>conftest.$ac_ext + cat >>conftest.$ac_ext <<_ACEOF + /* end confdefs.h. */ + +-#include +- ++/* Override any gcc2 internal prototype to avoid an error. */ ++#ifdef __cplusplus ++extern "C" ++#endif ++/* We use char because int might match the return type of a gcc2 ++ builtin and then its argument prototype would still apply. */ ++char dcgettext (); + int + main () + { +-return !ngettext ("","", 1) ++dcgettext (); + ; + return 0; + } +@@ -21377,24 +20996,48 @@ if { (eval echo "$as_me:$LINENO: \"$ac_l + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then +- gt_cv_func_ngettext_libc=yes ++ ac_cv_lib_intl_dcgettext=yes + else + echo "$as_me: failed program was:" >&5 + sed 's/^/| /' conftest.$ac_ext >&5 + +-gt_cv_func_ngettext_libc=no ++ac_cv_lib_intl_dcgettext=no + fi + rm -f conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext ++LIBS=$ac_check_lib_save_LIBS ++fi ++echo "$as_me:$LINENO: result: $ac_cv_lib_intl_dcgettext" >&5 ++echo "${ECHO_T}$ac_cv_lib_intl_dcgettext" >&6 ++if test $ac_cv_lib_intl_dcgettext = yes; then ++ gt_cv_func_dgettext_libintl=yes ++ libintl_extra_libs=-liconv ++else ++ : ++fi + ++else ++ : + fi +-echo "$as_me:$LINENO: result: $gt_cv_func_ngettext_libc" >&5 +-echo "${ECHO_T}$gt_cv_func_ngettext_libc" >&6 + +- if test "$gt_cv_func_ngettext_libc" = "yes" ; then +- echo "$as_me:$LINENO: checking for dgettext in libc" >&5 +-echo $ECHO_N "checking for dgettext in libc... $ECHO_C" >&6 +-if test "${gt_cv_func_dgettext_libc+set}" = set; then ++ fi ++ ++ # ++ # If we found libintl, then check in it for bind_textdomain_codeset(); ++ # we'll prefer libc if neither have bind_textdomain_codeset(), ++ # and both have dgettext and ngettext ++ # ++ if test "$gt_cv_func_dgettext_libintl" = "yes" ; then ++ glib_save_LIBS="$LIBS" ++ LIBS="$LIBS -lintl $libintl_extra_libs" ++ unset ac_cv_func_bind_textdomain_codeset ++ ++for ac_func in bind_textdomain_codeset ++do ++as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh` ++echo "$as_me:$LINENO: checking for $ac_func" >&5 ++echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6 ++if eval "test \"\${$as_ac_var+set}\" = set"; then + echo $ECHO_N "(cached) $ECHO_C" >&6 + else + cat >conftest.$ac_ext <<_ACEOF +@@ -21403,13 +21046,47 @@ _ACEOF + cat confdefs.h >>conftest.$ac_ext + cat >>conftest.$ac_ext <<_ACEOF + /* end confdefs.h. */ ++/* Define $ac_func to an innocuous variant, in case declares $ac_func. ++ For example, HP-UX 11i declares gettimeofday. */ ++#define $ac_func innocuous_$ac_func + +-#include ++/* System header to define __stub macros and hopefully few prototypes, ++ which can conflict with char $ac_func (); below. ++ Prefer to if __STDC__ is defined, since ++ exists even on freestanding compilers. */ ++ ++#ifdef __STDC__ ++# include ++#else ++# include ++#endif ++ ++#undef $ac_func ++ ++/* Override any gcc2 internal prototype to avoid an error. */ ++#ifdef __cplusplus ++extern "C" ++{ ++#endif ++/* We use char because int might match the return type of a gcc2 ++ builtin and then its argument prototype would still apply. */ ++char $ac_func (); ++/* The GNU C library defines this for functions which it implements ++ to always fail with ENOSYS. Some functions are actually named ++ something starting with __ and the normal name is an alias. */ ++#if defined (__stub_$ac_func) || defined (__stub___$ac_func) ++choke me ++#else ++char (*f) () = $ac_func; ++#endif ++#ifdef __cplusplus ++} ++#endif + + int + main () + { +-return !dgettext ("","") ++return f != $ac_func; + ; + return 0; + } +@@ -21436,24 +21113,94 @@ if { (eval echo "$as_me:$LINENO: \"$ac_l + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then +- gt_cv_func_dgettext_libc=yes ++ eval "$as_ac_var=yes" + else + echo "$as_me: failed program was:" >&5 + sed 's/^/| /' conftest.$ac_ext >&5 + +-gt_cv_func_dgettext_libc=no ++eval "$as_ac_var=no" + fi + rm -f conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext ++fi ++echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5 ++echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6 ++if test `eval echo '${'$as_ac_var'}'` = yes; then ++ cat >>confdefs.h <<_ACEOF ++#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1 ++_ACEOF + + fi +-echo "$as_me:$LINENO: result: $gt_cv_func_dgettext_libc" >&5 +-echo "${ECHO_T}$gt_cv_func_dgettext_libc" >&6 ++done ++ ++ LIBS="$glib_save_LIBS" ++ ++ if test "$ac_cv_func_bind_textdomain_codeset" = "yes" ; then ++ gt_cv_func_dgettext_libc=no ++ else ++ if test "$gt_cv_func_dgettext_libc" = "yes" \ ++ && test "$gt_cv_func_ngettext_libc" = "yes"; then ++ gt_cv_func_dgettext_libintl=no ++ fi ++ fi ++ fi + fi + +- if test "$gt_cv_func_ngettext_libc" = "yes" ; then ++ if test "$gt_cv_func_dgettext_libc" = "yes" \ ++ || test "$gt_cv_func_dgettext_libintl" = "yes"; then ++ gt_cv_have_gettext=yes ++ fi + +-for ac_func in bind_textdomain_codeset ++ if test "$gt_cv_func_dgettext_libintl" = "yes"; then ++ INTLLIBS="-lintl $libintl_extra_libs" ++ fi ++ ++ if test "$gt_cv_have_gettext" = "yes"; then ++ ++cat >>confdefs.h <<\_ACEOF ++#define HAVE_GETTEXT 1 ++_ACEOF ++ ++ # Extract the first word of "msgfmt", so it can be a program name with args. ++set dummy msgfmt; ac_word=$2 ++echo "$as_me:$LINENO: checking for $ac_word" >&5 ++echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 ++if test "${ac_cv_path_MSGFMT+set}" = set; then ++ echo $ECHO_N "(cached) $ECHO_C" >&6 ++else ++ case "$MSGFMT" in ++ /*) ++ ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path. ++ ;; ++ *) ++ IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" ++ for ac_dir in $PATH; do ++ test -z "$ac_dir" && ac_dir=. ++ if test -f $ac_dir/$ac_word; then ++ if test -z "`$ac_dir/$ac_word -h 2>&1 | grep 'dv '`"; then ++ ac_cv_path_MSGFMT="$ac_dir/$ac_word" ++ break ++ fi ++ fi ++ done ++ IFS="$ac_save_ifs" ++ test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT="no" ++ ;; ++esac ++fi ++MSGFMT="$ac_cv_path_MSGFMT" ++if test "$MSGFMT" != "no"; then ++ echo "$as_me:$LINENO: result: $MSGFMT" >&5 ++echo "${ECHO_T}$MSGFMT" >&6 ++else ++ echo "$as_me:$LINENO: result: no" >&5 ++echo "${ECHO_T}no" >&6 ++fi ++ if test "$MSGFMT" != "no"; then ++ glib_save_LIBS="$LIBS" ++ LIBS="$LIBS $INTLLIBS" ++ ++for ac_func in dcgettext + do + as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh` + echo "$as_me:$LINENO: checking for $ac_func" >&5 +@@ -21554,40 +21301,94 @@ _ACEOF + fi + done + ++ # Extract the first word of "gmsgfmt", so it can be a program name with args. ++set dummy gmsgfmt; ac_word=$2 ++echo "$as_me:$LINENO: checking for $ac_word" >&5 ++echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 ++if test "${ac_cv_path_GMSGFMT+set}" = set; then ++ echo $ECHO_N "(cached) $ECHO_C" >&6 ++else ++ case $GMSGFMT in ++ [\\/]* | ?:[\\/]*) ++ ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path. ++ ;; ++ *) ++ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR ++for as_dir in $PATH ++do ++ IFS=$as_save_IFS ++ test -z "$as_dir" && as_dir=. ++ for ac_exec_ext in '' $ac_executable_extensions; do ++ if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ++ ac_cv_path_GMSGFMT="$as_dir/$ac_word$ac_exec_ext" ++ echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 ++ break 2 ++ fi ++done ++done ++ ++ test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT" ++ ;; ++esac ++fi ++GMSGFMT=$ac_cv_path_GMSGFMT ++ ++if test -n "$GMSGFMT"; then ++ echo "$as_me:$LINENO: result: $GMSGFMT" >&5 ++echo "${ECHO_T}$GMSGFMT" >&6 ++else ++ echo "$as_me:$LINENO: result: no" >&5 ++echo "${ECHO_T}no" >&6 ++fi ++ ++ # Extract the first word of "xgettext", so it can be a program name with args. ++set dummy xgettext; ac_word=$2 ++echo "$as_me:$LINENO: checking for $ac_word" >&5 ++echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 ++if test "${ac_cv_path_XGETTEXT+set}" = set; then ++ echo $ECHO_N "(cached) $ECHO_C" >&6 ++else ++ case "$XGETTEXT" in ++ /*) ++ ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path. ++ ;; ++ *) ++ IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" ++ for ac_dir in $PATH; do ++ test -z "$ac_dir" && ac_dir=. ++ if test -f $ac_dir/$ac_word; then ++ if test -z "`$ac_dir/$ac_word -h 2>&1 | grep '(HELP)'`"; then ++ ac_cv_path_XGETTEXT="$ac_dir/$ac_word" ++ break + fi +- +- # +- # If we don't have everything we want, check in libintl +- # +- if test "$gt_cv_func_dgettext_libc" != "yes" \ +- || test "$gt_cv_func_ngettext_libc" != "yes" \ +- || test "$ac_cv_func_bind_textdomain_codeset" != "yes" ; then +- +- echo "$as_me:$LINENO: checking for bindtextdomain in -lintl" >&5 +-echo $ECHO_N "checking for bindtextdomain in -lintl... $ECHO_C" >&6 +-if test "${ac_cv_lib_intl_bindtextdomain+set}" = set; then +- echo $ECHO_N "(cached) $ECHO_C" >&6 ++ fi ++ done ++ IFS="$ac_save_ifs" ++ test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":" ++ ;; ++esac ++fi ++XGETTEXT="$ac_cv_path_XGETTEXT" ++if test "$XGETTEXT" != ":"; then ++ echo "$as_me:$LINENO: result: $XGETTEXT" >&5 ++echo "${ECHO_T}$XGETTEXT" >&6 + else +- ac_check_lib_save_LIBS=$LIBS +-LIBS="-lintl $LIBS" +-cat >conftest.$ac_ext <<_ACEOF ++ echo "$as_me:$LINENO: result: no" >&5 ++echo "${ECHO_T}no" >&6 ++fi ++ ++ cat >conftest.$ac_ext <<_ACEOF + /* confdefs.h. */ + _ACEOF + cat confdefs.h >>conftest.$ac_ext + cat >>conftest.$ac_ext <<_ACEOF + /* end confdefs.h. */ + +-/* Override any gcc2 internal prototype to avoid an error. */ +-#ifdef __cplusplus +-extern "C" +-#endif +-/* We use char because int might match the return type of a gcc2 +- builtin and then its argument prototype would still apply. */ +-char bindtextdomain (); + int + main () + { +-bindtextdomain (); ++extern int _nl_msg_cat_cntr; ++ return _nl_msg_cat_cntr + ; + return 0; + } +@@ -21614,45 +21415,66 @@ if { (eval echo "$as_me:$LINENO: \"$ac_l + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then +- ac_cv_lib_intl_bindtextdomain=yes ++ CATOBJEXT=.gmo ++ DATADIRNAME=share + else + echo "$as_me: failed program was:" >&5 + sed 's/^/| /' conftest.$ac_ext >&5 + +-ac_cv_lib_intl_bindtextdomain=no +-fi +-rm -f conftest.err conftest.$ac_objext \ +- conftest$ac_exeext conftest.$ac_ext +-LIBS=$ac_check_lib_save_LIBS +-fi +-echo "$as_me:$LINENO: result: $ac_cv_lib_intl_bindtextdomain" >&5 +-echo "${ECHO_T}$ac_cv_lib_intl_bindtextdomain" >&6 +-if test $ac_cv_lib_intl_bindtextdomain = yes; then +- echo "$as_me:$LINENO: checking for ngettext in -lintl" >&5 +-echo $ECHO_N "checking for ngettext in -lintl... $ECHO_C" >&6 +-if test "${ac_cv_lib_intl_ngettext+set}" = set; then ++case $host in ++ *-*-solaris*) ++ echo "$as_me:$LINENO: checking for bind_textdomain_codeset" >&5 ++echo $ECHO_N "checking for bind_textdomain_codeset... $ECHO_C" >&6 ++if test "${ac_cv_func_bind_textdomain_codeset+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 + else +- ac_check_lib_save_LIBS=$LIBS +-LIBS="-lintl $LIBS" +-cat >conftest.$ac_ext <<_ACEOF ++ cat >conftest.$ac_ext <<_ACEOF + /* confdefs.h. */ + _ACEOF + cat confdefs.h >>conftest.$ac_ext + cat >>conftest.$ac_ext <<_ACEOF + /* end confdefs.h. */ ++/* Define bind_textdomain_codeset to an innocuous variant, in case declares bind_textdomain_codeset. ++ For example, HP-UX 11i declares gettimeofday. */ ++#define bind_textdomain_codeset innocuous_bind_textdomain_codeset ++ ++/* System header to define __stub macros and hopefully few prototypes, ++ which can conflict with char bind_textdomain_codeset (); below. ++ Prefer to if __STDC__ is defined, since ++ exists even on freestanding compilers. */ ++ ++#ifdef __STDC__ ++# include ++#else ++# include ++#endif ++ ++#undef bind_textdomain_codeset + + /* Override any gcc2 internal prototype to avoid an error. */ + #ifdef __cplusplus + extern "C" ++{ + #endif + /* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +-char ngettext (); ++char bind_textdomain_codeset (); ++/* The GNU C library defines this for functions which it implements ++ to always fail with ENOSYS. Some functions are actually named ++ something starting with __ and the normal name is an alias. */ ++#if defined (__stub_bind_textdomain_codeset) || defined (__stub___bind_textdomain_codeset) ++choke me ++#else ++char (*f) () = bind_textdomain_codeset; ++#endif ++#ifdef __cplusplus ++} ++#endif ++ + int + main () + { +-ngettext (); ++return f != bind_textdomain_codeset; + ; + return 0; + } +@@ -21679,27 +21501,176 @@ if { (eval echo "$as_me:$LINENO: \"$ac_l + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then +- ac_cv_lib_intl_ngettext=yes ++ ac_cv_func_bind_textdomain_codeset=yes + else + echo "$as_me: failed program was:" >&5 + sed 's/^/| /' conftest.$ac_ext >&5 + +-ac_cv_lib_intl_ngettext=no +-fi +-rm -f conftest.err conftest.$ac_objext \ +- conftest$ac_exeext conftest.$ac_ext +-LIBS=$ac_check_lib_save_LIBS +-fi +-echo "$as_me:$LINENO: result: $ac_cv_lib_intl_ngettext" >&5 +-echo "${ECHO_T}$ac_cv_lib_intl_ngettext" >&6 +-if test $ac_cv_lib_intl_ngettext = yes; then +- echo "$as_me:$LINENO: checking for dgettext in -lintl" >&5 +-echo $ECHO_N "checking for dgettext in -lintl... $ECHO_C" >&6 +-if test "${ac_cv_lib_intl_dgettext+set}" = set; then ++ac_cv_func_bind_textdomain_codeset=no ++fi ++rm -f conftest.err conftest.$ac_objext \ ++ conftest$ac_exeext conftest.$ac_ext ++fi ++echo "$as_me:$LINENO: result: $ac_cv_func_bind_textdomain_codeset" >&5 ++echo "${ECHO_T}$ac_cv_func_bind_textdomain_codeset" >&6 ++if test $ac_cv_func_bind_textdomain_codeset = yes; then ++ CATOBJEXT=.gmo ++ DATADIRNAME=share ++else ++ CATOBJEXT=.mo ++ DATADIRNAME=lib ++fi ++ ++ ;; ++ *) ++ CATOBJEXT=.mo ++ DATADIRNAME=lib ++ ;; ++ esac ++fi ++rm -f conftest.err conftest.$ac_objext \ ++ conftest$ac_exeext conftest.$ac_ext ++ LIBS="$glib_save_LIBS" ++ INSTOBJEXT=.mo ++ else ++ gt_cv_have_gettext=no ++ fi ++ fi ++ ++fi ++ ++ ++ ++ if test "$gt_cv_have_gettext" = "yes" ; then ++ ++cat >>confdefs.h <<\_ACEOF ++#define ENABLE_NLS 1 ++_ACEOF ++ ++ fi ++ ++ if test "$XGETTEXT" != ":"; then ++ if $XGETTEXT --omit-header /dev/null 2> /dev/null; then ++ : ; ++ else ++ echo "$as_me:$LINENO: result: found xgettext program is not GNU xgettext; ignore it" >&5 ++echo "${ECHO_T}found xgettext program is not GNU xgettext; ignore it" >&6 ++ XGETTEXT=":" ++ fi ++ fi ++ ++ # We need to process the po/ directory. ++ POSUB=po ++ ++ ac_config_commands="$ac_config_commands default-1" ++ ++ ++ for lang in $ALL_LINGUAS; do ++ GMOFILES="$GMOFILES $lang.gmo" ++ POFILES="$POFILES $lang.po" ++ done ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ if test "$gt_cv_have_gettext" = "yes"; then ++ if test "x$ALL_LINGUAS" = "x"; then ++ LINGUAS= ++ else ++ echo "$as_me:$LINENO: checking for catalogs to be installed" >&5 ++echo $ECHO_N "checking for catalogs to be installed... $ECHO_C" >&6 ++ NEW_LINGUAS= ++ for presentlang in $ALL_LINGUAS; do ++ useit=no ++ if test "%UNSET%" != "${LINGUAS-%UNSET%}"; then ++ desiredlanguages="$LINGUAS" ++ else ++ desiredlanguages="$ALL_LINGUAS" ++ fi ++ for desiredlang in $desiredlanguages; do ++ # Use the presentlang catalog if desiredlang is ++ # a. equal to presentlang, or ++ # b. a variant of presentlang (because in this case, ++ # presentlang can be used as a fallback for messages ++ # which are not translated in the desiredlang catalog). ++ case "$desiredlang" in ++ "$presentlang"*) useit=yes;; ++ esac ++ done ++ if test $useit = yes; then ++ NEW_LINGUAS="$NEW_LINGUAS $presentlang" ++ fi ++ done ++ LINGUAS=$NEW_LINGUAS ++ echo "$as_me:$LINENO: result: $LINGUAS" >&5 ++echo "${ECHO_T}$LINGUAS" >&6 ++ fi ++ ++ if test -n "$LINGUAS"; then ++ for lang in $LINGUAS; do CATALOGS="$CATALOGS $lang$CATOBJEXT"; done ++ fi ++ fi ++ ++ MKINSTALLDIRS= ++ if test -n "$ac_aux_dir"; then ++ MKINSTALLDIRS="$ac_aux_dir/mkinstalldirs" ++ fi ++ if test -z "$MKINSTALLDIRS"; then ++ MKINSTALLDIRS="\$(top_srcdir)/mkinstalldirs" ++ fi ++ ++ ++ test -d po || mkdir po ++ if test "x$srcdir" != "x."; then ++ if test "x`echo $srcdir | sed 's@/.*@@'`" = "x"; then ++ posrcprefix="$srcdir/" ++ else ++ posrcprefix="../$srcdir/" ++ fi ++ else ++ posrcprefix="../" ++ fi ++ rm -f po/POTFILES ++ sed -e "/^#/d" -e "/^\$/d" -e "s,.*, $posrcprefix& \\\\," -e "\$s/\(.*\) \\\\/\1/" \ ++ < $srcdir/po/POTFILES.in > po/POTFILES ++ ++ ++echo "$as_me:$LINENO: checking locale directory" >&5 ++echo $ECHO_N "checking locale directory... $ECHO_C" >&6 ++if test "x$prefix" = "xNONE"; then ++ PACKAGE_LOCALE_DIR=$ac_default_prefix/share/locale ++else ++ PACKAGE_LOCALE_DIR=$prefix/share/locale ++fi ++ ++ ++cat >>confdefs.h <<_ACEOF ++#define PACKAGE_LOCALE_DIR "$PACKAGE_LOCALE_DIR" ++_ACEOF ++ ++ echo "$as_me:$LINENO: result: \"$PACKAGE_LOCALE_DIR\"" >&5 ++echo "${ECHO_T}\"$PACKAGE_LOCALE_DIR\"" >&6 ++ ++INTLTOOL_QALCULATE_DEFINITIONS_RULE='%.xml: %.xml.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po-defs/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -x -u -c $(top_builddir)/po-defs/.intltool-merge-cache $(top_srcdir)/po-defs $< $@' ++ ++ ++ ++echo "$as_me:$LINENO: checking for pthread_create in -lpthread" >&5 ++echo $ECHO_N "checking for pthread_create in -lpthread... $ECHO_C" >&6 ++if test "${ac_cv_lib_pthread_pthread_create+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 + else + ac_check_lib_save_LIBS=$LIBS +-LIBS="-lintl $LIBS" ++LIBS="-lpthread $LIBS" + cat >conftest.$ac_ext <<_ACEOF + /* confdefs.h. */ + _ACEOF +@@ -21713,11 +21684,11 @@ extern "C" + #endif + /* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +-char dgettext (); ++char pthread_create (); + int + main () + { +-dgettext (); ++pthread_create (); + ; + return 0; + } +@@ -21731,7 +21702,7 @@ if { (eval echo "$as_me:$LINENO: \"$ac_l + cat conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } && +- { ac_try='test -z "$ac_cxx_werror_flag" ++ { ac_try='test -z "$ac_c_werror_flag" + || test ! -s conftest.err' + { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 +@@ -21744,192 +21715,159 @@ if { (eval echo "$as_me:$LINENO: \"$ac_l + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then +- ac_cv_lib_intl_dgettext=yes ++ ac_cv_lib_pthread_pthread_create=yes + else + echo "$as_me: failed program was:" >&5 + sed 's/^/| /' conftest.$ac_ext >&5 + +-ac_cv_lib_intl_dgettext=no ++ac_cv_lib_pthread_pthread_create=no + fi + rm -f conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + LIBS=$ac_check_lib_save_LIBS + fi +-echo "$as_me:$LINENO: result: $ac_cv_lib_intl_dgettext" >&5 +-echo "${ECHO_T}$ac_cv_lib_intl_dgettext" >&6 +-if test $ac_cv_lib_intl_dgettext = yes; then +- gt_cv_func_dgettext_libintl=yes ++echo "$as_me:$LINENO: result: $ac_cv_lib_pthread_pthread_create" >&5 ++echo "${ECHO_T}$ac_cv_lib_pthread_pthread_create" >&6 ++if test $ac_cv_lib_pthread_pthread_create = yes; then ++ LIBS="$LIBS -lpthread" + fi + +-fi + +-fi ++ac_ext=cc ++ac_cpp='$CXXCPP $CPPFLAGS' ++ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' ++ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ++ac_compiler_gnu=$ac_cv_cxx_compiler_gnu + + +- if test "$gt_cv_func_dgettext_libintl" != "yes" ; then +- echo "$as_me:$LINENO: checking if -liconv is needed to use gettext" >&5 +-echo $ECHO_N "checking if -liconv is needed to use gettext... $ECHO_C" >&6 +- echo "$as_me:$LINENO: result: " >&5 +-echo "${ECHO_T}" >&6 +- echo "$as_me:$LINENO: checking for ngettext in -lintl" >&5 +-echo $ECHO_N "checking for ngettext in -lintl... $ECHO_C" >&6 +-if test "${ac_cv_lib_intl_ngettext+set}" = set; then +- echo $ECHO_N "(cached) $ECHO_C" >&6 +-else +- ac_check_lib_save_LIBS=$LIBS +-LIBS="-lintl -liconv $LIBS" +-cat >conftest.$ac_ext <<_ACEOF +-/* confdefs.h. */ +-_ACEOF +-cat confdefs.h >>conftest.$ac_ext +-cat >>conftest.$ac_ext <<_ACEOF +-/* end confdefs.h. */ + +-/* Override any gcc2 internal prototype to avoid an error. */ +-#ifdef __cplusplus +-extern "C" +-#endif +-/* We use char because int might match the return type of a gcc2 +- builtin and then its argument prototype would still apply. */ +-char ngettext (); +-int +-main () +-{ +-ngettext (); +- ; +- return 0; +-} +-_ACEOF +-rm -f conftest.$ac_objext conftest$ac_exeext +-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 +- (eval $ac_link) 2>conftest.er1 +- ac_status=$? +- grep -v '^ *+' conftest.er1 >conftest.err +- rm -f conftest.er1 +- cat conftest.err >&5 +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); } && +- { ac_try='test -z "$ac_cxx_werror_flag" +- || test ! -s conftest.err' +- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 +- (eval $ac_try) 2>&5 +- ac_status=$? +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; } && +- { ac_try='test -s conftest$ac_exeext' +- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 +- (eval $ac_try) 2>&5 +- ac_status=$? +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; }; then +- ac_cv_lib_intl_ngettext=yes ++# Check whether --with-cln-prefix or --without-cln-prefix was given. ++if test "${with_cln_prefix+set}" = set; then ++ withval="$with_cln_prefix" ++ cln_config_prefix="$withval" + else +- echo "$as_me: failed program was:" >&5 +-sed 's/^/| /' conftest.$ac_ext >&5 ++ cln_config_prefix="" ++fi; + +-ac_cv_lib_intl_ngettext=no +-fi +-rm -f conftest.err conftest.$ac_objext \ +- conftest$ac_exeext conftest.$ac_ext +-LIBS=$ac_check_lib_save_LIBS +-fi +-echo "$as_me:$LINENO: result: $ac_cv_lib_intl_ngettext" >&5 +-echo "${ECHO_T}$ac_cv_lib_intl_ngettext" >&6 +-if test $ac_cv_lib_intl_ngettext = yes; then +- echo "$as_me:$LINENO: checking for dcgettext in -lintl" >&5 +-echo $ECHO_N "checking for dcgettext in -lintl... $ECHO_C" >&6 +-if test "${ac_cv_lib_intl_dcgettext+set}" = set; then +- echo $ECHO_N "(cached) $ECHO_C" >&6 ++# Check whether --with-cln-exec-prefix or --without-cln-exec-prefix was given. ++if test "${with_cln_exec_prefix+set}" = set; then ++ withval="$with_cln_exec_prefix" ++ cln_config_exec_prefix="$withval" + else +- ac_check_lib_save_LIBS=$LIBS +-LIBS="-lintl -liconv $LIBS" +-cat >conftest.$ac_ext <<_ACEOF +-/* confdefs.h. */ +-_ACEOF +-cat confdefs.h >>conftest.$ac_ext +-cat >>conftest.$ac_ext <<_ACEOF +-/* end confdefs.h. */ ++ cln_config_exec_prefix="" ++fi; ++# Check whether --enable-clntest or --disable-clntest was given. ++if test "${enable_clntest+set}" = set; then ++ enableval="$enable_clntest" + +-/* Override any gcc2 internal prototype to avoid an error. */ +-#ifdef __cplusplus +-extern "C" +-#endif +-/* We use char because int might match the return type of a gcc2 +- builtin and then its argument prototype would still apply. */ +-char dcgettext (); +-int +-main () +-{ +-dcgettext (); +- ; +- return 0; +-} +-_ACEOF +-rm -f conftest.$ac_objext conftest$ac_exeext +-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 +- (eval $ac_link) 2>conftest.er1 +- ac_status=$? +- grep -v '^ *+' conftest.er1 >conftest.err +- rm -f conftest.er1 +- cat conftest.err >&5 +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); } && +- { ac_try='test -z "$ac_cxx_werror_flag" +- || test ! -s conftest.err' +- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 +- (eval $ac_try) 2>&5 +- ac_status=$? +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; } && +- { ac_try='test -s conftest$ac_exeext' +- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 +- (eval $ac_try) 2>&5 +- ac_status=$? +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; }; then +- ac_cv_lib_intl_dcgettext=yes + else +- echo "$as_me: failed program was:" >&5 +-sed 's/^/| /' conftest.$ac_ext >&5 ++ enable_clntest=yes ++fi; + +-ac_cv_lib_intl_dcgettext=no +-fi +-rm -f conftest.err conftest.$ac_objext \ +- conftest$ac_exeext conftest.$ac_ext +-LIBS=$ac_check_lib_save_LIBS ++if test x$cln_config_exec_prefix != x ; then ++ cln_config_args="$cln_config_args --exec-prefix=$cln_config_exec_prefix" ++ if test x${CLN_CONFIG+set} != xset ; then ++ CLN_CONFIG=$cln_config_exec_prefix/bin/cln-config ++ fi + fi +-echo "$as_me:$LINENO: result: $ac_cv_lib_intl_dcgettext" >&5 +-echo "${ECHO_T}$ac_cv_lib_intl_dcgettext" >&6 +-if test $ac_cv_lib_intl_dcgettext = yes; then +- gt_cv_func_dgettext_libintl=yes +- libintl_extra_libs=-liconv +-else +- : ++if test x$cln_config_prefix != x ; then ++ cln_config_args="$cln_config_args --prefix=$cln_config_prefix" ++ if test x${CLN_CONFIG+set} != xset ; then ++ CLN_CONFIG=$cln_config_prefix/bin/cln-config ++ fi + fi + ++# Extract the first word of "cln-config", so it can be a program name with args. ++set dummy cln-config; ac_word=$2 ++echo "$as_me:$LINENO: checking for $ac_word" >&5 ++echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 ++if test "${ac_cv_path_CLN_CONFIG+set}" = set; then ++ echo $ECHO_N "(cached) $ECHO_C" >&6 + else +- : +-fi +- +- fi ++ case $CLN_CONFIG in ++ [\\/]* | ?:[\\/]*) ++ ac_cv_path_CLN_CONFIG="$CLN_CONFIG" # Let the user override the test with a path. ++ ;; ++ *) ++ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR ++for as_dir in $PATH ++do ++ IFS=$as_save_IFS ++ test -z "$as_dir" && as_dir=. ++ for ac_exec_ext in '' $ac_executable_extensions; do ++ if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ++ ac_cv_path_CLN_CONFIG="$as_dir/$ac_word$ac_exec_ext" ++ echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 ++ break 2 ++ fi ++done ++done + +- # +- # If we found libintl, then check in it for bind_textdomain_codeset(); +- # we'll prefer libc if neither have bind_textdomain_codeset(), +- # and both have dgettext and ngettext +- # +- if test "$gt_cv_func_dgettext_libintl" = "yes" ; then +- glib_save_LIBS="$LIBS" +- LIBS="$LIBS -lintl $libintl_extra_libs" +- unset ac_cv_func_bind_textdomain_codeset ++ test -z "$ac_cv_path_CLN_CONFIG" && ac_cv_path_CLN_CONFIG="no" ++ ;; ++esac ++fi ++CLN_CONFIG=$ac_cv_path_CLN_CONFIG + +-for ac_func in bind_textdomain_codeset +-do +-as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh` +-echo "$as_me:$LINENO: checking for $ac_func" >&5 +-echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6 +-if eval "test \"\${$as_ac_var+set}\" = set"; then +- echo $ECHO_N "(cached) $ECHO_C" >&6 ++if test -n "$CLN_CONFIG"; then ++ echo "$as_me:$LINENO: result: $CLN_CONFIG" >&5 ++echo "${ECHO_T}$CLN_CONFIG" >&6 ++else ++ echo "$as_me:$LINENO: result: no" >&5 ++echo "${ECHO_T}no" >&6 ++fi ++ ++cln_min_version=1.1.0 ++echo "$as_me:$LINENO: checking for CLN - version >= $cln_min_version" >&5 ++echo $ECHO_N "checking for CLN - version >= $cln_min_version... $ECHO_C" >&6 ++if test "$CLN_CONFIG" = "no" ; then ++ echo "$as_me:$LINENO: result: no" >&5 ++echo "${ECHO_T}no" >&6 ++ echo "*** The cln-config script installed by CLN could not be found" ++ echo "*** If CLN was installed in PREFIX, make sure PREFIX/bin is in" ++ echo "*** your path, or set the CLN_CONFIG environment variable to the" ++ echo "*** full path to cln-config." ++ { { echo "$as_me:$LINENO: error: No suitable installed version of CLN could be found." >&5 ++echo "$as_me: error: No suitable installed version of CLN could be found." >&2;} ++ { (exit 1); exit 1; }; } ++else ++ cln_min_major_version=`echo $cln_min_version | \ ++ sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\1/'` ++ cln_min_minor_version=`echo $cln_min_version | \ ++ sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\2/'` ++ cln_min_micro_version=`echo $cln_min_version | \ ++ sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\3/'` ++ CLN_CPPFLAGS=`$CLN_CONFIG $cln_config_args --cppflags` ++ CLN_LIBS=`$CLN_CONFIG $cln_config_args --libs` ++ cln_config_version=`$CLN_CONFIG $cln_config_args --version` ++ cln_config_major_version=`echo $cln_config_version | \ ++ sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\1/'` ++ cln_config_minor_version=`echo $cln_config_version | \ ++ sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\2/'` ++ cln_config_micro_version=`echo $cln_config_version | \ ++ sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\3/'` ++ if test \( $cln_config_major_version -lt $cln_min_major_version \) -o \ ++ \( $cln_config_major_version -eq $cln_min_major_version -a $cln_config_minor_version -lt $cln_min_minor_version \) -o \ ++ \( $cln_config_major_version -eq $cln_min_major_version -a $cln_config_minor_version -eq $cln_min_minor_version -a $cln_config_micro_version -lt $cln_min_micro_version \); then ++ echo -e "\n*** 'cln-config --version' returned $cln_config_major_version.$cln_config_minor_version.$cln_config_micro_version, but the minimum version" ++ echo "*** of CLN required is $cln_min_major_version.$cln_min_minor_version.$cln_min_micro_version. If cln-config is correct, then it is" ++ echo "*** best to upgrade to the required version." ++ echo "*** If cln-config was wrong, set the environment variable CLN_CONFIG" ++ echo "*** to point to the correct copy of cln-config, and remove the file" ++ echo "*** config.cache before re-running configure." ++ { { echo "$as_me:$LINENO: error: No suitable installed version of CLN could be found." >&5 ++echo "$as_me: error: No suitable installed version of CLN could be found." >&2;} ++ { (exit 1); exit 1; }; } ++ else ++ no_cln="" ++ if test "x$enable_clntest" = "xyes" ; then ++ ac_save_CPPFLAGS="$CPPFLAGS" ++ ac_save_LIBS="$LIBS" ++ CPPFLAGS="$CPPFLAGS $CLN_CPPFLAGS" ++ LIBS="$LIBS $CLN_LIBS" ++ rm -f conf.clntest ++ if test "$cross_compiling" = yes; then ++ echo $ac_n "cross compiling; assumed OK... $ac_c" + else + cat >conftest.$ac_ext <<_ACEOF + /* confdefs.h. */ +@@ -21937,215 +21875,99 @@ _ACEOF + cat confdefs.h >>conftest.$ac_ext + cat >>conftest.$ac_ext <<_ACEOF + /* end confdefs.h. */ +-/* Define $ac_func to an innocuous variant, in case declares $ac_func. +- For example, HP-UX 11i declares gettimeofday. */ +-#define $ac_func innocuous_$ac_func +- +-/* System header to define __stub macros and hopefully few prototypes, +- which can conflict with char $ac_func (); below. +- Prefer to if __STDC__ is defined, since +- exists even on freestanding compilers. */ + +-#ifdef __STDC__ +-# include +-#else +-# include +-#endif ++#include ++#include ++#include + +-#undef $ac_func ++/* we do not #include because autoconf in C++ mode inserts a ++ prototype for exit() that conflicts with the one in stdlib.h */ ++extern "C" int system(const char *); + +-/* Override any gcc2 internal prototype to avoid an error. */ +-#ifdef __cplusplus +-extern "C" ++int main(void) + { +-#endif +-/* We use char because int might match the return type of a gcc2 +- builtin and then its argument prototype would still apply. */ +-char $ac_func (); +-/* The GNU C library defines this for functions which it implements +- to always fail with ENOSYS. Some functions are actually named +- something starting with __ and the normal name is an alias. */ +-#if defined (__stub_$ac_func) || defined (__stub___$ac_func) +-choke me +-#else +-char (*f) () = $ac_func; +-#endif +-#ifdef __cplusplus +-} +-#endif ++ system("touch conf.clntest"); + +-int +-main () +-{ +-return f != $ac_func; +- ; +- return 0; ++ if ((CL_VERSION_MAJOR != $cln_config_major_version) || ++ (CL_VERSION_MINOR != $cln_config_minor_version) || ++ (CL_VERSION_PATCHLEVEL != $cln_config_micro_version)) { ++ printf("\n*** 'cln-config --version' returned %d.%d.%d, but the header file I found\n", $cln_config_major_version, $cln_config_minor_version, $cln_config_micro_version); ++ printf("*** corresponds to %d.%d.%d. This mismatch suggests your installation of CLN\n", CL_VERSION_MAJOR, CL_VERSION_MINOR, CL_VERSION_PATCHLEVEL); ++ printf("*** is corrupted or you have specified some wrong -I compiler flags.\n"); ++ printf("*** Please inquire and consider reinstalling CLN.\n"); ++ return 1; ++ } ++ if ((cln::version_major != $cln_config_major_version) || ++ (cln::version_minor != $cln_config_minor_version) || ++ (cln::version_patchlevel != $cln_config_micro_version)) { ++ printf("\n*** 'cln-config --version' returned %d.%d.%d, but the library I found\n", $cln_config_major_version, $cln_config_minor_version, $cln_config_micro_version); ++ printf("*** corresponds to %d.%d.%d. This mismatch suggests your installation of CLN\n", cln::version_major, cln::version_minor, cln::version_patchlevel); ++ printf("*** is corrupted or you have specified some wrong -L compiler flags.\n"); ++ printf("*** Please inquire and consider reinstalling CLN.\n"); ++ return 1; ++ } ++ return 0; + } ++ + _ACEOF +-rm -f conftest.$ac_objext conftest$ac_exeext ++rm -f conftest$ac_exeext + if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 +- (eval $ac_link) 2>conftest.er1 +- ac_status=$? +- grep -v '^ *+' conftest.er1 >conftest.err +- rm -f conftest.er1 +- cat conftest.err >&5 +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); } && +- { ac_try='test -z "$ac_cxx_werror_flag" +- || test ! -s conftest.err' +- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 +- (eval $ac_try) 2>&5 ++ (eval $ac_link) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; } && +- { ac_try='test -s conftest$ac_exeext' ++ (exit $ac_status); } && { ac_try='./conftest$ac_exeext' + { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then +- eval "$as_ac_var=yes" ++ : + else +- echo "$as_me: failed program was:" >&5 ++ echo "$as_me: program exited with status $ac_status" >&5 ++echo "$as_me: failed program was:" >&5 + sed 's/^/| /' conftest.$ac_ext >&5 + +-eval "$as_ac_var=no" +-fi +-rm -f conftest.err conftest.$ac_objext \ +- conftest$ac_exeext conftest.$ac_ext ++( exit $ac_status ) ++no_cln=yes + fi +-echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5 +-echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6 +-if test `eval echo '${'$as_ac_var'}'` = yes; then +- cat >>confdefs.h <<_ACEOF +-#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1 +-_ACEOF +- ++rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext + fi +-done +- +- LIBS="$glib_save_LIBS" +- +- if test "$ac_cv_func_bind_textdomain_codeset" = "yes" ; then +- gt_cv_func_dgettext_libc=no +- else +- if test "$gt_cv_func_dgettext_libc" = "yes" \ +- && test "$gt_cv_func_ngettext_libc" = "yes"; then +- gt_cv_func_dgettext_libintl=no +- fi +- fi ++ CPPFLAGS="$ac_save_CPPFLAGS" ++ LIBS="$ac_save_LIBS" + fi +- fi +- +- if test "$gt_cv_func_dgettext_libc" = "yes" \ +- || test "$gt_cv_func_dgettext_libintl" = "yes"; then +- gt_cv_have_gettext=yes +- fi +- +- if test "$gt_cv_func_dgettext_libintl" = "yes"; then +- INTLLIBS="-lintl $libintl_extra_libs" +- fi ++ if test "x$no_cln" = x ; then ++ echo "$as_me:$LINENO: result: yes, $cln_config_version" >&5 ++echo "${ECHO_T}yes, $cln_config_version" >&6 + +- if test "$gt_cv_have_gettext" = "yes"; then ++ LIBS="$LIBS $CLN_LIBS" ++ CPPFLAGS="$CPPFLAGS $CLN_CPPFLAGS" + + cat >>confdefs.h <<\_ACEOF +-#define HAVE_GETTEXT 1 +-_ACEOF +- +- # Extract the first word of "msgfmt", so it can be a program name with args. +-set dummy msgfmt; ac_word=$2 +-echo "$as_me:$LINENO: checking for $ac_word" >&5 +-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 +-if test "${ac_cv_path_MSGFMT+set}" = set; then +- echo $ECHO_N "(cached) $ECHO_C" >&6 +-else +- case "$MSGFMT" in +- /*) +- ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path. +- ;; +- *) +- IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" +- for ac_dir in $PATH; do +- test -z "$ac_dir" && ac_dir=. +- if test -f $ac_dir/$ac_word; then +- if test -z "`$ac_dir/$ac_word -h 2>&1 | grep 'dv '`"; then +- ac_cv_path_MSGFMT="$ac_dir/$ac_word" +- break +- fi +- fi +- done +- IFS="$ac_save_ifs" +- test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT="no" +- ;; +-esac +-fi +-MSGFMT="$ac_cv_path_MSGFMT" +-if test "$MSGFMT" != "no"; then +- echo "$as_me:$LINENO: result: $MSGFMT" >&5 +-echo "${ECHO_T}$MSGFMT" >&6 +-else +- echo "$as_me:$LINENO: result: no" >&5 +-echo "${ECHO_T}no" >&6 +-fi +- if test "$MSGFMT" != "no"; then +- glib_save_LIBS="$LIBS" +- LIBS="$LIBS $INTLLIBS" +- +-for ac_func in dcgettext +-do +-as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh` +-echo "$as_me:$LINENO: checking for $ac_func" >&5 +-echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6 +-if eval "test \"\${$as_ac_var+set}\" = set"; then +- echo $ECHO_N "(cached) $ECHO_C" >&6 +-else +- cat >conftest.$ac_ext <<_ACEOF +-/* confdefs.h. */ ++#define HAVE_LIBCLN 1 + _ACEOF +-cat confdefs.h >>conftest.$ac_ext +-cat >>conftest.$ac_ext <<_ACEOF +-/* end confdefs.h. */ +-/* Define $ac_func to an innocuous variant, in case declares $ac_func. +- For example, HP-UX 11i declares gettimeofday. */ +-#define $ac_func innocuous_$ac_func +- +-/* System header to define __stub macros and hopefully few prototypes, +- which can conflict with char $ac_func (); below. +- Prefer to if __STDC__ is defined, since +- exists even on freestanding compilers. */ +- +-#ifdef __STDC__ +-# include +-#else +-# include +-#endif + +-#undef $ac_func + +-/* Override any gcc2 internal prototype to avoid an error. */ +-#ifdef __cplusplus +-extern "C" +-{ +-#endif +-/* We use char because int might match the return type of a gcc2 +- builtin and then its argument prototype would still apply. */ +-char $ac_func (); +-/* The GNU C library defines this for functions which it implements +- to always fail with ENOSYS. Some functions are actually named +- something starting with __ and the normal name is an alias. */ +-#if defined (__stub_$ac_func) || defined (__stub___$ac_func) +-choke me +-#else +-char (*f) () = $ac_func; +-#endif +-#ifdef __cplusplus +-} +-#endif ++ else ++ echo "$as_me:$LINENO: result: no" >&5 ++echo "${ECHO_T}no" >&6 ++ if test ! -f conf.clntest ; then ++ echo "*** Could not run CLN test program, checking why..." ++ CPPFLAGS="$CFLAGS $CLN_CPPFLAGS" ++ LIBS="$LIBS $CLN_LIBS" ++ cat >conftest.$ac_ext <<_ACEOF ++/* confdefs.h. */ ++_ACEOF ++cat confdefs.h >>conftest.$ac_ext ++cat >>conftest.$ac_ext <<_ACEOF ++/* end confdefs.h. */ ++ ++#include ++#include + + int + main () + { +-return f != $ac_func; ++ return 0; + ; + return 0; + } +@@ -22172,36 +21994,53 @@ if { (eval echo "$as_me:$LINENO: \"$ac_l + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then +- eval "$as_ac_var=yes" ++ echo "*** The test program compiled, but did not run. This usually means" ++ echo "*** that the run-time linker is not finding CLN or finding the wrong" ++ echo "*** version of CLN. If it is not finding CLN, you'll need to set your" ++ echo "*** LD_LIBRARY_PATH environment variable, or edit /etc/ld.so.conf to point" ++ echo "*** to the installed location. Also, make sure you have run ldconfig if that" ++ echo "*** is required on your system." + else + echo "$as_me: failed program was:" >&5 + sed 's/^/| /' conftest.$ac_ext >&5 + +-eval "$as_ac_var=no" ++ echo "*** The test program failed to compile or link. See the file config.log for the" ++ echo "*** exact error that occured. This usually means CLN was incorrectly installed" ++ echo "*** or that you have moved CLN since it was installed. In the latter case, you" ++ echo "*** may want to edit the cln-config script: $CLN_CONFIG." + fi + rm -f conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext ++ CPPFLAGS="$ac_save_CPPFLAGS" ++ LIBS="$ac_save_LIBS" ++ fi ++ CLN_CPPFLAGS="" ++ CLN_LIBS="" ++ { { echo "$as_me:$LINENO: error: No suitable installed version of CLN could be found." >&5 ++echo "$as_me: error: No suitable installed version of CLN could be found." >&2;} ++ { (exit 1); exit 1; }; } ++ fi ++ fi + fi +-echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5 +-echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6 +-if test `eval echo '${'$as_ac_var'}'` = yes; then +- cat >>confdefs.h <<_ACEOF +-#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1 +-_ACEOF + +-fi +-done + +- # Extract the first word of "gmsgfmt", so it can be a program name with args. +-set dummy gmsgfmt; ac_word=$2 ++rm -f conf.clntest ++ ++ ++ ++ ++if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then ++ if test -n "$ac_tool_prefix"; then ++ # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args. ++set dummy ${ac_tool_prefix}pkg-config; ac_word=$2 + echo "$as_me:$LINENO: checking for $ac_word" >&5 + echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 +-if test "${ac_cv_path_GMSGFMT+set}" = set; then ++if test "${ac_cv_path_PKG_CONFIG+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 + else +- case $GMSGFMT in ++ case $PKG_CONFIG in + [\\/]* | ?:[\\/]*) +- ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path. ++ ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path. + ;; + *) + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +@@ -22211,348 +22050,509 @@ do + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then +- ac_cv_path_GMSGFMT="$as_dir/$ac_word$ac_exec_ext" ++ ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" + echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi + done + done + +- test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT" + ;; + esac + fi +-GMSGFMT=$ac_cv_path_GMSGFMT ++PKG_CONFIG=$ac_cv_path_PKG_CONFIG + +-if test -n "$GMSGFMT"; then +- echo "$as_me:$LINENO: result: $GMSGFMT" >&5 +-echo "${ECHO_T}$GMSGFMT" >&6 ++if test -n "$PKG_CONFIG"; then ++ echo "$as_me:$LINENO: result: $PKG_CONFIG" >&5 ++echo "${ECHO_T}$PKG_CONFIG" >&6 + else + echo "$as_me:$LINENO: result: no" >&5 + echo "${ECHO_T}no" >&6 + fi + +- # Extract the first word of "xgettext", so it can be a program name with args. +-set dummy xgettext; ac_word=$2 ++fi ++if test -z "$ac_cv_path_PKG_CONFIG"; then ++ ac_pt_PKG_CONFIG=$PKG_CONFIG ++ # Extract the first word of "pkg-config", so it can be a program name with args. ++set dummy pkg-config; ac_word=$2 + echo "$as_me:$LINENO: checking for $ac_word" >&5 + echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 +-if test "${ac_cv_path_XGETTEXT+set}" = set; then ++if test "${ac_cv_path_ac_pt_PKG_CONFIG+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 + else +- case "$XGETTEXT" in +- /*) +- ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path. ++ case $ac_pt_PKG_CONFIG in ++ [\\/]* | ?:[\\/]*) ++ ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path. + ;; + *) +- IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" +- for ac_dir in $PATH; do +- test -z "$ac_dir" && ac_dir=. +- if test -f $ac_dir/$ac_word; then +- if test -z "`$ac_dir/$ac_word -h 2>&1 | grep '(HELP)'`"; then +- ac_cv_path_XGETTEXT="$ac_dir/$ac_word" +- break +- fi +- fi +- done +- IFS="$ac_save_ifs" +- test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":" ++ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR ++for as_dir in $PATH ++do ++ IFS=$as_save_IFS ++ test -z "$as_dir" && as_dir=. ++ for ac_exec_ext in '' $ac_executable_extensions; do ++ if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ++ ac_cv_path_ac_pt_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" ++ echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 ++ break 2 ++ fi ++done ++done ++ + ;; + esac + fi +-XGETTEXT="$ac_cv_path_XGETTEXT" +-if test "$XGETTEXT" != ":"; then +- echo "$as_me:$LINENO: result: $XGETTEXT" >&5 +-echo "${ECHO_T}$XGETTEXT" >&6 ++ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG ++ ++if test -n "$ac_pt_PKG_CONFIG"; then ++ echo "$as_me:$LINENO: result: $ac_pt_PKG_CONFIG" >&5 ++echo "${ECHO_T}$ac_pt_PKG_CONFIG" >&6 + else + echo "$as_me:$LINENO: result: no" >&5 + echo "${ECHO_T}no" >&6 + fi + +- cat >conftest.$ac_ext <<_ACEOF +-/* confdefs.h. */ +-_ACEOF +-cat confdefs.h >>conftest.$ac_ext +-cat >>conftest.$ac_ext <<_ACEOF +-/* end confdefs.h. */ ++ PKG_CONFIG=$ac_pt_PKG_CONFIG ++else ++ PKG_CONFIG="$ac_cv_path_PKG_CONFIG" ++fi ++ ++fi ++if test -n "$PKG_CONFIG"; then ++ _pkg_min_version=0.9.0 ++ echo "$as_me:$LINENO: checking pkg-config is at least version $_pkg_min_version" >&5 ++echo $ECHO_N "checking pkg-config is at least version $_pkg_min_version... $ECHO_C" >&6 ++ if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then ++ echo "$as_me:$LINENO: result: yes" >&5 ++echo "${ECHO_T}yes" >&6 ++ else ++ echo "$as_me:$LINENO: result: no" >&5 ++echo "${ECHO_T}no" >&6 ++ PKG_CONFIG="" ++ fi ++ ++fi ++ ++pkg_failed=no ++echo "$as_me:$LINENO: checking for GLIB" >&5 ++echo $ECHO_N "checking for GLIB... $ECHO_C" >&6 ++ ++if test -n "$PKG_CONFIG"; then ++ if test -n "$GLIB_CFLAGS"; then ++ pkg_cv_GLIB_CFLAGS="$GLIB_CFLAGS" ++ else ++ if test -n "$PKG_CONFIG" && \ ++ { (echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \" ++ glib-2.0 >= 2.4 ++ libxml-2.0 ++ \"") >&5 ++ ($PKG_CONFIG --exists --print-errors " ++ glib-2.0 >= 2.4 ++ libxml-2.0 ++ ") 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; then ++ pkg_cv_GLIB_CFLAGS=`$PKG_CONFIG --cflags " ++ glib-2.0 >= 2.4 ++ libxml-2.0 ++ " 2>/dev/null` ++else ++ pkg_failed=yes ++fi ++ fi ++else ++ pkg_failed=untried ++fi ++if test -n "$PKG_CONFIG"; then ++ if test -n "$GLIB_LIBS"; then ++ pkg_cv_GLIB_LIBS="$GLIB_LIBS" ++ else ++ if test -n "$PKG_CONFIG" && \ ++ { (echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \" ++ glib-2.0 >= 2.4 ++ libxml-2.0 ++ \"") >&5 ++ ($PKG_CONFIG --exists --print-errors " ++ glib-2.0 >= 2.4 ++ libxml-2.0 ++ ") 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; then ++ pkg_cv_GLIB_LIBS=`$PKG_CONFIG --libs " ++ glib-2.0 >= 2.4 ++ libxml-2.0 ++ " 2>/dev/null` ++else ++ pkg_failed=yes ++fi ++ fi ++else ++ pkg_failed=untried ++fi ++ ++ ++ ++if test $pkg_failed = yes; then ++ ++if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then ++ _pkg_short_errors_supported=yes ++else ++ _pkg_short_errors_supported=no ++fi ++ if test $_pkg_short_errors_supported = yes; then ++ GLIB_PKG_ERRORS=`$PKG_CONFIG --short-errors --errors-to-stdout --print-errors " ++ glib-2.0 >= 2.4 ++ libxml-2.0 ++ "` ++ else ++ GLIB_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors " ++ glib-2.0 >= 2.4 ++ libxml-2.0 ++ "` ++ fi ++ # Put the nasty error message in config.log where it belongs ++ echo "$GLIB_PKG_ERRORS" >&5 ++ ++ { { echo "$as_me:$LINENO: error: Package requirements ( ++ glib-2.0 >= 2.4 ++ libxml-2.0 ++ ) were not met: ++ ++$GLIB_PKG_ERRORS ++ ++Consider adjusting the PKG_CONFIG_PATH environment variable if you ++installed software in a non-standard prefix. + +-int +-main () +-{ +-extern int _nl_msg_cat_cntr; +- return _nl_msg_cat_cntr +- ; +- return 0; +-} +-_ACEOF +-rm -f conftest.$ac_objext conftest$ac_exeext +-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 +- (eval $ac_link) 2>conftest.er1 +- ac_status=$? +- grep -v '^ *+' conftest.er1 >conftest.err +- rm -f conftest.er1 +- cat conftest.err >&5 +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); } && +- { ac_try='test -z "$ac_cxx_werror_flag" +- || test ! -s conftest.err' +- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 +- (eval $ac_try) 2>&5 +- ac_status=$? +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; } && +- { ac_try='test -s conftest$ac_exeext' +- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 +- (eval $ac_try) 2>&5 +- ac_status=$? +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; }; then +- CATOBJEXT=.gmo +- DATADIRNAME=share +-else +- echo "$as_me: failed program was:" >&5 +-sed 's/^/| /' conftest.$ac_ext >&5 ++Alternatively, you may set the environment variables GLIB_CFLAGS ++and GLIB_LIBS to avoid the need to call pkg-config. ++See the pkg-config man page for more details. ++" >&5 ++echo "$as_me: error: Package requirements ( ++ glib-2.0 >= 2.4 ++ libxml-2.0 ++ ) were not met: + +-case $host in +- *-*-solaris*) +- echo "$as_me:$LINENO: checking for bind_textdomain_codeset" >&5 +-echo $ECHO_N "checking for bind_textdomain_codeset... $ECHO_C" >&6 +-if test "${ac_cv_func_bind_textdomain_codeset+set}" = set; then +- echo $ECHO_N "(cached) $ECHO_C" >&6 ++$GLIB_PKG_ERRORS ++ ++Consider adjusting the PKG_CONFIG_PATH environment variable if you ++installed software in a non-standard prefix. ++ ++Alternatively, you may set the environment variables GLIB_CFLAGS ++and GLIB_LIBS to avoid the need to call pkg-config. ++See the pkg-config man page for more details. ++" >&2;} ++ { (exit 1); exit 1; }; } ++elif test $pkg_failed = untried; then ++ { { echo "$as_me:$LINENO: error: The pkg-config script could not be found or is too old. Make sure it ++is in your PATH or set the PKG_CONFIG environment variable to the full ++path to pkg-config. ++ ++Alternatively, you may set the environment variables GLIB_CFLAGS ++and GLIB_LIBS to avoid the need to call pkg-config. ++See the pkg-config man page for more details. ++ ++To get pkg-config, see . ++See \`config.log' for more details." >&5 ++echo "$as_me: error: The pkg-config script could not be found or is too old. Make sure it ++is in your PATH or set the PKG_CONFIG environment variable to the full ++path to pkg-config. ++ ++Alternatively, you may set the environment variables GLIB_CFLAGS ++and GLIB_LIBS to avoid the need to call pkg-config. ++See the pkg-config man page for more details. ++ ++To get pkg-config, see . ++See \`config.log' for more details." >&2;} ++ { (exit 1); exit 1; }; } + else +- cat >conftest.$ac_ext <<_ACEOF +-/* confdefs.h. */ +-_ACEOF +-cat confdefs.h >>conftest.$ac_ext +-cat >>conftest.$ac_ext <<_ACEOF +-/* end confdefs.h. */ +-/* Define bind_textdomain_codeset to an innocuous variant, in case declares bind_textdomain_codeset. +- For example, HP-UX 11i declares gettimeofday. */ +-#define bind_textdomain_codeset innocuous_bind_textdomain_codeset ++ GLIB_CFLAGS=$pkg_cv_GLIB_CFLAGS ++ GLIB_LIBS=$pkg_cv_GLIB_LIBS ++ echo "$as_me:$LINENO: result: yes" >&5 ++echo "${ECHO_T}yes" >&6 ++ : ++fi + +-/* System header to define __stub macros and hopefully few prototypes, +- which can conflict with char bind_textdomain_codeset (); below. +- Prefer to if __STDC__ is defined, since +- exists even on freestanding compilers. */ + +-#ifdef __STDC__ +-# include +-#else +-# include +-#endif + +-#undef bind_textdomain_codeset + +-/* Override any gcc2 internal prototype to avoid an error. */ +-#ifdef __cplusplus +-extern "C" +-{ +-#endif +-/* We use char because int might match the return type of a gcc2 +- builtin and then its argument prototype would still apply. */ +-char bind_textdomain_codeset (); +-/* The GNU C library defines this for functions which it implements +- to always fail with ENOSYS. Some functions are actually named +- something starting with __ and the normal name is an alias. */ +-#if defined (__stub_bind_textdomain_codeset) || defined (__stub___bind_textdomain_codeset) +-choke me +-#else +-char (*f) () = bind_textdomain_codeset; +-#endif +-#ifdef __cplusplus +-} +-#endif ++pkg_failed=no ++echo "$as_me:$LINENO: checking for GTK" >&5 ++echo $ECHO_N "checking for GTK... $ECHO_C" >&6 + +-int +-main () +-{ +-return f != bind_textdomain_codeset; +- ; +- return 0; +-} +-_ACEOF +-rm -f conftest.$ac_objext conftest$ac_exeext +-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 +- (eval $ac_link) 2>conftest.er1 +- ac_status=$? +- grep -v '^ *+' conftest.er1 >conftest.err +- rm -f conftest.er1 +- cat conftest.err >&5 +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); } && +- { ac_try='test -z "$ac_cxx_werror_flag" +- || test ! -s conftest.err' +- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 +- (eval $ac_try) 2>&5 ++if test -n "$PKG_CONFIG"; then ++ if test -n "$GTK_CFLAGS"; then ++ pkg_cv_GTK_CFLAGS="$GTK_CFLAGS" ++ else ++ if test -n "$PKG_CONFIG" && \ ++ { (echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \" ++ gtk+-2.0 >= 2.4 ++ gdk-pixbuf-2.0 ++ \"") >&5 ++ ($PKG_CONFIG --exists --print-errors " ++ gtk+-2.0 >= 2.4 ++ gdk-pixbuf-2.0 ++ ") 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; } && +- { ac_try='test -s conftest$ac_exeext' +- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 +- (eval $ac_try) 2>&5 ++ (exit $ac_status); }; then ++ pkg_cv_GTK_CFLAGS=`$PKG_CONFIG --cflags " ++ gtk+-2.0 >= 2.4 ++ gdk-pixbuf-2.0 ++ " 2>/dev/null` ++else ++ pkg_failed=yes ++fi ++ fi ++else ++ pkg_failed=untried ++fi ++if test -n "$PKG_CONFIG"; then ++ if test -n "$GTK_LIBS"; then ++ pkg_cv_GTK_LIBS="$GTK_LIBS" ++ else ++ if test -n "$PKG_CONFIG" && \ ++ { (echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \" ++ gtk+-2.0 >= 2.4 ++ gdk-pixbuf-2.0 ++ \"") >&5 ++ ($PKG_CONFIG --exists --print-errors " ++ gtk+-2.0 >= 2.4 ++ gdk-pixbuf-2.0 ++ ") 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; }; then +- ac_cv_func_bind_textdomain_codeset=yes ++ (exit $ac_status); }; then ++ pkg_cv_GTK_LIBS=`$PKG_CONFIG --libs " ++ gtk+-2.0 >= 2.4 ++ gdk-pixbuf-2.0 ++ " 2>/dev/null` + else +- echo "$as_me: failed program was:" >&5 +-sed 's/^/| /' conftest.$ac_ext >&5 +- +-ac_cv_func_bind_textdomain_codeset=no +-fi +-rm -f conftest.err conftest.$ac_objext \ +- conftest$ac_exeext conftest.$ac_ext ++ pkg_failed=yes + fi +-echo "$as_me:$LINENO: result: $ac_cv_func_bind_textdomain_codeset" >&5 +-echo "${ECHO_T}$ac_cv_func_bind_textdomain_codeset" >&6 +-if test $ac_cv_func_bind_textdomain_codeset = yes; then +- CATOBJEXT=.gmo +- DATADIRNAME=share ++ fi + else +- CATOBJEXT=.mo +- DATADIRNAME=lib ++ pkg_failed=untried + fi + +- ;; +- *) +- CATOBJEXT=.mo +- DATADIRNAME=lib +- ;; +- esac ++ ++ ++if test $pkg_failed = yes; then ++ ++if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then ++ _pkg_short_errors_supported=yes ++else ++ _pkg_short_errors_supported=no + fi +-rm -f conftest.err conftest.$ac_objext \ +- conftest$ac_exeext conftest.$ac_ext +- LIBS="$glib_save_LIBS" +- INSTOBJEXT=.mo +- else +- gt_cv_have_gettext=no +- fi +- fi ++ if test $_pkg_short_errors_supported = yes; then ++ GTK_PKG_ERRORS=`$PKG_CONFIG --short-errors --errors-to-stdout --print-errors " ++ gtk+-2.0 >= 2.4 ++ gdk-pixbuf-2.0 ++ "` ++ else ++ GTK_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors " ++ gtk+-2.0 >= 2.4 ++ gdk-pixbuf-2.0 ++ "` ++ fi ++ # Put the nasty error message in config.log where it belongs ++ echo "$GTK_PKG_ERRORS" >&5 + +-fi ++ { { echo "$as_me:$LINENO: error: Package requirements ( ++ gtk+-2.0 >= 2.4 ++ gdk-pixbuf-2.0 ++ ) were not met: + ++$GTK_PKG_ERRORS + ++Consider adjusting the PKG_CONFIG_PATH environment variable if you ++installed software in a non-standard prefix. + +- if test "$gt_cv_have_gettext" = "yes" ; then ++Alternatively, you may set the environment variables GTK_CFLAGS ++and GTK_LIBS to avoid the need to call pkg-config. ++See the pkg-config man page for more details. ++" >&5 ++echo "$as_me: error: Package requirements ( ++ gtk+-2.0 >= 2.4 ++ gdk-pixbuf-2.0 ++ ) were not met: + +-cat >>confdefs.h <<\_ACEOF +-#define ENABLE_NLS 1 +-_ACEOF ++$GTK_PKG_ERRORS + +- fi ++Consider adjusting the PKG_CONFIG_PATH environment variable if you ++installed software in a non-standard prefix. + +- if test "$XGETTEXT" != ":"; then +- if $XGETTEXT --omit-header /dev/null 2> /dev/null; then +- : ; +- else +- echo "$as_me:$LINENO: result: found xgettext program is not GNU xgettext; ignore it" >&5 +-echo "${ECHO_T}found xgettext program is not GNU xgettext; ignore it" >&6 +- XGETTEXT=":" +- fi +- fi ++Alternatively, you may set the environment variables GTK_CFLAGS ++and GTK_LIBS to avoid the need to call pkg-config. ++See the pkg-config man page for more details. ++" >&2;} ++ { (exit 1); exit 1; }; } ++elif test $pkg_failed = untried; then ++ { { echo "$as_me:$LINENO: error: The pkg-config script could not be found or is too old. Make sure it ++is in your PATH or set the PKG_CONFIG environment variable to the full ++path to pkg-config. + +- # We need to process the po/ directory. +- POSUB=po ++Alternatively, you may set the environment variables GTK_CFLAGS ++and GTK_LIBS to avoid the need to call pkg-config. ++See the pkg-config man page for more details. + +- ac_config_commands="$ac_config_commands default-1" ++To get pkg-config, see . ++See \`config.log' for more details." >&5 ++echo "$as_me: error: The pkg-config script could not be found or is too old. Make sure it ++is in your PATH or set the PKG_CONFIG environment variable to the full ++path to pkg-config. + ++Alternatively, you may set the environment variables GTK_CFLAGS ++and GTK_LIBS to avoid the need to call pkg-config. ++See the pkg-config man page for more details. ++ ++To get pkg-config, see . ++See \`config.log' for more details." >&2;} ++ { (exit 1); exit 1; }; } ++else ++ GTK_CFLAGS=$pkg_cv_GTK_CFLAGS ++ GTK_LIBS=$pkg_cv_GTK_LIBS ++ echo "$as_me:$LINENO: result: yes" >&5 ++echo "${ECHO_T}yes" >&6 ++ : ++fi + +- for lang in $ALL_LINGUAS; do +- GMOFILES="$GMOFILES $lang.gmo" +- POFILES="$POFILES $lang.po" +- done + + + ++pkg_failed=no ++echo "$as_me:$LINENO: checking for QALCULATE" >&5 ++echo $ECHO_N "checking for QALCULATE... $ECHO_C" >&6 + ++if test -n "$PKG_CONFIG"; then ++ if test -n "$QALCULATE_CFLAGS"; then ++ pkg_cv_QALCULATE_CFLAGS="$QALCULATE_CFLAGS" ++ else ++ if test -n "$PKG_CONFIG" && \ ++ { (echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \" ++ libqalculate >= 0.9.4 ++ \"") >&5 ++ ($PKG_CONFIG --exists --print-errors " ++ libqalculate >= 0.9.4 ++ ") 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; then ++ pkg_cv_QALCULATE_CFLAGS=`$PKG_CONFIG --cflags " ++ libqalculate >= 0.9.4 ++ " 2>/dev/null` ++else ++ pkg_failed=yes ++fi ++ fi ++else ++ pkg_failed=untried ++fi ++if test -n "$PKG_CONFIG"; then ++ if test -n "$QALCULATE_LIBS"; then ++ pkg_cv_QALCULATE_LIBS="$QALCULATE_LIBS" ++ else ++ if test -n "$PKG_CONFIG" && \ ++ { (echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \" ++ libqalculate >= 0.9.4 ++ \"") >&5 ++ ($PKG_CONFIG --exists --print-errors " ++ libqalculate >= 0.9.4 ++ ") 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; then ++ pkg_cv_QALCULATE_LIBS=`$PKG_CONFIG --libs " ++ libqalculate >= 0.9.4 ++ " 2>/dev/null` ++else ++ pkg_failed=yes ++fi ++ fi ++else ++ pkg_failed=untried ++fi + + + ++if test $pkg_failed = yes; then + ++if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then ++ _pkg_short_errors_supported=yes ++else ++ _pkg_short_errors_supported=no ++fi ++ if test $_pkg_short_errors_supported = yes; then ++ QALCULATE_PKG_ERRORS=`$PKG_CONFIG --short-errors --errors-to-stdout --print-errors " ++ libqalculate >= 0.9.4 ++ "` ++ else ++ QALCULATE_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors " ++ libqalculate >= 0.9.4 ++ "` ++ fi ++ # Put the nasty error message in config.log where it belongs ++ echo "$QALCULATE_PKG_ERRORS" >&5 + ++ { { echo "$as_me:$LINENO: error: Package requirements ( ++ libqalculate >= 0.9.4 ++ ) were not met: + ++$QALCULATE_PKG_ERRORS + ++Consider adjusting the PKG_CONFIG_PATH environment variable if you ++installed software in a non-standard prefix. + ++Alternatively, you may set the environment variables QALCULATE_CFLAGS ++and QALCULATE_LIBS to avoid the need to call pkg-config. ++See the pkg-config man page for more details. ++" >&5 ++echo "$as_me: error: Package requirements ( ++ libqalculate >= 0.9.4 ++ ) were not met: + +- if test "$gt_cv_have_gettext" = "yes"; then +- if test "x$ALL_LINGUAS" = "x"; then +- LINGUAS= +- else +- echo "$as_me:$LINENO: checking for catalogs to be installed" >&5 +-echo $ECHO_N "checking for catalogs to be installed... $ECHO_C" >&6 +- NEW_LINGUAS= +- for presentlang in $ALL_LINGUAS; do +- useit=no +- if test "%UNSET%" != "${LINGUAS-%UNSET%}"; then +- desiredlanguages="$LINGUAS" +- else +- desiredlanguages="$ALL_LINGUAS" +- fi +- for desiredlang in $desiredlanguages; do +- # Use the presentlang catalog if desiredlang is +- # a. equal to presentlang, or +- # b. a variant of presentlang (because in this case, +- # presentlang can be used as a fallback for messages +- # which are not translated in the desiredlang catalog). +- case "$desiredlang" in +- "$presentlang"*) useit=yes;; +- esac +- done +- if test $useit = yes; then +- NEW_LINGUAS="$NEW_LINGUAS $presentlang" +- fi +- done +- LINGUAS=$NEW_LINGUAS +- echo "$as_me:$LINENO: result: $LINGUAS" >&5 +-echo "${ECHO_T}$LINGUAS" >&6 +- fi ++$QALCULATE_PKG_ERRORS + +- if test -n "$LINGUAS"; then +- for lang in $LINGUAS; do CATALOGS="$CATALOGS $lang$CATOBJEXT"; done +- fi +- fi ++Consider adjusting the PKG_CONFIG_PATH environment variable if you ++installed software in a non-standard prefix. + +- MKINSTALLDIRS= +- if test -n "$ac_aux_dir"; then +- MKINSTALLDIRS="$ac_aux_dir/mkinstalldirs" +- fi +- if test -z "$MKINSTALLDIRS"; then +- MKINSTALLDIRS="\$(top_srcdir)/mkinstalldirs" +- fi ++Alternatively, you may set the environment variables QALCULATE_CFLAGS ++and QALCULATE_LIBS to avoid the need to call pkg-config. ++See the pkg-config man page for more details. ++" >&2;} ++ { (exit 1); exit 1; }; } ++elif test $pkg_failed = untried; then ++ { { echo "$as_me:$LINENO: error: The pkg-config script could not be found or is too old. Make sure it ++is in your PATH or set the PKG_CONFIG environment variable to the full ++path to pkg-config. + ++Alternatively, you may set the environment variables QALCULATE_CFLAGS ++and QALCULATE_LIBS to avoid the need to call pkg-config. ++See the pkg-config man page for more details. + +- test -d po || mkdir po +- if test "x$srcdir" != "x."; then +- if test "x`echo $srcdir | sed 's@/.*@@'`" = "x"; then +- posrcprefix="$srcdir/" +- else +- posrcprefix="../$srcdir/" +- fi +- else +- posrcprefix="../" +- fi +- rm -f po/POTFILES +- sed -e "/^#/d" -e "/^\$/d" -e "s,.*, $posrcprefix& \\\\," -e "\$s/\(.*\) \\\\/\1/" \ +- < $srcdir/po/POTFILES.in > po/POTFILES ++To get pkg-config, see . ++See \`config.log' for more details." >&5 ++echo "$as_me: error: The pkg-config script could not be found or is too old. Make sure it ++is in your PATH or set the PKG_CONFIG environment variable to the full ++path to pkg-config. + ++Alternatively, you may set the environment variables QALCULATE_CFLAGS ++and QALCULATE_LIBS to avoid the need to call pkg-config. ++See the pkg-config man page for more details. + +-echo "$as_me:$LINENO: checking locale directory" >&5 +-echo $ECHO_N "checking locale directory... $ECHO_C" >&6 +-if test "x$prefix" = "xNONE"; then +- PACKAGE_LOCALE_DIR=$ac_default_prefix/share/locale ++To get pkg-config, see . ++See \`config.log' for more details." >&2;} ++ { (exit 1); exit 1; }; } + else +- PACKAGE_LOCALE_DIR=$prefix/share/locale ++ QALCULATE_CFLAGS=$pkg_cv_QALCULATE_CFLAGS ++ QALCULATE_LIBS=$pkg_cv_QALCULATE_LIBS ++ echo "$as_me:$LINENO: result: yes" >&5 ++echo "${ECHO_T}yes" >&6 ++ : + fi + + +-cat >>confdefs.h <<_ACEOF +-#define PACKAGE_LOCALE_DIR "$PACKAGE_LOCALE_DIR" +-_ACEOF +- +- echo "$as_me:$LINENO: result: \"$PACKAGE_LOCALE_DIR\"" >&5 +-echo "${ECHO_T}\"$PACKAGE_LOCALE_DIR\"" >&6 +- +-INTLTOOL_QALCULATE_DEFINITIONS_RULE='%.xml: %.xml.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po-defs/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -x -u -c $(top_builddir)/po-defs/.intltool-merge-cache $(top_srcdir)/po-defs $< $@' +- + + + ac_config_files="$ac_config_files Makefile data/Makefile src/Makefile po/Makefile.in" diff --git a/math/qalculate-units/patches/patch-ab b/math/qalculate-units/patches/patch-ab new file mode 100644 index 00000000000..c21745ee4ba --- /dev/null +++ b/math/qalculate-units/patches/patch-ab @@ -0,0 +1,72 @@ +$NetBSD: patch-ab,v 1.1 2006/06/22 18:52:01 jlam Exp $ + +--- configure.in.orig 2006-04-18 03:13:12.000000000 -0400 ++++ configure.in +@@ -55,6 +55,33 @@ fi + changequote([,])dnl + + ++dnl ------------------------------------- ++dnl | internationalization (i18n) support |------------------------------------ ++dnl ------------------------------------- ++ ++GETTEXT_PACKAGE=qalculate-units ++AC_SUBST(GETTEXT_PACKAGE) ++AC_DEFINE_UNQUOTED(GETTEXT_PACKAGE,"$GETTEXT_PACKAGE",[The package name for gettext]) ++ ++dnl Please keep this in alphabetical order ++ALL_LINGUAS="nl sv" ++AM_GLIB_GNU_GETTEXT ++ ++dnl AM_GLIB_GNU_GETTEXT sets $DATADIRNAME ++AC_MSG_CHECKING(locale directory) ++if test "x$prefix" = "xNONE"; then ++ PACKAGE_LOCALE_DIR=$ac_default_prefix/share/locale ++else ++ PACKAGE_LOCALE_DIR=$prefix/share/locale ++fi ++ ++AC_DEFINE_UNQUOTED(PACKAGE_LOCALE_DIR, "$PACKAGE_LOCALE_DIR", ++ [The directory in which qalculate's locale data will be stored]) ++ AC_MSG_RESULT("$PACKAGE_LOCALE_DIR") ++ ++INTLTOOL_QALCULATE_DEFINITIONS_RULE='%.xml: %.xml.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po-defs/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -x -u -c $(top_builddir)/po-defs/.intltool-merge-cache $(top_srcdir)/po-defs $< [$]@' ++AC_SUBST(INTLTOOL_QALCULATE_DEFINITIONS_RULE) ++ + dnl -------------------------------- + dnl | check for neccessary libraries |----------------------------------------- + dnl -------------------------------- +@@ -89,33 +116,6 @@ PKG_CHECK_MODULES(QALCULATE, [ + AC_SUBST(QALCULATE_CFLAGS) + AC_SUBST(QALCULATE_LIBS) + +-dnl ------------------------------------- +-dnl | internationalization (i18n) support |------------------------------------ +-dnl ------------------------------------- +- +-GETTEXT_PACKAGE=qalculate-units +-AC_SUBST(GETTEXT_PACKAGE) +-AC_DEFINE_UNQUOTED(GETTEXT_PACKAGE,"$GETTEXT_PACKAGE",[The package name for gettext]) +- +-dnl Please keep this in alphabetical order +-ALL_LINGUAS="nl sv" +-AM_GLIB_GNU_GETTEXT +- +-dnl AM_GLIB_GNU_GETTEXT sets $DATADIRNAME +-AC_MSG_CHECKING(locale directory) +-if test "x$prefix" = "xNONE"; then +- PACKAGE_LOCALE_DIR=$ac_default_prefix/share/locale +-else +- PACKAGE_LOCALE_DIR=$prefix/share/locale +-fi +- +-AC_DEFINE_UNQUOTED(PACKAGE_LOCALE_DIR, "$PACKAGE_LOCALE_DIR", +- [The directory in which qalculate's locale data will be stored]) +- AC_MSG_RESULT("$PACKAGE_LOCALE_DIR") +- +-INTLTOOL_QALCULATE_DEFINITIONS_RULE='%.xml: %.xml.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po-defs/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -x -u -c $(top_builddir)/po-defs/.intltool-merge-cache $(top_srcdir)/po-defs $< [$]@' +-AC_SUBST(INTLTOOL_QALCULATE_DEFINITIONS_RULE) +- + dnl -------- + dnl | output |----------------------------------------------------------------- + dnl -------- diff --git a/math/qalculate/distinfo b/math/qalculate/distinfo index a79a6b44311..d90485d6c31 100644 --- a/math/qalculate/distinfo +++ b/math/qalculate/distinfo @@ -1,8 +1,9 @@ -$NetBSD: distinfo,v 1.12 2006/06/14 20:14:21 adam Exp $ +$NetBSD: distinfo,v 1.13 2006/06/22 18:52:00 jlam Exp $ SHA1 (libqalculate-0.9.4.tar.gz) = 78468f5a0329b01e146a71ff8d1b9b823ed52262 RMD160 (libqalculate-0.9.4.tar.gz) = 8d14a0ac6790eeab0d8fe2d7b8f87381d1ad223c Size (libqalculate-0.9.4.tar.gz) = 1055947 bytes SHA1 (patch-aa) = fda2983150bbbdecc1578e747d8a6aa7ef965f3f -SHA1 (patch-ab) = bdc1a55f186ce7ab8c9ccb470d6d02f5ab10e483 +SHA1 (patch-ab) = 9888beca031650259fcb4f194e2ead39c73a9a70 SHA1 (patch-ac) = 98e817d60fc4cd521e7d227ecd330364ec072ecd +SHA1 (patch-ad) = 192adfe4ca7c0752109e02cce3ce74a385554176 diff --git a/math/qalculate/patches/patch-ab b/math/qalculate/patches/patch-ab index b1c629f56c7..dc3462c27a3 100644 --- a/math/qalculate/patches/patch-ab +++ b/math/qalculate/patches/patch-ab @@ -1,6 +1,6 @@ -$NetBSD: patch-ab,v 1.7 2006/06/14 20:14:21 adam Exp $ +$NetBSD: patch-ab,v 1.8 2006/06/22 18:52:00 jlam Exp $ ---- configure.orig 2006-06-01 22:14:56.000000000 +0200 +--- configure.orig 2006-06-01 16:14:56.000000000 -0400 +++ configure @@ -20042,12 +20042,10 @@ LIBTOOL='$(SHELL) $(top_builddir)/libtoo if test "x$GCC" = "xyes"; then @@ -15,43 +15,4031 @@ $NetBSD: patch-ab,v 1.7 2006/06/14 20:14:21 adam Exp $ ;; esac fi -@@ -20073,13 +20071,13 @@ QALCULATE_AGE=0 +@@ -20073,13 +20071,206 @@ QALCULATE_AGE=0 -echo "$as_me:$LINENO: checking for pthread_create in -lpthread" >&5 -echo $ECHO_N "checking for pthread_create in -lpthread... $ECHO_C" >&6 -+echo "$as_me:$LINENO: checking for pthread_create in ${PTHREAD_LDFLAGS} ${PTHREAD_LIBS}" >&5 -+echo $ECHO_N "checking for pthread_create in ${PTHREAD_LDFLAGS} ${PTHREAD_LIBS}... $ECHO_C" >&6 - if test "${ac_cv_lib_pthread_pthread_create+set}" = set; then +-if test "${ac_cv_lib_pthread_pthread_create+set}" = set; then ++ ++QALCULATE_TEXT="" ++LN_QALCULATE="" ++USE_READLINE="yes" ++READLINE_LIBS="" ++if test "x$enable_textport" = "xyes" ; then ++ QALCULATE_TEXT="qalc" ++ LN_QALCULATE="qalc" ++ ++ echo "$as_me:$LINENO: checking whether to use readline" >&5 ++echo $ECHO_N "checking whether to use readline... $ECHO_C" >&6 ++ ++# Check whether --with-readline or --without-readline was given. ++if test "${with_readline+set}" = set; then ++ withval="$with_readline" ++ case "${withval}" in ++ yes) USE_READLINE="yes" ; echo "$as_me:$LINENO: result: yes" >&5 ++echo "${ECHO_T}yes" >&6 ;; ++ no) USE_READLINE="no" ; echo "$as_me:$LINENO: result: no" >&5 ++echo "${ECHO_T}no" >&6 ;; ++ only) USE_READLINE="yes" ++ EXTRA_LIBREADLINE_DEPS=" " ++ echo "$as_me:$LINENO: result: yes (using only readline)" >&5 ++echo "${ECHO_T}yes (using only readline)" >&6 ;; ++ *) USE_READLINE="yes" ++ EXTRA_LIBREADLINE_DEPS="${withval}" ++ echo "$as_me:$LINENO: result: yes (using extra libraries ${withval})" >&5 ++echo "${ECHO_T}yes (using extra libraries ${withval})" >&6 ;; ++ esac ++else ++ echo "$as_me:$LINENO: result: ${USE_READLINE}" >&5 ++echo "${ECHO_T}${USE_READLINE}" >&6 ++fi; ++ ++ if test "$USE_READLINE" = yes ; then ++ ++ ++ ++for ac_header in readline/readline.h readline/history.h ++do ++as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh` ++if eval "test \"\${$as_ac_Header+set}\" = set"; then ++ echo "$as_me:$LINENO: checking for $ac_header" >&5 ++echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6 ++if eval "test \"\${$as_ac_Header+set}\" = set"; then ++ echo $ECHO_N "(cached) $ECHO_C" >&6 ++fi ++echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5 ++echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6 ++else ++ # Is the header compilable? ++echo "$as_me:$LINENO: checking $ac_header usability" >&5 ++echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6 ++cat >conftest.$ac_ext <<_ACEOF ++/* confdefs.h. */ ++_ACEOF ++cat confdefs.h >>conftest.$ac_ext ++cat >>conftest.$ac_ext <<_ACEOF ++/* end confdefs.h. */ ++$ac_includes_default ++#include <$ac_header> ++_ACEOF ++rm -f conftest.$ac_objext ++if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 ++ (eval $ac_compile) 2>conftest.er1 ++ ac_status=$? ++ grep -v '^ *+' conftest.er1 >conftest.err ++ rm -f conftest.er1 ++ cat conftest.err >&5 ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); } && ++ { ac_try='test -z "$ac_cxx_werror_flag" ++ || test ! -s conftest.err' ++ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 ++ (eval $ac_try) 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; } && ++ { ac_try='test -s conftest.$ac_objext' ++ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 ++ (eval $ac_try) 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; }; then ++ ac_header_compiler=yes ++else ++ echo "$as_me: failed program was:" >&5 ++sed 's/^/| /' conftest.$ac_ext >&5 ++ ++ac_header_compiler=no ++fi ++rm -f conftest.err conftest.$ac_objext conftest.$ac_ext ++echo "$as_me:$LINENO: result: $ac_header_compiler" >&5 ++echo "${ECHO_T}$ac_header_compiler" >&6 ++ ++# Is the header present? ++echo "$as_me:$LINENO: checking $ac_header presence" >&5 ++echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6 ++cat >conftest.$ac_ext <<_ACEOF ++/* confdefs.h. */ ++_ACEOF ++cat confdefs.h >>conftest.$ac_ext ++cat >>conftest.$ac_ext <<_ACEOF ++/* end confdefs.h. */ ++#include <$ac_header> ++_ACEOF ++if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5 ++ (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 ++ ac_status=$? ++ grep -v '^ *+' conftest.er1 >conftest.err ++ rm -f conftest.er1 ++ cat conftest.err >&5 ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); } >/dev/null; then ++ if test -s conftest.err; then ++ ac_cpp_err=$ac_cxx_preproc_warn_flag ++ ac_cpp_err=$ac_cpp_err$ac_cxx_werror_flag ++ else ++ ac_cpp_err= ++ fi ++else ++ ac_cpp_err=yes ++fi ++if test -z "$ac_cpp_err"; then ++ ac_header_preproc=yes ++else ++ echo "$as_me: failed program was:" >&5 ++sed 's/^/| /' conftest.$ac_ext >&5 ++ ++ ac_header_preproc=no ++fi ++rm -f conftest.err conftest.$ac_ext ++echo "$as_me:$LINENO: result: $ac_header_preproc" >&5 ++echo "${ECHO_T}$ac_header_preproc" >&6 ++ ++# So? What about this header? ++case $ac_header_compiler:$ac_header_preproc:$ac_cxx_preproc_warn_flag in ++ yes:no: ) ++ { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5 ++echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;} ++ { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5 ++echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;} ++ ac_header_preproc=yes ++ ;; ++ no:yes:* ) ++ { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5 ++echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;} ++ { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5 ++echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;} ++ { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5 ++echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;} ++ { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5 ++echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;} ++ { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5 ++echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;} ++ { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5 ++echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;} ++ ( ++ cat <<\_ASBOX ++## ------------------------------------------ ## ++## Report this to the AC_PACKAGE_NAME lists. ## ++## ------------------------------------------ ## ++_ASBOX ++ ) | ++ sed "s/^/$as_me: WARNING: /" >&2 ++ ;; ++esac ++echo "$as_me:$LINENO: checking for $ac_header" >&5 ++echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6 ++if eval "test \"\${$as_ac_Header+set}\" = set"; then ++ echo $ECHO_N "(cached) $ECHO_C" >&6 ++else ++ eval "$as_ac_Header=\$ac_header_preproc" ++fi ++echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5 ++echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6 ++ ++fi ++if test `eval echo '${'$as_ac_Header'}'` = yes; then ++ cat >>confdefs.h <<_ACEOF ++#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1 ++_ACEOF ++ ++fi ++ ++done ++ ++ if test "x${ac_cv_header_readline_readline_h}" != "xyes" -o "x${ac_cv_header_readline_history_h}" != "xyes"; then ++ { echo "$as_me:$LINENO: WARNING: Could not find the headers for libreadline." >&5 ++echo "$as_me: WARNING: Could not find the headers for libreadline." >&2;} ++ else ++ if test "$EXTRA_LIBREADLINE_DEPS" = "" ; then ++ unset ac_cv_lib_readline_readline ++ echo "$as_me:$LINENO: checking for readline in -lreadline" >&5 ++echo $ECHO_N "checking for readline in -lreadline... $ECHO_C" >&6 ++if test "${ac_cv_lib_readline_readline+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else ac_check_lib_save_LIBS=$LIBS -LIBS="-lpthread $LIBS" -+LIBS="${PTHREAD_LDFLAGS} ${PTHREAD_LIBS} $LIBS" ++LIBS="-lreadline -lncurses $LIBS" cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF -@@ -20138,7 +20136,7 @@ fi - echo "$as_me:$LINENO: result: $ac_cv_lib_pthread_pthread_create" >&5 - echo "${ECHO_T}$ac_cv_lib_pthread_pthread_create" >&6 - if test $ac_cv_lib_pthread_pthread_create = yes; then +@@ -20093,11 +20284,11 @@ extern "C" + #endif + /* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +-char pthread_create (); ++char readline (); + int + main () + { +-pthread_create (); ++readline (); + ; + return 0; + } +@@ -20111,7 +20302,7 @@ if { (eval echo "$as_me:$LINENO: \"$ac_l + cat conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } && +- { ac_try='test -z "$ac_c_werror_flag" ++ { ac_try='test -z "$ac_cxx_werror_flag" + || test ! -s conftest.err' + { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 +@@ -20124,259 +20315,140 @@ if { (eval echo "$as_me:$LINENO: \"$ac_l + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then +- ac_cv_lib_pthread_pthread_create=yes ++ ac_cv_lib_readline_readline=yes + else + echo "$as_me: failed program was:" >&5 + sed 's/^/| /' conftest.$ac_ext >&5 + +-ac_cv_lib_pthread_pthread_create=no ++ac_cv_lib_readline_readline=no + fi + rm -f conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + LIBS=$ac_check_lib_save_LIBS + fi +-echo "$as_me:$LINENO: result: $ac_cv_lib_pthread_pthread_create" >&5 +-echo "${ECHO_T}$ac_cv_lib_pthread_pthread_create" >&6 +-if test $ac_cv_lib_pthread_pthread_create = yes; then - LIBS="$LIBS -lpthread" -+ LIBS="$LIBS ${PTHREAD_LDFLAGS} ${PTHREAD_LIBS}" ++echo "$as_me:$LINENO: result: $ac_cv_lib_readline_readline" >&5 ++echo "${ECHO_T}$ac_cv_lib_readline_readline" >&6 ++if test $ac_cv_lib_readline_readline = yes; then ++ HAVE_LIBREADLINE=true ++else ++ HAVE_LIBREADLINE=false + fi + ++ if test x${HAVE_LIBREADLINE} = xtrue ; then ++ echo " Using -lreadline -lncurses" ++ EXTRA_LIBREADLINE_DEPS=-lncurses + +-ac_ext=cc +-ac_cpp='$CXXCPP $CPPFLAGS' +-ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' +-ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' +-ac_compiler_gnu=$ac_cv_cxx_compiler_gnu +- +- ++cat >>confdefs.h <<\_ACEOF ++#define HAVE_LIBREADLINE 1 ++_ACEOF + +-# Check whether --with-cln-prefix or --without-cln-prefix was given. +-if test "${with_cln_prefix+set}" = set; then +- withval="$with_cln_prefix" +- cln_config_prefix="$withval" ++ else ++ unset ac_cv_lib_readline_readline ++ echo "$as_me:$LINENO: checking for readline in -lreadline" >&5 ++echo $ECHO_N "checking for readline in -lreadline... $ECHO_C" >&6 ++if test "${ac_cv_lib_readline_readline+set}" = set; then ++ echo $ECHO_N "(cached) $ECHO_C" >&6 + else +- cln_config_prefix="" +-fi; ++ ac_check_lib_save_LIBS=$LIBS ++LIBS="-lreadline -lcurses $LIBS" ++cat >conftest.$ac_ext <<_ACEOF ++/* confdefs.h. */ ++_ACEOF ++cat confdefs.h >>conftest.$ac_ext ++cat >>conftest.$ac_ext <<_ACEOF ++/* end confdefs.h. */ + +-# Check whether --with-cln-exec-prefix or --without-cln-exec-prefix was given. +-if test "${with_cln_exec_prefix+set}" = set; then +- withval="$with_cln_exec_prefix" +- cln_config_exec_prefix="$withval" +-else +- cln_config_exec_prefix="" +-fi; +-# Check whether --enable-clntest or --disable-clntest was given. +-if test "${enable_clntest+set}" = set; then +- enableval="$enable_clntest" +- +-else +- enable_clntest=yes +-fi; +- +-if test x$cln_config_exec_prefix != x ; then +- cln_config_args="$cln_config_args --exec-prefix=$cln_config_exec_prefix" +- if test x${CLN_CONFIG+set} != xset ; then +- CLN_CONFIG=$cln_config_exec_prefix/bin/cln-config +- fi +-fi +-if test x$cln_config_prefix != x ; then +- cln_config_args="$cln_config_args --prefix=$cln_config_prefix" +- if test x${CLN_CONFIG+set} != xset ; then +- CLN_CONFIG=$cln_config_prefix/bin/cln-config +- fi +-fi +- +-# Extract the first word of "cln-config", so it can be a program name with args. +-set dummy cln-config; ac_word=$2 +-echo "$as_me:$LINENO: checking for $ac_word" >&5 +-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 +-if test "${ac_cv_path_CLN_CONFIG+set}" = set; then +- echo $ECHO_N "(cached) $ECHO_C" >&6 +-else +- case $CLN_CONFIG in +- [\\/]* | ?:[\\/]*) +- ac_cv_path_CLN_CONFIG="$CLN_CONFIG" # Let the user override the test with a path. +- ;; +- *) +- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +-for as_dir in $PATH +-do +- IFS=$as_save_IFS +- test -z "$as_dir" && as_dir=. +- for ac_exec_ext in '' $ac_executable_extensions; do +- if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then +- ac_cv_path_CLN_CONFIG="$as_dir/$ac_word$ac_exec_ext" +- echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 +- break 2 +- fi +-done +-done +- +- test -z "$ac_cv_path_CLN_CONFIG" && ac_cv_path_CLN_CONFIG="no" +- ;; +-esac +-fi +-CLN_CONFIG=$ac_cv_path_CLN_CONFIG +- +-if test -n "$CLN_CONFIG"; then +- echo "$as_me:$LINENO: result: $CLN_CONFIG" >&5 +-echo "${ECHO_T}$CLN_CONFIG" >&6 +-else +- echo "$as_me:$LINENO: result: no" >&5 +-echo "${ECHO_T}no" >&6 +-fi +- +-cln_min_version=1.1.0 +-echo "$as_me:$LINENO: checking for CLN - version >= $cln_min_version" >&5 +-echo $ECHO_N "checking for CLN - version >= $cln_min_version... $ECHO_C" >&6 +-if test "$CLN_CONFIG" = "no" ; then +- echo "$as_me:$LINENO: result: no" >&5 +-echo "${ECHO_T}no" >&6 +- echo "*** The cln-config script installed by CLN could not be found" +- echo "*** If CLN was installed in PREFIX, make sure PREFIX/bin is in" +- echo "*** your path, or set the CLN_CONFIG environment variable to the" +- echo "*** full path to cln-config." +- { { echo "$as_me:$LINENO: error: No suitable installed version of CLN could be found." >&5 +-echo "$as_me: error: No suitable installed version of CLN could be found." >&2;} +- { (exit 1); exit 1; }; } +-else +- cln_min_major_version=`echo $cln_min_version | \ +- sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\1/'` +- cln_min_minor_version=`echo $cln_min_version | \ +- sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\2/'` +- cln_min_micro_version=`echo $cln_min_version | \ +- sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\3/'` +- CLN_CPPFLAGS=`$CLN_CONFIG $cln_config_args --cppflags` +- CLN_LIBS=`$CLN_CONFIG $cln_config_args --libs` +- cln_config_version=`$CLN_CONFIG $cln_config_args --version` +- cln_config_major_version=`echo $cln_config_version | \ +- sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\1/'` +- cln_config_minor_version=`echo $cln_config_version | \ +- sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\2/'` +- cln_config_micro_version=`echo $cln_config_version | \ +- sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\3/'` +- if test \( $cln_config_major_version -lt $cln_min_major_version \) -o \ +- \( $cln_config_major_version -eq $cln_min_major_version -a $cln_config_minor_version -lt $cln_min_minor_version \) -o \ +- \( $cln_config_major_version -eq $cln_min_major_version -a $cln_config_minor_version -eq $cln_min_minor_version -a $cln_config_micro_version -lt $cln_min_micro_version \); then +- echo -e "\n*** 'cln-config --version' returned $cln_config_major_version.$cln_config_minor_version.$cln_config_micro_version, but the minimum version" +- echo "*** of CLN required is $cln_min_major_version.$cln_min_minor_version.$cln_min_micro_version. If cln-config is correct, then it is" +- echo "*** best to upgrade to the required version." +- echo "*** If cln-config was wrong, set the environment variable CLN_CONFIG" +- echo "*** to point to the correct copy of cln-config, and remove the file" +- echo "*** config.cache before re-running configure." +- { { echo "$as_me:$LINENO: error: No suitable installed version of CLN could be found." >&5 +-echo "$as_me: error: No suitable installed version of CLN could be found." >&2;} +- { (exit 1); exit 1; }; } +- else +- no_cln="" +- if test "x$enable_clntest" = "xyes" ; then +- ac_save_CPPFLAGS="$CPPFLAGS" +- ac_save_LIBS="$LIBS" +- CPPFLAGS="$CPPFLAGS $CLN_CPPFLAGS" +- LIBS="$LIBS $CLN_LIBS" +- rm -f conf.clntest +- if test "$cross_compiling" = yes; then +- echo $ac_n "cross compiling; assumed OK... $ac_c" +-else +- cat >conftest.$ac_ext <<_ACEOF +-/* confdefs.h. */ +-_ACEOF +-cat confdefs.h >>conftest.$ac_ext +-cat >>conftest.$ac_ext <<_ACEOF +-/* end confdefs.h. */ +- +-#include +-#include +-#include +- +-/* we do not #include because autoconf in C++ mode inserts a +- prototype for exit() that conflicts with the one in stdlib.h */ +-extern "C" int system(const char *); +- +-int main(void) ++/* Override any gcc2 internal prototype to avoid an error. */ ++#ifdef __cplusplus ++extern "C" ++#endif ++/* We use char because int might match the return type of a gcc2 ++ builtin and then its argument prototype would still apply. */ ++char readline (); ++int ++main () + { +- system("touch conf.clntest"); +- +- if ((CL_VERSION_MAJOR != $cln_config_major_version) || +- (CL_VERSION_MINOR != $cln_config_minor_version) || +- (CL_VERSION_PATCHLEVEL != $cln_config_micro_version)) { +- printf("\n*** 'cln-config --version' returned %d.%d.%d, but the header file I found\n", $cln_config_major_version, $cln_config_minor_version, $cln_config_micro_version); +- printf("*** corresponds to %d.%d.%d. This mismatch suggests your installation of CLN\n", CL_VERSION_MAJOR, CL_VERSION_MINOR, CL_VERSION_PATCHLEVEL); +- printf("*** is corrupted or you have specified some wrong -I compiler flags.\n"); +- printf("*** Please inquire and consider reinstalling CLN.\n"); +- return 1; +- } +- if ((cln::version_major != $cln_config_major_version) || +- (cln::version_minor != $cln_config_minor_version) || +- (cln::version_patchlevel != $cln_config_micro_version)) { +- printf("\n*** 'cln-config --version' returned %d.%d.%d, but the library I found\n", $cln_config_major_version, $cln_config_minor_version, $cln_config_micro_version); +- printf("*** corresponds to %d.%d.%d. This mismatch suggests your installation of CLN\n", cln::version_major, cln::version_minor, cln::version_patchlevel); +- printf("*** is corrupted or you have specified some wrong -L compiler flags.\n"); +- printf("*** Please inquire and consider reinstalling CLN.\n"); +- return 1; +- } +- return 0; ++readline (); ++ ; ++ return 0; + } +- + _ACEOF +-rm -f conftest$ac_exeext ++rm -f conftest.$ac_objext conftest$ac_exeext + if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 +- (eval $ac_link) 2>&5 ++ (eval $ac_link) 2>conftest.er1 + ac_status=$? ++ grep -v '^ *+' conftest.er1 >conftest.err ++ rm -f conftest.er1 ++ cat conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); } && { ac_try='./conftest$ac_exeext' ++ (exit $ac_status); } && ++ { ac_try='test -z "$ac_cxx_werror_flag" ++ || test ! -s conftest.err' ++ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 ++ (eval $ac_try) 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; } && ++ { ac_try='test -s conftest$ac_exeext' + { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then +- : ++ ac_cv_lib_readline_readline=yes + else +- echo "$as_me: program exited with status $ac_status" >&5 +-echo "$as_me: failed program was:" >&5 ++ echo "$as_me: failed program was:" >&5 + sed 's/^/| /' conftest.$ac_ext >&5 + +-( exit $ac_status ) +-no_cln=yes ++ac_cv_lib_readline_readline=no + fi +-rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext ++rm -f conftest.err conftest.$ac_objext \ ++ conftest$ac_exeext conftest.$ac_ext ++LIBS=$ac_check_lib_save_LIBS ++fi ++echo "$as_me:$LINENO: result: $ac_cv_lib_readline_readline" >&5 ++echo "${ECHO_T}$ac_cv_lib_readline_readline" >&6 ++if test $ac_cv_lib_readline_readline = yes; then ++ HAVE_LIBREADLINE=true ++else ++ HAVE_LIBREADLINE=false + fi +- CPPFLAGS="$ac_save_CPPFLAGS" +- LIBS="$ac_save_LIBS" +- fi +- if test "x$no_cln" = x ; then +- echo "$as_me:$LINENO: result: yes, $cln_config_version" >&5 +-echo "${ECHO_T}yes, $cln_config_version" >&6 + +- LIBS="$LIBS $CLN_LIBS" +- CPPFLAGS="$CPPFLAGS $CLN_CPPFLAGS" ++ if test x${HAVE_LIBREADLINE} = xtrue ; then ++ echo " Using -lreadline -lcurses" ++ EXTRA_LIBREADLINE_DEPS=-lcurses + + cat >>confdefs.h <<\_ACEOF +-#define HAVE_LIBCLN 1 ++#define HAVE_LIBREADLINE 1 + _ACEOF + +- + else +- echo "$as_me:$LINENO: result: no" >&5 +-echo "${ECHO_T}no" >&6 +- if test ! -f conf.clntest ; then +- echo "*** Could not run CLN test program, checking why..." +- CPPFLAGS="$CFLAGS $CLN_CPPFLAGS" +- LIBS="$LIBS $CLN_LIBS" +- cat >conftest.$ac_ext <<_ACEOF ++ unset ac_cv_lib_readline_readline ++ echo "$as_me:$LINENO: checking for readline in -lreadline" >&5 ++echo $ECHO_N "checking for readline in -lreadline... $ECHO_C" >&6 ++if test "${ac_cv_lib_readline_readline+set}" = set; then ++ echo $ECHO_N "(cached) $ECHO_C" >&6 ++else ++ ac_check_lib_save_LIBS=$LIBS ++LIBS="-lreadline -ltermcap $LIBS" ++cat >conftest.$ac_ext <<_ACEOF + /* confdefs.h. */ + _ACEOF + cat confdefs.h >>conftest.$ac_ext + cat >>conftest.$ac_ext <<_ACEOF + /* end confdefs.h. */ + +-#include +-#include +- ++/* Override any gcc2 internal prototype to avoid an error. */ ++#ifdef __cplusplus ++extern "C" ++#endif ++/* We use char because int might match the return type of a gcc2 ++ builtin and then its argument prototype would still apply. */ ++char readline (); + int + main () + { +- return 0; ++readline (); + ; + return 0; + } +@@ -20403,328 +20475,230 @@ if { (eval echo "$as_me:$LINENO: \"$ac_l + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then +- echo "*** The test program compiled, but did not run. This usually means" +- echo "*** that the run-time linker is not finding CLN or finding the wrong" +- echo "*** version of CLN. If it is not finding CLN, you'll need to set your" +- echo "*** LD_LIBRARY_PATH environment variable, or edit /etc/ld.so.conf to point" +- echo "*** to the installed location. Also, make sure you have run ldconfig if that" +- echo "*** is required on your system." ++ ac_cv_lib_readline_readline=yes + else + echo "$as_me: failed program was:" >&5 + sed 's/^/| /' conftest.$ac_ext >&5 + +- echo "*** The test program failed to compile or link. See the file config.log for the" +- echo "*** exact error that occured. This usually means CLN was incorrectly installed" +- echo "*** or that you have moved CLN since it was installed. In the latter case, you" +- echo "*** may want to edit the cln-config script: $CLN_CONFIG." ++ac_cv_lib_readline_readline=no + fi + rm -f conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +- CPPFLAGS="$ac_save_CPPFLAGS" +- LIBS="$ac_save_LIBS" +- fi +- CLN_CPPFLAGS="" +- CLN_LIBS="" +- { { echo "$as_me:$LINENO: error: No suitable installed version of CLN could be found." >&5 +-echo "$as_me: error: No suitable installed version of CLN could be found." >&2;} +- { (exit 1); exit 1; }; } +- fi +- fi ++LIBS=$ac_check_lib_save_LIBS ++fi ++echo "$as_me:$LINENO: result: $ac_cv_lib_readline_readline" >&5 ++echo "${ECHO_T}$ac_cv_lib_readline_readline" >&6 ++if test $ac_cv_lib_readline_readline = yes; then ++ HAVE_LIBREADLINE=true ++else ++ HAVE_LIBREADLINE=false + fi + ++ if test x${HAVE_LIBREADLINE} = xtrue ; then ++ echo " Using -lreadline -ltermcap" ++ EXTRA_LIBREADLINE_DEPS=-ltermcap + +-rm -f conf.clntest +- +- +- +- ++cat >>confdefs.h <<\_ACEOF ++#define HAVE_LIBREADLINE 1 ++_ACEOF + +-if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then +- if test -n "$ac_tool_prefix"; then +- # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args. +-set dummy ${ac_tool_prefix}pkg-config; ac_word=$2 +-echo "$as_me:$LINENO: checking for $ac_word" >&5 +-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 +-if test "${ac_cv_path_PKG_CONFIG+set}" = set; then ++ else ++ unset ac_cv_lib_readline_readline ++ echo "$as_me:$LINENO: checking for readline in -lreadline" >&5 ++echo $ECHO_N "checking for readline in -lreadline... $ECHO_C" >&6 ++if test "${ac_cv_lib_readline_readline+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 + else +- case $PKG_CONFIG in +- [\\/]* | ?:[\\/]*) +- ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path. +- ;; +- *) +- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +-for as_dir in $PATH +-do +- IFS=$as_save_IFS +- test -z "$as_dir" && as_dir=. +- for ac_exec_ext in '' $ac_executable_extensions; do +- if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then +- ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" +- echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 +- break 2 +- fi +-done +-done +- +- ;; +-esac +-fi +-PKG_CONFIG=$ac_cv_path_PKG_CONFIG +- +-if test -n "$PKG_CONFIG"; then +- echo "$as_me:$LINENO: result: $PKG_CONFIG" >&5 +-echo "${ECHO_T}$PKG_CONFIG" >&6 +-else +- echo "$as_me:$LINENO: result: no" >&5 +-echo "${ECHO_T}no" >&6 +-fi ++ ac_check_lib_save_LIBS=$LIBS ++LIBS="-lreadline $LIBS" ++cat >conftest.$ac_ext <<_ACEOF ++/* confdefs.h. */ ++_ACEOF ++cat confdefs.h >>conftest.$ac_ext ++cat >>conftest.$ac_ext <<_ACEOF ++/* end confdefs.h. */ + +-fi +-if test -z "$ac_cv_path_PKG_CONFIG"; then +- ac_pt_PKG_CONFIG=$PKG_CONFIG +- # Extract the first word of "pkg-config", so it can be a program name with args. +-set dummy pkg-config; ac_word=$2 +-echo "$as_me:$LINENO: checking for $ac_word" >&5 +-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 +-if test "${ac_cv_path_ac_pt_PKG_CONFIG+set}" = set; then +- echo $ECHO_N "(cached) $ECHO_C" >&6 ++/* Override any gcc2 internal prototype to avoid an error. */ ++#ifdef __cplusplus ++extern "C" ++#endif ++/* We use char because int might match the return type of a gcc2 ++ builtin and then its argument prototype would still apply. */ ++char readline (); ++int ++main () ++{ ++readline (); ++ ; ++ return 0; ++} ++_ACEOF ++rm -f conftest.$ac_objext conftest$ac_exeext ++if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 ++ (eval $ac_link) 2>conftest.er1 ++ ac_status=$? ++ grep -v '^ *+' conftest.er1 >conftest.err ++ rm -f conftest.er1 ++ cat conftest.err >&5 ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); } && ++ { ac_try='test -z "$ac_cxx_werror_flag" ++ || test ! -s conftest.err' ++ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 ++ (eval $ac_try) 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; } && ++ { ac_try='test -s conftest$ac_exeext' ++ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 ++ (eval $ac_try) 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; }; then ++ ac_cv_lib_readline_readline=yes + else +- case $ac_pt_PKG_CONFIG in +- [\\/]* | ?:[\\/]*) +- ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path. +- ;; +- *) +- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +-for as_dir in $PATH +-do +- IFS=$as_save_IFS +- test -z "$as_dir" && as_dir=. +- for ac_exec_ext in '' $ac_executable_extensions; do +- if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then +- ac_cv_path_ac_pt_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" +- echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 +- break 2 +- fi +-done +-done ++ echo "$as_me: failed program was:" >&5 ++sed 's/^/| /' conftest.$ac_ext >&5 + +- ;; +-esac ++ac_cv_lib_readline_readline=no + fi +-ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG +- +-if test -n "$ac_pt_PKG_CONFIG"; then +- echo "$as_me:$LINENO: result: $ac_pt_PKG_CONFIG" >&5 +-echo "${ECHO_T}$ac_pt_PKG_CONFIG" >&6 +-else +- echo "$as_me:$LINENO: result: no" >&5 +-echo "${ECHO_T}no" >&6 ++rm -f conftest.err conftest.$ac_objext \ ++ conftest$ac_exeext conftest.$ac_ext ++LIBS=$ac_check_lib_save_LIBS + fi +- +- PKG_CONFIG=$ac_pt_PKG_CONFIG ++echo "$as_me:$LINENO: result: $ac_cv_lib_readline_readline" >&5 ++echo "${ECHO_T}$ac_cv_lib_readline_readline" >&6 ++if test $ac_cv_lib_readline_readline = yes; then ++ HAVE_LIBREADLINE=true + else +- PKG_CONFIG="$ac_cv_path_PKG_CONFIG" ++ HAVE_LIBREADLINE=false + fi + +-fi +-if test -n "$PKG_CONFIG"; then +- _pkg_min_version=0.9.0 +- echo "$as_me:$LINENO: checking pkg-config is at least version $_pkg_min_version" >&5 +-echo $ECHO_N "checking pkg-config is at least version $_pkg_min_version... $ECHO_C" >&6 +- if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then +- echo "$as_me:$LINENO: result: yes" >&5 +-echo "${ECHO_T}yes" >&6 +- else +- echo "$as_me:$LINENO: result: no" >&5 +-echo "${ECHO_T}no" >&6 +- PKG_CONFIG="" +- fi +- +-fi ++ if test x${HAVE_LIBREADLINE} = xtrue ; then + +-pkg_failed=no +-echo "$as_me:$LINENO: checking for GLIB" >&5 +-echo $ECHO_N "checking for GLIB... $ECHO_C" >&6 ++cat >>confdefs.h <<\_ACEOF ++#define HAVE_LIBREADLINE 1 ++_ACEOF + +-if test -n "$PKG_CONFIG"; then +- if test -n "$GLIB_CFLAGS"; then +- pkg_cv_GLIB_CFLAGS="$GLIB_CFLAGS" ++ fi ++ fi ++ fi ++ fi + else +- if test -n "$PKG_CONFIG" && \ +- { (echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \" +- glib-2.0 +- libxml-2.0 >= 2.3.8 +- \"") >&5 +- ($PKG_CONFIG --exists --print-errors " +- glib-2.0 +- libxml-2.0 >= 2.3.8 +- ") 2>&5 +- ac_status=$? +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; then +- pkg_cv_GLIB_CFLAGS=`$PKG_CONFIG --cflags " +- glib-2.0 +- libxml-2.0 >= 2.3.8 +- " 2>/dev/null` +-else +- pkg_failed=yes +-fi +- fi ++ unset ac_cv_lib_readline_readline ++ echo "$as_me:$LINENO: checking for readline in -lreadline" >&5 ++echo $ECHO_N "checking for readline in -lreadline... $ECHO_C" >&6 ++if test "${ac_cv_lib_readline_readline+set}" = set; then ++ echo $ECHO_N "(cached) $ECHO_C" >&6 + else +- pkg_failed=untried +-fi +-if test -n "$PKG_CONFIG"; then +- if test -n "$GLIB_LIBS"; then +- pkg_cv_GLIB_LIBS="$GLIB_LIBS" +- else +- if test -n "$PKG_CONFIG" && \ +- { (echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \" +- glib-2.0 +- libxml-2.0 >= 2.3.8 +- \"") >&5 +- ($PKG_CONFIG --exists --print-errors " +- glib-2.0 +- libxml-2.0 >= 2.3.8 +- ") 2>&5 ++ ac_check_lib_save_LIBS=$LIBS ++LIBS="-lreadline ${EXTRA_LIBREADLINE_DEPS} $LIBS" ++cat >conftest.$ac_ext <<_ACEOF ++/* confdefs.h. */ ++_ACEOF ++cat confdefs.h >>conftest.$ac_ext ++cat >>conftest.$ac_ext <<_ACEOF ++/* end confdefs.h. */ ++ ++/* Override any gcc2 internal prototype to avoid an error. */ ++#ifdef __cplusplus ++extern "C" ++#endif ++/* We use char because int might match the return type of a gcc2 ++ builtin and then its argument prototype would still apply. */ ++char readline (); ++int ++main () ++{ ++readline (); ++ ; ++ return 0; ++} ++_ACEOF ++rm -f conftest.$ac_objext conftest$ac_exeext ++if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 ++ (eval $ac_link) 2>conftest.er1 ++ ac_status=$? ++ grep -v '^ *+' conftest.er1 >conftest.err ++ rm -f conftest.er1 ++ cat conftest.err >&5 ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); } && ++ { ac_try='test -z "$ac_cxx_werror_flag" ++ || test ! -s conftest.err' ++ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 ++ (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; then +- pkg_cv_GLIB_LIBS=`$PKG_CONFIG --libs " +- glib-2.0 +- libxml-2.0 >= 2.3.8 +- " 2>/dev/null` ++ (exit $ac_status); }; } && ++ { ac_try='test -s conftest$ac_exeext' ++ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 ++ (eval $ac_try) 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; }; then ++ ac_cv_lib_readline_readline=yes + else +- pkg_failed=yes ++ echo "$as_me: failed program was:" >&5 ++sed 's/^/| /' conftest.$ac_ext >&5 ++ ++ac_cv_lib_readline_readline=no + fi +- fi +-else +- pkg_failed=untried ++rm -f conftest.err conftest.$ac_objext \ ++ conftest$ac_exeext conftest.$ac_ext ++LIBS=$ac_check_lib_save_LIBS + fi +- +- +- +-if test $pkg_failed = yes; then +- +-if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then +- _pkg_short_errors_supported=yes ++echo "$as_me:$LINENO: result: $ac_cv_lib_readline_readline" >&5 ++echo "${ECHO_T}$ac_cv_lib_readline_readline" >&6 ++if test $ac_cv_lib_readline_readline = yes; then ++ HAVE_LIBREADLINE=true + else +- _pkg_short_errors_supported=no ++ HAVE_LIBREADLINE=false + fi +- if test $_pkg_short_errors_supported = yes; then +- GLIB_PKG_ERRORS=`$PKG_CONFIG --short-errors --errors-to-stdout --print-errors " +- glib-2.0 +- libxml-2.0 >= 2.3.8 +- "` +- else +- GLIB_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors " +- glib-2.0 +- libxml-2.0 >= 2.3.8 +- "` +- fi +- # Put the nasty error message in config.log where it belongs +- echo "$GLIB_PKG_ERRORS" >&5 +- +- { { echo "$as_me:$LINENO: error: Package requirements ( +- glib-2.0 +- libxml-2.0 >= 2.3.8 +- ) were not met: + +-$GLIB_PKG_ERRORS +- +-Consider adjusting the PKG_CONFIG_PATH environment variable if you +-installed software in a non-standard prefix. ++ if test x${HAVE_LIBREADLINE} = xtrue ; then ++ echo " Using -lreadline ${EXTRA_LIBREADLINE_DEPS}" + +-Alternatively, you may set the environment variables GLIB_CFLAGS +-and GLIB_LIBS to avoid the need to call pkg-config. +-See the pkg-config man page for more details. +-" >&5 +-echo "$as_me: error: Package requirements ( +- glib-2.0 +- libxml-2.0 >= 2.3.8 +- ) were not met: ++cat >>confdefs.h <<\_ACEOF ++#define HAVE_LIBREADLINE 1 ++_ACEOF + +-$GLIB_PKG_ERRORS ++ fi ++ fi ++ if test x${HAVE_LIBREADLINE} = xtrue; then ++ READLINE_LIBS="-lreadline -lhistory ${EXTRA_LIBREADLINE_DEPS}" ++ else ++ { echo "$as_me:$LINENO: WARNING: Could not find libreadline." >&5 ++echo "$as_me: WARNING: Could not find libreadline." >&2;} ++ fi ++ fi ++ fi ++fi + +-Consider adjusting the PKG_CONFIG_PATH environment variable if you +-installed software in a non-standard prefix. + +-Alternatively, you may set the environment variables GLIB_CFLAGS +-and GLIB_LIBS to avoid the need to call pkg-config. +-See the pkg-config man page for more details. +-" >&2;} +- { (exit 1); exit 1; }; } +-elif test $pkg_failed = untried; then +- { { echo "$as_me:$LINENO: error: The pkg-config script could not be found or is too old. Make sure it +-is in your PATH or set the PKG_CONFIG environment variable to the full +-path to pkg-config. + +-Alternatively, you may set the environment variables GLIB_CFLAGS +-and GLIB_LIBS to avoid the need to call pkg-config. +-See the pkg-config man page for more details. + +-To get pkg-config, see . +-See \`config.log' for more details." >&5 +-echo "$as_me: error: The pkg-config script could not be found or is too old. Make sure it +-is in your PATH or set the PKG_CONFIG environment variable to the full +-path to pkg-config. + +-Alternatively, you may set the environment variables GLIB_CFLAGS +-and GLIB_LIBS to avoid the need to call pkg-config. +-See the pkg-config man page for more details. + +-To get pkg-config, see . +-See \`config.log' for more details." >&2;} +- { (exit 1); exit 1; }; } +-else +- GLIB_CFLAGS=$pkg_cv_GLIB_CFLAGS +- GLIB_LIBS=$pkg_cv_GLIB_LIBS +- echo "$as_me:$LINENO: result: yes" >&5 +-echo "${ECHO_T}yes" >&6 +- : ++QALCULATE_DEFS2DOC="" ++if test "x$enable_defs2doc" = "xyes" ; then ++ QALCULATE_DEFS2DOC="defs2doc" + fi + + + ++GETTEXT_PACKAGE=libqalculate + +-QALCULATE_TEXT="" +-LN_QALCULATE="" +-USE_READLINE="yes" +-READLINE_LIBS="" +-if test "x$enable_textport" = "xyes" ; then +- QALCULATE_TEXT="qalc" +- LN_QALCULATE="qalc" +- +- echo "$as_me:$LINENO: checking whether to use readline" >&5 +-echo $ECHO_N "checking whether to use readline... $ECHO_C" >&6 + +-# Check whether --with-readline or --without-readline was given. +-if test "${with_readline+set}" = set; then +- withval="$with_readline" +- case "${withval}" in +- yes) USE_READLINE="yes" ; echo "$as_me:$LINENO: result: yes" >&5 +-echo "${ECHO_T}yes" >&6 ;; +- no) USE_READLINE="no" ; echo "$as_me:$LINENO: result: no" >&5 +-echo "${ECHO_T}no" >&6 ;; +- only) USE_READLINE="yes" +- EXTRA_LIBREADLINE_DEPS=" " +- echo "$as_me:$LINENO: result: yes (using only readline)" >&5 +-echo "${ECHO_T}yes (using only readline)" >&6 ;; +- *) USE_READLINE="yes" +- EXTRA_LIBREADLINE_DEPS="${withval}" +- echo "$as_me:$LINENO: result: yes (using extra libraries ${withval})" >&5 +-echo "${ECHO_T}yes (using extra libraries ${withval})" >&6 ;; +- esac +-else +- echo "$as_me:$LINENO: result: ${USE_READLINE}" >&5 +-echo "${ECHO_T}${USE_READLINE}" >&6 +-fi; ++cat >>confdefs.h <<_ACEOF ++#define GETTEXT_PACKAGE "$GETTEXT_PACKAGE" ++_ACEOF + +- if test "$USE_READLINE" = yes ; then + ++ALL_LINGUAS="nl sv" + + +-for ac_header in readline/readline.h readline/history.h ++for ac_header in locale.h + do + as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh` + if eval "test \"\${$as_ac_Header+set}\" = set"; then +@@ -20873,44 +20847,102 @@ fi + + done + +- if test "x${ac_cv_header_readline_readline_h}" != "xyes" -o "x${ac_cv_header_readline_history_h}" != "xyes"; then +- { echo "$as_me:$LINENO: WARNING: Could not find the headers for libreadline." >&5 +-echo "$as_me: WARNING: Could not find the headers for libreadline." >&2;} +- else +- if test "$EXTRA_LIBREADLINE_DEPS" = "" ; then +- unset ac_cv_lib_readline_readline +- echo "$as_me:$LINENO: checking for readline in -lreadline" >&5 +-echo $ECHO_N "checking for readline in -lreadline... $ECHO_C" >&6 +-if test "${ac_cv_lib_readline_readline+set}" = set; then ++ if test $ac_cv_header_locale_h = yes; then ++ echo "$as_me:$LINENO: checking for LC_MESSAGES" >&5 ++echo $ECHO_N "checking for LC_MESSAGES... $ECHO_C" >&6 ++if test "${am_cv_val_LC_MESSAGES+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 + else +- ac_check_lib_save_LIBS=$LIBS +-LIBS="-lreadline -lncurses $LIBS" +-cat >conftest.$ac_ext <<_ACEOF ++ cat >conftest.$ac_ext <<_ACEOF + /* confdefs.h. */ + _ACEOF + cat confdefs.h >>conftest.$ac_ext + cat >>conftest.$ac_ext <<_ACEOF + /* end confdefs.h. */ +- +-/* Override any gcc2 internal prototype to avoid an error. */ +-#ifdef __cplusplus +-extern "C" +-#endif +-/* We use char because int might match the return type of a gcc2 +- builtin and then its argument prototype would still apply. */ +-char readline (); ++#include + int + main () + { +-readline (); ++return LC_MESSAGES + ; + return 0; + } + _ACEOF +-rm -f conftest.$ac_objext conftest$ac_exeext +-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 +- (eval $ac_link) 2>conftest.er1 ++rm -f conftest.$ac_objext conftest$ac_exeext ++if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 ++ (eval $ac_link) 2>conftest.er1 ++ ac_status=$? ++ grep -v '^ *+' conftest.er1 >conftest.err ++ rm -f conftest.er1 ++ cat conftest.err >&5 ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); } && ++ { ac_try='test -z "$ac_cxx_werror_flag" ++ || test ! -s conftest.err' ++ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 ++ (eval $ac_try) 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; } && ++ { ac_try='test -s conftest$ac_exeext' ++ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 ++ (eval $ac_try) 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; }; then ++ am_cv_val_LC_MESSAGES=yes ++else ++ echo "$as_me: failed program was:" >&5 ++sed 's/^/| /' conftest.$ac_ext >&5 ++ ++am_cv_val_LC_MESSAGES=no ++fi ++rm -f conftest.err conftest.$ac_objext \ ++ conftest$ac_exeext conftest.$ac_ext ++fi ++echo "$as_me:$LINENO: result: $am_cv_val_LC_MESSAGES" >&5 ++echo "${ECHO_T}$am_cv_val_LC_MESSAGES" >&6 ++ if test $am_cv_val_LC_MESSAGES = yes; then ++ ++cat >>confdefs.h <<\_ACEOF ++#define HAVE_LC_MESSAGES 1 ++_ACEOF ++ ++ fi ++ fi ++ USE_NLS=yes ++ ++ ++ gt_cv_have_gettext=no ++ ++ CATOBJEXT=NONE ++ XGETTEXT=: ++ INTLLIBS= ++ ++ if test "${ac_cv_header_libintl_h+set}" = set; then ++ echo "$as_me:$LINENO: checking for libintl.h" >&5 ++echo $ECHO_N "checking for libintl.h... $ECHO_C" >&6 ++if test "${ac_cv_header_libintl_h+set}" = set; then ++ echo $ECHO_N "(cached) $ECHO_C" >&6 ++fi ++echo "$as_me:$LINENO: result: $ac_cv_header_libintl_h" >&5 ++echo "${ECHO_T}$ac_cv_header_libintl_h" >&6 ++else ++ # Is the header compilable? ++echo "$as_me:$LINENO: checking libintl.h usability" >&5 ++echo $ECHO_N "checking libintl.h usability... $ECHO_C" >&6 ++cat >conftest.$ac_ext <<_ACEOF ++/* confdefs.h. */ ++_ACEOF ++cat confdefs.h >>conftest.$ac_ext ++cat >>conftest.$ac_ext <<_ACEOF ++/* end confdefs.h. */ ++$ac_includes_default ++#include ++_ACEOF ++rm -f conftest.$ac_objext ++if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 ++ (eval $ac_compile) 2>conftest.er1 + ac_status=$? + grep -v '^ *+' conftest.er1 >conftest.err + rm -f conftest.er1 +@@ -20924,146 +20956,131 @@ if { (eval echo "$as_me:$LINENO: \"$ac_l + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; } && +- { ac_try='test -s conftest$ac_exeext' ++ { ac_try='test -s conftest.$ac_objext' + { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then +- ac_cv_lib_readline_readline=yes ++ ac_header_compiler=yes + else + echo "$as_me: failed program was:" >&5 + sed 's/^/| /' conftest.$ac_ext >&5 + +-ac_cv_lib_readline_readline=no +-fi +-rm -f conftest.err conftest.$ac_objext \ +- conftest$ac_exeext conftest.$ac_ext +-LIBS=$ac_check_lib_save_LIBS +-fi +-echo "$as_me:$LINENO: result: $ac_cv_lib_readline_readline" >&5 +-echo "${ECHO_T}$ac_cv_lib_readline_readline" >&6 +-if test $ac_cv_lib_readline_readline = yes; then +- HAVE_LIBREADLINE=true +-else +- HAVE_LIBREADLINE=false ++ac_header_compiler=no fi ++rm -f conftest.err conftest.$ac_objext conftest.$ac_ext ++echo "$as_me:$LINENO: result: $ac_header_compiler" >&5 ++echo "${ECHO_T}$ac_header_compiler" >&6 +- if test x${HAVE_LIBREADLINE} = xtrue ; then +- echo " Using -lreadline -lncurses" +- EXTRA_LIBREADLINE_DEPS=-lncurses +- +-cat >>confdefs.h <<\_ACEOF +-#define HAVE_LIBREADLINE 1 +-_ACEOF +- +- else +- unset ac_cv_lib_readline_readline +- echo "$as_me:$LINENO: checking for readline in -lreadline" >&5 +-echo $ECHO_N "checking for readline in -lreadline... $ECHO_C" >&6 +-if test "${ac_cv_lib_readline_readline+set}" = set; then +- echo $ECHO_N "(cached) $ECHO_C" >&6 +-else +- ac_check_lib_save_LIBS=$LIBS +-LIBS="-lreadline -lcurses $LIBS" ++# Is the header present? ++echo "$as_me:$LINENO: checking libintl.h presence" >&5 ++echo $ECHO_N "checking libintl.h presence... $ECHO_C" >&6 + cat >conftest.$ac_ext <<_ACEOF + /* confdefs.h. */ + _ACEOF + cat confdefs.h >>conftest.$ac_ext + cat >>conftest.$ac_ext <<_ACEOF + /* end confdefs.h. */ +- +-/* Override any gcc2 internal prototype to avoid an error. */ +-#ifdef __cplusplus +-extern "C" +-#endif +-/* We use char because int might match the return type of a gcc2 +- builtin and then its argument prototype would still apply. */ +-char readline (); +-int +-main () +-{ +-readline (); +- ; +- return 0; +-} ++#include + _ACEOF +-rm -f conftest.$ac_objext conftest$ac_exeext +-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 +- (eval $ac_link) 2>conftest.er1 ++if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5 ++ (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 + ac_status=$? + grep -v '^ *+' conftest.er1 >conftest.err + rm -f conftest.er1 + cat conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); } && +- { ac_try='test -z "$ac_cxx_werror_flag" +- || test ! -s conftest.err' +- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 +- (eval $ac_try) 2>&5 +- ac_status=$? +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; } && +- { ac_try='test -s conftest$ac_exeext' +- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 +- (eval $ac_try) 2>&5 +- ac_status=$? +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; }; then +- ac_cv_lib_readline_readline=yes ++ (exit $ac_status); } >/dev/null; then ++ if test -s conftest.err; then ++ ac_cpp_err=$ac_cxx_preproc_warn_flag ++ ac_cpp_err=$ac_cpp_err$ac_cxx_werror_flag ++ else ++ ac_cpp_err= ++ fi ++else ++ ac_cpp_err=yes ++fi ++if test -z "$ac_cpp_err"; then ++ ac_header_preproc=yes + else + echo "$as_me: failed program was:" >&5 + sed 's/^/| /' conftest.$ac_ext >&5 -@@ -22058,11 +22056,11 @@ extern "C" +-ac_cv_lib_readline_readline=no +-fi +-rm -f conftest.err conftest.$ac_objext \ +- conftest$ac_exeext conftest.$ac_ext +-LIBS=$ac_check_lib_save_LIBS ++ ac_header_preproc=no + fi +-echo "$as_me:$LINENO: result: $ac_cv_lib_readline_readline" >&5 +-echo "${ECHO_T}$ac_cv_lib_readline_readline" >&6 +-if test $ac_cv_lib_readline_readline = yes; then +- HAVE_LIBREADLINE=true ++rm -f conftest.err conftest.$ac_ext ++echo "$as_me:$LINENO: result: $ac_header_preproc" >&5 ++echo "${ECHO_T}$ac_header_preproc" >&6 ++ ++# So? What about this header? ++case $ac_header_compiler:$ac_header_preproc:$ac_cxx_preproc_warn_flag in ++ yes:no: ) ++ { echo "$as_me:$LINENO: WARNING: libintl.h: accepted by the compiler, rejected by the preprocessor!" >&5 ++echo "$as_me: WARNING: libintl.h: accepted by the compiler, rejected by the preprocessor!" >&2;} ++ { echo "$as_me:$LINENO: WARNING: libintl.h: proceeding with the compiler's result" >&5 ++echo "$as_me: WARNING: libintl.h: proceeding with the compiler's result" >&2;} ++ ac_header_preproc=yes ++ ;; ++ no:yes:* ) ++ { echo "$as_me:$LINENO: WARNING: libintl.h: present but cannot be compiled" >&5 ++echo "$as_me: WARNING: libintl.h: present but cannot be compiled" >&2;} ++ { echo "$as_me:$LINENO: WARNING: libintl.h: check for missing prerequisite headers?" >&5 ++echo "$as_me: WARNING: libintl.h: check for missing prerequisite headers?" >&2;} ++ { echo "$as_me:$LINENO: WARNING: libintl.h: see the Autoconf documentation" >&5 ++echo "$as_me: WARNING: libintl.h: see the Autoconf documentation" >&2;} ++ { echo "$as_me:$LINENO: WARNING: libintl.h: section \"Present But Cannot Be Compiled\"" >&5 ++echo "$as_me: WARNING: libintl.h: section \"Present But Cannot Be Compiled\"" >&2;} ++ { echo "$as_me:$LINENO: WARNING: libintl.h: proceeding with the preprocessor's result" >&5 ++echo "$as_me: WARNING: libintl.h: proceeding with the preprocessor's result" >&2;} ++ { echo "$as_me:$LINENO: WARNING: libintl.h: in the future, the compiler will take precedence" >&5 ++echo "$as_me: WARNING: libintl.h: in the future, the compiler will take precedence" >&2;} ++ ( ++ cat <<\_ASBOX ++## ------------------------------------------ ## ++## Report this to the AC_PACKAGE_NAME lists. ## ++## ------------------------------------------ ## ++_ASBOX ++ ) | ++ sed "s/^/$as_me: WARNING: /" >&2 ++ ;; ++esac ++echo "$as_me:$LINENO: checking for libintl.h" >&5 ++echo $ECHO_N "checking for libintl.h... $ECHO_C" >&6 ++if test "${ac_cv_header_libintl_h+set}" = set; then ++ echo $ECHO_N "(cached) $ECHO_C" >&6 + else +- HAVE_LIBREADLINE=false ++ ac_cv_header_libintl_h=$ac_header_preproc + fi ++echo "$as_me:$LINENO: result: $ac_cv_header_libintl_h" >&5 ++echo "${ECHO_T}$ac_cv_header_libintl_h" >&6 + +- if test x${HAVE_LIBREADLINE} = xtrue ; then +- echo " Using -lreadline -lcurses" +- EXTRA_LIBREADLINE_DEPS=-lcurses +- +-cat >>confdefs.h <<\_ACEOF +-#define HAVE_LIBREADLINE 1 +-_ACEOF ++fi ++if test $ac_cv_header_libintl_h = yes; then ++ gt_cv_func_dgettext_libintl="no" ++ libintl_extra_libs="" + +- else +- unset ac_cv_lib_readline_readline +- echo "$as_me:$LINENO: checking for readline in -lreadline" >&5 +-echo $ECHO_N "checking for readline in -lreadline... $ECHO_C" >&6 +-if test "${ac_cv_lib_readline_readline+set}" = set; then ++ # ++ # First check in libc ++ # ++ echo "$as_me:$LINENO: checking for ngettext in libc" >&5 ++echo $ECHO_N "checking for ngettext in libc... $ECHO_C" >&6 ++if test "${gt_cv_func_ngettext_libc+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 + else +- ac_check_lib_save_LIBS=$LIBS +-LIBS="-lreadline -ltermcap $LIBS" +-cat >conftest.$ac_ext <<_ACEOF ++ cat >conftest.$ac_ext <<_ACEOF + /* confdefs.h. */ + _ACEOF + cat confdefs.h >>conftest.$ac_ext + cat >>conftest.$ac_ext <<_ACEOF + /* end confdefs.h. */ + +-/* Override any gcc2 internal prototype to avoid an error. */ +-#ifdef __cplusplus +-extern "C" +-#endif +-/* We use char because int might match the return type of a gcc2 +- builtin and then its argument prototype would still apply. */ +-char readline (); ++#include ++ + int + main () + { +-readline (); ++return !ngettext ("","", 1) + ; + return 0; + } +@@ -21090,60 +21107,39 @@ if { (eval echo "$as_me:$LINENO: \"$ac_l + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then +- ac_cv_lib_readline_readline=yes ++ gt_cv_func_ngettext_libc=yes + else + echo "$as_me: failed program was:" >&5 + sed 's/^/| /' conftest.$ac_ext >&5 + +-ac_cv_lib_readline_readline=no ++gt_cv_func_ngettext_libc=no + fi + rm -f conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +-LIBS=$ac_check_lib_save_LIBS +-fi +-echo "$as_me:$LINENO: result: $ac_cv_lib_readline_readline" >&5 +-echo "${ECHO_T}$ac_cv_lib_readline_readline" >&6 +-if test $ac_cv_lib_readline_readline = yes; then +- HAVE_LIBREADLINE=true +-else +- HAVE_LIBREADLINE=false +-fi + +- if test x${HAVE_LIBREADLINE} = xtrue ; then +- echo " Using -lreadline -ltermcap" +- EXTRA_LIBREADLINE_DEPS=-ltermcap +- +-cat >>confdefs.h <<\_ACEOF +-#define HAVE_LIBREADLINE 1 +-_ACEOF ++fi ++echo "$as_me:$LINENO: result: $gt_cv_func_ngettext_libc" >&5 ++echo "${ECHO_T}$gt_cv_func_ngettext_libc" >&6 + +- else +- unset ac_cv_lib_readline_readline +- echo "$as_me:$LINENO: checking for readline in -lreadline" >&5 +-echo $ECHO_N "checking for readline in -lreadline... $ECHO_C" >&6 +-if test "${ac_cv_lib_readline_readline+set}" = set; then ++ if test "$gt_cv_func_ngettext_libc" = "yes" ; then ++ echo "$as_me:$LINENO: checking for dgettext in libc" >&5 ++echo $ECHO_N "checking for dgettext in libc... $ECHO_C" >&6 ++if test "${gt_cv_func_dgettext_libc+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 + else +- ac_check_lib_save_LIBS=$LIBS +-LIBS="-lreadline $LIBS" +-cat >conftest.$ac_ext <<_ACEOF ++ cat >conftest.$ac_ext <<_ACEOF + /* confdefs.h. */ + _ACEOF + cat confdefs.h >>conftest.$ac_ext + cat >>conftest.$ac_ext <<_ACEOF + /* end confdefs.h. */ + +-/* Override any gcc2 internal prototype to avoid an error. */ +-#ifdef __cplusplus +-extern "C" +-#endif +-/* We use char because int might match the return type of a gcc2 +- builtin and then its argument prototype would still apply. */ +-char readline (); ++#include ++ + int + main () + { +-readline (); ++return !dgettext ("","") + ; + return 0; + } +@@ -21170,62 +21166,78 @@ if { (eval echo "$as_me:$LINENO: \"$ac_l + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then +- ac_cv_lib_readline_readline=yes ++ gt_cv_func_dgettext_libc=yes + else + echo "$as_me: failed program was:" >&5 + sed 's/^/| /' conftest.$ac_ext >&5 + +-ac_cv_lib_readline_readline=no +-fi +-rm -f conftest.err conftest.$ac_objext \ +- conftest$ac_exeext conftest.$ac_ext +-LIBS=$ac_check_lib_save_LIBS +-fi +-echo "$as_me:$LINENO: result: $ac_cv_lib_readline_readline" >&5 +-echo "${ECHO_T}$ac_cv_lib_readline_readline" >&6 +-if test $ac_cv_lib_readline_readline = yes; then +- HAVE_LIBREADLINE=true +-else +- HAVE_LIBREADLINE=false ++gt_cv_func_dgettext_libc=no + fi ++rm -f conftest.err conftest.$ac_objext \ ++ conftest$ac_exeext conftest.$ac_ext + +- if test x${HAVE_LIBREADLINE} = xtrue ; then ++fi ++echo "$as_me:$LINENO: result: $gt_cv_func_dgettext_libc" >&5 ++echo "${ECHO_T}$gt_cv_func_dgettext_libc" >&6 ++ fi + +-cat >>confdefs.h <<\_ACEOF +-#define HAVE_LIBREADLINE 1 +-_ACEOF ++ if test "$gt_cv_func_ngettext_libc" = "yes" ; then + +- fi +- fi +- fi +- fi +- else +- unset ac_cv_lib_readline_readline +- echo "$as_me:$LINENO: checking for readline in -lreadline" >&5 +-echo $ECHO_N "checking for readline in -lreadline... $ECHO_C" >&6 +-if test "${ac_cv_lib_readline_readline+set}" = set; then ++for ac_func in bind_textdomain_codeset ++do ++as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh` ++echo "$as_me:$LINENO: checking for $ac_func" >&5 ++echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6 ++if eval "test \"\${$as_ac_var+set}\" = set"; then + echo $ECHO_N "(cached) $ECHO_C" >&6 + else +- ac_check_lib_save_LIBS=$LIBS +-LIBS="-lreadline ${EXTRA_LIBREADLINE_DEPS} $LIBS" +-cat >conftest.$ac_ext <<_ACEOF ++ cat >conftest.$ac_ext <<_ACEOF + /* confdefs.h. */ + _ACEOF + cat confdefs.h >>conftest.$ac_ext + cat >>conftest.$ac_ext <<_ACEOF + /* end confdefs.h. */ ++/* Define $ac_func to an innocuous variant, in case declares $ac_func. ++ For example, HP-UX 11i declares gettimeofday. */ ++#define $ac_func innocuous_$ac_func ++ ++/* System header to define __stub macros and hopefully few prototypes, ++ which can conflict with char $ac_func (); below. ++ Prefer to if __STDC__ is defined, since ++ exists even on freestanding compilers. */ ++ ++#ifdef __STDC__ ++# include ++#else ++# include ++#endif ++ ++#undef $ac_func + + /* Override any gcc2 internal prototype to avoid an error. */ + #ifdef __cplusplus + extern "C" ++{ #endif /* We use char because int might match the return type of a gcc2 builtin and then its argument prototype would still apply. */ --char dgettext (); -+char dgettext (const char *, const char *); +-char readline (); ++char $ac_func (); ++/* The GNU C library defines this for functions which it implements ++ to always fail with ENOSYS. Some functions are actually named ++ something starting with __ and the normal name is an alias. */ ++#if defined (__stub_$ac_func) || defined (__stub___$ac_func) ++choke me ++#else ++char (*f) () = $ac_func; ++#endif ++#ifdef __cplusplus ++} ++#endif ++ + int + main () + { +-readline (); ++return f != $ac_func; + ; + return 0; + } +@@ -21252,94 +21264,67 @@ if { (eval echo "$as_me:$LINENO: \"$ac_l + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then +- ac_cv_lib_readline_readline=yes ++ eval "$as_ac_var=yes" + else + echo "$as_me: failed program was:" >&5 + sed 's/^/| /' conftest.$ac_ext >&5 + +-ac_cv_lib_readline_readline=no ++eval "$as_ac_var=no" + fi + rm -f conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +-LIBS=$ac_check_lib_save_LIBS +-fi +-echo "$as_me:$LINENO: result: $ac_cv_lib_readline_readline" >&5 +-echo "${ECHO_T}$ac_cv_lib_readline_readline" >&6 +-if test $ac_cv_lib_readline_readline = yes; then +- HAVE_LIBREADLINE=true +-else +- HAVE_LIBREADLINE=false + fi +- +- if test x${HAVE_LIBREADLINE} = xtrue ; then +- echo " Using -lreadline ${EXTRA_LIBREADLINE_DEPS}" +- +-cat >>confdefs.h <<\_ACEOF +-#define HAVE_LIBREADLINE 1 ++echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5 ++echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6 ++if test `eval echo '${'$as_ac_var'}'` = yes; then ++ cat >>confdefs.h <<_ACEOF ++#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1 + _ACEOF + +- fi +- fi +- if test x${HAVE_LIBREADLINE} = xtrue; then +- READLINE_LIBS="-lreadline -lhistory ${EXTRA_LIBREADLINE_DEPS}" +- else +- { echo "$as_me:$LINENO: WARNING: Could not find libreadline." >&5 +-echo "$as_me: WARNING: Could not find libreadline." >&2;} +- fi +- fi +- fi +-fi +- +- +- +- +- +- +-QALCULATE_DEFS2DOC="" +-if test "x$enable_defs2doc" = "xyes" ; then +- QALCULATE_DEFS2DOC="defs2doc" + fi ++done + ++ fi + ++ # ++ # If we don't have everything we want, check in libintl ++ # ++ if test "$gt_cv_func_dgettext_libc" != "yes" \ ++ || test "$gt_cv_func_ngettext_libc" != "yes" \ ++ || test "$ac_cv_func_bind_textdomain_codeset" != "yes" ; then + +-GETTEXT_PACKAGE=libqalculate +- +- +-cat >>confdefs.h <<_ACEOF +-#define GETTEXT_PACKAGE "$GETTEXT_PACKAGE" +-_ACEOF +- +- +-ALL_LINGUAS="nl sv" +- +- +-for ac_header in locale.h +-do +-as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh` +-if eval "test \"\${$as_ac_Header+set}\" = set"; then +- echo "$as_me:$LINENO: checking for $ac_header" >&5 +-echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6 +-if eval "test \"\${$as_ac_Header+set}\" = set"; then ++ echo "$as_me:$LINENO: checking for bindtextdomain in -lintl" >&5 ++echo $ECHO_N "checking for bindtextdomain in -lintl... $ECHO_C" >&6 ++if test "${ac_cv_lib_intl_bindtextdomain+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +-fi +-echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5 +-echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6 + else +- # Is the header compilable? +-echo "$as_me:$LINENO: checking $ac_header usability" >&5 +-echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6 ++ ac_check_lib_save_LIBS=$LIBS ++LIBS="-lintl $LIBS" + cat >conftest.$ac_ext <<_ACEOF + /* confdefs.h. */ + _ACEOF + cat confdefs.h >>conftest.$ac_ext + cat >>conftest.$ac_ext <<_ACEOF + /* end confdefs.h. */ +-$ac_includes_default +-#include <$ac_header> ++ ++/* Override any gcc2 internal prototype to avoid an error. */ ++#ifdef __cplusplus ++extern "C" ++#endif ++/* We use char because int might match the return type of a gcc2 ++ builtin and then its argument prototype would still apply. */ ++char bindtextdomain (); ++int ++main () ++{ ++bindtextdomain (); ++ ; ++ return 0; ++} + _ACEOF +-rm -f conftest.$ac_objext +-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 +- (eval $ac_compile) 2>conftest.er1 ++rm -f conftest.$ac_objext conftest$ac_exeext ++if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 ++ (eval $ac_link) 2>conftest.er1 + ac_status=$? + grep -v '^ *+' conftest.er1 >conftest.err + rm -f conftest.er1 +@@ -21353,132 +21338,51 @@ if { (eval echo "$as_me:$LINENO: \"$ac_c + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; } && +- { ac_try='test -s conftest.$ac_objext' ++ { ac_try='test -s conftest$ac_exeext' + { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then +- ac_header_compiler=yes +-else +- echo "$as_me: failed program was:" >&5 +-sed 's/^/| /' conftest.$ac_ext >&5 +- +-ac_header_compiler=no +-fi +-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext +-echo "$as_me:$LINENO: result: $ac_header_compiler" >&5 +-echo "${ECHO_T}$ac_header_compiler" >&6 +- +-# Is the header present? +-echo "$as_me:$LINENO: checking $ac_header presence" >&5 +-echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6 +-cat >conftest.$ac_ext <<_ACEOF +-/* confdefs.h. */ +-_ACEOF +-cat confdefs.h >>conftest.$ac_ext +-cat >>conftest.$ac_ext <<_ACEOF +-/* end confdefs.h. */ +-#include <$ac_header> +-_ACEOF +-if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5 +- (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 +- ac_status=$? +- grep -v '^ *+' conftest.er1 >conftest.err +- rm -f conftest.er1 +- cat conftest.err >&5 +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); } >/dev/null; then +- if test -s conftest.err; then +- ac_cpp_err=$ac_cxx_preproc_warn_flag +- ac_cpp_err=$ac_cpp_err$ac_cxx_werror_flag +- else +- ac_cpp_err= +- fi +-else +- ac_cpp_err=yes +-fi +-if test -z "$ac_cpp_err"; then +- ac_header_preproc=yes +-else +- echo "$as_me: failed program was:" >&5 +-sed 's/^/| /' conftest.$ac_ext >&5 +- +- ac_header_preproc=no +-fi +-rm -f conftest.err conftest.$ac_ext +-echo "$as_me:$LINENO: result: $ac_header_preproc" >&5 +-echo "${ECHO_T}$ac_header_preproc" >&6 +- +-# So? What about this header? +-case $ac_header_compiler:$ac_header_preproc:$ac_cxx_preproc_warn_flag in +- yes:no: ) +- { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5 +-echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;} +- { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5 +-echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;} +- ac_header_preproc=yes +- ;; +- no:yes:* ) +- { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5 +-echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;} +- { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5 +-echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;} +- { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5 +-echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;} +- { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5 +-echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;} +- { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5 +-echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;} +- { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5 +-echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;} +- ( +- cat <<\_ASBOX +-## ------------------------------------------ ## +-## Report this to the AC_PACKAGE_NAME lists. ## +-## ------------------------------------------ ## +-_ASBOX +- ) | +- sed "s/^/$as_me: WARNING: /" >&2 +- ;; +-esac +-echo "$as_me:$LINENO: checking for $ac_header" >&5 +-echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6 +-if eval "test \"\${$as_ac_Header+set}\" = set"; then +- echo $ECHO_N "(cached) $ECHO_C" >&6 ++ ac_cv_lib_intl_bindtextdomain=yes + else +- eval "$as_ac_Header=\$ac_header_preproc" +-fi +-echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5 +-echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6 ++ echo "$as_me: failed program was:" >&5 ++sed 's/^/| /' conftest.$ac_ext >&5 + ++ac_cv_lib_intl_bindtextdomain=no + fi +-if test `eval echo '${'$as_ac_Header'}'` = yes; then +- cat >>confdefs.h <<_ACEOF +-#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1 +-_ACEOF +- ++rm -f conftest.err conftest.$ac_objext \ ++ conftest$ac_exeext conftest.$ac_ext ++LIBS=$ac_check_lib_save_LIBS + fi +- +-done +- +- if test $ac_cv_header_locale_h = yes; then +- echo "$as_me:$LINENO: checking for LC_MESSAGES" >&5 +-echo $ECHO_N "checking for LC_MESSAGES... $ECHO_C" >&6 +-if test "${am_cv_val_LC_MESSAGES+set}" = set; then ++echo "$as_me:$LINENO: result: $ac_cv_lib_intl_bindtextdomain" >&5 ++echo "${ECHO_T}$ac_cv_lib_intl_bindtextdomain" >&6 ++if test $ac_cv_lib_intl_bindtextdomain = yes; then ++ echo "$as_me:$LINENO: checking for ngettext in -lintl" >&5 ++echo $ECHO_N "checking for ngettext in -lintl... $ECHO_C" >&6 ++if test "${ac_cv_lib_intl_ngettext+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 + else +- cat >conftest.$ac_ext <<_ACEOF ++ ac_check_lib_save_LIBS=$LIBS ++LIBS="-lintl $LIBS" ++cat >conftest.$ac_ext <<_ACEOF + /* confdefs.h. */ + _ACEOF + cat confdefs.h >>conftest.$ac_ext + cat >>conftest.$ac_ext <<_ACEOF + /* end confdefs.h. */ +-#include ++ ++/* Override any gcc2 internal prototype to avoid an error. */ ++#ifdef __cplusplus ++extern "C" ++#endif ++/* We use char because int might match the return type of a gcc2 ++ builtin and then its argument prototype would still apply. */ ++char ngettext (); int main () { +-return LC_MESSAGES ++ngettext (); + ; + return 0; + } +@@ -21505,59 +21409,52 @@ if { (eval echo "$as_me:$LINENO: \"$ac_l + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then +- am_cv_val_LC_MESSAGES=yes ++ ac_cv_lib_intl_ngettext=yes + else + echo "$as_me: failed program was:" >&5 + sed 's/^/| /' conftest.$ac_ext >&5 + +-am_cv_val_LC_MESSAGES=no ++ac_cv_lib_intl_ngettext=no + fi + rm -f conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext ++LIBS=$ac_check_lib_save_LIBS + fi +-echo "$as_me:$LINENO: result: $am_cv_val_LC_MESSAGES" >&5 +-echo "${ECHO_T}$am_cv_val_LC_MESSAGES" >&6 +- if test $am_cv_val_LC_MESSAGES = yes; then +- +-cat >>confdefs.h <<\_ACEOF +-#define HAVE_LC_MESSAGES 1 +-_ACEOF +- +- fi +- fi +- USE_NLS=yes +- +- +- gt_cv_have_gettext=no +- +- CATOBJEXT=NONE +- XGETTEXT=: +- INTLLIBS= +- +- if test "${ac_cv_header_libintl_h+set}" = set; then +- echo "$as_me:$LINENO: checking for libintl.h" >&5 +-echo $ECHO_N "checking for libintl.h... $ECHO_C" >&6 +-if test "${ac_cv_header_libintl_h+set}" = set; then ++echo "$as_me:$LINENO: result: $ac_cv_lib_intl_ngettext" >&5 ++echo "${ECHO_T}$ac_cv_lib_intl_ngettext" >&6 ++if test $ac_cv_lib_intl_ngettext = yes; then ++ echo "$as_me:$LINENO: checking for dgettext in -lintl" >&5 ++echo $ECHO_N "checking for dgettext in -lintl... $ECHO_C" >&6 ++if test "${ac_cv_lib_intl_dgettext+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 +-fi +-echo "$as_me:$LINENO: result: $ac_cv_header_libintl_h" >&5 +-echo "${ECHO_T}$ac_cv_header_libintl_h" >&6 + else +- # Is the header compilable? +-echo "$as_me:$LINENO: checking libintl.h usability" >&5 +-echo $ECHO_N "checking libintl.h usability... $ECHO_C" >&6 ++ ac_check_lib_save_LIBS=$LIBS ++LIBS="-lintl $LIBS" + cat >conftest.$ac_ext <<_ACEOF + /* confdefs.h. */ + _ACEOF + cat confdefs.h >>conftest.$ac_ext + cat >>conftest.$ac_ext <<_ACEOF + /* end confdefs.h. */ +-$ac_includes_default +-#include ++ ++/* Override any gcc2 internal prototype to avoid an error. */ ++#ifdef __cplusplus ++extern "C" ++#endif ++/* We use char because int might match the return type of a gcc2 ++ builtin and then its argument prototype would still apply. */ ++char dgettext (); ++int ++main () ++{ ++dgettext (); ++ ; ++ return 0; ++} + _ACEOF +-rm -f conftest.$ac_objext +-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 +- (eval $ac_compile) 2>conftest.er1 ++rm -f conftest.$ac_objext conftest$ac_exeext ++if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 ++ (eval $ac_link) 2>conftest.er1 + ac_status=$? + grep -v '^ *+' conftest.er1 >conftest.err + rm -f conftest.er1 +@@ -21571,131 +21468,129 @@ if { (eval echo "$as_me:$LINENO: \"$ac_c + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; } && +- { ac_try='test -s conftest.$ac_objext' ++ { ac_try='test -s conftest$ac_exeext' + { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then +- ac_header_compiler=yes ++ ac_cv_lib_intl_dgettext=yes + else + echo "$as_me: failed program was:" >&5 + sed 's/^/| /' conftest.$ac_ext >&5 + +-ac_header_compiler=no ++ac_cv_lib_intl_dgettext=no ++fi ++rm -f conftest.err conftest.$ac_objext \ ++ conftest$ac_exeext conftest.$ac_ext ++LIBS=$ac_check_lib_save_LIBS ++fi ++echo "$as_me:$LINENO: result: $ac_cv_lib_intl_dgettext" >&5 ++echo "${ECHO_T}$ac_cv_lib_intl_dgettext" >&6 ++if test $ac_cv_lib_intl_dgettext = yes; then ++ gt_cv_func_dgettext_libintl=yes + fi +-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext +-echo "$as_me:$LINENO: result: $ac_header_compiler" >&5 +-echo "${ECHO_T}$ac_header_compiler" >&6 + +-# Is the header present? +-echo "$as_me:$LINENO: checking libintl.h presence" >&5 +-echo $ECHO_N "checking libintl.h presence... $ECHO_C" >&6 ++fi ++ ++fi ++ ++ ++ if test "$gt_cv_func_dgettext_libintl" != "yes" ; then ++ echo "$as_me:$LINENO: checking if -liconv is needed to use gettext" >&5 ++echo $ECHO_N "checking if -liconv is needed to use gettext... $ECHO_C" >&6 ++ echo "$as_me:$LINENO: result: " >&5 ++echo "${ECHO_T}" >&6 ++ echo "$as_me:$LINENO: checking for ngettext in -lintl" >&5 ++echo $ECHO_N "checking for ngettext in -lintl... $ECHO_C" >&6 ++if test "${ac_cv_lib_intl_ngettext+set}" = set; then ++ echo $ECHO_N "(cached) $ECHO_C" >&6 ++else ++ ac_check_lib_save_LIBS=$LIBS ++LIBS="-lintl -liconv $LIBS" + cat >conftest.$ac_ext <<_ACEOF + /* confdefs.h. */ + _ACEOF + cat confdefs.h >>conftest.$ac_ext + cat >>conftest.$ac_ext <<_ACEOF + /* end confdefs.h. */ +-#include ++ ++/* Override any gcc2 internal prototype to avoid an error. */ ++#ifdef __cplusplus ++extern "C" ++#endif ++/* We use char because int might match the return type of a gcc2 ++ builtin and then its argument prototype would still apply. */ ++char ngettext (); ++int ++main () ++{ ++ngettext (); ++ ; ++ return 0; ++} + _ACEOF +-if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5 +- (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 ++rm -f conftest.$ac_objext conftest$ac_exeext ++if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 ++ (eval $ac_link) 2>conftest.er1 + ac_status=$? + grep -v '^ *+' conftest.er1 >conftest.err + rm -f conftest.er1 + cat conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); } >/dev/null; then +- if test -s conftest.err; then +- ac_cpp_err=$ac_cxx_preproc_warn_flag +- ac_cpp_err=$ac_cpp_err$ac_cxx_werror_flag +- else +- ac_cpp_err= +- fi +-else +- ac_cpp_err=yes +-fi +-if test -z "$ac_cpp_err"; then +- ac_header_preproc=yes ++ (exit $ac_status); } && ++ { ac_try='test -z "$ac_cxx_werror_flag" ++ || test ! -s conftest.err' ++ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 ++ (eval $ac_try) 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; } && ++ { ac_try='test -s conftest$ac_exeext' ++ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 ++ (eval $ac_try) 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; }; then ++ ac_cv_lib_intl_ngettext=yes + else + echo "$as_me: failed program was:" >&5 + sed 's/^/| /' conftest.$ac_ext >&5 + +- ac_header_preproc=no +-fi +-rm -f conftest.err conftest.$ac_ext +-echo "$as_me:$LINENO: result: $ac_header_preproc" >&5 +-echo "${ECHO_T}$ac_header_preproc" >&6 +- +-# So? What about this header? +-case $ac_header_compiler:$ac_header_preproc:$ac_cxx_preproc_warn_flag in +- yes:no: ) +- { echo "$as_me:$LINENO: WARNING: libintl.h: accepted by the compiler, rejected by the preprocessor!" >&5 +-echo "$as_me: WARNING: libintl.h: accepted by the compiler, rejected by the preprocessor!" >&2;} +- { echo "$as_me:$LINENO: WARNING: libintl.h: proceeding with the compiler's result" >&5 +-echo "$as_me: WARNING: libintl.h: proceeding with the compiler's result" >&2;} +- ac_header_preproc=yes +- ;; +- no:yes:* ) +- { echo "$as_me:$LINENO: WARNING: libintl.h: present but cannot be compiled" >&5 +-echo "$as_me: WARNING: libintl.h: present but cannot be compiled" >&2;} +- { echo "$as_me:$LINENO: WARNING: libintl.h: check for missing prerequisite headers?" >&5 +-echo "$as_me: WARNING: libintl.h: check for missing prerequisite headers?" >&2;} +- { echo "$as_me:$LINENO: WARNING: libintl.h: see the Autoconf documentation" >&5 +-echo "$as_me: WARNING: libintl.h: see the Autoconf documentation" >&2;} +- { echo "$as_me:$LINENO: WARNING: libintl.h: section \"Present But Cannot Be Compiled\"" >&5 +-echo "$as_me: WARNING: libintl.h: section \"Present But Cannot Be Compiled\"" >&2;} +- { echo "$as_me:$LINENO: WARNING: libintl.h: proceeding with the preprocessor's result" >&5 +-echo "$as_me: WARNING: libintl.h: proceeding with the preprocessor's result" >&2;} +- { echo "$as_me:$LINENO: WARNING: libintl.h: in the future, the compiler will take precedence" >&5 +-echo "$as_me: WARNING: libintl.h: in the future, the compiler will take precedence" >&2;} +- ( +- cat <<\_ASBOX +-## ------------------------------------------ ## +-## Report this to the AC_PACKAGE_NAME lists. ## +-## ------------------------------------------ ## +-_ASBOX +- ) | +- sed "s/^/$as_me: WARNING: /" >&2 +- ;; +-esac +-echo "$as_me:$LINENO: checking for libintl.h" >&5 +-echo $ECHO_N "checking for libintl.h... $ECHO_C" >&6 +-if test "${ac_cv_header_libintl_h+set}" = set; then +- echo $ECHO_N "(cached) $ECHO_C" >&6 +-else +- ac_cv_header_libintl_h=$ac_header_preproc +-fi +-echo "$as_me:$LINENO: result: $ac_cv_header_libintl_h" >&5 +-echo "${ECHO_T}$ac_cv_header_libintl_h" >&6 +- ++ac_cv_lib_intl_ngettext=no + fi +-if test $ac_cv_header_libintl_h = yes; then +- gt_cv_func_dgettext_libintl="no" +- libintl_extra_libs="" +- +- # +- # First check in libc +- # +- echo "$as_me:$LINENO: checking for ngettext in libc" >&5 +-echo $ECHO_N "checking for ngettext in libc... $ECHO_C" >&6 +-if test "${gt_cv_func_ngettext_libc+set}" = set; then ++rm -f conftest.err conftest.$ac_objext \ ++ conftest$ac_exeext conftest.$ac_ext ++LIBS=$ac_check_lib_save_LIBS ++fi ++echo "$as_me:$LINENO: result: $ac_cv_lib_intl_ngettext" >&5 ++echo "${ECHO_T}$ac_cv_lib_intl_ngettext" >&6 ++if test $ac_cv_lib_intl_ngettext = yes; then ++ echo "$as_me:$LINENO: checking for dcgettext in -lintl" >&5 ++echo $ECHO_N "checking for dcgettext in -lintl... $ECHO_C" >&6 ++if test "${ac_cv_lib_intl_dcgettext+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 + else +- cat >conftest.$ac_ext <<_ACEOF ++ ac_check_lib_save_LIBS=$LIBS ++LIBS="-lintl -liconv $LIBS" ++cat >conftest.$ac_ext <<_ACEOF + /* confdefs.h. */ + _ACEOF + cat confdefs.h >>conftest.$ac_ext + cat >>conftest.$ac_ext <<_ACEOF + /* end confdefs.h. */ + +-#include +- ++/* Override any gcc2 internal prototype to avoid an error. */ ++#ifdef __cplusplus ++extern "C" ++#endif ++/* We use char because int might match the return type of a gcc2 ++ builtin and then its argument prototype would still apply. */ ++char dcgettext (); + int + main () + { +-return !ngettext ("","", 1) ++dcgettext (); + ; + return 0; + } +@@ -21722,24 +21617,48 @@ if { (eval echo "$as_me:$LINENO: \"$ac_l + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then +- gt_cv_func_ngettext_libc=yes ++ ac_cv_lib_intl_dcgettext=yes + else + echo "$as_me: failed program was:" >&5 + sed 's/^/| /' conftest.$ac_ext >&5 + +-gt_cv_func_ngettext_libc=no ++ac_cv_lib_intl_dcgettext=no + fi + rm -f conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext ++LIBS=$ac_check_lib_save_LIBS ++fi ++echo "$as_me:$LINENO: result: $ac_cv_lib_intl_dcgettext" >&5 ++echo "${ECHO_T}$ac_cv_lib_intl_dcgettext" >&6 ++if test $ac_cv_lib_intl_dcgettext = yes; then ++ gt_cv_func_dgettext_libintl=yes ++ libintl_extra_libs=-liconv ++else ++ : ++fi + ++else ++ : + fi +-echo "$as_me:$LINENO: result: $gt_cv_func_ngettext_libc" >&5 +-echo "${ECHO_T}$gt_cv_func_ngettext_libc" >&6 + +- if test "$gt_cv_func_ngettext_libc" = "yes" ; then +- echo "$as_me:$LINENO: checking for dgettext in libc" >&5 +-echo $ECHO_N "checking for dgettext in libc... $ECHO_C" >&6 +-if test "${gt_cv_func_dgettext_libc+set}" = set; then ++ fi ++ ++ # ++ # If we found libintl, then check in it for bind_textdomain_codeset(); ++ # we'll prefer libc if neither have bind_textdomain_codeset(), ++ # and both have dgettext and ngettext ++ # ++ if test "$gt_cv_func_dgettext_libintl" = "yes" ; then ++ glib_save_LIBS="$LIBS" ++ LIBS="$LIBS -lintl $libintl_extra_libs" ++ unset ac_cv_func_bind_textdomain_codeset ++ ++for ac_func in bind_textdomain_codeset ++do ++as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh` ++echo "$as_me:$LINENO: checking for $ac_func" >&5 ++echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6 ++if eval "test \"\${$as_ac_var+set}\" = set"; then + echo $ECHO_N "(cached) $ECHO_C" >&6 + else + cat >conftest.$ac_ext <<_ACEOF +@@ -21748,13 +21667,47 @@ _ACEOF + cat confdefs.h >>conftest.$ac_ext + cat >>conftest.$ac_ext <<_ACEOF + /* end confdefs.h. */ ++/* Define $ac_func to an innocuous variant, in case declares $ac_func. ++ For example, HP-UX 11i declares gettimeofday. */ ++#define $ac_func innocuous_$ac_func + +-#include ++/* System header to define __stub macros and hopefully few prototypes, ++ which can conflict with char $ac_func (); below. ++ Prefer to if __STDC__ is defined, since ++ exists even on freestanding compilers. */ ++ ++#ifdef __STDC__ ++# include ++#else ++# include ++#endif ++ ++#undef $ac_func ++ ++/* Override any gcc2 internal prototype to avoid an error. */ ++#ifdef __cplusplus ++extern "C" ++{ ++#endif ++/* We use char because int might match the return type of a gcc2 ++ builtin and then its argument prototype would still apply. */ ++char $ac_func (); ++/* The GNU C library defines this for functions which it implements ++ to always fail with ENOSYS. Some functions are actually named ++ something starting with __ and the normal name is an alias. */ ++#if defined (__stub_$ac_func) || defined (__stub___$ac_func) ++choke me ++#else ++char (*f) () = $ac_func; ++#endif ++#ifdef __cplusplus ++} ++#endif + + int + main () + { +-return !dgettext ("","") ++return f != $ac_func; + ; + return 0; + } +@@ -21781,24 +21734,94 @@ if { (eval echo "$as_me:$LINENO: \"$ac_l + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then +- gt_cv_func_dgettext_libc=yes ++ eval "$as_ac_var=yes" + else + echo "$as_me: failed program was:" >&5 + sed 's/^/| /' conftest.$ac_ext >&5 + +-gt_cv_func_dgettext_libc=no ++eval "$as_ac_var=no" + fi + rm -f conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext ++fi ++echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5 ++echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6 ++if test `eval echo '${'$as_ac_var'}'` = yes; then ++ cat >>confdefs.h <<_ACEOF ++#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1 ++_ACEOF + + fi +-echo "$as_me:$LINENO: result: $gt_cv_func_dgettext_libc" >&5 +-echo "${ECHO_T}$gt_cv_func_dgettext_libc" >&6 ++done ++ ++ LIBS="$glib_save_LIBS" ++ ++ if test "$ac_cv_func_bind_textdomain_codeset" = "yes" ; then ++ gt_cv_func_dgettext_libc=no ++ else ++ if test "$gt_cv_func_dgettext_libc" = "yes" \ ++ && test "$gt_cv_func_ngettext_libc" = "yes"; then ++ gt_cv_func_dgettext_libintl=no ++ fi ++ fi ++ fi + fi + +- if test "$gt_cv_func_ngettext_libc" = "yes" ; then ++ if test "$gt_cv_func_dgettext_libc" = "yes" \ ++ || test "$gt_cv_func_dgettext_libintl" = "yes"; then ++ gt_cv_have_gettext=yes ++ fi + +-for ac_func in bind_textdomain_codeset ++ if test "$gt_cv_func_dgettext_libintl" = "yes"; then ++ INTLLIBS="-lintl $libintl_extra_libs" ++ fi ++ ++ if test "$gt_cv_have_gettext" = "yes"; then ++ ++cat >>confdefs.h <<\_ACEOF ++#define HAVE_GETTEXT 1 ++_ACEOF ++ ++ # Extract the first word of "msgfmt", so it can be a program name with args. ++set dummy msgfmt; ac_word=$2 ++echo "$as_me:$LINENO: checking for $ac_word" >&5 ++echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 ++if test "${ac_cv_path_MSGFMT+set}" = set; then ++ echo $ECHO_N "(cached) $ECHO_C" >&6 ++else ++ case "$MSGFMT" in ++ /*) ++ ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path. ++ ;; ++ *) ++ IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" ++ for ac_dir in $PATH; do ++ test -z "$ac_dir" && ac_dir=. ++ if test -f $ac_dir/$ac_word; then ++ if test -z "`$ac_dir/$ac_word -h 2>&1 | grep 'dv '`"; then ++ ac_cv_path_MSGFMT="$ac_dir/$ac_word" ++ break ++ fi ++ fi ++ done ++ IFS="$ac_save_ifs" ++ test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT="no" ++ ;; ++esac ++fi ++MSGFMT="$ac_cv_path_MSGFMT" ++if test "$MSGFMT" != "no"; then ++ echo "$as_me:$LINENO: result: $MSGFMT" >&5 ++echo "${ECHO_T}$MSGFMT" >&6 ++else ++ echo "$as_me:$LINENO: result: no" >&5 ++echo "${ECHO_T}no" >&6 ++fi ++ if test "$MSGFMT" != "no"; then ++ glib_save_LIBS="$LIBS" ++ LIBS="$LIBS $INTLLIBS" ++ ++for ac_func in dcgettext + do + as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh` + echo "$as_me:$LINENO: checking for $ac_func" >&5 +@@ -21897,42 +21920,96 @@ if test `eval echo '${'$as_ac_var'}'` = + _ACEOF + + fi +-done +- +- fi +- +- # +- # If we don't have everything we want, check in libintl +- # +- if test "$gt_cv_func_dgettext_libc" != "yes" \ +- || test "$gt_cv_func_ngettext_libc" != "yes" \ +- || test "$ac_cv_func_bind_textdomain_codeset" != "yes" ; then ++done ++ ++ # Extract the first word of "gmsgfmt", so it can be a program name with args. ++set dummy gmsgfmt; ac_word=$2 ++echo "$as_me:$LINENO: checking for $ac_word" >&5 ++echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 ++if test "${ac_cv_path_GMSGFMT+set}" = set; then ++ echo $ECHO_N "(cached) $ECHO_C" >&6 ++else ++ case $GMSGFMT in ++ [\\/]* | ?:[\\/]*) ++ ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path. ++ ;; ++ *) ++ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR ++for as_dir in $PATH ++do ++ IFS=$as_save_IFS ++ test -z "$as_dir" && as_dir=. ++ for ac_exec_ext in '' $ac_executable_extensions; do ++ if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ++ ac_cv_path_GMSGFMT="$as_dir/$ac_word$ac_exec_ext" ++ echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 ++ break 2 ++ fi ++done ++done ++ ++ test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT" ++ ;; ++esac ++fi ++GMSGFMT=$ac_cv_path_GMSGFMT ++ ++if test -n "$GMSGFMT"; then ++ echo "$as_me:$LINENO: result: $GMSGFMT" >&5 ++echo "${ECHO_T}$GMSGFMT" >&6 ++else ++ echo "$as_me:$LINENO: result: no" >&5 ++echo "${ECHO_T}no" >&6 ++fi ++ ++ # Extract the first word of "xgettext", so it can be a program name with args. ++set dummy xgettext; ac_word=$2 ++echo "$as_me:$LINENO: checking for $ac_word" >&5 ++echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 ++if test "${ac_cv_path_XGETTEXT+set}" = set; then ++ echo $ECHO_N "(cached) $ECHO_C" >&6 ++else ++ case "$XGETTEXT" in ++ /*) ++ ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path. ++ ;; ++ *) ++ IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" ++ for ac_dir in $PATH; do ++ test -z "$ac_dir" && ac_dir=. ++ if test -f $ac_dir/$ac_word; then ++ if test -z "`$ac_dir/$ac_word -h 2>&1 | grep '(HELP)'`"; then ++ ac_cv_path_XGETTEXT="$ac_dir/$ac_word" ++ break ++ fi ++ fi ++ done ++ IFS="$ac_save_ifs" ++ test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":" ++ ;; ++esac ++fi ++XGETTEXT="$ac_cv_path_XGETTEXT" ++if test "$XGETTEXT" != ":"; then ++ echo "$as_me:$LINENO: result: $XGETTEXT" >&5 ++echo "${ECHO_T}$XGETTEXT" >&6 ++else ++ echo "$as_me:$LINENO: result: no" >&5 ++echo "${ECHO_T}no" >&6 ++fi + +- echo "$as_me:$LINENO: checking for bindtextdomain in -lintl" >&5 +-echo $ECHO_N "checking for bindtextdomain in -lintl... $ECHO_C" >&6 +-if test "${ac_cv_lib_intl_bindtextdomain+set}" = set; then +- echo $ECHO_N "(cached) $ECHO_C" >&6 +-else +- ac_check_lib_save_LIBS=$LIBS +-LIBS="-lintl $LIBS" +-cat >conftest.$ac_ext <<_ACEOF ++ cat >conftest.$ac_ext <<_ACEOF + /* confdefs.h. */ + _ACEOF + cat confdefs.h >>conftest.$ac_ext + cat >>conftest.$ac_ext <<_ACEOF + /* end confdefs.h. */ + +-/* Override any gcc2 internal prototype to avoid an error. */ +-#ifdef __cplusplus +-extern "C" +-#endif +-/* We use char because int might match the return type of a gcc2 +- builtin and then its argument prototype would still apply. */ +-char bindtextdomain (); + int + main () + { +-bindtextdomain (); ++extern int _nl_msg_cat_cntr; ++ return _nl_msg_cat_cntr + ; + return 0; + } +@@ -21959,45 +22036,66 @@ if { (eval echo "$as_me:$LINENO: \"$ac_l + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then +- ac_cv_lib_intl_bindtextdomain=yes ++ CATOBJEXT=.gmo ++ DATADIRNAME=share + else + echo "$as_me: failed program was:" >&5 + sed 's/^/| /' conftest.$ac_ext >&5 + +-ac_cv_lib_intl_bindtextdomain=no +-fi +-rm -f conftest.err conftest.$ac_objext \ +- conftest$ac_exeext conftest.$ac_ext +-LIBS=$ac_check_lib_save_LIBS +-fi +-echo "$as_me:$LINENO: result: $ac_cv_lib_intl_bindtextdomain" >&5 +-echo "${ECHO_T}$ac_cv_lib_intl_bindtextdomain" >&6 +-if test $ac_cv_lib_intl_bindtextdomain = yes; then +- echo "$as_me:$LINENO: checking for ngettext in -lintl" >&5 +-echo $ECHO_N "checking for ngettext in -lintl... $ECHO_C" >&6 +-if test "${ac_cv_lib_intl_ngettext+set}" = set; then ++case $host in ++ *-*-solaris*) ++ echo "$as_me:$LINENO: checking for bind_textdomain_codeset" >&5 ++echo $ECHO_N "checking for bind_textdomain_codeset... $ECHO_C" >&6 ++if test "${ac_cv_func_bind_textdomain_codeset+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 + else +- ac_check_lib_save_LIBS=$LIBS +-LIBS="-lintl $LIBS" +-cat >conftest.$ac_ext <<_ACEOF ++ cat >conftest.$ac_ext <<_ACEOF + /* confdefs.h. */ + _ACEOF + cat confdefs.h >>conftest.$ac_ext + cat >>conftest.$ac_ext <<_ACEOF + /* end confdefs.h. */ ++/* Define bind_textdomain_codeset to an innocuous variant, in case declares bind_textdomain_codeset. ++ For example, HP-UX 11i declares gettimeofday. */ ++#define bind_textdomain_codeset innocuous_bind_textdomain_codeset ++ ++/* System header to define __stub macros and hopefully few prototypes, ++ which can conflict with char bind_textdomain_codeset (); below. ++ Prefer to if __STDC__ is defined, since ++ exists even on freestanding compilers. */ ++ ++#ifdef __STDC__ ++# include ++#else ++# include ++#endif ++ ++#undef bind_textdomain_codeset + + /* Override any gcc2 internal prototype to avoid an error. */ + #ifdef __cplusplus + extern "C" ++{ + #endif + /* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +-char ngettext (); ++char bind_textdomain_codeset (); ++/* The GNU C library defines this for functions which it implements ++ to always fail with ENOSYS. Some functions are actually named ++ something starting with __ and the normal name is an alias. */ ++#if defined (__stub_bind_textdomain_codeset) || defined (__stub___bind_textdomain_codeset) ++choke me ++#else ++char (*f) () = bind_textdomain_codeset; ++#endif ++#ifdef __cplusplus ++} ++#endif ++ + int + main () + { +-ngettext (); ++return f != bind_textdomain_codeset; + ; + return 0; + } +@@ -22024,105 +22122,176 @@ if { (eval echo "$as_me:$LINENO: \"$ac_l + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then +- ac_cv_lib_intl_ngettext=yes ++ ac_cv_func_bind_textdomain_codeset=yes + else + echo "$as_me: failed program was:" >&5 + sed 's/^/| /' conftest.$ac_ext >&5 + +-ac_cv_lib_intl_ngettext=no ++ac_cv_func_bind_textdomain_codeset=no + fi + rm -f conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +-LIBS=$ac_check_lib_save_LIBS + fi +-echo "$as_me:$LINENO: result: $ac_cv_lib_intl_ngettext" >&5 +-echo "${ECHO_T}$ac_cv_lib_intl_ngettext" >&6 +-if test $ac_cv_lib_intl_ngettext = yes; then +- echo "$as_me:$LINENO: checking for dgettext in -lintl" >&5 +-echo $ECHO_N "checking for dgettext in -lintl... $ECHO_C" >&6 +-if test "${ac_cv_lib_intl_dgettext+set}" = set; then +- echo $ECHO_N "(cached) $ECHO_C" >&6 ++echo "$as_me:$LINENO: result: $ac_cv_func_bind_textdomain_codeset" >&5 ++echo "${ECHO_T}$ac_cv_func_bind_textdomain_codeset" >&6 ++if test $ac_cv_func_bind_textdomain_codeset = yes; then ++ CATOBJEXT=.gmo ++ DATADIRNAME=share + else +- ac_check_lib_save_LIBS=$LIBS +-LIBS="-lintl $LIBS" +-cat >conftest.$ac_ext <<_ACEOF +-/* confdefs.h. */ +-_ACEOF +-cat confdefs.h >>conftest.$ac_ext +-cat >>conftest.$ac_ext <<_ACEOF +-/* end confdefs.h. */ ++ CATOBJEXT=.mo ++ DATADIRNAME=lib ++fi + +-/* Override any gcc2 internal prototype to avoid an error. */ +-#ifdef __cplusplus +-extern "C" +-#endif +-/* We use char because int might match the return type of a gcc2 +- builtin and then its argument prototype would still apply. */ +-char dgettext (); +-int +-main () +-{ -dgettext (); -+dgettext ("", ""); +- ; +- return 0; +-} ++ ;; ++ *) ++ CATOBJEXT=.mo ++ DATADIRNAME=lib ++ ;; ++ esac ++fi ++rm -f conftest.err conftest.$ac_objext \ ++ conftest$ac_exeext conftest.$ac_ext ++ LIBS="$glib_save_LIBS" ++ INSTOBJEXT=.mo ++ else ++ gt_cv_have_gettext=no ++ fi ++ fi ++ ++fi ++ ++ ++ ++ if test "$gt_cv_have_gettext" = "yes" ; then ++ ++cat >>confdefs.h <<\_ACEOF ++#define ENABLE_NLS 1 + _ACEOF +-rm -f conftest.$ac_objext conftest$ac_exeext +-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 +- (eval $ac_link) 2>conftest.er1 +- ac_status=$? +- grep -v '^ *+' conftest.er1 >conftest.err +- rm -f conftest.er1 +- cat conftest.err >&5 +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); } && +- { ac_try='test -z "$ac_cxx_werror_flag" +- || test ! -s conftest.err' +- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 +- (eval $ac_try) 2>&5 +- ac_status=$? +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; } && +- { ac_try='test -s conftest$ac_exeext' +- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 +- (eval $ac_try) 2>&5 +- ac_status=$? +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; }; then +- ac_cv_lib_intl_dgettext=yes +-else +- echo "$as_me: failed program was:" >&5 +-sed 's/^/| /' conftest.$ac_ext >&5 + +-ac_cv_lib_intl_dgettext=no +-fi +-rm -f conftest.err conftest.$ac_objext \ +- conftest$ac_exeext conftest.$ac_ext +-LIBS=$ac_check_lib_save_LIBS +-fi +-echo "$as_me:$LINENO: result: $ac_cv_lib_intl_dgettext" >&5 +-echo "${ECHO_T}$ac_cv_lib_intl_dgettext" >&6 +-if test $ac_cv_lib_intl_dgettext = yes; then +- gt_cv_func_dgettext_libintl=yes +-fi ++ fi ++ ++ if test "$XGETTEXT" != ":"; then ++ if $XGETTEXT --omit-header /dev/null 2> /dev/null; then ++ : ; ++ else ++ echo "$as_me:$LINENO: result: found xgettext program is not GNU xgettext; ignore it" >&5 ++echo "${ECHO_T}found xgettext program is not GNU xgettext; ignore it" >&6 ++ XGETTEXT=":" ++ fi ++ fi ++ ++ # We need to process the po/ directory. ++ POSUB=po ++ ++ ac_config_commands="$ac_config_commands default-1" ++ ++ ++ for lang in $ALL_LINGUAS; do ++ GMOFILES="$GMOFILES $lang.gmo" ++ POFILES="$POFILES $lang.po" ++ done ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ ++ if test "$gt_cv_have_gettext" = "yes"; then ++ if test "x$ALL_LINGUAS" = "x"; then ++ LINGUAS= ++ else ++ echo "$as_me:$LINENO: checking for catalogs to be installed" >&5 ++echo $ECHO_N "checking for catalogs to be installed... $ECHO_C" >&6 ++ NEW_LINGUAS= ++ for presentlang in $ALL_LINGUAS; do ++ useit=no ++ if test "%UNSET%" != "${LINGUAS-%UNSET%}"; then ++ desiredlanguages="$LINGUAS" ++ else ++ desiredlanguages="$ALL_LINGUAS" ++ fi ++ for desiredlang in $desiredlanguages; do ++ # Use the presentlang catalog if desiredlang is ++ # a. equal to presentlang, or ++ # b. a variant of presentlang (because in this case, ++ # presentlang can be used as a fallback for messages ++ # which are not translated in the desiredlang catalog). ++ case "$desiredlang" in ++ "$presentlang"*) useit=yes;; ++ esac ++ done ++ if test $useit = yes; then ++ NEW_LINGUAS="$NEW_LINGUAS $presentlang" ++ fi ++ done ++ LINGUAS=$NEW_LINGUAS ++ echo "$as_me:$LINENO: result: $LINGUAS" >&5 ++echo "${ECHO_T}$LINGUAS" >&6 ++ fi ++ ++ if test -n "$LINGUAS"; then ++ for lang in $LINGUAS; do CATALOGS="$CATALOGS $lang$CATOBJEXT"; done ++ fi ++ fi ++ ++ MKINSTALLDIRS= ++ if test -n "$ac_aux_dir"; then ++ MKINSTALLDIRS="$ac_aux_dir/mkinstalldirs" ++ fi ++ if test -z "$MKINSTALLDIRS"; then ++ MKINSTALLDIRS="\$(top_srcdir)/mkinstalldirs" ++ fi ++ + +-fi ++ test -d po || mkdir po ++ if test "x$srcdir" != "x."; then ++ if test "x`echo $srcdir | sed 's@/.*@@'`" = "x"; then ++ posrcprefix="$srcdir/" ++ else ++ posrcprefix="../$srcdir/" ++ fi ++ else ++ posrcprefix="../" ++ fi ++ rm -f po/POTFILES ++ sed -e "/^#/d" -e "/^\$/d" -e "s,.*, $posrcprefix& \\\\," -e "\$s/\(.*\) \\\\/\1/" \ ++ < $srcdir/po/POTFILES.in > po/POTFILES + ++ ++echo "$as_me:$LINENO: checking locale directory" >&5 ++echo $ECHO_N "checking locale directory... $ECHO_C" >&6 ++if test "x$prefix" = "xNONE"; then ++ PACKAGE_LOCALE_DIR=$ac_default_prefix/share/locale ++else ++ PACKAGE_LOCALE_DIR=$prefix/share/locale + fi + + +- if test "$gt_cv_func_dgettext_libintl" != "yes" ; then +- echo "$as_me:$LINENO: checking if -liconv is needed to use gettext" >&5 +-echo $ECHO_N "checking if -liconv is needed to use gettext... $ECHO_C" >&6 +- echo "$as_me:$LINENO: result: " >&5 +-echo "${ECHO_T}" >&6 +- echo "$as_me:$LINENO: checking for ngettext in -lintl" >&5 +-echo $ECHO_N "checking for ngettext in -lintl... $ECHO_C" >&6 +-if test "${ac_cv_lib_intl_ngettext+set}" = set; then ++cat >>confdefs.h <<_ACEOF ++#define PACKAGE_LOCALE_DIR "$PACKAGE_LOCALE_DIR" ++_ACEOF ++ ++ echo "$as_me:$LINENO: result: \"$PACKAGE_LOCALE_DIR\"" >&5 ++echo "${ECHO_T}\"$PACKAGE_LOCALE_DIR\"" >&6 ++ ++INTLTOOL_QALCULATE_DEFINITIONS_RULE='%.xml: %.xml.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po-defs/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -x -u -c $(top_builddir)/po-defs/.intltool-merge-cache $(top_srcdir)/po-defs $< $@' ++ ++ ++ ++echo "$as_me:$LINENO: checking for pthread_create in ${PTHREAD_LDFLAGS} ${PTHREAD_LIBS}" >&5 ++echo $ECHO_N "checking for pthread_create in ${PTHREAD_LDFLAGS} ${PTHREAD_LIBS}... $ECHO_C" >&6 ++if test "${ac_cv_lib_pthread_pthread_create+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 + else + ac_check_lib_save_LIBS=$LIBS +-LIBS="-lintl -liconv $LIBS" ++LIBS="${PTHREAD_LDFLAGS} ${PTHREAD_LIBS} $LIBS" + cat >conftest.$ac_ext <<_ACEOF + /* confdefs.h. */ + _ACEOF +@@ -22136,11 +22305,11 @@ extern "C" + #endif + /* We use char because int might match the return type of a gcc2 + builtin and then its argument prototype would still apply. */ +-char ngettext (); ++char pthread_create (); + int + main () + { +-ngettext (); ++pthread_create (); + ; + return 0; + } +@@ -22154,7 +22323,7 @@ if { (eval echo "$as_me:$LINENO: \"$ac_l + cat conftest.err >&5 + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } && +- { ac_try='test -z "$ac_cxx_werror_flag" ++ { ac_try='test -z "$ac_c_werror_flag" + || test ! -s conftest.err' + { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 +@@ -22167,114 +22336,159 @@ if { (eval echo "$as_me:$LINENO: \"$ac_l + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then +- ac_cv_lib_intl_ngettext=yes ++ ac_cv_lib_pthread_pthread_create=yes + else + echo "$as_me: failed program was:" >&5 + sed 's/^/| /' conftest.$ac_ext >&5 + +-ac_cv_lib_intl_ngettext=no ++ac_cv_lib_pthread_pthread_create=no + fi + rm -f conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + LIBS=$ac_check_lib_save_LIBS + fi +-echo "$as_me:$LINENO: result: $ac_cv_lib_intl_ngettext" >&5 +-echo "${ECHO_T}$ac_cv_lib_intl_ngettext" >&6 +-if test $ac_cv_lib_intl_ngettext = yes; then +- echo "$as_me:$LINENO: checking for dcgettext in -lintl" >&5 +-echo $ECHO_N "checking for dcgettext in -lintl... $ECHO_C" >&6 +-if test "${ac_cv_lib_intl_dcgettext+set}" = set; then +- echo $ECHO_N "(cached) $ECHO_C" >&6 ++echo "$as_me:$LINENO: result: $ac_cv_lib_pthread_pthread_create" >&5 ++echo "${ECHO_T}$ac_cv_lib_pthread_pthread_create" >&6 ++if test $ac_cv_lib_pthread_pthread_create = yes; then ++ LIBS="$LIBS ${PTHREAD_LDFLAGS} ${PTHREAD_LIBS}" ++fi ++ ++ ++ac_ext=cc ++ac_cpp='$CXXCPP $CPPFLAGS' ++ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' ++ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ++ac_compiler_gnu=$ac_cv_cxx_compiler_gnu ++ ++ ++ ++# Check whether --with-cln-prefix or --without-cln-prefix was given. ++if test "${with_cln_prefix+set}" = set; then ++ withval="$with_cln_prefix" ++ cln_config_prefix="$withval" + else +- ac_check_lib_save_LIBS=$LIBS +-LIBS="-lintl -liconv $LIBS" +-cat >conftest.$ac_ext <<_ACEOF +-/* confdefs.h. */ +-_ACEOF +-cat confdefs.h >>conftest.$ac_ext +-cat >>conftest.$ac_ext <<_ACEOF +-/* end confdefs.h. */ ++ cln_config_prefix="" ++fi; + +-/* Override any gcc2 internal prototype to avoid an error. */ +-#ifdef __cplusplus +-extern "C" +-#endif +-/* We use char because int might match the return type of a gcc2 +- builtin and then its argument prototype would still apply. */ +-char dcgettext (); +-int +-main () +-{ +-dcgettext (); +- ; +- return 0; +-} +-_ACEOF +-rm -f conftest.$ac_objext conftest$ac_exeext +-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 +- (eval $ac_link) 2>conftest.er1 +- ac_status=$? +- grep -v '^ *+' conftest.er1 >conftest.err +- rm -f conftest.er1 +- cat conftest.err >&5 +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); } && +- { ac_try='test -z "$ac_cxx_werror_flag" +- || test ! -s conftest.err' +- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 +- (eval $ac_try) 2>&5 +- ac_status=$? +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; } && +- { ac_try='test -s conftest$ac_exeext' +- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 +- (eval $ac_try) 2>&5 +- ac_status=$? +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; }; then +- ac_cv_lib_intl_dcgettext=yes ++# Check whether --with-cln-exec-prefix or --without-cln-exec-prefix was given. ++if test "${with_cln_exec_prefix+set}" = set; then ++ withval="$with_cln_exec_prefix" ++ cln_config_exec_prefix="$withval" + else +- echo "$as_me: failed program was:" >&5 +-sed 's/^/| /' conftest.$ac_ext >&5 ++ cln_config_exec_prefix="" ++fi; ++# Check whether --enable-clntest or --disable-clntest was given. ++if test "${enable_clntest+set}" = set; then ++ enableval="$enable_clntest" + +-ac_cv_lib_intl_dcgettext=no ++else ++ enable_clntest=yes ++fi; ++ ++if test x$cln_config_exec_prefix != x ; then ++ cln_config_args="$cln_config_args --exec-prefix=$cln_config_exec_prefix" ++ if test x${CLN_CONFIG+set} != xset ; then ++ CLN_CONFIG=$cln_config_exec_prefix/bin/cln-config ++ fi + fi +-rm -f conftest.err conftest.$ac_objext \ +- conftest$ac_exeext conftest.$ac_ext +-LIBS=$ac_check_lib_save_LIBS ++if test x$cln_config_prefix != x ; then ++ cln_config_args="$cln_config_args --prefix=$cln_config_prefix" ++ if test x${CLN_CONFIG+set} != xset ; then ++ CLN_CONFIG=$cln_config_prefix/bin/cln-config ++ fi + fi +-echo "$as_me:$LINENO: result: $ac_cv_lib_intl_dcgettext" >&5 +-echo "${ECHO_T}$ac_cv_lib_intl_dcgettext" >&6 +-if test $ac_cv_lib_intl_dcgettext = yes; then +- gt_cv_func_dgettext_libintl=yes +- libintl_extra_libs=-liconv ++ ++# Extract the first word of "cln-config", so it can be a program name with args. ++set dummy cln-config; ac_word=$2 ++echo "$as_me:$LINENO: checking for $ac_word" >&5 ++echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 ++if test "${ac_cv_path_CLN_CONFIG+set}" = set; then ++ echo $ECHO_N "(cached) $ECHO_C" >&6 + else +- : ++ case $CLN_CONFIG in ++ [\\/]* | ?:[\\/]*) ++ ac_cv_path_CLN_CONFIG="$CLN_CONFIG" # Let the user override the test with a path. ++ ;; ++ *) ++ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR ++for as_dir in $PATH ++do ++ IFS=$as_save_IFS ++ test -z "$as_dir" && as_dir=. ++ for ac_exec_ext in '' $ac_executable_extensions; do ++ if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ++ ac_cv_path_CLN_CONFIG="$as_dir/$ac_word$ac_exec_ext" ++ echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 ++ break 2 ++ fi ++done ++done ++ ++ test -z "$ac_cv_path_CLN_CONFIG" && ac_cv_path_CLN_CONFIG="no" ++ ;; ++esac + fi ++CLN_CONFIG=$ac_cv_path_CLN_CONFIG + ++if test -n "$CLN_CONFIG"; then ++ echo "$as_me:$LINENO: result: $CLN_CONFIG" >&5 ++echo "${ECHO_T}$CLN_CONFIG" >&6 + else +- : ++ echo "$as_me:$LINENO: result: no" >&5 ++echo "${ECHO_T}no" >&6 + fi + +- fi +- +- # +- # If we found libintl, then check in it for bind_textdomain_codeset(); +- # we'll prefer libc if neither have bind_textdomain_codeset(), +- # and both have dgettext and ngettext +- # +- if test "$gt_cv_func_dgettext_libintl" = "yes" ; then +- glib_save_LIBS="$LIBS" +- LIBS="$LIBS -lintl $libintl_extra_libs" +- unset ac_cv_func_bind_textdomain_codeset +- +-for ac_func in bind_textdomain_codeset +-do +-as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh` +-echo "$as_me:$LINENO: checking for $ac_func" >&5 +-echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6 +-if eval "test \"\${$as_ac_var+set}\" = set"; then +- echo $ECHO_N "(cached) $ECHO_C" >&6 ++cln_min_version=1.1.0 ++echo "$as_me:$LINENO: checking for CLN - version >= $cln_min_version" >&5 ++echo $ECHO_N "checking for CLN - version >= $cln_min_version... $ECHO_C" >&6 ++if test "$CLN_CONFIG" = "no" ; then ++ echo "$as_me:$LINENO: result: no" >&5 ++echo "${ECHO_T}no" >&6 ++ echo "*** The cln-config script installed by CLN could not be found" ++ echo "*** If CLN was installed in PREFIX, make sure PREFIX/bin is in" ++ echo "*** your path, or set the CLN_CONFIG environment variable to the" ++ echo "*** full path to cln-config." ++ { { echo "$as_me:$LINENO: error: No suitable installed version of CLN could be found." >&5 ++echo "$as_me: error: No suitable installed version of CLN could be found." >&2;} ++ { (exit 1); exit 1; }; } ++else ++ cln_min_major_version=`echo $cln_min_version | \ ++ sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\1/'` ++ cln_min_minor_version=`echo $cln_min_version | \ ++ sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\2/'` ++ cln_min_micro_version=`echo $cln_min_version | \ ++ sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\3/'` ++ CLN_CPPFLAGS=`$CLN_CONFIG $cln_config_args --cppflags` ++ CLN_LIBS=`$CLN_CONFIG $cln_config_args --libs` ++ cln_config_version=`$CLN_CONFIG $cln_config_args --version` ++ cln_config_major_version=`echo $cln_config_version | \ ++ sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\1/'` ++ cln_config_minor_version=`echo $cln_config_version | \ ++ sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\2/'` ++ cln_config_micro_version=`echo $cln_config_version | \ ++ sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\3/'` ++ if test \( $cln_config_major_version -lt $cln_min_major_version \) -o \ ++ \( $cln_config_major_version -eq $cln_min_major_version -a $cln_config_minor_version -lt $cln_min_minor_version \) -o \ ++ \( $cln_config_major_version -eq $cln_min_major_version -a $cln_config_minor_version -eq $cln_min_minor_version -a $cln_config_micro_version -lt $cln_min_micro_version \); then ++ echo -e "\n*** 'cln-config --version' returned $cln_config_major_version.$cln_config_minor_version.$cln_config_micro_version, but the minimum version" ++ echo "*** of CLN required is $cln_min_major_version.$cln_min_minor_version.$cln_min_micro_version. If cln-config is correct, then it is" ++ echo "*** best to upgrade to the required version." ++ echo "*** If cln-config was wrong, set the environment variable CLN_CONFIG" ++ echo "*** to point to the correct copy of cln-config, and remove the file" ++ echo "*** config.cache before re-running configure." ++ { { echo "$as_me:$LINENO: error: No suitable installed version of CLN could be found." >&5 ++echo "$as_me: error: No suitable installed version of CLN could be found." >&2;} ++ { (exit 1); exit 1; }; } ++ else ++ no_cln="" ++ if test "x$enable_clntest" = "xyes" ; then ++ ac_save_CPPFLAGS="$CPPFLAGS" ++ ac_save_LIBS="$LIBS" ++ CPPFLAGS="$CPPFLAGS $CLN_CPPFLAGS" ++ LIBS="$LIBS $CLN_LIBS" ++ rm -f conf.clntest ++ if test "$cross_compiling" = yes; then ++ echo $ac_n "cross compiling; assumed OK... $ac_c" + else + cat >conftest.$ac_ext <<_ACEOF + /* confdefs.h. */ +@@ -22282,215 +22496,99 @@ _ACEOF + cat confdefs.h >>conftest.$ac_ext + cat >>conftest.$ac_ext <<_ACEOF + /* end confdefs.h. */ +-/* Define $ac_func to an innocuous variant, in case declares $ac_func. +- For example, HP-UX 11i declares gettimeofday. */ +-#define $ac_func innocuous_$ac_func +- +-/* System header to define __stub macros and hopefully few prototypes, +- which can conflict with char $ac_func (); below. +- Prefer to if __STDC__ is defined, since +- exists even on freestanding compilers. */ + +-#ifdef __STDC__ +-# include +-#else +-# include +-#endif ++#include ++#include ++#include + +-#undef $ac_func ++/* we do not #include because autoconf in C++ mode inserts a ++ prototype for exit() that conflicts with the one in stdlib.h */ ++extern "C" int system(const char *); + +-/* Override any gcc2 internal prototype to avoid an error. */ +-#ifdef __cplusplus +-extern "C" ++int main(void) + { +-#endif +-/* We use char because int might match the return type of a gcc2 +- builtin and then its argument prototype would still apply. */ +-char $ac_func (); +-/* The GNU C library defines this for functions which it implements +- to always fail with ENOSYS. Some functions are actually named +- something starting with __ and the normal name is an alias. */ +-#if defined (__stub_$ac_func) || defined (__stub___$ac_func) +-choke me +-#else +-char (*f) () = $ac_func; +-#endif +-#ifdef __cplusplus +-} +-#endif ++ system("touch conf.clntest"); + +-int +-main () +-{ +-return f != $ac_func; +- ; +- return 0; ++ if ((CL_VERSION_MAJOR != $cln_config_major_version) || ++ (CL_VERSION_MINOR != $cln_config_minor_version) || ++ (CL_VERSION_PATCHLEVEL != $cln_config_micro_version)) { ++ printf("\n*** 'cln-config --version' returned %d.%d.%d, but the header file I found\n", $cln_config_major_version, $cln_config_minor_version, $cln_config_micro_version); ++ printf("*** corresponds to %d.%d.%d. This mismatch suggests your installation of CLN\n", CL_VERSION_MAJOR, CL_VERSION_MINOR, CL_VERSION_PATCHLEVEL); ++ printf("*** is corrupted or you have specified some wrong -I compiler flags.\n"); ++ printf("*** Please inquire and consider reinstalling CLN.\n"); ++ return 1; ++ } ++ if ((cln::version_major != $cln_config_major_version) || ++ (cln::version_minor != $cln_config_minor_version) || ++ (cln::version_patchlevel != $cln_config_micro_version)) { ++ printf("\n*** 'cln-config --version' returned %d.%d.%d, but the library I found\n", $cln_config_major_version, $cln_config_minor_version, $cln_config_micro_version); ++ printf("*** corresponds to %d.%d.%d. This mismatch suggests your installation of CLN\n", cln::version_major, cln::version_minor, cln::version_patchlevel); ++ printf("*** is corrupted or you have specified some wrong -L compiler flags.\n"); ++ printf("*** Please inquire and consider reinstalling CLN.\n"); ++ return 1; ++ } ++ return 0; + } ++ + _ACEOF +-rm -f conftest.$ac_objext conftest$ac_exeext ++rm -f conftest$ac_exeext + if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 +- (eval $ac_link) 2>conftest.er1 +- ac_status=$? +- grep -v '^ *+' conftest.er1 >conftest.err +- rm -f conftest.er1 +- cat conftest.err >&5 +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); } && +- { ac_try='test -z "$ac_cxx_werror_flag" +- || test ! -s conftest.err' +- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 +- (eval $ac_try) 2>&5 ++ (eval $ac_link) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; } && +- { ac_try='test -s conftest$ac_exeext' ++ (exit $ac_status); } && { ac_try='./conftest$ac_exeext' + { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 + (eval $ac_try) 2>&5 + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then +- eval "$as_ac_var=yes" ++ : + else +- echo "$as_me: failed program was:" >&5 ++ echo "$as_me: program exited with status $ac_status" >&5 ++echo "$as_me: failed program was:" >&5 + sed 's/^/| /' conftest.$ac_ext >&5 + +-eval "$as_ac_var=no" +-fi +-rm -f conftest.err conftest.$ac_objext \ +- conftest$ac_exeext conftest.$ac_ext ++( exit $ac_status ) ++no_cln=yes + fi +-echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5 +-echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6 +-if test `eval echo '${'$as_ac_var'}'` = yes; then +- cat >>confdefs.h <<_ACEOF +-#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1 +-_ACEOF +- ++rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext + fi +-done +- +- LIBS="$glib_save_LIBS" +- +- if test "$ac_cv_func_bind_textdomain_codeset" = "yes" ; then +- gt_cv_func_dgettext_libc=no +- else +- if test "$gt_cv_func_dgettext_libc" = "yes" \ +- && test "$gt_cv_func_ngettext_libc" = "yes"; then +- gt_cv_func_dgettext_libintl=no +- fi +- fi ++ CPPFLAGS="$ac_save_CPPFLAGS" ++ LIBS="$ac_save_LIBS" + fi +- fi +- +- if test "$gt_cv_func_dgettext_libc" = "yes" \ +- || test "$gt_cv_func_dgettext_libintl" = "yes"; then +- gt_cv_have_gettext=yes +- fi +- +- if test "$gt_cv_func_dgettext_libintl" = "yes"; then +- INTLLIBS="-lintl $libintl_extra_libs" +- fi ++ if test "x$no_cln" = x ; then ++ echo "$as_me:$LINENO: result: yes, $cln_config_version" >&5 ++echo "${ECHO_T}yes, $cln_config_version" >&6 + +- if test "$gt_cv_have_gettext" = "yes"; then ++ LIBS="$LIBS $CLN_LIBS" ++ CPPFLAGS="$CPPFLAGS $CLN_CPPFLAGS" + + cat >>confdefs.h <<\_ACEOF +-#define HAVE_GETTEXT 1 +-_ACEOF +- +- # Extract the first word of "msgfmt", so it can be a program name with args. +-set dummy msgfmt; ac_word=$2 +-echo "$as_me:$LINENO: checking for $ac_word" >&5 +-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 +-if test "${ac_cv_path_MSGFMT+set}" = set; then +- echo $ECHO_N "(cached) $ECHO_C" >&6 +-else +- case "$MSGFMT" in +- /*) +- ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path. +- ;; +- *) +- IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" +- for ac_dir in $PATH; do +- test -z "$ac_dir" && ac_dir=. +- if test -f $ac_dir/$ac_word; then +- if test -z "`$ac_dir/$ac_word -h 2>&1 | grep 'dv '`"; then +- ac_cv_path_MSGFMT="$ac_dir/$ac_word" +- break +- fi +- fi +- done +- IFS="$ac_save_ifs" +- test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT="no" +- ;; +-esac +-fi +-MSGFMT="$ac_cv_path_MSGFMT" +-if test "$MSGFMT" != "no"; then +- echo "$as_me:$LINENO: result: $MSGFMT" >&5 +-echo "${ECHO_T}$MSGFMT" >&6 +-else +- echo "$as_me:$LINENO: result: no" >&5 +-echo "${ECHO_T}no" >&6 +-fi +- if test "$MSGFMT" != "no"; then +- glib_save_LIBS="$LIBS" +- LIBS="$LIBS $INTLLIBS" +- +-for ac_func in dcgettext +-do +-as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh` +-echo "$as_me:$LINENO: checking for $ac_func" >&5 +-echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6 +-if eval "test \"\${$as_ac_var+set}\" = set"; then +- echo $ECHO_N "(cached) $ECHO_C" >&6 +-else +- cat >conftest.$ac_ext <<_ACEOF +-/* confdefs.h. */ ++#define HAVE_LIBCLN 1 + _ACEOF +-cat confdefs.h >>conftest.$ac_ext +-cat >>conftest.$ac_ext <<_ACEOF +-/* end confdefs.h. */ +-/* Define $ac_func to an innocuous variant, in case declares $ac_func. +- For example, HP-UX 11i declares gettimeofday. */ +-#define $ac_func innocuous_$ac_func +- +-/* System header to define __stub macros and hopefully few prototypes, +- which can conflict with char $ac_func (); below. +- Prefer to if __STDC__ is defined, since +- exists even on freestanding compilers. */ + +-#ifdef __STDC__ +-# include +-#else +-# include +-#endif +- +-#undef $ac_func + +-/* Override any gcc2 internal prototype to avoid an error. */ +-#ifdef __cplusplus +-extern "C" +-{ +-#endif +-/* We use char because int might match the return type of a gcc2 +- builtin and then its argument prototype would still apply. */ +-char $ac_func (); +-/* The GNU C library defines this for functions which it implements +- to always fail with ENOSYS. Some functions are actually named +- something starting with __ and the normal name is an alias. */ +-#if defined (__stub_$ac_func) || defined (__stub___$ac_func) +-choke me +-#else +-char (*f) () = $ac_func; +-#endif +-#ifdef __cplusplus +-} +-#endif ++ else ++ echo "$as_me:$LINENO: result: no" >&5 ++echo "${ECHO_T}no" >&6 ++ if test ! -f conf.clntest ; then ++ echo "*** Could not run CLN test program, checking why..." ++ CPPFLAGS="$CFLAGS $CLN_CPPFLAGS" ++ LIBS="$LIBS $CLN_LIBS" ++ cat >conftest.$ac_ext <<_ACEOF ++/* confdefs.h. */ ++_ACEOF ++cat confdefs.h >>conftest.$ac_ext ++cat >>conftest.$ac_ext <<_ACEOF ++/* end confdefs.h. */ ++ ++#include ++#include + + int + main () + { +-return f != $ac_func; ++ return 0; ; return 0; } +@@ -22517,36 +22615,54 @@ if { (eval echo "$as_me:$LINENO: \"$ac_l + ac_status=$? + echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; }; then +- eval "$as_ac_var=yes" ++ echo "*** The test program compiled, but did not run. This usually means" ++ echo "*** that the run-time linker is not finding CLN or finding the wrong" ++ echo "*** version of CLN. If it is not finding CLN, you'll need to set your" ++ echo "*** LD_LIBRARY_PATH environment variable, or edit /etc/ld.so.conf to point" ++ echo "*** to the installed location. Also, make sure you have run ldconfig if that" ++ echo "*** is required on your system." + else + echo "$as_me: failed program was:" >&5 + sed 's/^/| /' conftest.$ac_ext >&5 + +-eval "$as_ac_var=no" ++ echo "*** The test program failed to compile or link. See the file config.log for the" ++ echo "*** exact error that occured. This usually means CLN was incorrectly installed" ++ echo "*** or that you have moved CLN since it was installed. In the latter case, you" ++ echo "*** may want to edit the cln-config script: $CLN_CONFIG." + fi + rm -f conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext ++ CPPFLAGS="$ac_save_CPPFLAGS" ++ LIBS="$ac_save_LIBS" ++ fi ++ CLN_CPPFLAGS="" ++ CLN_LIBS="" ++ { { echo "$as_me:$LINENO: error: No suitable installed version of CLN could be found." >&5 ++echo "$as_me: error: No suitable installed version of CLN could be found." >&2;} ++ { (exit 1); exit 1; }; } ++ fi ++ fi + fi +-echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5 +-echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6 +-if test `eval echo '${'$as_ac_var'}'` = yes; then +- cat >>confdefs.h <<_ACEOF +-#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1 +-_ACEOF + +-fi +-done + +- # Extract the first word of "gmsgfmt", so it can be a program name with args. +-set dummy gmsgfmt; ac_word=$2 ++rm -f conf.clntest ++ ++ ++ ++ ++ ++if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then ++ if test -n "$ac_tool_prefix"; then ++ # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args. ++set dummy ${ac_tool_prefix}pkg-config; ac_word=$2 + echo "$as_me:$LINENO: checking for $ac_word" >&5 + echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 +-if test "${ac_cv_path_GMSGFMT+set}" = set; then ++if test "${ac_cv_path_PKG_CONFIG+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 + else +- case $GMSGFMT in ++ case $PKG_CONFIG in + [\\/]* | ?:[\\/]*) +- ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path. ++ ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path. + ;; + *) + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +@@ -22556,349 +22672,231 @@ do + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then +- ac_cv_path_GMSGFMT="$as_dir/$ac_word$ac_exec_ext" ++ ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" + echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi + done + done + +- test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT" + ;; + esac + fi +-GMSGFMT=$ac_cv_path_GMSGFMT ++PKG_CONFIG=$ac_cv_path_PKG_CONFIG + +-if test -n "$GMSGFMT"; then +- echo "$as_me:$LINENO: result: $GMSGFMT" >&5 +-echo "${ECHO_T}$GMSGFMT" >&6 ++if test -n "$PKG_CONFIG"; then ++ echo "$as_me:$LINENO: result: $PKG_CONFIG" >&5 ++echo "${ECHO_T}$PKG_CONFIG" >&6 + else + echo "$as_me:$LINENO: result: no" >&5 + echo "${ECHO_T}no" >&6 + fi + +- # Extract the first word of "xgettext", so it can be a program name with args. +-set dummy xgettext; ac_word=$2 ++fi ++if test -z "$ac_cv_path_PKG_CONFIG"; then ++ ac_pt_PKG_CONFIG=$PKG_CONFIG ++ # Extract the first word of "pkg-config", so it can be a program name with args. ++set dummy pkg-config; ac_word=$2 + echo "$as_me:$LINENO: checking for $ac_word" >&5 + echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6 +-if test "${ac_cv_path_XGETTEXT+set}" = set; then ++if test "${ac_cv_path_ac_pt_PKG_CONFIG+set}" = set; then + echo $ECHO_N "(cached) $ECHO_C" >&6 + else +- case "$XGETTEXT" in +- /*) +- ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path. ++ case $ac_pt_PKG_CONFIG in ++ [\\/]* | ?:[\\/]*) ++ ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path. + ;; + *) +- IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:" +- for ac_dir in $PATH; do +- test -z "$ac_dir" && ac_dir=. +- if test -f $ac_dir/$ac_word; then +- if test -z "`$ac_dir/$ac_word -h 2>&1 | grep '(HELP)'`"; then +- ac_cv_path_XGETTEXT="$ac_dir/$ac_word" +- break +- fi +- fi +- done +- IFS="$ac_save_ifs" +- test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":" ++ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR ++for as_dir in $PATH ++do ++ IFS=$as_save_IFS ++ test -z "$as_dir" && as_dir=. ++ for ac_exec_ext in '' $ac_executable_extensions; do ++ if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ++ ac_cv_path_ac_pt_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" ++ echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 ++ break 2 ++ fi ++done ++done ++ + ;; + esac + fi +-XGETTEXT="$ac_cv_path_XGETTEXT" +-if test "$XGETTEXT" != ":"; then +- echo "$as_me:$LINENO: result: $XGETTEXT" >&5 +-echo "${ECHO_T}$XGETTEXT" >&6 +-else +- echo "$as_me:$LINENO: result: no" >&5 +-echo "${ECHO_T}no" >&6 +-fi +- +- cat >conftest.$ac_ext <<_ACEOF +-/* confdefs.h. */ +-_ACEOF +-cat confdefs.h >>conftest.$ac_ext +-cat >>conftest.$ac_ext <<_ACEOF +-/* end confdefs.h. */ +- +-int +-main () +-{ +-extern int _nl_msg_cat_cntr; +- return _nl_msg_cat_cntr +- ; +- return 0; +-} +-_ACEOF +-rm -f conftest.$ac_objext conftest$ac_exeext +-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 +- (eval $ac_link) 2>conftest.er1 +- ac_status=$? +- grep -v '^ *+' conftest.er1 >conftest.err +- rm -f conftest.er1 +- cat conftest.err >&5 +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); } && +- { ac_try='test -z "$ac_cxx_werror_flag" +- || test ! -s conftest.err' +- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 +- (eval $ac_try) 2>&5 +- ac_status=$? +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; } && +- { ac_try='test -s conftest$ac_exeext' +- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 +- (eval $ac_try) 2>&5 +- ac_status=$? +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; }; then +- CATOBJEXT=.gmo +- DATADIRNAME=share +-else +- echo "$as_me: failed program was:" >&5 +-sed 's/^/| /' conftest.$ac_ext >&5 +- +-case $host in +- *-*-solaris*) +- echo "$as_me:$LINENO: checking for bind_textdomain_codeset" >&5 +-echo $ECHO_N "checking for bind_textdomain_codeset... $ECHO_C" >&6 +-if test "${ac_cv_func_bind_textdomain_codeset+set}" = set; then +- echo $ECHO_N "(cached) $ECHO_C" >&6 +-else +- cat >conftest.$ac_ext <<_ACEOF +-/* confdefs.h. */ +-_ACEOF +-cat confdefs.h >>conftest.$ac_ext +-cat >>conftest.$ac_ext <<_ACEOF +-/* end confdefs.h. */ +-/* Define bind_textdomain_codeset to an innocuous variant, in case declares bind_textdomain_codeset. +- For example, HP-UX 11i declares gettimeofday. */ +-#define bind_textdomain_codeset innocuous_bind_textdomain_codeset +- +-/* System header to define __stub macros and hopefully few prototypes, +- which can conflict with char bind_textdomain_codeset (); below. +- Prefer to if __STDC__ is defined, since +- exists even on freestanding compilers. */ +- +-#ifdef __STDC__ +-# include +-#else +-# include +-#endif +- +-#undef bind_textdomain_codeset +- +-/* Override any gcc2 internal prototype to avoid an error. */ +-#ifdef __cplusplus +-extern "C" +-{ +-#endif +-/* We use char because int might match the return type of a gcc2 +- builtin and then its argument prototype would still apply. */ +-char bind_textdomain_codeset (); +-/* The GNU C library defines this for functions which it implements +- to always fail with ENOSYS. Some functions are actually named +- something starting with __ and the normal name is an alias. */ +-#if defined (__stub_bind_textdomain_codeset) || defined (__stub___bind_textdomain_codeset) +-choke me +-#else +-char (*f) () = bind_textdomain_codeset; +-#endif +-#ifdef __cplusplus +-} +-#endif ++ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG + +-int +-main () +-{ +-return f != bind_textdomain_codeset; +- ; +- return 0; +-} +-_ACEOF +-rm -f conftest.$ac_objext conftest$ac_exeext +-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 +- (eval $ac_link) 2>conftest.er1 +- ac_status=$? +- grep -v '^ *+' conftest.er1 >conftest.err +- rm -f conftest.er1 +- cat conftest.err >&5 +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); } && +- { ac_try='test -z "$ac_cxx_werror_flag" +- || test ! -s conftest.err' +- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 +- (eval $ac_try) 2>&5 +- ac_status=$? +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; } && +- { ac_try='test -s conftest$ac_exeext' +- { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 +- (eval $ac_try) 2>&5 +- ac_status=$? +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; }; then +- ac_cv_func_bind_textdomain_codeset=yes ++if test -n "$ac_pt_PKG_CONFIG"; then ++ echo "$as_me:$LINENO: result: $ac_pt_PKG_CONFIG" >&5 ++echo "${ECHO_T}$ac_pt_PKG_CONFIG" >&6 + else +- echo "$as_me: failed program was:" >&5 +-sed 's/^/| /' conftest.$ac_ext >&5 +- +-ac_cv_func_bind_textdomain_codeset=no +-fi +-rm -f conftest.err conftest.$ac_objext \ +- conftest$ac_exeext conftest.$ac_ext ++ echo "$as_me:$LINENO: result: no" >&5 ++echo "${ECHO_T}no" >&6 + fi +-echo "$as_me:$LINENO: result: $ac_cv_func_bind_textdomain_codeset" >&5 +-echo "${ECHO_T}$ac_cv_func_bind_textdomain_codeset" >&6 +-if test $ac_cv_func_bind_textdomain_codeset = yes; then +- CATOBJEXT=.gmo +- DATADIRNAME=share ++ ++ PKG_CONFIG=$ac_pt_PKG_CONFIG + else +- CATOBJEXT=.mo +- DATADIRNAME=lib ++ PKG_CONFIG="$ac_cv_path_PKG_CONFIG" + fi + +- ;; +- *) +- CATOBJEXT=.mo +- DATADIRNAME=lib +- ;; +- esac + fi +-rm -f conftest.err conftest.$ac_objext \ +- conftest$ac_exeext conftest.$ac_ext +- LIBS="$glib_save_LIBS" +- INSTOBJEXT=.mo ++if test -n "$PKG_CONFIG"; then ++ _pkg_min_version=0.9.0 ++ echo "$as_me:$LINENO: checking pkg-config is at least version $_pkg_min_version" >&5 ++echo $ECHO_N "checking pkg-config is at least version $_pkg_min_version... $ECHO_C" >&6 ++ if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then ++ echo "$as_me:$LINENO: result: yes" >&5 ++echo "${ECHO_T}yes" >&6 + else +- gt_cv_have_gettext=no ++ echo "$as_me:$LINENO: result: no" >&5 ++echo "${ECHO_T}no" >&6 ++ PKG_CONFIG="" + fi +- fi + + fi + ++pkg_failed=no ++echo "$as_me:$LINENO: checking for GLIB" >&5 ++echo $ECHO_N "checking for GLIB... $ECHO_C" >&6 + +- +- if test "$gt_cv_have_gettext" = "yes" ; then +- +-cat >>confdefs.h <<\_ACEOF +-#define ENABLE_NLS 1 +-_ACEOF +- ++if test -n "$PKG_CONFIG"; then ++ if test -n "$GLIB_CFLAGS"; then ++ pkg_cv_GLIB_CFLAGS="$GLIB_CFLAGS" ++ else ++ if test -n "$PKG_CONFIG" && \ ++ { (echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \" ++ glib-2.0 ++ libxml-2.0 >= 2.3.8 ++ \"") >&5 ++ ($PKG_CONFIG --exists --print-errors " ++ glib-2.0 ++ libxml-2.0 >= 2.3.8 ++ ") 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; then ++ pkg_cv_GLIB_CFLAGS=`$PKG_CONFIG --cflags " ++ glib-2.0 ++ libxml-2.0 >= 2.3.8 ++ " 2>/dev/null` ++else ++ pkg_failed=yes ++fi + fi +- +- if test "$XGETTEXT" != ":"; then +- if $XGETTEXT --omit-header /dev/null 2> /dev/null; then +- : ; +- else +- echo "$as_me:$LINENO: result: found xgettext program is not GNU xgettext; ignore it" >&5 +-echo "${ECHO_T}found xgettext program is not GNU xgettext; ignore it" >&6 +- XGETTEXT=":" +- fi ++else ++ pkg_failed=untried ++fi ++if test -n "$PKG_CONFIG"; then ++ if test -n "$GLIB_LIBS"; then ++ pkg_cv_GLIB_LIBS="$GLIB_LIBS" ++ else ++ if test -n "$PKG_CONFIG" && \ ++ { (echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \" ++ glib-2.0 ++ libxml-2.0 >= 2.3.8 ++ \"") >&5 ++ ($PKG_CONFIG --exists --print-errors " ++ glib-2.0 ++ libxml-2.0 >= 2.3.8 ++ ") 2>&5 ++ ac_status=$? ++ echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; then ++ pkg_cv_GLIB_LIBS=`$PKG_CONFIG --libs " ++ glib-2.0 ++ libxml-2.0 >= 2.3.8 ++ " 2>/dev/null` ++else ++ pkg_failed=yes ++fi + fi +- +- # We need to process the po/ directory. +- POSUB=po +- +- ac_config_commands="$ac_config_commands default-1" +- +- +- for lang in $ALL_LINGUAS; do +- GMOFILES="$GMOFILES $lang.gmo" +- POFILES="$POFILES $lang.po" +- done +- +- +- +- ++else ++ pkg_failed=untried ++fi + + + ++if test $pkg_failed = yes; then + ++if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then ++ _pkg_short_errors_supported=yes ++else ++ _pkg_short_errors_supported=no ++fi ++ if test $_pkg_short_errors_supported = yes; then ++ GLIB_PKG_ERRORS=`$PKG_CONFIG --short-errors --errors-to-stdout --print-errors " ++ glib-2.0 ++ libxml-2.0 >= 2.3.8 ++ "` ++ else ++ GLIB_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors " ++ glib-2.0 ++ libxml-2.0 >= 2.3.8 ++ "` ++ fi ++ # Put the nasty error message in config.log where it belongs ++ echo "$GLIB_PKG_ERRORS" >&5 + ++ { { echo "$as_me:$LINENO: error: Package requirements ( ++ glib-2.0 ++ libxml-2.0 >= 2.3.8 ++ ) were not met: + ++$GLIB_PKG_ERRORS + ++Consider adjusting the PKG_CONFIG_PATH environment variable if you ++installed software in a non-standard prefix. + ++Alternatively, you may set the environment variables GLIB_CFLAGS ++and GLIB_LIBS to avoid the need to call pkg-config. ++See the pkg-config man page for more details. ++" >&5 ++echo "$as_me: error: Package requirements ( ++ glib-2.0 ++ libxml-2.0 >= 2.3.8 ++ ) were not met: + +- if test "$gt_cv_have_gettext" = "yes"; then +- if test "x$ALL_LINGUAS" = "x"; then +- LINGUAS= +- else +- echo "$as_me:$LINENO: checking for catalogs to be installed" >&5 +-echo $ECHO_N "checking for catalogs to be installed... $ECHO_C" >&6 +- NEW_LINGUAS= +- for presentlang in $ALL_LINGUAS; do +- useit=no +- if test "%UNSET%" != "${LINGUAS-%UNSET%}"; then +- desiredlanguages="$LINGUAS" +- else +- desiredlanguages="$ALL_LINGUAS" +- fi +- for desiredlang in $desiredlanguages; do +- # Use the presentlang catalog if desiredlang is +- # a. equal to presentlang, or +- # b. a variant of presentlang (because in this case, +- # presentlang can be used as a fallback for messages +- # which are not translated in the desiredlang catalog). +- case "$desiredlang" in +- "$presentlang"*) useit=yes;; +- esac +- done +- if test $useit = yes; then +- NEW_LINGUAS="$NEW_LINGUAS $presentlang" +- fi +- done +- LINGUAS=$NEW_LINGUAS +- echo "$as_me:$LINENO: result: $LINGUAS" >&5 +-echo "${ECHO_T}$LINGUAS" >&6 +- fi ++$GLIB_PKG_ERRORS + +- if test -n "$LINGUAS"; then +- for lang in $LINGUAS; do CATALOGS="$CATALOGS $lang$CATOBJEXT"; done +- fi +- fi ++Consider adjusting the PKG_CONFIG_PATH environment variable if you ++installed software in a non-standard prefix. + +- MKINSTALLDIRS= +- if test -n "$ac_aux_dir"; then +- MKINSTALLDIRS="$ac_aux_dir/mkinstalldirs" +- fi +- if test -z "$MKINSTALLDIRS"; then +- MKINSTALLDIRS="\$(top_srcdir)/mkinstalldirs" +- fi ++Alternatively, you may set the environment variables GLIB_CFLAGS ++and GLIB_LIBS to avoid the need to call pkg-config. ++See the pkg-config man page for more details. ++" >&2;} ++ { (exit 1); exit 1; }; } ++elif test $pkg_failed = untried; then ++ { { echo "$as_me:$LINENO: error: The pkg-config script could not be found or is too old. Make sure it ++is in your PATH or set the PKG_CONFIG environment variable to the full ++path to pkg-config. + ++Alternatively, you may set the environment variables GLIB_CFLAGS ++and GLIB_LIBS to avoid the need to call pkg-config. ++See the pkg-config man page for more details. + +- test -d po || mkdir po +- if test "x$srcdir" != "x."; then +- if test "x`echo $srcdir | sed 's@/.*@@'`" = "x"; then +- posrcprefix="$srcdir/" +- else +- posrcprefix="../$srcdir/" +- fi +- else +- posrcprefix="../" +- fi +- rm -f po/POTFILES +- sed -e "/^#/d" -e "/^\$/d" -e "s,.*, $posrcprefix& \\\\," -e "\$s/\(.*\) \\\\/\1/" \ +- < $srcdir/po/POTFILES.in > po/POTFILES ++To get pkg-config, see . ++See \`config.log' for more details." >&5 ++echo "$as_me: error: The pkg-config script could not be found or is too old. Make sure it ++is in your PATH or set the PKG_CONFIG environment variable to the full ++path to pkg-config. + ++Alternatively, you may set the environment variables GLIB_CFLAGS ++and GLIB_LIBS to avoid the need to call pkg-config. ++See the pkg-config man page for more details. + +-echo "$as_me:$LINENO: checking locale directory" >&5 +-echo $ECHO_N "checking locale directory... $ECHO_C" >&6 +-if test "x$prefix" = "xNONE"; then +- PACKAGE_LOCALE_DIR=$ac_default_prefix/share/locale ++To get pkg-config, see . ++See \`config.log' for more details." >&2;} ++ { (exit 1); exit 1; }; } + else +- PACKAGE_LOCALE_DIR=$prefix/share/locale ++ GLIB_CFLAGS=$pkg_cv_GLIB_CFLAGS ++ GLIB_LIBS=$pkg_cv_GLIB_LIBS ++ echo "$as_me:$LINENO: result: yes" >&5 ++echo "${ECHO_T}yes" >&6 ++ : + fi + + +-cat >>confdefs.h <<_ACEOF +-#define PACKAGE_LOCALE_DIR "$PACKAGE_LOCALE_DIR" +-_ACEOF +- +- echo "$as_me:$LINENO: result: \"$PACKAGE_LOCALE_DIR\"" >&5 +-echo "${ECHO_T}\"$PACKAGE_LOCALE_DIR\"" >&6 +- +-INTLTOOL_QALCULATE_DEFINITIONS_RULE='%.xml: %.xml.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po-defs/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -x -u -c $(top_builddir)/po-defs/.intltool-merge-cache $(top_srcdir)/po-defs $< $@' +- +- + + ac_config_files="$ac_config_files Makefile src/Makefile libqalculate/Makefile data/Makefile po/Makefile.in po-defs/Makefile docs/Makefile docs/reference/Makefile libqalculate.pc" + cat >confcache <<\_ACEOF diff --git a/math/qalculate/patches/patch-ad b/math/qalculate/patches/patch-ad new file mode 100644 index 00000000000..931b6a7fb0a --- /dev/null +++ b/math/qalculate/patches/patch-ad @@ -0,0 +1,62 @@ +$NetBSD: patch-ad,v 1.1 2006/06/22 18:52:00 jlam Exp $ + +--- configure.in.orig 2006-04-13 06:24:58.000000000 -0400 ++++ configure.in +@@ -84,28 +84,6 @@ AC_SUBST(QALCULATE_AGE) + + + dnl -------------------------------- +-dnl | check for neccessary libraries |----------------------------------------- +-dnl -------------------------------- +- +-AC_CHECK_LIB(pthread, pthread_create, [LIBS="$LIBS -lpthread"]) +- +-AC_LANG([C++]) +- +-AC_PATH_CLN(1.1.0, [ +- LIBS="$LIBS $CLN_LIBS" +- CPPFLAGS="$CPPFLAGS $CLN_CPPFLAGS" +- AC_DEFINE(HAVE_LIBCLN,1,[If CLN can be used]) +-], AC_MSG_ERROR([No suitable installed version of CLN could be found.])) +- +- +-PKG_CHECK_MODULES(GLIB, [ +- glib-2.0 +- libxml-2.0 >= 2.3.8 +- ]) +-AC_SUBST(GLIB_CFLAGS) +-AC_SUBST(GLIB_LIBS) +- +-dnl -------------------------------- + dnl | check for readline |----------------------------------------- + dnl -------------------------------- + +@@ -230,6 +208,28 @@ AC_DEFINE_UNQUOTED(PACKAGE_LOCALE_DIR, " + INTLTOOL_QALCULATE_DEFINITIONS_RULE='%.xml: %.xml.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po-defs/*.po) ; LC_ALL=C $(INTLTOOL_MERGE) -x -u -c $(top_builddir)/po-defs/.intltool-merge-cache $(top_srcdir)/po-defs $< [$]@' + AC_SUBST(INTLTOOL_QALCULATE_DEFINITIONS_RULE) + ++dnl -------------------------------- ++dnl | check for neccessary libraries |----------------------------------------- ++dnl -------------------------------- ++ ++AC_CHECK_LIB(pthread, pthread_create, [LIBS="$LIBS -lpthread"]) ++ ++AC_LANG([C++]) ++ ++AC_PATH_CLN(1.1.0, [ ++ LIBS="$LIBS $CLN_LIBS" ++ CPPFLAGS="$CPPFLAGS $CLN_CPPFLAGS" ++ AC_DEFINE(HAVE_LIBCLN,1,[If CLN can be used]) ++], AC_MSG_ERROR([No suitable installed version of CLN could be found.])) ++ ++ ++PKG_CHECK_MODULES(GLIB, [ ++ glib-2.0 ++ libxml-2.0 >= 2.3.8 ++ ]) ++AC_SUBST(GLIB_CFLAGS) ++AC_SUBST(GLIB_LIBS) ++ + dnl -------- + dnl | output |----------------------------------------------------------------- + dnl -------- -- cgit v1.2.3