Home | History | Annotate | Download | only in trunk
      1 #
      2 # spec file for package SUNWgnome-file-mgr
      3 #
      4 # includes module(s): eel, nautilus, gnome-mount,
      5 #                     gnome-volume-manager
      6 #
      7 # Copyright 2008 Sun Microsystems, Inc.
      8 # This file and all modifications and additions to the pristine
      9 # package are under the same license as the package itself.
     10 #
     11 # Owner: stephen
     12 
     13 %include Solaris.inc
     14 
     15 %define with_hal %(pkginfo -q SUNWhal && echo 1 || echo 0)
     16 
     17 %use eel = eel.spec
     18 %use nautilus = nautilus.spec
     19 %use open_terminal= nautilus-open-terminal.spec
     20 
     21 %if %with_hal
     22 %use gmount = gnome-mount.spec
     23 %use gvm = gnome-volume-manager.spec
     24 %endif
     25 
     26 Name:                    SUNWgnome-file-mgr
     27 Summary:                 GNOME file manager
     28 Version:                 %{default_pkg_version}
     29 Source:                  %{name}-manpages-0.1.tar.gz
     30 SUNW_BaseDir:            %{_basedir}
     31 SUNW_Copyright:          %{name}.copyright
     32 BuildRoot:               %{_tmppath}/%{name}-%{version}-build
     33 
     34 %include default-depend.inc
     35 BuildRequires: SUNWgnome-component-devel
     36 BuildRequires: SUNWlibrsvg-devel
     37 BuildRequires: SUNWgnome-audio-devel
     38 BuildRequires: SUNWlibexif-devel
     39 BuildRequires: SUNWlibpopt-devel
     40 BuildRequires: SUNWgnome-libs-devel
     41 BuildRequires: SUNWgnome-vfs-devel
     42 BuildRequires: SUNWgnome-base-libs-devel
     43 BuildRequires: SUNWgnome-config-devel
     44 BuildRequires: SUNWgnome-panel-devel
     45 BuildRequires: SUNWgnome-print-devel
     46 Requires: SUNWgnome-file-mgr-root
     47 Requires: SUNWgnome-libs
     48 Requires: SUNWgnome-vfs
     49 Requires: SUNWgnome-base-libs
     50 Requires: SUNWgnome-config
     51 Requires: SUNWgnome-panel
     52 Requires: SUNWgnome-print
     53 Requires: SUNWgnome-audio
     54 Requires: SUNWgnome-component
     55 Requires: SUNWlibexif
     56 Requires: SUNWlibms
     57 Requires: SUNWlibpopt
     58 Requires: SUNWlibrsvg
     59 Requires: SUNWperl584usr
     60 Requires: SUNWbzip
     61 Requires: SUNWzlib
     62 Requires: SUNWlxml
     63 Requires: SUNWpostrun
     64 %if %with_hal
     65 Requires: SUNWhal
     66 %endif
     67 
     68 %package root
     69 Summary:                 %{summary} - / filesystem
     70 SUNW_BaseDir:            /
     71 %include default-depend.inc
     72 Requires: SUNWpostrun-root
     73 Requires: SUNWgnome-config
     74 
     75 %package devel
     76 Summary:                 %{summary} - development files
     77 SUNW_BaseDir:            %{_basedir}
     78 %include default-depend.inc
     79 
     80 %if %build_l10n
     81 %package l10n
     82 Summary:                 %{summary} - l10n files
     83 SUNW_BaseDir:            %{_basedir}
     84 %include default-depend.inc
     85 Requires:                %{name}
     86 %endif
     87 
     88 %prep
     89 rm -rf %name-%version
     90 mkdir %name-%version
     91 %eel.prep -d %name-%version
     92 %nautilus.prep -d %name-%version
     93 %open_terminal.prep -d %name-%version
     94 
     95 %if %with_hal
     96 %gmount.prep -d %name-%version
     97 %gvm.prep -d %name-%version
     98 %endif
     99 cd %{_builddir}/%name-%version
    100 gzcat %SOURCE0 | tar xf -
    101 
    102 %build
    103 PKG_CONFIG_DISABLE_UNINSTALLED=
    104 unset PKG_CONFIG_DISABLE_UNINSTALLED
    105 
    106 export PKG_CONFIG_PATH=../eel-%{eel.version}:../nautilus-%{nautilus.version}/libnautilus-extension:%{_pkg_config_path}
    107 export CFLAGS="%optflags -I%{_includedir} -DGNOME_DESKTOP_USE_UNSTABLE_API"
    108 export RPM_OPT_FLAGS="$CFLAGS"
    109 export LDFLAGS="%_ldflags"
    110 export ACLOCAL_FLAGS="-I /usr/share/aclocal"
    111 
    112 %eel.build -d %name-%version
    113 %nautilus.build -d %name-%version
    114 %open_terminal.build -d %name-%version
    115 
    116 %if %with_hal
    117 export LDFLAGS="%_ldflags -L/usr/X11/lib -R/usr/X11/lib -lX11 -lresolv"
    118 %gmount.build -d %name-%version
    119 %gvm.build -d %name-%version
    120 %endif
    121 
    122 %install
    123 rm -rf $RPM_BUILD_ROOT
    124 %eel.install -d %name-%version
    125 %nautilus.install -d %name-%version
    126 %open_terminal.install -d %name-%version
    127 
    128 %if %with_hal
    129 %gmount.install -d %name-%version
    130 %gvm.install -d %name-%version
    131 %endif
    132 
    133 rm -rf $RPM_BUILD_ROOT%{_mandir}
    134 cd %{_builddir}/%name-%version/sun-manpages
    135 make install DESTDIR=$RPM_BUILD_ROOT
    136 
    137 # generated in the postinstall scripts (update-mime-database)
    138 rm -rf $RPM_BUILD_ROOT%{_datadir}/mime
    139 
    140 %if %build_l10n
    141 %else
    142 # REMOVE l10n FILES
    143 rm -rf $RPM_BUILD_ROOT%{_datadir}/locale
    144 %endif
    145 
    146 %{?pkgbuild_postprocess: %pkgbuild_postprocess -v -c "%{version}:%{jds_version}:%{name}:$RPM_ARCH:%(date +%%Y-%%m-%%d):%{support_level}" $RPM_BUILD_ROOT}
    147 
    148 %clean
    149 rm -rf $RPM_BUILD_ROOT
    150 
    151 %post
    152 ( echo 'test -x /usr/bin/update-desktop-database || exit 0';
    153   echo '/usr/bin/update-desktop-database'
    154 ) | $BASEDIR/lib/postrun -b -u -c JDS_wait
    155 ( echo 'test -x %{_bindir}/update-mime-database || exit 0';
    156   echo '%{_bindir}/update-mime-database %{_datadir}/mime'
    157 ) | $BASEDIR/lib/postrun -b -u -c JDS_wait
    158 
    159 %postun
    160 test -x $BASEDIR/lib/postrun || exit 0
    161 ( echo 'test -x /usr/bin/update-desktop-database || exit 0';
    162   echo '/usr/bin/update-desktop-database'
    163 ) | $BASEDIR/lib/postrun -b -u -c JDS
    164 ( echo 'test -x %{_bindir}/update-mime-database || exit 0';
    165   echo '%{_bindir}/update-mime-database %{_datadir}/mime'
    166 ) | $BASEDIR/lib/postrun -b -u -c JDS
    167 
    168 %post root
    169 %include gconf-install.script
    170 
    171 %preun root
    172 test -x $BASEDIR/var/lib/postrun/postrun || exit 0
    173 ( echo 'test -x $PKG_INSTALL_ROOT/usr/bin/gconftool-2 || {';
    174   echo '  echo "WARNING: gconftool-2 not found; not uninstalling gconf schemas"';
    175   echo '  exit 0';
    176   echo '}';
    177   echo 'umask 0022';
    178   echo 'GCONF_CONFIG_SOURCE=xml:merged:$BASEDIR/etc/gconf/gconf.xml.defaults';
    179   echo 'GCONF_BACKEND_DIR=$PKG_INSTALL_ROOT/usr/lib/GConf/2';
    180   echo 'LD_LIBRARY_PATH=$PKG_INSTALL_ROOT/usr/lib';
    181   echo 'export GCONF_CONFIG_SOURCE GCONF_BACKEND_DIR LD_LIBRARY_PATH';
    182   echo 'SDIR=$BASEDIR%{_sysconfdir}/gconf/schemas';
    183 %if %with_hal
    184   echo 'schemas="$SDIR/apps_nautilus_preferences.schemas';
    185   echo '         $SDIR/gnome-mount.schemas';
    186   echo '         $SDIR/gnome-volume-control.schemas"';
    187 %else
    188   echo 'schemas="$SDIR/apps_nautilus_preferences.schemas';
    189   echo '         $SDIR/nautilus-open-terminal.schemas"';
    190 %endif
    191   echo '$PKG_INSTALL_ROOT/usr/bin/gconftool-2 --makefile-uninstall-rule $schemas'
    192 ) | $BASEDIR/var/lib/postrun/postrun -i -c JDS -a
    193 
    194 %files
    195 %defattr (-, root, bin)
    196 %dir %attr (0755, root, bin) %{_bindir}
    197 %{_bindir}/*
    198 %dir %attr (0755, root, bin) %{_libdir}
    199 %{_libdir}/bonobo/servers
    200 %{_libdir}/nautilus/extensions-2.0/*.so
    201 %{_libdir}/lib*.so*
    202 %if %with_hal
    203 %{_libexecdir}/gnome-volume-manager
    204 %endif
    205 %dir %attr (0755, root, sys) %{_datadir}
    206 %dir %attr (0755, root, other) %{_datadir}/applications
    207 %{_datadir}/applications/*
    208 %if %with_hal
    209 %dir %attr (0755, root, other) %{_datadir}/gnome-mount
    210 %{_datadir}/gnome-mount/*
    211 %dir %attr (0755, root, other) %{_datadir}/gnome-volume-manager
    212 %{_datadir}/gnome-volume-manager/*
    213 %endif
    214 %{_datadir}/gtk-doc
    215 %dir %attr (-, root, other) %{_datadir}/icons
    216 %dir %attr (-, root, other) %{_datadir}/icons/hicolor
    217 %dir %attr (-, root, other) %{_datadir}/icons/hicolor/16x16
    218 %dir %attr (-, root, other) %{_datadir}/icons/hicolor/16x16/apps
    219 %{_datadir}/icons/hicolor/16x16/apps/nautilus.png
    220 %dir %attr (-, root, other) %{_datadir}/icons/hicolor/22x22
    221 %dir %attr (-, root, other) %{_datadir}/icons/hicolor/22x22/apps
    222 %{_datadir}/icons/hicolor/22x22/apps/nautilus.png
    223 %dir %attr (-, root, other) %{_datadir}/icons/hicolor/24x24
    224 %dir %attr (-, root, other) %{_datadir}/icons/hicolor/24x24/apps
    225 %{_datadir}/icons/hicolor/24x24/apps/nautilus.png
    226 %dir %attr (-, root, other) %{_datadir}/icons/hicolor/32x32
    227 %dir %attr (-, root, other) %{_datadir}/icons/hicolor/32x32/apps
    228 %{_datadir}/icons/hicolor/32x32/apps/nautilus.png
    229 %dir %attr (-, root, other) %{_datadir}/icons/hicolor/scalable
    230 %dir %attr (-, root, other) %{_datadir}/icons/hicolor/scalable/apps
    231 %{_datadir}/icons/hicolor/scalable/apps/nautilus.svg
    232 %{_datadir}/nautilus
    233 %dir %attr (0755, root, other) %{_datadir}/pixmaps
    234 %{_datadir}/pixmaps/*
    235 %dir %attr(0755, root, bin) %{_mandir}
    236 %dir %attr(0755, root, bin) %{_mandir}/*
    237 %{_mandir}/*/*
    238 
    239 %files root
    240 %defattr (-, root, sys)
    241 %attr (0755, root, sys) %dir %{_sysconfdir}
    242 %{_sysconfdir}/gconf/schemas/apps_nautilus_preferences.schemas
    243 %{_sysconfdir}/gconf/schemas/nautilus-open-terminal.schemas
    244 %if %with_hal
    245 %{_sysconfdir}/gconf/schemas/gnome-mount.schemas
    246 %{_sysconfdir}/gconf/schemas/gnome-volume-manager.schemas
    247 %{_sysconfdir}/xdg
    248 %endif
    249 
    250 %files devel
    251 %defattr (-, root, bin)
    252 %dir %attr (0755, root, bin) %{_includedir}
    253 %{_includedir}/*
    254 %dir %attr (0755, root, bin) %{_libdir}
    255 %dir %attr (0755, root, other) %{_libdir}/pkgconfig
    256 %{_libdir}/pkgconfig/*
    257 
    258 %if %build_l10n
    259 %files l10n
    260 %defattr (-, root, bin)
    261 %dir %attr (0755, root, sys) %{_datadir}
    262 %attr (-, root, other) %{_datadir}/locale
    263 %endif
    264 
    265 %changelog
    266 * Wed Jun 04 2008 - damien.carbery@sun.com
    267 - Update %files (add %{_datadir}/gtk-doc).
    268 * Thu May 01 2008 - damien.carbery@sun.com
    269 - Update %files (remove %{_datadir}/gnome and add %{_sysconfdir}/xdg) after
    270   bumping gnome-volume-manager.
    271 * Fri Feb 29 2008 - damien.carbery@sun.com
    272 - Add nautilus-open-terminal.schemas to %files and %preun root.
    273 * Tue Jan 29 2008 - damien.carbery@sun.com
    274 - Add -DGNOME_DESKTOP_USE_UNSTABLE_API to CFLAGS to get it to build.
    275 * Thu Jan 17 2008 - damien.carbery@sun.com
    276 - Set ACLOCAL_FLAGS to pick up the modified intltool.m4.
    277 * Fri Jan 11 2008 - padraig.obriain@sun.com
    278 - Change extensions directory to extensions-2.0
    279 * Thu Jan  3 2008 - laca@sun.com
    280 - use gconf-install.script instead of an inline script
    281 * Fri Sep 28 2007 - laca@sun.com
    282 - delete Nevada X dep
    283 * Wed Sep 05 2007 - damien.carbery@sun.com
    284 - Remove references to SUNWgnome-a11y-base-libs as its contents have been
    285   moved to SUNWgnome-base-libs.
    286 * Tue Apr 24 2007 - laca@sun.com
    287 - s/0755/-/ in defattr so that files are not made all executable
    288 * Tue Dec 19 2006 - damien.carbery@sun.com
    289 - Update %files for new graphics files.
    290 * Fri Oct 20 2006 - damien.carbery@sun.com
    291 - Remove SUNWhalh BuildRequires because header files are in SUNWhea in snv_51.
    292 * Mon Sep 18 2006 - Brian.Cameron@sun.com
    293 - Add SUNWhalh BuildRequires.
    294 * Fri Sep 01 2006 - Matt.Keenan@sun.com
    295 - New Manpage tarball
    296 * Mon Aug 14 2006 - damien.carbery@sun.com
    297 - Add Build/Requires SUNWhal after check-deps.pl run.
    298 * Sat Aug 12 2006 - laca@sun.com
    299 - delete some unnecessary env variables
    300 * Thu Jul 25 2006 - brian.cameron@sun.com
    301 - Add gnome-volume-manager and gnome-mount for HAL integration.
    302 * Fri Jul 14 2006 - laca@sun.com
    303 - update %post/%postun/etc scripts to support diskless client setup,
    304   part of 6448317
    305 * Thu Jun 29 2006 - laca@sun.com
    306 - update postrun scripts
    307 * Sun Jun 11 2006 - laca@sun.com
    308 - change group from other to bin/sys
    309 * Thu Jun  1 2006 - laca@sun.com
    310 - use post/preun scripts to install schemas into the merged gconf files
    311 * Wed May 10 2006 - laca@sun.com
    312 - merge -share pkg(s) into the base pkg(s)
    313 * Mon Feb 20 2006 - damien.carbery@sun.com
    314 - Update Build/Requires after running check-deps.pl script.
    315 * Mon Jan 09 2006 - damien.carbery@sun.com
    316 - Delete mime dir structure.
    317 * Sat Dec  3 2005 - laca@sun.com
    318 - add %post script that runs update-desktop-database
    319 * Thu Jul 28 2005 - damien.carbery@sun.com
    320 - Add SUNWlibrsvg-devel build dependency. Add SUNWlibrsvg runtime dependency.
    321 * Thu Jun 02 2005 - brian.cameron
    322 - Bumped to 2.10, fixed packaging.
    323 * Sat Oct 02 2004 - laca@sun.com
    324 - added %pkgbuild_postprocess
    325 * Thu Sep 09 2004 - matt.keenan@sun.com
    326 - Added nautlius-file-management-properties.1 manpage
    327 * Mon Aug 23 2004 - laca@sun.com
    328 - s/SUNWpl5u/SUNWperl584usr/
    329 * Wed Aug 18 2004 - damien.carbery@sun.com
    330 - Change manpage perms for Solaris integration.
    331 * Tue Jul 27 2004 - damien.carbery@sun.com
    332 - Add SUNWgnome-component-devel as BuildRequires, for ORBit-2.0.
    333 * Sat Jun 26 2004 - shirley.woo@sun.com
    334 - Changed install location to /usr/...
    335 * Mon Jun 07 2004 - brian.cameron@sun.com
    336 - Added SUNWlibexif dependency, then removed it since it is alrady
    337   a dependency of SUNWgnome-libs.
    338 * Wed Jun 02 2004 - takao.fujiwara@sun.com
    339 - Added %{_datadir}/locale to install l10n messages
    340 * Thu May 20 2004 - brian.cameron@sun.com
    341 - Added man page to share package.
    342 * Thu May 13 2004 - brian.cameron@sun.com
    343 - Removed %{_libdir}/nautilus-*-helper from packages since Glynn
    344   removed these files that were added via ext-sources on May 5th.
    345 * Fri Apr 30 2004 - niall.power@sun.com
    346 - adjust %files for new nautilus version
    347 * Fri Mar 26 2004 - laca@sun.com
    348 - fix %files for libexecdir change
    349 * Wed Mar 24 2004 - brian.cameron@sun.com
    350 - Added SGML man page integration
    351 * Mon Mar 01 2004 - laca@sun.com
    352 - remove dependencies on SUNWgnome-libs-root and -share
    353 * Thu Feb 26 2004 - niall.power@sun.com
    354 - remove clashing (and empty gconf.xml files) after schema installation
    355 - add "-R%{_libdir}" to LDFLAGS
    356 - define PERL5LIB for XML::Parser
    357 - add a defattr for %package devel
    358 * Mon Feb 23 2004 - niall.power@sun.com
    359 - install gconf schemas at the end of the install stage
    360 * Wed Feb 18 2004 - niall.power@sun.com
    361 - removed gnome-desktop as it's provided by the panel pkgs now.
    362 - removed rsvg man pages from file maps + tidy up
    363 - removed unnecessary exported CFLAGS
    364 * Wed Feb 18 2004 - laca (at] sun.com
    365 - moved librsvg to SUNWgnome-libs as it is required by other modules as well
    366 * Mon Feb 16 2004 - niall.power (at] sun.com
    367 - initial spec file created
    368