File gconf2-branding-SLES.spec of Package gconf2-branding-openSUSE

# spec file for package gconf2-branding-SLES (Version 2.24)
# Copyright (c) 2008 SUSE LINUX Products GmbH, Nuernberg, Germany.
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.

# Please submit bugfixes or comments via

# norootforbuild

%define         build_openSUSE 0
%define         build_SLED 0
%define         build_SLES 1
%if %build_openSUSE
%define         branding_name openSUSE
%define         desktop_data  openSUSE
%define         desktop_data_ver  11.1
%if %build_SLED
%define         branding_name SLED
%define         desktop_data  SLED
%define         desktop_data_ver  11
%if %build_SLES
%define         branding_name SLES
%define         desktop_data  SLED
%define         desktop_data_ver  11
# Do not edit this auto generated file! Edit

Name:           gconf2-branding-SLES
License:        BSD 3-Clause
Group:          System/GUI/GNOME
Summary:        SLES defaults for the GNOME configuration system
Version:        2.24
Release:        13
BuildArch:      noarch
BuildRoot:      %{_tmppath}/%{name}-%{version}-build
PreReq:         gconf2
Source1:        gconf2-branding-gnome-splash.png
# panel-default-setup.entries from gnome-panel (patched SuSE version):
Source2:        panel-default-setup.entries
Source3:        gconf2-branding-COPYING
Source4:        gnome-wallpaper-11.0.2.tar.bz2
Source5:        GnomeOnlineHelp.desktop
Source6:        SuSE.desktop
Source7:        suse-icon.tar.bz2
Source8:        suse-help.svg
Source9:        gnome-wallpaper-11.1.tar.bz2
# PATCH-FEATURE-OPENSUSE gnome-panel-layout.patch -- panel-default-setup.entries patch for gnome-panel:
Patch0:         gnome-panel-layout.patch
# PATCH-FEATURE-OPENSUSE gnome-panel-layout-SLES.patch -- panel-default-setup.entries patch for gnome-panel:
Patch1:         gnome-panel-layout-SLES.patch
Provides:       gconf2-branding = 2.20
Conflicts:      otherproviders(gconf2-branding)
Supplements:    packageand(gconf2:branding-SLES)
# This package provides openSUSE gnome-session splash:
Provides:       gnome-session-branding = 2.20
Provides:       gnome-session-branding-SLES = 2.20
Supplements:    packageand(gnome-session:branding-SLES)
BuildRequires:  desktop-data-%{desktop_data} gconf2
# For directory ownership of %{_datadir}/pixmaps/splash:
# BuildRequires:  gnome-session
# For directory ownership of %{_datadir}/backgrounds:
# BuildRequires:  gnome-themes
#BRAND: gconf2-branding-openSUSE provides branding Look and Feel using
#BRAND: gconf schemas. All referenced files must be present in this
#BRAND: package or in required packages.
# Referenced Metacity theme Gilouche is part of gtk2-theme-openSUSE:
Requires:       gtk2-theme-%{desktop_data} desktop-data-%{desktop_data} = %{desktop_data_ver}
Suggests:       desktop-data-SLES-extra-gnome

This package provides SLES defaults for configurations based on GConf
database system.

%package -n desktop-data-SLES-extra-gnome
License:        BSD 3-Clause
Enhances:       gconf2-branding-SLES
Supplements:    desktop-data-%{desktop_data}-extra
Summary:        SLES defaults for the GNOME configuration system
Group:          System/GUI/GNOME
Version:        %{desktop_data_ver}
Release:        6

%description -n desktop-data-SLES-extra-gnome
This package provides SLES defaults for configurations based on GConf
database system.

%setup -q -T -a4 -a7 -a9 -c %{name}-%{version}
cp -a %{S:1} gnome-splash-SLES.png
cp -a %{S:2} .
cp -a %{S:3} COPYING
%if %build_openSUSE || %build_SLED
%if %build_SLES


