From: <har...@us...> - 2009-09-26 14:52:04
|
Revision: 4495 http://hugin.svn.sourceforge.net/hugin/?rev=4495&view=rev Author: harryvanderwolf Date: 2009-09-26 14:51:53 +0000 (Sat, 26 Sep 2009) Log Message: ----------- [OSX] correct stupid mistake w.r.t. internal bundle linking to english help file for languages without help file. This should now function correctly Modified Paths: -------------- hugin/trunk/mac/localise-help.sh hugin/trunk/mac/localised.sh Modified: hugin/trunk/mac/localise-help.sh =================================================================== --- hugin/trunk/mac/localise-help.sh 2009-09-26 13:25:07 UTC (rev 4494) +++ hugin/trunk/mac/localise-help.sh 2009-09-26 14:51:53 UTC (rev 4495) @@ -5,7 +5,9 @@ resdir="$TARGET_BUILD_DIR/$PRODUCT_NAME.app/Contents/Resources" huginsrcdir="../src/hugin1/hugin" xrcsrcdir="$huginsrcdir/xrc" +translationsdir="../src/translations" + mkdir -p "$resdir" for helplang in "en_EN" "fr_FR" "it_IT" @@ -25,4 +27,14 @@ done fi +done + +# Create softlinks to existing english help file in case a locale translation exist but no help files +for lang in "en" $(ls $translationsdir/*.po | sed -e "s/^.*\///g" -e "s/\.po//g") +do + if [ $lang != "fr" ] && [ $lang != "it" ] && [ $lang != "en" ] + then + cd "$resdir/$lang.lproj" + ln -s "../en.lproj/help" "help" + fi done \ No newline at end of file Modified: hugin/trunk/mac/localised.sh =================================================================== --- hugin/trunk/mac/localised.sh 2009-09-26 13:25:07 UTC (rev 4494) +++ hugin/trunk/mac/localised.sh 2009-09-26 14:51:53 UTC (rev 4495) @@ -10,6 +10,11 @@ mkdir -p "$resdir" +# The first thing to do is create a fake en.lproj and en.lproj/help folder +# If these do not exist the proper links can't be created +#mkdir -p "$resdir/en.lproj" +#mkdir -p "$resdir/en.lproj/help" + for lang in "en" $(ls $translationsdir/*.po | sed -e "s/^.*\///g" -e "s/\.po//g") do @@ -30,27 +35,28 @@ if [ $lang = "en" ] then continue - else - if [ $lang != "fr" ] && [ $lang != "it" ] - then - ln -s "$resdir/en.lproj/help" "$localisedresdir/help" - fi +# else +# if [ $lang != "fr" ] && [ $lang != "it" ] +# then +# ln -sf "$resdir/en.lproj/help" "../$lang.lproj/help" +# fi fi echo "$lang/hugin.mo from $lang.po" - msgfmt -v -o "$localedir/hugin.mo" "$translationsdir/$lang.po" + /opt/local/bin/msgfmt -v -o "$localedir/hugin.mo" "$translationsdir/$lang.po" echo "$lang/wxstd.mo from $wxWidgetsLocaleDir/$lang.po" if [ -f "$wxWidgetsLocaleDir/$lang.po" ] then - msgfmt -v -o "$localedir/wxstd.mo" "$wxWidgetsLocaleDir/$lang.po" + /opt/local/bin/msgfmt -v -o "$localedir/wxstd.mo" "$wxWidgetsLocaleDir/$lang.po" + # hack to get link to help file else echo "$lang.po not found;" parentLang=`echo $lang|sed s/_.*//` echo "$lang/wxstd.mo from $wxWidgetsLocaleDir/$parentLang.po" if [ -f "$wxWidgetsLocaleDir/$parentLang.po" ] then - msgfmt -v -o "$localedir/wxstd.mo" "$wxWidgetsLocaleDir/$parentLang.po" + /opt/local/bin/msgfmt -v -o "$localedir/wxstd.mo" "$wxWidgetsLocaleDir/$parentLang.po" else echo "$parentLang.po not found;" fi This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |