Index: Makefile.am =================================================================== RCS file: /home/freeciv/CVS/freeciv/Makefile.am,v retrieving revision 1.23 diff -u -r1.23 Makefile.am --- Makefile.am 2002/06/12 08:21:40 1.23 +++ Makefile.am 2002/08/11 20:12:30 @@ -19,12 +19,13 @@ endif -SUBDIRS= $(DSUBDIRS) intl common $(SSUBDIRS) $(CSUBDIRS) po doc +SUBDIRS= $(DSUBDIRS) common $(SSUBDIRS) $(CSUBDIRS) po doc m4 -EXTRA_DIST= acconfig.h \ +EXTRA_DIST= acconfig.h \ autogen.sh \ civ \ config.mac.h \ + config.rpath \ configure.ac \ configure.in \ diff_ignore \ @@ -64,30 +65,10 @@ debian/menu \ debian/rules \ debian/watch \ - m4/ac_path_lib.m4 \ - m4/esd.m4 \ - m4/gettext.m4 \ - m4/glib-2.0.m4 \ - m4/glib-gettext.m4 \ - m4/glib.m4 \ - m4/glibc.m4 \ - m4/gtk-2.0.m4 \ - m4/gtk.m4 \ - m4/iconv.m4 \ - m4/imlib.m4 \ - m4/langinfo.m4 \ - m4/lcmessage.m4 \ - m4/ngettext.m4 \ - m4/posix.m4 \ - m4/progtest.m4 \ - m4/readline.m4 \ - m4/sdl.m4 \ - m4/sound.m4 \ - m4/vsnprintf.m4 \ - m4/x.213 \ - m4/x.252 \ vms/config.h_vms \ vms/freeciv_h.vms \ vms/imlib_config.h_vms \ vms/readme.vms \ vms/vms_build.com + +ACLOCAL_AMFLAGS = -I m4 Index: autogen.sh =================================================================== RCS file: /home/freeciv/CVS/freeciv/autogen.sh,v retrieving revision 1.9 diff -u -r1.9 autogen.sh --- autogen.sh 2002/07/26 00:50:09 1.9 +++ autogen.sh 2002/08/11 20:12:30 @@ -144,11 +144,11 @@ version_check 1 "autoconf" "ftp://ftp.gnu.org/pub/gnu/autoconf/" 2 13 || DIE=1 fi -version_check 1 "automake" "ftp://ftp.gnu.org/pub/gnu/automake/" 1 4 || DIE=1 +version_check 1 "automake" "ftp://ftp.gnu.org/pub/gnu/automake/" 1 5 || DIE=1 if [ "$FC_USE_NLS" = "yes" ]; then DIE2=0 - version_check 1 "xgettext" "ftp://ftp.gnu.org/pub/gnu/gettext/" 0 10 36 || DIE2=1 - version_check 1 "msgfmt" "ftp://ftp.gnu.org/pub/gnu/gettext/" 0 10 36 || DIE2=1 + version_check 1 "xgettext" "ftp://ftp.gnu.org/pub/gnu/gettext/" 0 11 0 || DIE2=1 + version_check 1 "msgfmt" "ftp://ftp.gnu.org/pub/gnu/gettext/" 0 11 0 || DIE2=1 if [ "$DIE2" -eq 1 ]; then echo echo "You may want to use --disable-nls to disable NLS." @@ -165,11 +165,8 @@ echo "+ using new autoconf configuration (use --disable-autoconf2.52 to use old)" fi -echo "+ creating acinclude.m4" -cat m4/*.m4 > acinclude.m4 - echo "+ running aclocal ..." -aclocal $ACLOCAL_FLAGS || { +aclocal -I m4 $ACLOCAL_FLAGS || { echo echo "aclocal failed - check that all needed development files are present on system" exit 1 Index: configure.ac =================================================================== RCS file: /home/freeciv/CVS/freeciv/configure.ac,v retrieving revision 1.20 diff -u -r1.20 configure.ac --- configure.ac 2002/07/29 06:07:49 1.20 +++ configure.ac 2002/08/11 20:12:49 @@ -143,14 +143,8 @@ dnl AC_PROG_MAKE_SET dnl I18n support -ALL_LINGUAS="da de en_GB es et fi fr hu it ja nl no pl pt pt_BR ro ru sv" -AM_GNU_GETTEXT(,need-ngettext) +AM_GNU_GETTEXT([external],[need-ngettext]) -dnl AM_GNU_GETTEXT doesn't have all features we want -dnl or they don't behave correctly. -dnl Old gettext binaries don't understand plurals. (ngettext, msgid_plural) -dnl and there are some problems with missing ngettext. - if test "$USE_NLS" = "yes"; then dnl nls_cv_force_use_gnu_gettext is set by AM_GNU_GETTEXT dnl it is "yes" when --with-included-gettext is given @@ -174,7 +168,7 @@ fi if test "$IS_BETA_VERSION" = "1" || test "$IS_DEVEL_VERSION" = "1"; then - AC_MSG_CHECKING(for GNU xgettext version >= 0.10.36) + AC_MSG_CHECKING(for GNU xgettext version >= 0.11.0) xgettext_version=`$XGETTEXT --version 2>&1 | grep GNU | sed 's/"/ /g'` AC_TRY_RUN([ #include @@ -192,7 +186,7 @@ return 1; } sscanf(p, "%d.%d.%d", &major, &minor, &patch); - if (major < 1 && (minor < 10 || (minor == 10 && patch < 36))) { + if (major < 1 && minor < 11) { return 1; } return 0; @@ -209,7 +203,7 @@ echo error ) - AC_MSG_CHECKING(for GNU msgfmt version >= 0.10.35) + AC_MSG_CHECKING(for GNU msgfmt version >= 0.11.0) msgfmt_version=`$MSGFMT --version 2>&1 | grep GNU | sed 's/"/ /g'` AC_TRY_RUN([ #include @@ -228,7 +222,7 @@ return 1; } sscanf(p, "%d.%d.%d", &major, &minor, &patch); - if (major < 1 && (minor < 10 || (minor == 10 && patch < 35))) { + if (major < 1 && minor < 11) { return 1; } return 0; @@ -240,7 +234,7 @@ AC_MSG_RESULT(no) AC_MSG_ERROR(You are unable to create *.gmo files. This is development version which doesn't include them. Please update your -gettext package. We recommend you versions >= 0.10.38. Or use +gettext package. We recommend versions >= 0.11.0. Or use --disable-nls instead.) ] , @@ -281,7 +275,6 @@ fi dnl Windows-specific settings -AC_DIAGNOSE([obsolete],[AC_MINGW32 is obsolete: use AC_CANONICAL_HOST and $host_os]) case $host_os in *mingw32* ) MINGW32=yes;; * ) MINGW32=no;; @@ -619,62 +612,6 @@ fi]) fi -dnl Freeciv uses a non-standard macro, Q_(), to handle cases of qualified -dnl translatable strings and macro PL_() to handle plural forms. -dnl Since the Gettext supplied Autoconf support -dnl doesn't seem to have a way to add new keywords to its xgettext call, -dnl we do the following. -dnl The Gettext supplied Autoconf support starts with 'po/Makefile.in.in', -dnl and builds 'po/Makefile.in' then 'po/Makefile'. In order for the -dnl commonly used _() and N_() macros to work, there should be somewhere -dnl in that 'po/Makefile' a call to xgettext with "--keyword=_" and -dnl "--keyword=N_" as arguments. To support Q_() and PL_(), -dnl the following simply dnl replaces instances of -dnl "--keyword=N_" with "--keyword=N_ --keyword=Q_ --keyword=PL_:1,2" -dnl in the 'po/Makefile' file. -AC_CONFIG_COMMANDS([fc_default-1],[[if test -f po/Makefile ; then - if grep 'keyword=N_ --keyword=Q_ --keyword=PL_:1,2' po/Makefile >/dev/null 2>&1 ; then - # has already been extended - : - else - echo extending po/Makefile - mv -f po/Makefile po/Makefile.tmp - sed -e 's/--keyword=N_/--keyword=N_ --keyword=Q_ --keyword=PL_:1,2/g' po/Makefile.tmp > po/Makefile - rm po/Makefile.tmp - fi - fi]],[[]]) - -dnl Vast quantities of meaningless errors from xgettext is also annoying. -dnl We fix this by forcing xgettext to assume all files are C source files. -AC_CONFIG_COMMANDS([fc_default-2],[[if test -f po/Makefile ; then - if grep 'language=C --files-from=\$(srcdir)/POTFILES.in' po/Makefile >/dev/null 2>&1 ; then - # has already been silenced - : - else - echo silencing po/Makefile - mv -f po/Makefile po/Makefile.tmp - sed -e 's/--files-from=$(srcdir)\/POTFILES.in/--language=C --files-from=$(srcdir)\/POTFILES.in/' po/Makefile.tmp > po/Makefile - rm po/Makefile.tmp - fi - fi]],[[]]) - -dnl Most of the C comments copied to freeciv.pot are spurious; -dnl change to only copy those with prefix "TRANS:" -dnl Also add --escape to the arguments to convert extended -dnl characters to escape characters. This affects some of the -dnl gui-mui strings, which use 0x1B escape character. -AC_CONFIG_COMMANDS([fc_default-4],[[if test -f po/Makefile ; then - if grep 'add-comments="TRANS:" --escape' po/Makefile >/dev/null 2>&1 ; then - # has already been modified - : - else - echo modifying po/Makefile add-comments/escape - mv -f po/Makefile po/Makefile.tmp - sed -e 's/add-comments/add-comments="TRANS:" --escape/' po/Makefile.tmp > po/Makefile - rm po/Makefile.tmp - fi - fi]],[[]]) - dnl The BeOS sys/uio.h is broken. This kludges it out of existence. dnl (This still causes lots of spurious changes to config.h on BeOS.) AC_CONFIG_COMMANDS([fc_default-5],[[if test x`uname -s` = xBeOS ; then @@ -684,7 +621,7 @@ sed -e 's/#define HAVE_SYS_UIO_H 1/#undef HAVE_SYS_UIO_H/g' config.h.tmp > config.h rm config.h.tmp fi - fi]],[[]]) + fi]]) AC_CONFIG_FILES([Makefile @@ -697,6 +634,7 @@ data/civ2/Makefile data/scenario/Makefile data/nation/Makefile + m4/Makefile common/Makefile ai/Makefile client/Makefile @@ -708,9 +646,8 @@ client/gui-win32/Makefile client/gui-stub/Makefile server/Makefile - intl/Makefile po/Makefile.in doc/Makefile undep.sh]) -AC_CONFIG_COMMANDS([default],[[ chmod +x undep.sh ; ./undep.sh ]],[[]]) +AC_CONFIG_COMMANDS([default],[[ chmod +x undep.sh ; ./undep.sh ]]) AC_OUTPUT Index: configure.in =================================================================== RCS file: /home/freeciv/CVS/freeciv/configure.in,v retrieving revision 1.199 diff -u -r1.199 configure.in --- configure.in 2002/07/29 06:07:49 1.199 +++ configure.in 2002/08/11 20:12:49 @@ -142,14 +142,8 @@ dnl AC_PROG_MAKE_SET dnl I18n support -ALL_LINGUAS="da de en_GB es et fi fr hu it ja nl no pl pt pt_BR ro ru sv" -AM_GNU_GETTEXT(,need-ngettext) +AM_GNU_GETTEXT([external],[need-ngettext]) -dnl AM_GNU_GETTEXT doesn't have all features we want -dnl or they don't behave correctly. -dnl Old gettext binaries don't understand plurals. (ngettext, msgid_plural) -dnl and there are some problems with missing ngettext. - if test "$USE_NLS" = "yes"; then dnl nls_cv_force_use_gnu_gettext is set by AM_GNU_GETTEXT dnl it is "yes" when --with-included-gettext is given @@ -173,7 +167,7 @@ fi if test "$IS_BETA_VERSION" = "1" || test "$IS_DEVEL_VERSION" = "1"; then - AC_MSG_CHECKING(for GNU xgettext version >= 0.10.36) + AC_MSG_CHECKING(for GNU xgettext version >= 0.11.0) xgettext_version=`$XGETTEXT --version 2>&1 | grep GNU | sed 's/"/ /g'` AC_TRY_RUN([ #include @@ -191,7 +185,7 @@ return 1; } sscanf(p, "%d.%d.%d", &major, &minor, &patch); - if (major < 1 && (minor < 10 || (minor == 10 && patch < 36))) { + if (major < 1 && minor < 11) { return 1; } return 0; @@ -208,7 +202,7 @@ echo error ) - AC_MSG_CHECKING(for GNU msgfmt version >= 0.10.36) + AC_MSG_CHECKING(for GNU msgfmt version >= 0.11.0) msgfmt_version=`$MSGFMT --version 2>&1 | grep GNU | sed 's/"/ /g'` AC_TRY_RUN([ #include @@ -227,7 +221,7 @@ return 1; } sscanf(p, "%d.%d.%d", &major, &minor, &patch); - if (major < 1 && (minor < 10 || (minor == 10 && patch < 35))) { + if (major < 1 && minor < 11) { return 1; } return 0; @@ -239,7 +233,7 @@ AC_MSG_RESULT(no) AC_MSG_ERROR(You are unable to create *.gmo files. This is development version which doesn't include them. Please update your -gettext package. We recommend you versions >= 0.10.38. Or use +gettext package. We recommend versions >= 0.11.0. Or use --disable-nls instead.) ] , @@ -613,65 +607,6 @@ fi]) fi -dnl Freeciv uses a non-standard macro, Q_(), to handle cases of qualified -dnl translatable strings and macro PL_() to handle plural forms. -dnl Since the Gettext supplied Autoconf support -dnl doesn't seem to have a way to add new keywords to its xgettext call, -dnl we do the following. -dnl The Gettext supplied Autoconf support starts with 'po/Makefile.in.in', -dnl and builds 'po/Makefile.in' then 'po/Makefile'. In order for the -dnl commonly used _() and N_() macros to work, there should be somewhere -dnl in that 'po/Makefile' a call to xgettext with "--keyword=_" and -dnl "--keyword=N_" as arguments. To support Q_() and PL_(), -dnl the following simply dnl replaces instances of -dnl "--keyword=N_" with "--keyword=N_ --keyword=Q_ --keyword=PL_:1,2" -dnl in the 'po/Makefile' file. -AC_OUTPUT_COMMANDS( - [if test -f po/Makefile ; then - if grep 'keyword=N_ --keyword=Q_ --keyword=PL_:1,2' po/Makefile >/dev/null 2>&1 ; then - # has already been extended - : - else - echo extending po/Makefile - mv -f po/Makefile po/Makefile.tmp - sed -e 's/--keyword=N_/--keyword=N_ --keyword=Q_ --keyword=PL_:1,2/g' po/Makefile.tmp > po/Makefile - rm po/Makefile.tmp - fi - fi]) - -dnl Vast quantities of meaningless errors from xgettext is also annoying. -dnl We fix this by forcing xgettext to assume all files are C source files. -AC_OUTPUT_COMMANDS( - [if test -f po/Makefile ; then - if grep 'language=C --files-from=\$(srcdir)/POTFILES.in' po/Makefile >/dev/null 2>&1 ; then - # has already been silenced - : - else - echo silencing po/Makefile - mv -f po/Makefile po/Makefile.tmp - sed -e 's/--files-from=$(srcdir)\/POTFILES.in/--language=C --files-from=$(srcdir)\/POTFILES.in/' po/Makefile.tmp > po/Makefile - rm po/Makefile.tmp - fi - fi]) - -dnl Most of the C comments copied to freeciv.pot are spurious; -dnl change to only copy those with prefix "TRANS:" -dnl Also add --escape to the arguments to convert extended -dnl characters to escape characters. This affects some of the -dnl gui-mui strings, which use 0x1B escape character. -AC_OUTPUT_COMMANDS( - [if test -f po/Makefile ; then - if grep 'add-comments="TRANS:" --escape' po/Makefile >/dev/null 2>&1 ; then - # has already been modified - : - else - echo modifying po/Makefile add-comments/escape - mv -f po/Makefile po/Makefile.tmp - sed -e 's/add-comments/add-comments="TRANS:" --escape/' po/Makefile.tmp > po/Makefile - rm po/Makefile.tmp - fi - fi]) - dnl The BeOS sys/uio.h is broken. This kluges it out of existence. dnl (This still causes lots of spurious changes to config.h on BeOS.) AC_OUTPUT_COMMANDS( @@ -686,6 +621,7 @@ AC_OUTPUT(Makefile + m4/Makefile data/Makefile data/misc/Makefile data/isotrident/Makefile @@ -706,7 +642,7 @@ client/gui-win32/Makefile client/gui-stub/Makefile server/Makefile - intl/Makefile po/Makefile.in doc/Makefile + m4/Makefile undep.sh, [ chmod +x undep.sh ; ./undep.sh ]) Index: client/Makefile.am =================================================================== RCS file: /home/freeciv/CVS/freeciv/client/Makefile.am,v retrieving revision 1.43 diff -u -r1.43 Makefile.am --- client/Makefile.am 2002/07/08 16:03:27 1.43 +++ client/Makefile.am 2002/08/11 20:12:55 @@ -169,6 +169,6 @@ civclient_DEPENDENCIES = @gui_sources@/libguiclient.a \ ../common/libcivcommon.a agents/libagents.a civclient_LDADD = @gui_sources@/libguiclient.a \ - ../common/libcivcommon.a @INTLLIBS@ @gui_sources@/libguiclient.a \ + ../common/libcivcommon.a @LIBINTL@ @gui_sources@/libguiclient.a \ ../common/libcivcommon.a @CLIENT_LIBS@ agents/libagents.a \ @CLIENT_LIBS@ @SOUND_LIBS@ Index: po/ChangeLog =================================================================== RCS file: /home/freeciv/CVS/freeciv/po/ChangeLog,v retrieving revision 1.2 diff -u -r1.2 ChangeLog --- po/ChangeLog 2001/06/15 23:12:58 1.2 +++ po/ChangeLog 2002/08/11 20:13:09 @@ -1,3 +1,14 @@ +2002-08-11 gettextize + + * Makefile.in.in: Upgrade to gettext-0.11.5. + * Rules-quot: New file, from gettext-0.11.5. + * boldquot.sed: New file, from gettext-0.11.5. + * en@boldquot.header: New file, from gettext-0.11.5. + * en@quot.header: New file, from gettext-0.11.5. * insert-header.sin: New file, from gettext-0.11.5. + * quot.sed: New file, from gettext-0.11.5. + * remove-potcdate.sin: New file, from gettext-0.11.5. + 2001-06-15 gettextize * Makefile.in.in: Upgrade to gettext-0.10.38. Index: server/Makefile.am =================================================================== RCS file: /home/freeciv/CVS/freeciv/server/Makefile.am,v retrieving revision 1.22 diff -u -r1.22 Makefile.am --- server/Makefile.am 2001/06/15 23:12:59 1.22 +++ server/Makefile.am 2002/08/11 20:13:10 @@ -70,4 +70,4 @@ civserver_DEPENDENCIES = ../common/libcivcommon.a ../ai/libcivai.a ./libcivserver.a -civserver_LDADD = ../common/libcivcommon.a ../ai/libcivai.a ./libcivserver.a @INTLLIBS@ ../common/libcivcommon.a ../ai/libcivai.a ./libcivserver.a $(SERVER_LIBS) +civserver_LDADD = ../common/libcivcommon.a ../ai/libcivai.a ./libcivserver.a @LIBINTL@ ../common/libcivcommon.a ../ai/libcivai.a ./libcivserver.a $(SERVER_LIBS)