install -d $RPM_BUILD_ROOT%{_datadir}/pixmaps/splash $RPM_BUILD_ROOT%{_datadir}/backgrounds $RPM_BUILD_ROOT%{_datadir}/gnome-background-properties
install -m0644 gnome-splash-SLES.png $RPM_BUILD_ROOT%{_datadir}/pixmaps/splash/
# current dynamic background
cp -a glass $RPM_BUILD_ROOT%{_datadir}/backgrounds/
install -m0644 desktop-backgrounds-glass.xml $RPM_BUILD_ROOT%{_datadir}/gnome-background-properties/desktop-data-SLES-extra-gnome.xml
%if %build_openSUSE
# old 11.0 dynamic background
cp -a grass $RPM_BUILD_ROOT%{_datadir}/backgrounds/
install -m0644 desktop-backgrounds-grass.xml $RPM_BUILD_ROOT%{_datadir}/gnome-background-properties/desktop-data-SLES-11.0-extra-gnome.xml
# Only vendor preferences are allowed here.
# Stuff to "Make OpenSUSE working must remain in particular packages!
%define gconf_call gconftool-2 --direct --config-source=xml::$RPM_BUILD_ROOT%{_sysconfdir}/gconf/gconf.xml.vendor
%define gconf_set %gconf_call --set
%define gconf_load %gconf_call --load
mkdir -p $RPM_BUILD_ROOT%{_sysconfdir}/gconf/gconf.xml.vendor
# Set actions list differently from upstream:
#%gconf_set /apps/control-center/cc_actions_list --type=list --list-type=string "[Add Printer;system-config-printer.desktop,Configure Network;nm-connection-editor.desktop,Change Password;gnome-passwd.desktop,Add User;YaST2/users.desktop,Open Administrator Settings;YaST.desktop]"
# Change epiphany homepage:
%if %build_openSUSE
%gconf_set /apps/epiphany/general/homepage --type=string ""
%if %build_SLED || %build_SLES
%gconf_set /apps/epiphany/general/homepage --type=string ""
# Globally disable movement of predefined panels in gnome-panel:
%gconf_set /apps/panel/global/disable_movement --type=bool "true"
# Display all workspaces in the gnome-panel window list applet:
# FIXME: This key has no applyto and it cannot work. But it is now the default.
#%gconf_set /schemas/apps/window_list_applet/prefs/display_all_workspaces --type=bool "true"
# Icon used on gdm greeter
%gconf_set /apps/gdm/simple-greeter/logo_icon_name --type=string "gdm-suse"
# No user list in GDM for SLED/SLES
%if %build_SLED || %build_SLES
%gconf_set /apps/gdm/simple-greeter/disable_user_list --type=bool "true"
# Depends on the gnome-power-manager-notify-idle-sleep.patch in g-p-m
%gconf_set /apps/gnome-power-manager/notify/idle_sleep --type=bool "true"
# Enable Energy Star compliant default configuration
%gconf_set /apps/gnome-power-manager/actions/sleep_type_battery --type=string "suspend"
%gconf_set /apps/gnome-power-manager/timeout/sleep_display_ac --type=int 300
# To complete Energy Star compliant default configuration, you should enable this too:
# (disabled by default because suspending is not working fine in all cases)
#%gconf_set /apps/gnome-power-manager/timeout/sleep_computer_battery --type=int 1200
#%gconf_set /apps/gnome-power-manager/timeout/sleep_computer_ac --type=int 1200
# Use custom splash screen in gnome-session:
%gconf_set /apps/gnome-session/options/splash_image --type=string "%{_datadir}/pixmaps/splash/gnome-splash-SLES.png"
# Use gnome-wm as default window manager:
%gconf_set /desktop/gnome/session/required_components/windowmanager --type=string "gnome-wm"
# Define default keybinding of gnome-settings-daemon:
# FIX-OPENSUSE gnome-settings-daemon-default-config.patch
%gconf_set /apps/gnome_settings_daemon/keybindings/help --type=string "XF86Help"
# Enable xrandr notification by default bnc#440868
%gconf_set /apps/gnome_settings_daemon/xrandr/show_notification_icon --type=bool "TRUE"
# Do not show process 'estimated memory usage' column on startup:
# FIX-UPSTREAM gnome-system-monitor-resident-schema.patch bnc157022 bgo336376 -- Probably need to really show Resident by default
%gconf_set /apps/procman/proctree/col_15_visible --type=bool "FALSE"
%gconf_set /apps/gnome-terminal/global/use_mnemonics --type=bool "false"
%gconf_set /apps/gnome-terminal/global/use_menu_accelerators --type=bool "false"
# Use firefox, not epiphany for all apps handled by gnome-vfs2 and libgnome (keep inactive for ftp):
%gconf_set /desktop/gnome/url-handlers/http/command --type=string "firefox %s"
%gconf_set /desktop/gnome/url-handlers/https/command --type=string "firefox %s"
%gconf_set /desktop/gnome/url-handlers/ftp/command --type=string "firefox %s"
%gconf_set /desktop/gnome/applications/browser/exec --type=string "firefox"
# Use xchat for irc
%gconf_set /desktop/gnome/url-handlers/irc/command --type=string "xchat --existing --url=%s"
%gconf_set /desktop/gnome/url-handlers/irc/enabled --type=bool "true"
# Change default look of GNOME in libgnome:
# Change default background (scriptlets may alter this value):
%if %build_openSUSE
test -f %{_datadir}/wallpapers/%{desktop_data}111-1600x1200.png
# WARNING: Don't forget to change value in scriptlets below:
%gconf_set /desktop/gnome/background/picture_filename --type=string "%{_datadir}/wallpapers/%{desktop_data}111-1600x1200.png"
%if %build_SLED || %build_SLES
test -f %{_datadir}/wallpapers/%{desktop_data}110-1600x1200.png
# WARNING: Don't forget to change value in scriptlets below:
%gconf_set /desktop/gnome/background/picture_filename --type=string "%{_datadir}/wallpapers/%{desktop_data}110-1600x1200.png"
%gconf_set /desktop/gnome/background/picture_options --type=string "stretched"
%gconf_set /desktop/gnome/background/primary_color --type=string "#258c06"
%gconf_set /desktop/gnome/background/secondary_color --type=string "#258c06"
%gconf_set /desktop/gnome/file_views/icon_theme --type=string "Gilouche"
%gconf_set /desktop/gnome/interface/accessibility --type=bool "false"
%gconf_set /desktop/gnome/interface/icon_theme --type=string "Gilouche"
# WARNING: gtk2-branding-SLES must contain the same, otherwise it
# will change when gnome-settings-daemon starts:
%gconf_set /desktop/gnome/interface/gtk_theme --type=string "Gilouche"
# Enable sound events by default in libgnome:
%gconf_set /desktop/gnome/sound/enable_esd --type=bool "false"
%gconf_set /desktop/gnome/sound/event_sounds --type=bool "true"
# Disable audible bell in metacity:
%gconf_set /apps/metacity/general/audible_bell --type=bool "false"
%if %build_SLED || %build_SLES
# Enable Windows flag keys to show the panel's main menu in SLED:
%gconf_set /apps/metacity/global_keybindings/panel_main_menu_list --type=list --list-type=string "[Super_L,Super_R]"
# Change default theme in Metacity:
%gconf_set /apps/metacity/general/theme --type=string "Gilouche"
# FIX-OPENSUSE nautilus-config-defaults.patch -- Default configuration
# Enables the classic Nautilus behavior, where all windows are browsers:
%gconf_set /apps/nautilus/preferences/always_use_browser --type=bool "true"
# Never preview sounds when mousing over an icon:
%gconf_set /apps/nautilus/preferences/preview_sound --type=string "never"
# Computer icon invisible on desktop:
%gconf_set /apps/nautilus/desktop/computer_icon_visible --type=bool "false"
# Change notification-daemon theme used when displaying notifications:
%gconf_set /apps/notification-daemon/theme --type=string "bubble"
# And generate default GNOME panel layout:
export GCONF_CONFIG_SOURCE=`usr/bin/gconftool-2 --get-default-source`
%gconf_load panel-default-setup.entries
# Merge is optional, but one larger file is better than many small files:
gconf-merge-tree $RPM_BUILD_ROOT%{_sysconfdir}/gconf/gconf.xml.vendor
rm -rf $RPM_BUILD_ROOT%{_sysconfdir}/gconf/gconf.xml.vendor/*/*
rmdir $RPM_BUILD_ROOT%{_sysconfdir}/gconf/gconf.xml.vendor/* 2>/dev/null || :
# This is deliberately done after the merge. We may want to modify it in scriptlets.
# Set up .desktop files to be shown in users' desktops
%gconf_set /apps/nautilus/desktop/predefined_items_dir --type=string /usr/share/dist/desktop-files
install -d $RPM_BUILD_ROOT%{_datadir}/dist/desktop-files
install -d $RPM_BUILD_ROOT%{_datadir}/dist/icons
%if %build_openSUSE
install -m 0644 %{S:5} $RPM_BUILD_ROOT%{_datadir}/dist/desktop-files/
install -m 0644 %{S:6} $RPM_BUILD_ROOT%{_datadir}/dist/desktop-files/
# Compatibility: We cannot move these icons to another location without
# providing an homedir update process:
install -m 0644 %{S:8} $RPM_BUILD_ROOT%{_datadir}/dist/icons/
ln -s %{_datadir}/icons/hicolor/scalable/apps/gdm-suse.svg $RPM_BUILD_ROOT%{_datadir}/dist/icons/suse.svg
for size in 16 22 32 48; do
  install -D -m 0755 suse${size}.png $RPM_BUILD_ROOT%{_datadir}/icons/hicolor/${size}x${size}/apps/gdm-suse.png
install -D -m 0755 suse.svg $RPM_BUILD_ROOT%{_datadir}/icons/hicolor/scalable/apps/gdm-suse.svg


%triggerin -- desktop-data-SLES-extra-gnome
# If desktop-data-SLES-extra-gnome exists, we want nice dynamic background.
gconftool-2 >/dev/null --direct --config-source=xml::%{_sysconfdir}/gconf/gconf.xml.vendor --set\
    /desktop/gnome/background/picture_filename --type=string "%{_datadir}/backgrounds/glass/glass.xml" || true

%triggerpostun -- desktop-data-SLES-extra-gnome
# If desktop-data-SLES-extra-gnome exists, we want nice dynamic background.
if ! test -f %{_datadir}/backgrounds/glass/glass.xml ; then
%if %build_openSUSE
  gconftool-2 >/dev/null --direct --config-source=xml::%{_sysconfdir}/gconf/gconf.xml.vendor --set\
    /desktop/gnome/background/picture_filename --type=string "%{_datadir}/wallpapers/%{desktop_data}111-1600x1200.png" || true
%if %build_SLED || %build_SLES
  gconftool-2 >/dev/null --direct --config-source=xml::%{_sysconfdir}/gconf/gconf.xml.vendor --set\
    /desktop/gnome/background/picture_filename --type=string "%{_datadir}/wallpapers/%{desktop_data}110-1600x1200.png" || true

# If desktop-data-SLES-extra-gnome exists, we want nice dynamic background.
if test -f %{_datadir}/backgrounds/glass/glass.xml ; then
  gconftool-2 >/dev/null --direct --config-source=xml::%{_sysconfdir}/gconf/gconf.xml.vendor --set\
    /desktop/gnome/background/picture_filename --type=string "%{_datadir}/backgrounds/glass/glass.xml"

%verify(not md5 size mtime) %{_sysconfdir}/gconf/gconf.xml.vendor/*
%dir %{_datadir}/pixmaps/splash
# FIXME: Should be owned by a different package:
%dir %{_datadir}/backgrounds
%dir %{_datadir}/dist
%dir %{_datadir}/dist/desktop-files
%dir %{_datadir}/dist/icons
%if %build_openSUSE

%files -n desktop-data-SLES-extra-gnome
%if %build_openSUSE
# FIXME: Should be owned by a different package:
%dir %{_datadir}/backgrounds
%dir %{_datadir}/gnome-background-properties

* Mon Nov 17 2008
- make sure trigger scripts do not fail
* Fri Nov 14 2008
- Set /apps/gdm/simple-greeter/disable_user_list to true not false.
  Really fix bnc#439220.
* Wed Nov 12 2008
- Add PreReq: gconf2
* Sun Nov 09 2008
- Rename suse icons to gdm-suse to avoid conflict with
* Fri Nov 07 2008
- Set /apps/gnome-power-manager/notify/idle_sleep to TRUE (moved
  the default from gnome-power-manager to here, so we are upstream
  compliant without the branding package).
* Fri Nov 07 2008
- disable auto suspend and apply the other changes to all distros
* Fri Nov 07 2008
- Update dynamic background for new branding. Fix bnc#442560. We
  keep the old one for openSUSE, though (see Jakub's request in the
* Thu Nov 06 2008
- Don't show the user list in GDM for SLED/SLES. Fix bnc#439220.
- Add suse icons and use them in the GDM greeter. Part of
- Move icons of the desktop files from gnome-session to here.
* Thu Nov 06 2008
- Disable Energy Star compliant settings for openSUSE
* Tue Nov 04 2008
- Use the right version for desktop-data-openSUSE-extra-gnome.
  Part of bnc#440849.
- Remove changes for gnome-volume-manager: we dropped
* Mon Nov 03 2008
- Disable Energy compliant settings for SLES
- Enable xrandr notification icon by default (bnc#440868)
- Added HACKING file
* Fri Oct 31 2008
- Require desktop-data-SLED 11  not 11.1 on SLED/SLES
* Thu Oct 30 2008
- Fix build for SLED/SLES: the filename of the default wallpaper
* Wed Oct 22 2008
- Only install GnomeOnlineHelp.desktop and SuSE.desktop in
  /usr/share/dist/desktop-files for openSUSE.
* Fri Oct 17 2008
- Merge the openSUSE/SLED/SLES gconf2-branding packages, for
  easier maintenance.
- Remove use of %%sles_version and do the appropriate thing so that
  what we wanted to have in SLES/SLED and not in openSUSE happens.
- Remove /apps/gnome-power-manager/ui/cpufreq_show change: this
  feature was removed upstream.
- Remove branding for volume_mute, volume_down, volume_up, eject,
  search, email, www since upstream has the right values now.
- Use XF86Help for the help keybinding instead of 0xf5.
- Bump version to 2.24, since we have gconf2 2.24.
* Mon Oct 06 2008
- Conflict with other branding providers (FATE#304881).
* Tue Sep 30 2008
- Fixed directory ownership.
* Mon Sep 22 2008 
- Install GnomeOnlineHelp.desktop and SuSE.desktop in
  /usr/share/dist/desktop-files, and set the GConf key
  /apps/nautilus/desktop/predefined_items_dir to point to that
  directory.  This is the new way to define .desktop items that will
  appear in users' desktops.
* Thu Sep 18 2008
- Moved gnome-power-manager-energy-star.patch here, adding default
  Energy Star compliant default configuration (fate#304708)
* Wed Sep 10 2008
- Set gnome-wm script as default window manager, so that we can
  start compiz whenever the hardware allows (fate#304762)
* Tue Jul 22 2008
- Keep upstream default for the number of workspace (4).
- Change panel layout to have the workspace switcher by default.
* Tue Jul 15 2008
- adapt the required openSUSE version
* Tue Jun 24 2008
- Disable ESD startup by default to avoid weird things happening
  when running GNOME apps with root (YaST) (bnc#387052)
* Thu May 29 2008
- Use Gilouche theme instead of Industrial (bnc#391865).
* Tue May 20 2008
- Updated gnome-panel-layout.patch to re-add the mixer applet to
  default setups, now that it uses PulseAudio's volume control
* Tue May 13 2008
- Change the way we activate the main menu with the flag keys.
  Instead of relying on a patch that breaks in some cases (see
  bnc#372423), we use Super_L and Super_R in
* Thu May 01 2008
- Add irc: URL handler for xchat. Fix bnc#372232.
* Tue Apr 29 2008
- Fix the path to the default background in gconf
* Tue Apr 29 2008
- Don't set the following settings (consensus reached on mailing
  + /apps/file-roller/listing/list_mode to "all_files"
  + /apps/ghex2/datafont to "Courier Bold 12"
  + /apps/ghex2/headerfont to "Courier Bold 12"
  + /apps/stickynotes_applet/defaults/color to "#E1D54B"
  + /apps/stickynotes_applet/settings/use_system_color to "false"
  + /desktop/gnome/volume_manager/autoplay_cda_command to "banshee
    --play --audio-cd %%d"
  + /desktop/gnome/volume_manager/autoburn_audio_cd_command to
  "banshee --burn-cd %%d"
  + /desktop/gnome/volume_manager/autoipod_command to "banshee
    --dap %%h"
  + /desktop/gnome/volume_manager/autoburn to "true"
  + /desktop/gnome/volume_manager/autoplay_dvd to "true"
  + /desktop/gnome/volume_manager/autoipod to "true"
- Note that banshee will still be the default command for CD/music
  players -- it just moved from gnome-volume-manager to nautilus
  and some mime type magic.
- Remove duplicate /desktop/gnome/sound/enable_esd
- Change the default epiphany homepage to
* Wed Apr 23 2008
- Start sound server (PulseAudio) by default (bnc#377065)
* Mon Apr 21 2008
- gnome-wallpaper-openSUSE renamed to
  desktop-data-openSUSE-extra-gnome to better reflect other package
- desktop-data-openSUSE-extra-gnome now supplements
* Thu Apr 17 2008
- Removed background symlinks and handle it correctly in
* Wed Apr 16 2008
- Default background fixes (bnc#369924):
  * Use wallpaper file from desktop-data-openSUSE.
  * New optional dynamic wallpaper in gnome-wallpaper-openSUSE
  * Symliked all desktop-data-openSUSE wallpapers for convenience.
* Mon Apr 14 2008
- dont require packages just for the directory ownership.
* Mon Apr 14 2008
- Added openSUSE 11.0 GNOME splash (bnc#361234).
- Added openSUSE 11.0 default background (bnc#369924).
- Use packageand form of branding supplement.
* Wed Apr 09 2008
- Added COPYING file (bnc#369961).
* Mon Apr 07 2008
- Require gtk2-theme-openSUSE containing Metacity theme Gilouche.
* Tue Apr 01 2008
- Don't turn on metacity compositing manager by default. It might
  not work well for everybody, so stay with upstream default for
  now (ie, disabled by default).
* Thu Mar 20 2008
- Fixed windows keys settings: On for SLED, Off for openSUSE.
* Wed Mar 19 2008
- Removed mixer applet from default panel configuration.
* Fri Mar 14 2008
- Disable movement moved from gnome-panel to branding.
- Clean up of default configuration.
* Thu Mar 13 2008
- New SuSE package, collects all gconf vendor defaults
  (fate#301464, fate#301792).
- Included gnome-session-branding-openSUSE.
- Included default GNOME panel configuration (fate#301474).