+2001-12-11 Bruno Haible <bruno@clisp.org>
+
+ * configure.in: Use a variant of AC_PROG_CXX_WORKS that doesn't abort
+ upon failure.
+
2001-12-11 Bruno Haible <bruno@clisp.org>
* configure.in: Change version number to 0.11-pre3.
dnl Checks for optional programs for the tests/lang-* tests.
AC_CHECK_PROGS(CXX, $CCC c++ g++ gcc CC cxx cc++ cl, :)
if test "$CXX" != ":"; then
- AC_PROG_CXX_WORKS
+ dnl Use a modified version of AC_PROG_CXX_WORKS that does not exit
+ dnl upon failure.
+ AC_MSG_CHECKING([whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) works])
+ AC_LANG_SAVE
+ AC_LANG_CPLUSPLUS
+ AC_TRY_COMPILER([int main(){return(0);}], ac_cv_prog_cxx_works, ac_cv_prog_cxx_cross)
+ AC_LANG_RESTORE
+ AC_MSG_RESULT($ac_cv_prog_cxx_works)
+ if test $ac_cv_prog_cxx_works = no; then
+ CXX=:
+ fi
fi
dnl Generate the version information file in the intl/ directory.
+2001-12-11 Bruno Haible <bruno@clisp.org>
+
+ * javacomp.m4 (gt_JAVACOMP): Fix typo in jikes test.
+
2001-12-11 Bruno Haible <bruno@clisp.org>
* gettext.m4 (AM_PO_SUBDIRS): Don't insert obsolete Rules-* files into
}
EOF
unset JAVA_HOME
- jikes conftest.java
+ jikes conftest.java 2>/dev/null
error=$?
rm -f conftest.java conftest.class
- exit $?
+ exit $error
); then
HAVE_JIKES=1
ac_result="jikes"
+2001-12-11 Bruno Haible <bruno@clisp.org>
+
+ * lang-c++: Don't use ostream::form, it's a g++ 2.x extension not
+ present in ISO C++ or g++ 3.x.
+ * lang-objc: Drop error messages that can result from attempting to
+ compile an ObjectiveC program.
+ * lang-java: Set the default locale by hand. Some systems, like
+ Solaris, are not capable of setting the locale according to LC_ALL
+ by themselves.
+
2001-12-11 Bruno Haible <bruno@clisp.org>
* lang-objc: If the locale couldn't be set, exit with code 77, not 1.
#include <iostream.h>
#include <libintl.h>
#include <locale.h>
+#include <stdio.h>
#include <stdlib.h>
#define _(string) gettext (string)
cout << _("'Your command, please?', asked the waiter.") << endl;
- cout.form (ngettext ("a piece of cake", "%d pieces of cake", n), n);
- cout << endl;
+ printf (ngettext ("a piece of cake", "%d pieces of cake", n), n);
+ printf ("\n");
- cout.form (_("%s is replaced by %s."), "FF", "EUR");
- cout << endl;
+ printf (_("%s is replaced by %s."), "FF", "EUR");
+ printf ("\n");
}
EOF
public class Program {
public static void main (String[] args) {
+ // Some systems (like Solaris) don't set Locale.getDefault()
+ // as specified by LC_ALL. So set it by hand.
+ Locale.setDefault(new Locale("fr","FR"));
int n = Integer.parseInt(args[0]);
ResourceBundle catalog = ResourceBundle.getBundle("prog");
System.out.println(GettextResource.gettext(catalog,"'Your command, please?', asked the waiter."));
exit (0);
}
EOF
-${CC} ${CFLAGS} ${CPPFLAGS} ${LDFLAGS} -o hello hello.m \
+${CC} ${CFLAGS} ${CPPFLAGS} ${LDFLAGS} -o hello hello.m 2>/dev/null \
|| { echo "SKIP: lang-objc"; rm -fr $tmpfiles; exit 77; }
tmpfiles="$tmpfiles prog.m"