rpms/sunbird/devel sunbird-0.7-uilocale.patch, NONE, 1.1 sunbird.spec, 1.1, 1.2
Lubomir Kundrak (lkundrak)
fedora-extras-commits at redhat.com
Sun Mar 9 15:22:12 UTC 2008
Author: lkundrak
Update of /cvs/pkgs/rpms/sunbird/devel
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv9983/devel
Modified Files:
sunbird.spec
Added Files:
sunbird-0.7-uilocale.patch
Log Message:
Try to use the correct locale (#436693)
sunbird-0.7-uilocale.patch:
--- NEW FILE sunbird-0.7-uilocale.patch ---
Guess the UI locale to use. If only intl.locale.matchOS worked...
Lubomir Kundrak <lkundrak at redhat.com>
--- mozilla/calendar/sunbird/app/mozilla.in.orig 2008-02-28 14:08:25.000000000 +0100
+++ mozilla/calendar/sunbird/app/mozilla.in 2008-02-28 14:08:52.000000000 +0100
@@ -249,6 +249,22 @@ done
export MRE_HOME
+# Try without a local variant first, then with a local variant
+# So that pt-BR doesn't try to use pt for example
+
+SHORTMOZLOCALE=`echo $LANG | sed "s|_\([^.]*\).*||g"`
+MOZLOCALE=`echo $LANG | sed "s|_\([^.]*\).*|-\1|g"`
+
+if [ -f $dist_bin/extensions/langpack-${MOZLOCALE}@sunbird.mozilla.org/chrome/$MOZLOCALE.jar ]
+then
+ set -- "$@" -UILocale $MOZLOCALE
+else
+ if [ -f $dist_bin/extensions/langpack-${SHORTMOZLOCALE}@sunbird.mozilla.org/chrome/$SHORTMOZLOCALE.jar ]
+ then
+ set -- "$@" -UILocale $SHORTMOZLOCALE
+ fi
+fi
+
## Start addon scripts
moz_pis_startstop_scripts "start"
Index: sunbird.spec
===================================================================
RCS file: /cvs/pkgs/rpms/sunbird/devel/sunbird.spec,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- sunbird.spec 19 Feb 2008 17:49:15 -0000 1.1
+++ sunbird.spec 9 Mar 2008 15:21:34 -0000 1.2
@@ -5,7 +5,7 @@
Name: sunbird
Version: 0.7
-Release: 8%{?official:.official}%{?dist}
+Release: 9%{?official:.official}%{?dist}
Summary: Mozilla Sunbird Calendar
Group: Applications/Productivity
@@ -17,9 +17,9 @@
Source3: mozilla-extension-update.sh
Source100: find-external-requires
-# build patches
Patch1: sunbird-0.3.1-link-layout.patch
Patch2: sunbird-0.7-path.patch
+Patch3: sunbird-0.7-uilocale.patch
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
@@ -73,8 +73,9 @@
%prep
%setup -q -n mozilla
-%patch1 -p1 -b .link-layout
-%patch2 -p1 -b .path
+%patch1 -p1 -b .link-layout
+%patch2 -p1 -b .path
+%patch3 -p1 -b .uilocale
# Fix source perms to avoid errors in the debuginfo RPM (bug 357661)
find . -type f \( -name "*.cpp" -o -name "*.h" \) -exec chmod -x '{}' \;
@@ -272,6 +273,9 @@
%changelog
+* Thu Feb 28 2008 Lubomir Kundrak <lkundrak at redhat.com> 0.7-9
+- Try to use the correct locale (#436693)
+
* Mon Jan 21 2008 Lubomir Kundrak <lkundrak at redhat.com> 0.7-8
- Streamlined BuildRequires a bit
- Do not provide stuff that has to be provided by firefox
More information about the fedora-extras-commits
mailing list