Search
j0ke.net Open Build Service
>
Projects
>
mozilla
>
MozillaSunbird
> MozillaSunbird.spec
Sign Up
|
Log In
Username
Password
Cancel
Overview
Repositories
Revisions
Requests
Users
Advanced
Attributes
Meta
File MozillaSunbird.spec of Package MozillaSunbird
# # spec file for package MozillaSunbird (Version 0.8) # # Copyright (c) 2008 SUSE LINUX Products GmbH, Nuernberg, Germany. # This file and all modifications and additions to the pristine # package are under the same license as the package itself. # # Please submit bugfixes or comments via http://bugs.opensuse.org/ # # norootforbuild Name: MozillaSunbird BuildRequires: gcc-c++ libgnomeui-devel libidl-devel orbit-devel update-desktop-files zip %if 0%{?suse_version} > 1020 BuildRequires: fdupes %endif # fix broken 9.3 requirements %if 0%{?suse_version} <= 930 BuildRequires: freetype2-devel popt-devel %endif # fix broken SLES9 requirements %if 0%{?suse_version} == 910 BuildRequires: pkgconfig gnome-vfs2 libgnome libgnomeui %endif License: MPL/GPL/LGPL Version: 0.8 Release: 1 Summary: Mozilla's Calendar Application URL: http://www.mozilla.org/projects/calendar/ Group: Productivity/Office/Organizers Source: sunbird-%{version}-source.tar.bz2 Source1: sunbird.desktop Source2: l10n-%{version}.tar.bz2 Patch1: mozilla-gcc4.3-fixes.patch Patch2: mozilla-path_len.patch Patch4: nss-opt.patch Patch8: abuild.patch Patch9: locale.patch BuildRoot: %{_tmppath}/%{name}-%{version}-build PreReq: libstdc++ fileutils textutils /bin/sh %define _unpackaged_files_terminate_build 0 %define releasedate 2008040400 %define progname sunbird %define progdir %{_prefix}/%_lib/%{progname} %define my_provides /tmp/my-provides %define my_requires /tmp/my-requires %if 0%{?suse_version} > 930 BuildRequires: mozilla-nspr-devel %endif %if 0%{?suse_version} > 1010 || 0%{?opensuse_bs} BuildRequires: mozilla-nss-devel %endif %description The Sunbird Project is a redesign of the Mozilla Calendar component. The goal is to produce a cross-platform stand-alone calendar application based on Mozilla's XUL user interface language. At the moment, the Sunbird name is a project name. It is not official and may change in the future. The intended user is someone who uses Mozilla Firefox and Mozilla Thunderbird and wants a calendar application based on Mozilla. Authors: -------- Mozilla Foundation <drivers@mozilla.org> %package translations Summary: Translations of Mozilla Sunbird Provides: locale(%{name}:ca;cs;da;de;es_AR;es_ES;eu;fr;ga_IE;hu;it;ja;ka;ko;lt;mk;nb_NO;nl;pl;pt_BR;pt_PT;ru;sk;sl;sv_SE;tr;uk;zh_CN) Group: Productivity/Office/Organizers PreReq: %{name} = %{version} %description translations This package contains the additional languages for Sunbird. The Sunbird Project is a redesign of the Mozilla Calendar component. The goal is to produce a cross-platform stand-alone calendar application based on Mozilla's XUL user interface language. At the moment, the Sunbird name is a project name. It is not official and may change in the future. The intended user is someone who uses Mozilla Firefox and Mozilla Thunderbird and wants a calendar application based on Mozilla. Authors: -------- Mozilla Foundation <drivers@mozilla.org> %debug_package %prep %setup -n mozilla -b 2 -q %patch1 %patch2 -p1 %patch4 %patch8 -p1 %patch9 %build export MOZ_BUILD_DATE=%{releasedate} export MOZILLA_OFFICIAL=1 export BUILD_OFFICIAL=1 export CFLAGS="$RPM_OPT_FLAGS -Os -fno-strict-aliasing" %if 0%{?suse_version} > 1000 export CFLAGS="$CFLAGS -fstack-protector" %endif export CXXFLAGS="$CFLAGS" export MOZCONFIG=$RPM_BUILD_DIR/mozconfig cat << EOF > $MOZCONFIG mk_add_options MOZILLA_OFFICIAL=1 mk_add_options BUILD_OFFICIAL=1 mk_add_options MOZ_MAKE_FLAGS=%{?jobs:-j%jobs} . \$topsrcdir/calendar/sunbird/config/mozconfig ac_add_options --prefix=%{_prefix} ac_add_options --libdir=%{_libdir} ac_add_options --sysconfdir=%{_sysconfdir} ac_add_options --mandir=%{_mandir} ac_add_options --includedir=%{_includedir} ac_add_options --with-system-jpeg ac_add_options --with-system-png ac_add_options --with-system-zlib ac_add_options --enable-default-toolkit=gtk2 ac_add_options --enable-xft ac_add_options --disable-tests ac_add_options --disable-freetype2 ac_add_options --disable-installer ac_add_options --enable-static ac_add_options --disable-shared ac_add_options --enable-logging ac_add_options --enable-official-branding #ac_add_options --enable-debug EOF %if 0%{?suse_version} > 930 cat << EOF >> $MOZCONFIG ac_add_options --with-system-nspr ac_add_options --enable-system-cairo EOF %endif %if 0%{?suse_version} > 1010 || 0%{?opensuse_bs} cat << EOF >> $MOZCONFIG ac_add_options --with-system-nss EOF %endif make -f client.mk build %install make -C xpinstall/packager STRIP=/bin/true # copy tree into RPM_BUILD_ROOT mkdir -p $RPM_BUILD_ROOT%{progdir} cp -rf $RPM_BUILD_DIR/mozilla/dist/%{progname}/* $RPM_BUILD_ROOT%{progdir} mkdir $RPM_BUILD_ROOT%{_bindir} ln -sf ../..%{progdir}/%{progname} $RPM_BUILD_ROOT%{_bindir}/%{progname} # install additional locales echo %defattr\(-,root,root\) > %{_tmppath}/translations.list for locale in $(awk '{ print $1; }' calendar/locales/shipped-locales); do case $locale in ja-JP-mac|en-US) ;; *) make -C calendar/locales libs-$locale cp dist/xpi-stage/locale-$locale/chrome/$locale.jar \ dist/xpi-stage/locale-$locale/chrome/calendar-$locale.jar \ $RPM_BUILD_ROOT/%{progdir}/chrome cp dist/xpi-stage/locale-$locale/chrome/$locale.manifest \ dist/xpi-stage/locale-$locale/chrome/calendar-$locale.manifest \ $RPM_BUILD_ROOT/%{progdir}/chrome echo %{progdir}/chrome/$locale.jar >> %{_tmppath}/translations.list echo %{progdir}/chrome/$locale.manifest >> %{_tmppath}/translations.list echo %{progdir}/chrome/calendar-$locale.jar >> %{_tmppath}/translations.list echo %{progdir}/chrome/calendar-$locale.manifest >> %{_tmppath}/translations.list esac done # freedesktop definition mkdir -p $RPM_BUILD_ROOT/usr/share/applications/ install -m 644 %{SOURCE1} \ $RPM_BUILD_ROOT/usr/share/applications mkdir -p $RPM_BUILD_ROOT/usr/share/pixmaps/ cp -f $RPM_BUILD_ROOT%{progdir}/chrome/icons/default/default.xpm $RPM_BUILD_ROOT/usr/share/pixmaps/%{progname}.xpm %suse_update_desktop_file %{progname} Office Calendar GTK # modify provides and requires lists %if 0%{?suse_version} == 1000 || 0%{?suse_version} == 1010 cat << EOF > %{my_provides} grep -vE "libnss3.so|libnssckbi.so|libsmime3.so|libsoftokn3.so|libssl3.so|libfreebl3.so" | %{__find_provides} EOF chmod 755 %{my_provides} %define __find_provides %{my_provides} cat << EOF > %{my_requires} grep -vE "libnss3.so|libnssckbi.so|libsmime3.so|libsoftokn3.so|libssl3.so|libfreebl3.so|sunbird-bin" | %{__find_requires} EOF chmod 755 %{my_requires} %define __find_requires %{my_requires} %endif %if 0%{?suse_version} > 1020 %fdupes $RPM_BUILD_ROOT%{progdir} %fdupes $RPM_BUILD_ROOT%{_datadir} %endif %clean rm -rf $RPM_BUILD_ROOT %if 0%{?suse_version} == 1000 || 0%{?suse_version} == 1010 rm -f %{my_provides} rm -f %{my_requires} %endif rm -rf %{_tmppath}/translations.list %files %defattr(-,root,root) %{_bindir}/%{progname} %attr(644,root,root) %{_datadir}/pixmaps/%{progname}.xpm %attr(644,root,root) %{_datadir}/applications/%{progname}.desktop %dir %{progdir} %dir %{progdir}/chrome/ %{progdir}/chrome/icons/ %{progdir}/chrome/calendar-en-US.* %{progdir}/chrome/calendar.* %{progdir}/chrome/classic.* %{progdir}/chrome/comm.* %{progdir}/chrome/en-US.* %{progdir}/chrome/pippki.* %{progdir}/chrome/toolkit.* %{progdir}/components/ %{progdir}/defaults/ %{progdir}/extensions/ %{progdir}/greprefs/ %{progdir}/icons/ %{progdir}/js/ %{progdir}/res/ # NSPR %if 0%{?suse_version} <= 930 %{progdir}/libnspr4.so %{progdir}/libplc4.so %{progdir}/libplds4.so %endif # NSS %if 0%{?suse_version} <= 1010 && !0%{?opensuse_bs} %{progdir}/libnss3.so %{progdir}/libnssckbi.so %{progdir}/libsmime3.so %{progdir}/libsoftokn3.chk %{progdir}/libsoftokn3.so %{progdir}/libfreebl3.chk %{progdir}/libfreebl3.so %{progdir}/libssl3.so %endif # %{progdir}/libmozjs.so %{progdir}/libxpcom_compat.so %{progdir}/libxpcom_core.so %{progdir}/libxpcom.so %{progdir}/libxpistub.so %{progdir}/LICENSE %{progdir}/mozilla-xremote-client %{progdir}/README.txt %{progdir}/run-mozilla.sh %{progdir}/%{progname} %{progdir}/%{progname}-bin %exclude %{progdir}/updater %exclude %{progdir}/updater.ini %{progdir}/xpicleanup %{progdir}/dependentlibs.list %files translations -f %{_tmppath}/translations.list %defattr(-,root,root)