of just plain "fr_FR".
-2003-05-08 Bruno Haible <bruno@clisp.org>
+2003-06-19 Bruno Haible <bruno@clisp.org>
+
+ * configure.ac: Invoke gt_LOCALE_FR.
+
+2003-06-08 Bruno Haible <bruno@clisp.org>
* Makefile.am (config.h_vms): Don't define HAVE_ENVIRON_DECL. Define
eaccess.
dnl Checks for optional programs for the tests/lang-* tests.
gt_PROG_ANSI_CXX
+gt_LOCALE_FR
dnl Generate the version information file in the intl/ directory.
test -d intl || mkdir intl
+2003-06-19 Bruno Haible <bruno@clisp.org>
+
+ * locale-fr.m4: New file.
+ * Makefile.am (EXTRA_DIST): Add it.
+
2003-05-22 Bruno Haible <bruno@clisp.org>
* gettext-0.12.1 released.
hostname.m4 \
javacomp.m4 \
javaexec.m4 \
+locale-fr.m4 \
mbrtowc.m4 \
mbstate_t.m4 \
mbswidth.m4 \
--- /dev/null
+# locale-fr.m4 serial 1 (gettext-0.12.2)
+dnl Copyright (C) 2003 Free Software Foundation, Inc.
+dnl This file is free software, distributed under the terms of the GNU
+dnl General Public License. As a special exception to the GNU General
+dnl Public License, this file may be distributed as part of a program
+dnl that contains a configuration script generated by Autoconf, under
+dnl the same distribution terms as the rest of that program.
+
+dnl From Bruno Haible.
+
+dnl Determine the name of a french locale with traditional encoding.
+AC_DEFUN([gt_LOCALE_FR],
+[
+ AC_CACHE_CHECK([for a traditional french locale], gt_cv_locale_fr, [
+changequote(,)dnl
+ cat <<EOF > conftest.$ac_ext
+#include <locale.h>
+#include <time.h>
+struct tm t;
+char buf[16];
+int main () {
+ /* Check whether the given locale name is recognized by the system. */
+ if (setlocale (LC_ALL, "") == NULL) return 1;
+ /* Check whether the abbreviation of the second month is three bytes long.
+ This excludes the UTF-8 encoding. */
+ t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
+ if (strftime (buf, sizeof (buf), "%b", &t) != 3) return 1;
+ return 0;
+}
+EOF
+changequote([,])dnl
+ if AC_TRY_EVAL([ac_link]) && test -s conftest$ac_exeext; then
+ # Test for the usual locale name.
+ if (LC_ALL=fr_FR ./conftest; exit) 2>/dev/null; then
+ gt_cv_locale_fr=fr_FR
+ else
+ # Test for the locale name with explicit encoding suffix.
+ if (LC_ALL=fr_FR.ISO-8859-1 ./conftest; exit) 2>/dev/null; then
+ gt_cv_locale_fr=fr_FR
+ else
+ # Test for the AIX, OSF/1, FreeBSD, NetBSD locale name.
+ if (LC_ALL=fr_FR.ISO8859-1 ./conftest; exit) 2>/dev/null; then
+ gt_cv_locale_fr=fr_FR.ISO8859-1
+ else
+ # Test for the HP-UX locale name.
+ if (LC_ALL=fr_FR.iso88591 ./conftest; exit) 2>/dev/null; then
+ gt_cv_locale_fr=fr_FR.iso88591
+ else
+ # None found.
+ gt_cv_locale_fr=fr_FR
+ fi
+ fi
+ fi
+ fi
+ fi
+ rm -fr conftest*
+ ])
+ LOCALE_FR=$gt_cv_locale_fr
+ AC_SUBST([LOCALE_FR])
+])
+2003-06-19 Bruno Haible <bruno@clisp.org>
+
+ * Makefile.am (TESTS_ENVIRONMENT): Also set LOCALE_FR.
+ * lang-c: Use system dependent locale name $LOCALE_FR, not just fr_FR.
+ * lang-c++: Likewise.
+ * lang-clisp: Likewise.
+ * lang-gawk: Likewise.
+ * lang-java: Likewise.
+ * lang-librep: Likewise.
+ * lang-objc: Likewise.
+ * lang-pascal: Likewise.
+ * lang-perl: Likewise.
+ * lang-php: Likewise.
+ * lang-python-1: Likewise.
+ * lang-python-2: Likewise.
+ * lang-smalltalk: Likewise.
+ * lang-tcl: Likewise.
+
2003-06-17 Paul Eggert <eggert@twinsun.com>
- * gettext-tools/tests/msgcat-7: Put msgcat options before file name, so
- that the test doesn't fail if POSIXLY_CORRECT is set.
+ * msgcat-7: Put msgcat options before file name, so that the test
+ doesn't fail if POSIXLY_CORRECT is set.
2003-06-15 Bruno Haible <bruno@clisp.org>
CPPFLAGS='@CPPFLAGS@' LDFLAGS='@LDFLAGS@' \
LTLIBINTL='@LTLIBINTL@' \
TESTJAVA='@TESTJAVA@' \
+ LOCALE_FR='@LOCALE_FR@' \
CONFIG_SHELL='$(SHELL)' \
$(SHELL)
EUR remplace FF.
EOF
-LANGUAGE= ./prog fr_FR 2 > prog.out
+: ${LOCALE_FR=fr_FR}
+LANGUAGE= ./prog $LOCALE_FR 2 > prog.out
case $? in
0) ;;
77) rm -fr $tmpfiles; exit 77;;
EUR remplace FF.
EOF
-LANGUAGE= ./prog fr_FR 2 > prog.out
+: ${LOCALE_FR=fr_FR}
+LANGUAGE= ./prog $LOCALE_FR 2 > prog.out
case $? in
0) ;;
77) rm -fr $tmpfiles; exit 77;;
EUR remplace FF.
EOF
-CLISP_LANGUAGE= LANGUAGE= LC_ALL=fr_FR clisp prog.lisp 2 > prog.out || exit 1
+: ${LOCALE_FR=fr_FR}
+CLISP_LANGUAGE= LANGUAGE= LC_ALL=$LOCALE_FR clisp prog.lisp 2 > prog.out || exit 1
${DIFF} prog.ok prog.out || exit 1
rm -fr $tmpfiles
esac
# Test that gawk wasn't built with --disable-nls.
-LANGUAGE= LC_ALL=fr_FR gawk --version | grep logiciel > /dev/null
+: ${LOCALE_FR=fr_FR}
+LANGUAGE= LC_ALL=$LOCALE_FR gawk --version | grep logiciel > /dev/null
test $? = 0 || { rm -fr $tmpfiles; exit 77; }
tmpfiles="$tmpfiles prog.ok prog.out"
EUR remplace FF.
EOF
-LANGUAGE= LC_ALL=fr_FR gawk -v n=2 -f prog.awk > prog.out || exit 1
+: ${LOCALE_FR=fr_FR}
+LANGUAGE= LC_ALL=$LOCALE_FR gawk -v n=2 -f prog.awk > prog.out || exit 1
${DIFF} prog.ok prog.out || exit 1
rm -fr $tmpfiles
EUR remplace FF.
EOF
+: ${LOCALE_FR=fr_FR}
: ${JAVAEXEC="/bin/sh ../lib/javaexec.sh"}
-LANGUAGE= LC_ALL=fr_FR CLASSPATH=.:../../gettext-runtime/intl-java/libintl.jar ${JAVAEXEC} Program 2 > prog.out || exit 1
+LANGUAGE= LC_ALL=$LOCALE_FR CLASSPATH=.:../../gettext-runtime/intl-java/libintl.jar ${JAVAEXEC} Program 2 > prog.out || exit 1
${DIFF} prog.ok prog.out || exit 1
rm -fr $tmpfiles
EUR remplace FF.
EOF
-LANGUAGE= LC_ALL=fr_FR rep --no-rc --batch prog.jl > prog.out || exit 1
+: ${LOCALE_FR=fr_FR}
+LANGUAGE= LC_ALL=$LOCALE_FR rep --no-rc --batch prog.jl > prog.out || exit 1
${DIFF} prog.ok prog.out || exit 1
rm -fr $tmpfiles
EUR remplace FF.
EOF
-LANGUAGE= ./prog fr_FR 2 > prog.out
+: ${LOCALE_FR=fr_FR}
+LANGUAGE= ./prog $LOCALE_FR 2 > prog.out
case $? in
0) ;;
77) rm -fr $tmpfiles; exit 77;;
EUR remplace FF.
EOF
-LANGUAGE= LC_ALL= LC_MESSAGES= LC_CTYPE= LANG=fr_FR ./prog > prog.out || exit 1
+: ${LOCALE_FR=fr_FR}
+LANGUAGE= LC_ALL= LC_MESSAGES= LC_CTYPE= LANG=$LOCALE_FR ./prog > prog.out || exit 1
: ${DIFF=diff}
${DIFF} prog.ok prog.out || exit 1
perl -e 'use Locale::Messages;' 2>/dev/null \
|| { rm -fr $tmpfiles; exit 77; }
-LANGUAGE= LANG=fr_FR LC_MESSAGES= LC_ALL= perl program.pl > prog.out || exit 1
+: ${LOCALE_FR=fr_FR}
+LANGUAGE= LANG=$LOCALE_FR LC_MESSAGES= LC_ALL= perl program.pl > prog.out || exit 1
${DIFF} prog.ok prog.out || exit 1
rm -fr $tmpfiles
EUR remplace FF.
EOF
-LANGUAGE= LC_ALL=fr_FR php -q prog.php > prog.out || exit 1
+: ${LOCALE_FR=fr_FR}
+LANGUAGE= LC_ALL=$LOCALE_FR php -q prog.php > prog.out || exit 1
${DIFF} prog.ok prog.out || exit 1
rm -fr $tmpfiles
EUR remplace FF.
EOF
-LANGUAGE= LC_ALL=fr_FR python prog.py > prog.out || exit 1
+: ${LOCALE_FR=fr_FR}
+LANGUAGE= LC_ALL=$LOCALE_FR python prog.py > prog.out || exit 1
${DIFF} prog.ok prog.out || exit 1
rm -fr $tmpfiles
EUR remplace FF.
EOF
-LANGUAGE= LC_ALL=fr_FR python prog.py 2 > prog.out || exit 1
+: ${LOCALE_FR=fr_FR}
+LANGUAGE= LC_ALL=$LOCALE_FR python prog.py 2 > prog.out || exit 1
${DIFF} prog.ok prog.out || exit 1
rm -fr $tmpfiles
EUR remplace FF.
EOF
-LANGUAGE= LC_ALL=fr_FR gst -Q prog.st > prog.out || exit 1
+: ${LOCALE_FR=fr_FR}
+LANGUAGE= LC_ALL=$LOCALE_FR gst -Q prog.st > prog.out || exit 1
${DIFF} prog.ok prog.out || exit 1
rm -fr $tmpfiles
EUR remplace FF.
EOF
-LANGUAGE= LANG=fr_FR LC_MESSAGES= LC_ALL= tclsh program.tcl > prog.out || exit 1
+: ${LOCALE_FR=fr_FR}
+LANGUAGE= LANG=$LOCALE_FR LC_MESSAGES= LC_ALL= tclsh program.tcl > prog.out || exit 1
${DIFF} prog.ok prog.out || exit 1
rm -fr $tmpfiles