Home | History | Annotate | Download | only in trunk
      1 #
      2 # spec file for package SUNWgnome-desktop-prefs
      3 #
      4 # includes module(s): desktop-file-utils, control-center
      5 #
      6 # Copyright 2008 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 # Owner: dkenny
     11 #
     12 
     13 # NOTE: You must set up the OpenGL symlinks before building SUNWcompiz:
     14 #   #  /lib/svc/method/ogl-select start
     15 
     16 %include Solaris.inc
     17 
     18 %define with_hal %(pkginfo -q SUNWhal && echo 1 || echo 0)
     19 
     20 %use dfu = desktop-file-utils.spec
     21 %use cc = control-center.spec
     22 %use gsd = gnome-settings-daemon.spec
     23 
     24 Name:                    SUNWgnome-desktop-prefs
     25 Summary:                 GNOME desktop wide preference configuration tools
     26 Version:                 %{default_pkg_version}
     27 Source:                  %{name}-manpages-0.1.tar.gz
     28 # date:2007-11-07 bugster:6531454 owner:dkenny type:bug
     29 Patch1:                  control-center-01-passwd-in-terminal.diff
     30 SUNW_BaseDir:            %{_basedir}
     31 SUNW_Copyright:          %{name}.copyright
     32 BuildRoot:               %{_tmppath}/%{name}-%{version}-build
     33 
     34 %include default-depend.inc
     35 Requires: SUNWdbus-bindings
     36 Requires: SUNWevolution-data-server
     37 Requires: SUNWfontconfig
     38 Requires: SUNWfreetype2
     39 Requires: SUNWgnome-audio
     40 Requires: SUNWgnome-desktop-prefs-root
     41 Requires: SUNWgnome-base-libs
     42 Requires: SUNWgnome-config
     43 Requires: SUNWgnome-component
     44 Requires: SUNWgnome-panel
     45 Requires: SUNWgnome-file-mgr
     46 Requires: SUNWgnome-libs
     47 Requires: SUNWgnome-media
     48 Requires: SUNWgnome-vfs
     49 Requires: SUNWgnome-wm
     50 Requires: SUNWlibcanberra
     51 Requires: SUNWlibms
     52 Requires: SUNWlibpopt
     53 Requires: SUNWlxml
     54 Requires: SUNWpostrun
     55 Requires: SUNWxwxft
     56 Requires: SUNWbash
     57 %if %with_hal
     58 Requires: SUNWhal
     59 %endif
     60 # Depend on SUNWxorg-mesa on x86 for OpenGL support.
     61 %ifnarch sparc
     62 Requires: SUNWxorg-mesa
     63 %endif
     64 
     65 BuildRequires: SUNWgnome-audio-devel
     66 BuildRequires: SUNWgnome-media-devel
     67 BuildRequires: SUNWgnome-vfs-devel
     68 BuildRequires: SUNWlibcanberra-devel
     69 BuildRequires: SUNWlibpopt-devel
     70 BuildRequires: SUNWgnome-wm-devel
     71 %if %option_without_fox
     72 BuildRequires: SUNWxorg-headers
     73 %endif
     74 %if %option_with_dt
     75 BuildRequires: SUNWtltk
     76 %endif
     77 BuildRequires: SUNWevolution-data-server-devel
     78 BuildRequires: SUNWgnome-base-libs-devel
     79 BuildRequires: SUNWgnome-config-devel
     80 BuildRequires: SUNWgnome-component-devel
     81 BuildRequires: SUNWgnome-file-mgr-devel
     82 BuildRequires: SUNWgnome-panel-devel
     83 BuildRequires: SUNWgnome-libs-devel
     84 BuildRequires: SUNWdbus-bindings-devel
     85 
     86 %package root
     87 Summary:                 %{summary} - / filesystem
     88 SUNW_BaseDir:            /
     89 %include default-depend.inc
     90 Requires: SUNWpostrun-root
     91 Requires: SUNWgnome-config
     92 
     93 %package  devel
     94 Summary:                 %{summary} - development files
     95 SUNW_BaseDir:            %{_basedir}
     96 %include default-depend.inc
     97 Requires: SUNWgnome-desktop-prefs
     98 Requires: SUNWgamin
     99                                                                                 
    100 %if %build_l10n
    101 %package l10n
    102 Summary:                 %{summary} - l10n files
    103 SUNW_BaseDir:            %{_basedir}
    104 %include default-depend.inc
    105 Requires:                %{name}
    106 %endif
    107 
    108 %prep
    109 %ifnarch sparc
    110 # Testing that the OpenGL headers and libs are installed.
    111 # If this fails it means that the build machine is not properly configured
    112 test -f /usr/X11/include/GL/glx.h || {
    113   echo "Missing OpenGL headers. Stopping."
    114   echo "As root, run: \"/lib/svc/method/ogl-select start\""
    115   false
    116   }
    117 test -f /usr/X11/lib/modules/extensions/libglx.so  || {
    118   echo "Missing OpenGL libraries. Stopping."
    119   echo "As root, run: \"/lib/svc/method/ogl-select start\""
    120   false
    121   }
    122 %endif
    123 rm -rf %name-%version
    124 mkdir %name-%version
    125 %dfu.prep -d %name-%version
    126 %cc.prep -d %name-%version
    127 %gsd.prep -d %name-%version
    128 cd %{_builddir}/%name-%version
    129 gzcat %SOURCE0 | tar xf -
    130 cd %{_builddir}/%name-%version/%{cc.name}-%{cc.version}
    131 %patch1 -p1
    132 cd ..
    133 
    134 %build
    135 export CFLAGS="%optflags -I/usr/sfw/include -I/usr/X11/include -DGNOME_DESKTOP_USE_UNSTABLE_API"
    136 export RPM_OPT_FLAGS="$CFLAGS"
    137 PKG_CONFIG_DISABLE_UNINSTALLED=
    138 unset PKG_CONFIG_DISABLE_UNINSTALLED
    139 export PKG_CONFIG_PATH="../gnome-settings-daemon-%{gsd.version}/data:%{_pkg_config_path}"
    140 #FIXME: This stuff should be fixed in the component or the configure script
    141 export LDFLAGS="%_ldflags -L/usr/X11/lib -R/usr/X11/lib -L/usr/sfw/lib -R/usr/sfw/lib -lfreetype -lresolv"
    142 export EMACS=no
    143 
    144 %dfu.build -d %name-%version
    145 %gsd.build -d %name-%version
    146 %cc.build -d %name-%version
    147 
    148 %install
    149 rm -rf $RPM_BUILD_ROOT
    150 %dfu.install -d %name-%version
    151 export PATH=%{_builddir}/%name-%version/desktop-file-utils-%{dfu.version}/src:$PATH
    152 %cc.install -d %name-%version
    153 %gsd.install -d %name-%version
    154 
    155 rm -rf $RPM_BUILD_ROOT%{_mandir}
    156 cd %{_builddir}/%name-%version/sun-manpages
    157 make install DESTDIR=$RPM_BUILD_ROOT
    158 
    159 # FIXME: Remove %{_datadir}/mime until clash with SUNWgnome-vfs resolved.
    160 rm -r $RPM_BUILD_ROOT%{_datadir}/mime
    161 
    162 %if %build_l10n
    163 %else
    164 # REMOVE l10n FILES
    165 rm -rf $RPM_BUILD_ROOT%{_datadir}/locale
    166 %endif
    167 
    168 %{?pkgbuild_postprocess: %pkgbuild_postprocess -v -c "%{version}:%{jds_version}:%{name}:$RPM_ARCH:%(date +%%Y-%%m-%%d):%{support_level}" $RPM_BUILD_ROOT}
    169 
    170 %clean
    171 rm -rf $RPM_BUILD_ROOT
    172 
    173 # This package includes update-desktop-database but keeping this postrun
    174 # script the same as the ones in other packages so that it only runs once
    175 # for all pkgs (postrun -u option)
    176 %post
    177 ( echo 'test -x /usr/bin/update-desktop-database || exit 0';
    178   echo '/usr/bin/update-desktop-database'
    179 ) | $BASEDIR/lib/postrun -b -u -c JDS_wait
    180 ( echo 'test -x /usr/bin/scrollkeeper-update || exit 0';
    181   echo '/usr/bin/scrollkeeper-update'
    182 ) | $BASEDIR/lib/postrun -b -u -c JDS
    183 
    184 %postun
    185 test -x $BASEDIR/lib/postrun || exit 0
    186 ( echo 'test -x /usr/bin/scrollkeeper-update || exit 0';
    187   echo '/usr/bin/scrollkeeper-update'
    188 ) | $BASEDIR/lib/postrun -b -u -c JDS
    189 
    190 %post root
    191 %include gconf-install.script
    192 
    193 %preun root
    194 test -x $BASEDIR/var/lib/postrun/postrun || exit 0
    195 ( echo 'test -x $PKG_INSTALL_ROOT/usr/bin/gconftool-2 || {';
    196   echo '  echo "WARNING: gconftool-2 not found; not uninstalling gconf schemas"';
    197   echo '  exit 0';
    198   echo '}';
    199   echo 'umask 0022';
    200   echo 'GCONF_CONFIG_SOURCE=xml:merged:$BASEDIR/etc/gconf/gconf.xml.defaults';
    201   echo 'GCONF_BACKEND_DIR=$PKG_INSTALL_ROOT/usr/lib/GConf/2';
    202   echo 'LD_LIBRARY_PATH=$PKG_INSTALL_ROOT/usr/lib';
    203   echo 'export GCONF_CONFIG_SOURCE GCONF_BACKEND_DIR LD_LIBRARY_PATH';
    204   echo 'SDIR=$BASEDIR%{_sysconfdir}/gconf/schemas';
    205   echo 'schemas="$SDIR/apps_gnome_settings_daemon_keybindings.schemas';
    206   echo '         $SDIR/apps_gnome_settings_daemon_screensaver.schemas';
    207   echo '         $SDIR/control-center.schemas';
    208   echo '         $SDIR/apps_gnome_settings_daemon_xrandr.schemas';
    209   echo '         $SDIR/desktop_gnome_font_rendering.schemas"';
    210   echo '$PKG_INSTALL_ROOT/usr/bin/gconftool-2 --makefile-uninstall-rule $schemas'
    211 ) | $BASEDIR/var/lib/postrun/postrun -i -c JDS -a
    212 
    213 %files
    214 %defattr (-, root, bin)
    215 %dir %attr (0755, root, bin) %{_bindir}
    216 %{_bindir}/*
    217 %dir %attr (0755, root, bin) %{_libdir}
    218 %{_libdir}/lib*.so*
    219 %{_libdir}/window-manager-settings/*.so
    220 %{_libdir}/gnome-settings-daemon-2.0
    221 %{_libexecdir}/gnome-settings-daemon
    222 %dir %attr (0755, root, sys) %{_datadir}
    223 %dir %attr (0755, root, other) %{_datadir}/applications
    224 %{_datadir}/applications/*.desktop
    225 %if %is_s10
    226 %dir %attr (-, root, other) %{_datadir}/control-center
    227 %{_datadir}/control-center/*
    228 %else
    229 %{_datadir}/gnome-control-center
    230 %{_datadir}/gnome-settings-daemon
    231 %endif
    232 %{_datadir}/desktop-directories
    233 %{_datadir}/dbus-1
    234 %dir %attr (0755, root, other) %{_datadir}/gnome
    235 %{_datadir}/gnome/*
    236 %attr (-, root, other) %{_datadir}/icons
    237 %{_datadir}/omf
    238 #%dir %attr (0755, root, other) %{_datadir}/pixmaps
    239 #%{_datadir}/pixmaps/*
    240 %dir %attr(0755, root, bin) %{_mandir}
    241 %dir %attr(0755, root, bin) %{_mandir}/*
    242 %{_mandir}/*/*
    243 
    244 %files devel
    245 %defattr (-, root, bin)
    246 %dir %attr (0755, root, bin) %{_libdir}
    247 %dir %attr (0755, root, other) %{_libdir}/pkgconfig
    248 %{_libdir}/pkgconfig/*
    249 %dir %attr (0755, root, sys) %{_datadir}
    250 %dir %attr (0755, root, bin) %{_datadir}/pkgconfig
    251 %{_datadir}/pkgconfig/*
    252 %dir %attr (0755, root, bin) %{_includedir}
    253 %{_includedir}/*
    254 
    255 %files root
    256 %defattr (-, root, sys)
    257 %attr (0755, root, sys) %dir %{_sysconfdir}
    258 %{_sysconfdir}/gconf/schemas/apps_gnome_settings_daemon_keybindings.schemas
    259 %{_sysconfdir}/gconf/schemas/apps_gnome_settings_daemon_screensaver.schemas
    260 %{_sysconfdir}/gconf/schemas/apps_gnome_settings_daemon_xrandr.schemas
    261 %{_sysconfdir}/gconf/schemas/control-center.schemas
    262 %{_sysconfdir}/gconf/schemas/gnome-settings-daemon.schemas
    263 %{_sysconfdir}/gconf/schemas/desktop_gnome_font_rendering.schemas
    264 %{_sysconfdir}/xdg
    265 
    266 %if %build_l10n
    267 %files l10n
    268 %defattr (-, root, bin)
    269 %dir %attr (0755, root, sys) %{_datadir}
    270 %attr (-, root, other) %{_datadir}/locale
    271 %endif
    272 
    273 %changelog
    274 * Tue Aug 05 2008 - damien.carbery@sun.com
    275 - Add apps_gnome_settings_daemon_xrandr.schemas to %post and %files. Remove
    276   hack that created mimeinfo.cache - it is not needed because gnome-vfs is
    277   obsolete now.
    278 * Mon Aug 04 2008 - ghee.teo@sun.com
    279 - Removed control-center-01-solaris-printmgr.diff now that the Presto's
    280   print manager is integrated into vermillion.
    281 * Sat Jul 26 2008 - damien.carbery (at] sun.com
    282 - Create mimeinfo.cache because build breaking with /dev/null in proto. Remove
    283   fontilus.schemas from %post and %files as it is not installed. Also remove
    284   %{_sysconfdir}/gnome-vfs-2.0 from %files as it is not installed either.
    285 * Fri Jul 25 2008 - damien.carbery (at] sun.com
    286 - Update %files, removing %{_libdir}/gnome-vfs-2.0/modules/*.so and
    287   %{_libdir}/nautilus.
    288 * Thu Jun 05 2008 - damien.carbery (at] sun.com
    289 - Remove themus.schemas as it is no longer installed.
    290 * Wed May 21 2008 - damien.carbery (at] sun.com
    291 - Add 'Requires: SUNWxorg-mesa' to base package to fix #6705123.
    292 * Wed Apr 16 - damien.carbery (at] sun.com
    293 - Add Requires SUNWgamin to devel package. Mentioned in #6688818.
    294 * Mon Apr 07 - damien.carbery (at] sun.com
    295 - Change OpenGL check to only happen on x86.
    296 * Wed Apr 02 - damien.carbery (at] sun.com
    297 - Copy in changes from gnome-2-20 branch: break the build if the openGL headers
    298   and libraries are not present on the machine.
    299 * Wed Mar 12 2008 - damien.carbery (at] sun.com
    300 - Update %files for new tarball.
    301 * Tue Feb 26 2008 - brian.cameron (at] sun.com
    302 - Now gnome-settings-daemon depends on gnome-desktop in the SUNWgnome-panel
    303   package.  So add this dependency.
    304 * Fri Feb 15 2008 - damien.carbery (at] sun.com
    305 - Remove obsolete sparc patches, 02-sun-volume-keys and 03-sun-help-key.
    306   Renumber rest.
    307 * Fri Feb 15 2008 - damien.carbery (at] sun.com
    308 - Add Build/Requires SUNWdbus-bindings/-devel; Update %files for new location
    309   of plugins.
    310 * Tue Jan 29 2008 - damien.carbery (at] sun.com
    311 - Add -DGNOME_DESKTOP_USE_UNSTABLE_API to CFLAGS to get it to build.
    312 * Wed Jan 23 2008 - damien.carbery (at] sun.com
    313 - Set PKG_CONFIG_PATH to find the gnome-settings-daemon uninstalled.pc file.
    314 * Wed Jan 23 2008 - darren.kenny (at] sun.com
    315 - Move gnome-settings-daemon into it's own spec file to match project
    316   structures.
    317 * Thu Jan  3 2008 - laca@sun.com
    318 - use gconf-install.script instead of an inline script
    319 * Wed Nov 07 2007 - darren.kenny@sun.com
    320 - Add new patch control-center-04-passwd-in-terminal.diff
    321 - This is a tempoary fix for Bug#6531454 - using gnome-terminal & passwd - the
    322   correct fix depends on ON RFE 6627014 being implemented.
    323 * Tue Oct 30 2007 - laca@sun.com
    324 - s/without_java/with_java
    325 * Mon Oct  1 2007 - laca@sun.com
    326 - move export EMACS=no to %build from %prep and delete emacs dir from %files
    327 * Mon Oct  1 2007 - damien.carbery@sun.com
    328 - Add %{_datadir}/emacs to %files.
    329 * Fri Sep 28 2007 - laca@sun.com
    330 - add support to build on FOX instead of Nevada X
    331 - disable emacs support
    332 * Wed Sep 05 2007 - darren.kenny@sun.com
    333 - Bump to 2.19.92
    334 - Update files sections for new version.
    335 * Tue Apr 24 2007 - laca@sun.com
    336 - s/0755/-/ in defattr so that files are not made all executable
    337 * Thu Mar 15 2007 - damien.carbery@sun.com
    338 - Add Requires SUNWbash after check-deps.pl run.
    339 * Wed Feb 14 2007 - damien.carbery@sun.com
    340 - Update %files for new tarball.
    341 * Thu Feb  8 2007 - takao.fujiwara@sun.com
    342 - Update control-center-01-solaris-printmgr.diff for SUN_BRANDING
    343 * Sun Jan 28 2007 - laca@sun.com
    344 - update dir attributes so they work on both s10 and nevada
    345 * Wed Jan 24 2007 - damien.carbery@sun.com
    346 - Add %{_datadir}/icons to %files.
    347 * Tue Dec 19 2006 - ghee.teo@sun.com
    348 - Replace the script, solaris-printmgr-wrappper to use gksu instead of sticking
    349   with the old CDE action script.
    350 * Thu Dec 07 2006 - damien.carbery@sun.com
    351 - Remove schema file from %preun root and %files as it is no longer in the 
    352   control-center module. Remove icons dir from %files as they are not installed.
    353 * Fri Oct 20 2006 - damien.carbery@sun.com
    354 - Remove SUNWhalh BuildRequires because header files are in SUNWhea in snv_51.
    355 * Mon Sep 18 2006 - brian.cameron@sun.com
    356 - Add SUNWhalh BuildRequires
    357 * Tue Sep 05 2006 - brian.cameron@sun.com
    358 - Now check for HAL so we can use --enable/disable-hal as appropriate in 
    359   the control-center.spec file.  Remove panel dependency now that we no
    360   longer link against libxklavier.
    361 * Fri Sep 01 2006 - Matt.Keenan@sun.com
    362 - New Manpage tarball
    363 * Sat Aug 12 2006 - laca@sun.com
    364 - delete some unnecessary env variables
    365 * Sat Aug 12 2006 - laca@sun.com
    366 - change datadir/icons permissions back to root:other since it's a stable
    367   interface and wasn't supposed to be changed
    368 * Fri Jul 14 2006 - laca@sun.com
    369 - update %post/%postun/etc scripts to support diskless client setup,
    370   part of 6448317
    371 * Wed Jul 12 2006 - laca@sun.com
    372 - set correct attributes for mimeinfo.cache, fixes #6431057
    373 * Thu Jun 29 2006 - laca@sun.com
    374 - update postrun scripts
    375 * Fri Jun 23 2006 - christopher.hanna@sun.com
    376 - removed manpages not needed: gnome-file-types-properties and gnome-settings-daemon
    377 * Sun Jun 11 2006 - laca@sun.com
    378 - change group from other to bin/sys
    379 * Thu May 25 2006 - laca@sun.com
    380 - use post/preun scripts to install schemas into the merged gconf files
    381 * Wed May 10 2006 - laca@sun.com
    382 - merge -share pkg(s) into the base pkg(s)
    383 * Tue Apr 18 2006 - damien.carbery@sun.com
    384 - Add desktop-directories directory.
    385 * Wed Apr 05 2006 - glynn.foster@sun.com
    386 - Remove screensaver hack since xscreensaver installs into the
    387   right location.
    388 * Tue Feb 21 2006 - damien.carbery@sun.com
    389 - Add X packages to Requires after running check-deps.pl script.
    390 * Mon Feb 20 2006 - damien.carbery@sun.com
    391 - Complete update of Build/Requires after running check-deps.pl script.
    392 * Thu Feb 16 2006 - damien.carbery@sun.com
    393 - Update Build/Requires after running check-deps.pl script.
    394 * Thu Jan 19 2006 - brian.cameron@sun.com
    395 - Added %{_datadir}/gnome-default-applications to share package.
    396 * Sat Dec  3 2005 - laca@sun.com
    397 - add %post script that runs update-desktop-database
    398 * Thu Dec 01 2005 - damien.carbery@sun.com
    399 - Add Build/Requires SUNWevolution-data-server/-devel for libebook dependency.
    400 * Tue Jul 19 2005 - damien.carbery@sun.com
    401 - Add BuildRequires SUNWtltk because build was breaking without that package.
    402 * Wed Jul 13 2005 - brian.cameron@sun.com
    403 - Added SUNWgnome-panel dependency
    404 * Thu Jun 02 2005 - brian.cameron@sun.com
    405 - Bumped to 2.10, fixed packaging.
    406 * Tue Oct 26 2004 - srirama.sharma@wipro.com
    407 - Added patch control-center-03-sun-help-key.diff (to sparc only) to bind the 
    408   Sun help key to launch default help with Sun tpe Keyboards. Fixes the bugtraq
    409   bug#6182405.
    410 * Tue Oct 19 2004 - srirama.sharma@wipro.com
    411 - Added patch control-center-02-sun-volume-keys.diff (to sparc only) to bind 
    412   Sun keys Volume up, Volume Down and Volume Mute to control volume with Sun type
    413   keyboards. Fixes bugtraq bug#6173921.
    414 * Sat Oct 02 2004 - laca@sun.com
    415 - added %pkgbuild_postprocess
    416 * Sat Sep 11 2004 - laca@sun.com
    417 - Set LDFLAGS so Xrandr and Xrender can be found.
    418 * Thu Sep 09 2004 - matt.keenan@sun.com
    419 - Added gnome-at-properties.1, gnome-font-viewer.1 manpages
    420 * Wed Aug 18 2004 - damien.carbery@sun.com
    421 - Change manpage perms for Solaris integration.
    422 * Fri Aug  6 2004 - danek.duvall@sun.com
    423 - Add support for running the Solaris Print Manager (as root)
    424 * Tue Jul 13 2004 - damien.carbery@sun.com
    425 - Create symlink to screensaver-properties.desktop in capplets dir to fix
    426   bug 5070633.
    427 * Tue Jun 22 2004 - shirley.woo@sun.com
    428 - changed install location to /usr/lib and /usr/bin
    429 * Wed Jun  2 2004 - takao.fujiwara@sun.com
    430 - Added %{_datadir}/locale to install l10n messages
    431 * Wed Mar 24 2004 - brian.cameron@sun.com
    432 - Added SGML man page integration
    433 * Tue Mar 02 2004 - niall.power@sun.com
    434 - add {_libdir}/window-manager-settings
    435 * Mon Mar 01 2004 - laca@sun.com
    436 - remove libxklavier
    437 - add dependency on SUNWgnome-wm
    438 * Mon Feb 23 2004 - Niall.Power@sun.com
    439 - install gconf schemas at the end of the install
    440   stage.
    441 * Thu Feb 19 2004 - Niall.Power@sun.com
    442 - initial Solaris spec file
    443