1 # 2 # # spec file for package SUNWgnome-desklets 3 # 4 # includes module(s): gdesklets 5 # 6 # Copyright 2009 Sun Microsystems, Inc. 7 # This file and all modifications and additions to the pristine 8 # package are under the same license as the package itself. 9 # 10 %define owner jerrytan 11 # 12 %include Solaris.inc 13 14 %use gdesklets = gdesklets.spec 15 16 Name: SUNWgnome-desklets 17 Summary: GNOME desktop widgets engine 18 Version: %{default_pkg_version} 19 SUNW_BaseDir: %{_basedir} 20 SUNW_Copyright: %{name}.copyright 21 BuildRoot: %{_tmppath}/%{name}-%{version}-build 22 %include default-depend.inc 23 Requires: SUNWgtk2 24 Requires: SUNWPython 25 Requires: SUNWgnome-libs 26 Requires: SUNWlibrsvg 27 Requires: SUNWgnome-python-desktop 28 Requires: SUNWgnome-python-libs 29 Requires: SUNWgnome-desktop-prefs 30 Requires: SUNWdesktop-cache 31 BuildRequires: SUNWgtk2-devel 32 BuildRequires: SUNWPython-devel 33 BuildRequires: SUNWgnome-desktop-prefs-devel 34 BuildRequires: SUNWgnome-libs-devel 35 BuildRequires: SUNWgnome-python-desktop-devel 36 BuildRequires: SUNWgnome-python-libs-devel 37 BuildRequires: SUNWlibrsvg-devel 38 39 %if %build_l10n 40 %package l10n 41 Summary: %{summary} - l10n files 42 SUNW_BaseDir: %{_basedir} 43 %include default-depend.inc 44 Requires: %{name} 45 %endif 46 47 %prep 48 rm -rf %name-%version 49 mkdir %name-%version 50 %gdesklets.prep -d %name-%version 51 52 %build 53 export CFLAGS="%optflags" 54 export RPM_OPT_FLAGS="$CFLAGS" 55 export LDFLAGS="%_ldflags" 56 %gdesklets.build -d %name-%version 57 58 %install 59 %gdesklets.install -d %name-%version 60 61 # Change %{_bindir}/gdesklets symlink to a relative one. 62 cd $RPM_BUILD_ROOT%{_bindir} 63 rm gdesklets 64 ln -s ../lib/gdesklets/gdesklets 65 66 # fixes %_datadir/gdesklets/Displays/Calendar/gfx/months/README 67 chmod -R a+rX $RPM_BUILD_ROOT 68 69 rm -r $RPM_BUILD_ROOT%{_datadir}/mime 70 rm $RPM_BUILD_ROOT%{_datadir}/applications/*.cache 71 72 %if %build_l10n 73 %else 74 # REMOVE l10n FILES 75 rm -rf $RPM_BUILD_ROOT%{_datadir}/locale 76 %endif 77 78 %clean 79 rm -rf $RPM_BUILD_ROOT 80 81 %post 82 %restart_fmri desktop-mime-cache icon-cache 83 84 %postun 85 %restart_fmri desktop-mime-cache 86 87 %files 88 %doc -d gDesklets-%{gdesklets.version} AUTHORS 89 %doc(bzip2) -d gDesklets-%{gdesklets.version} COPYING README NEWS ChangeLog 90 %dir %attr (0755, root, other) %{_datadir}/doc 91 %defattr (-, root, bin) 92 %dir %attr (0755, root, bin) %{_bindir} 93 %{_bindir}/* 94 %dir %attr (0755, root, bin) %{_libdir} 95 %{_libdir}/gdesklets 96 %dir %attr (0755, root, sys) %{_datadir} 97 %dir %attr (0755, root, other) %{_datadir}/applications 98 %{_datadir}/applications/*.desktop 99 %dir %attr (0755, root, other) %{_datadir}/pixmaps 100 %{_datadir}/pixmaps/* 101 %dir %attr (0755, root, bin) %{_mandir} 102 %{_mandir}/* 103 %dir %attr (0755, root, other) %{_datadir}/icons 104 %dir %attr (0755, root, other) %{_datadir}/icons/gnome 105 %dir %attr (0755, root, other) %{_datadir}/icons/gnome/48x48 106 %dir %attr (0755, root, other) %{_datadir}/icons/gnome/48x48/mimetypes 107 %{_datadir}/icons/gnome/48x48/mimetypes/* 108 109 %if %build_l10n 110 %files l10n 111 %defattr (-, root, bin) 112 %dir %attr (0755, root, sys) %{_datadir} 113 %attr (-, root, other) %{_datadir}/locale 114 %endif 115 116 %changelog 117 * Fri Jun 26 2009 - chris.wang@sun.com 118 - Change owner to jerrytan 119 * Fri Apr 3 2009 - laca@sun.com 120 - use desktop-cache instead of postrun 121 * Wed Sep 18 2008 - chris.wang@sun.com 122 - Update copyright 123 * Wed Jun 04 2008 - damien.carbery@sun.com 124 - Make %{_bindir}/gdesklets a relative symlink as absolute symlinks are not 125 permitted by Solaris WOS. 126 * Mon Oct 15 2007 - laca@sun.com 127 - make all files in the package readable 128 * Thu Oct 11 2007 - halton.huo@sun.com 129 - Use desktop-database-install.script for %post 130 and desktop-database-uninstall.script for %postun 131 * Thu Oct 11 2007 - halton.huo@sun.com 132 - Change the inline postinstall script to an include 133 * Thu Mar 22 2007 - halton.huo@sun.com 134 - Change %{_datadir}/icons/gnome/48x48/mimetypes attr to root:other. 135 * Thu Feb 8 2007 - damien.carbery@sun.com 136 - Update dependency list for files used in %post and during build. 137 * Mon Feb 5 2007 - damien.carbery@sun.com 138 - Set %dir %attr for icons dirs. 139 - Remove 'rm -rf $RPM_BUILD_ROOT' from %install as it is not needed. 140 * Thu Jan 29 2007 - <chris.wang@sun.com> 141 - initial creation 142 143