diff options
author | Brian Tarricone <brian@tarricone.org> | 2008-10-12 08:40:41 +0000 |
---|---|---|
committer | Brian Tarricone <brian@tarricone.org> | 2008-10-12 08:40:41 +0000 |
commit | c54398798510d8c9c71748f0d781ff617e3bdb88 (patch) | |
tree | 4e676de8654c3416de1f402f212d9ca94c167a4b | |
parent | e716ab83cf0bc4c6065c0fe17c7ca2589617bb9e (diff) | |
download | xfce4-dev-tools-c54398798510d8c9c71748f0d781ff617e3bdb88.tar.gz |
* scripts/xdt-autogen.in: Only attempt to patch intltool merge for
versions of intltool < 0.40.0. Versions starting from 0.40.4 are
fixed, and earlier 0.40.x versions aren't patchable because they
use a systemwide copy of intltool-merge.
(Old svn revision: 28165)
-rw-r--r-- | ChangeLog | 7 | ||||
-rw-r--r-- | NEWS | 7 | ||||
-rw-r--r-- | scripts/xdt-autogen.in | 22 |
3 files changed, 34 insertions, 2 deletions
@@ -1,3 +1,10 @@ +2008-10-12 Brian Tarricone <bjt23@cornell.edu> + + * scripts/xdt-autogen.in: Only attempt to patch intltool merge for + versions of intltool < 0.40.0. Versions starting from 0.40.4 are + fixed, and earlier 0.40.x versions aren't patchable because they + use a systemwide copy of intltool-merge. + 2008-09-12 Jannis Pohlmann <jannis@xfce.org> * NEWS: Updated for the alpha release. @@ -1,3 +1,10 @@ +4.5.91 +====== + +- Don't try to patch intltool-merge.in for intltool 0.40.x: 0.40.4+ has + a fix for the bug, and 0.40.x earlier than that aren't patchable as they + run systemwide versions of the scripts. + 4.5.90 ====== - Add intltool-merge.in patch to xdt-autogen.in to fix merging translations diff --git a/scripts/xdt-autogen.in b/scripts/xdt-autogen.in index e52de4a..4626bd2 100644 --- a/scripts/xdt-autogen.in +++ b/scripts/xdt-autogen.in @@ -59,9 +59,28 @@ EOF ## ## This fixes a bug in intltool-merge that fails to merge translations -## for .desktop file keys that have a '-' or '_' char in them. +## for .desktop file keys that have a '-' or '_' char in them. this +## is fixed in intltool 0.40.4. ## patch_intltool_merge() { + verstring=`$XDT_PROG_INTLTOOLIZE --version | cut -d' ' -f4` + ver_major=`echo $verstring | cut -d. -f1` + ver_minor=`echo $verstring | cut -d. -f2` + ver_micro=`echo $verstring | cut -d. -f3` + + if test "$ver_major" -a "$ver_minor" -a "$ver_micro"; then + test $ver_major -gt 0 && return 0 + test $ver_minor -gt 40 && return 0 + test $ver_minor -eq 40 -a $ver_micro -ge 4 && return 0 + if test $ver_minor -eq 40 -a $ver_micro -lt 4; then + echo "WARNING: Unable to patch intltool-merge from versions 0.40.0 through 0.40.3." + echo "WARNING: Generated .desktop files may be invalid." + return 0 # already printed an error; just pretend success + fi + fi + + # attempt to patch, and hope it works... + test -z "$@" && echo 'Patching intltool-merge.in ...' echo '--- intltool-merge.in.orig 2008-08-24 19:02:59.000000000 -0700 +++ intltool-merge.in 2008-08-24 19:03:12.000000000 -0700 @@ -1182,9 +1182,9 @@ @@ -374,7 +393,6 @@ for configure_file in ${CONFIGURE_FILES}; do cd "${source_dir}" && ${XDT_PROG_INTLTOOLIZE} --automake --copy --force) || exit 1 if patch_intltool_merge --dry-run; then - echo 'Patching intltool-merge.in ...' patch_intltool_merge else echo 'WARNING: Failed to patch intltool-merge.in!' |