summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPaul Davis <paul@linuxaudiosystems.com>2013-10-22 11:08:50 -0400
committerPaul Davis <paul@linuxaudiosystems.com>2013-10-22 11:08:50 -0400
commitd92feec3f3a787f9d36de25f4a0f5f77f4028602 (patch)
tree22bf1de02c67c968c5b1c338de9bfecd9b2bd0ba
parent17cd6b4044bac5bb348d6a2f12caa2fa81d76327 (diff)
fix bundling of .mo files in OS X bundles
-rwxr-xr-xtools/osx_packaging/osx_build47
1 files changed, 34 insertions, 13 deletions
diff --git a/tools/osx_packaging/osx_build b/tools/osx_packaging/osx_build
index e3e4a23915..c47e64483c 100755
--- a/tools/osx_packaging/osx_build
+++ b/tools/osx_packaging/osx_build
@@ -219,21 +219,42 @@ fi
# copy locale files
if test x$WITH_NLS != x ; then
echo "NLS support ..."
- echo "I hope you remembered to run scons msgupdate!"
+ echo "I hope you remembered to run waf i18n"
LINGUAS=
- for file in $BUILD_ROOT/gtk2_ardour/*.mo
- do
- lang=`basename $file | sed 's/\.mo//'`
- mkdir -p $Locale/$lang/LC_MESSAGES
- cp $file $Locale/$lang/LC_MESSAGES/gtk2_ardour.mo
- LINGUAS="$LINGUAS $lang"
- done
- for file in $BUILD_ROOT/libs/ardour/*.mo
- do
- lang=`basename $file | sed 's/\.mo//'`
- mkdir -p $Locale/$lang/LC_MESSAGES
- cp $file $Locale/$lang/LC_MESSAGES/libardour.mo
+
+ for pkg in gtk2_ardour libs/ardour libs/gtkmm2ext ; do
+ files=`find ../../$pkg -name "*.mo"`
+
+ #
+ # the package name is appended with a number so that
+ # it can be parallel installed during a regular install
+ # with older (and newer) versions. it is just the major
+ # number of the release (i.e. leading digits)
+ #
+
+ vsuffix=`echo $release_version | sed 's/^\([0-9][0-9]*\).*/\1/'`
+
+ if [ -z "$files" ]; then
+ echo ""
+ echo "!!!! WARNING !!!! - Did not find any .mo files in ../../$pkg"
+ echo ""
+ fi
+
+ for file in $files
+ do
+ echo $file
+ lang=`basename $file | sed 's/\.mo//'`
+ mkdir -p $Locale/$lang/LC_MESSAGES
+ cp $file $Locale/$lang/LC_MESSAGES/`basename $pkg`$vsuffix.mo
+ echo copy $file to $Locale/$lang/LC_MESSAGES/`basename $pkg`$vsuffix.mo
+ if echo $LINGUAS | grep $lang >/dev/null 2>&1 ; then
+ :
+ else
+ LINGUAS="$LINGUAS $lang"
+ fi
+ done
done
+
for l in $LINGUAS
do
if [ -d $GTKSTACK_ROOT/share/locale/$l ] ; then