Hello community,

here is the log from the commit of package icewm for openSUSE:Factory checked 
in at 2014-01-08 20:06:36
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/icewm (Old)
 and      /work/SRC/openSUSE:Factory/.icewm.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "icewm"

Changes:
--------
--- /work/SRC/openSUSE:Factory/icewm/icewm.changes      2013-04-02 
11:52:14.000000000 +0200
+++ /work/SRC/openSUSE:Factory/.icewm.new/icewm.changes 2014-01-08 
20:06:38.000000000 +0100
@@ -1,0 +2,5 @@
+Wed Jan  8 13:23:11 UTC 2014 - [email protected]
+
+- merge icewm-lite into icewm.spec using update-alternatives
+
+-------------------------------------------------------------------

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ icewm.spec ++++++
--- /var/tmp/diff_new_pack.wyq2dX/_old  2014-01-08 20:06:39.000000000 +0100
+++ /var/tmp/diff_new_pack.wyq2dX/_new  2014-01-08 20:06:39.000000000 +0100
@@ -1,7 +1,7 @@
 #
 # spec file for package icewm
 #
-# Copyright (c) 2013 SUSE LINUX Products GmbH, Nuernberg, Germany.
+# Copyright (c) 2014 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
@@ -16,15 +16,22 @@
 #
 
 
+# default to gnome support
+%bcond_without gnome
+
 Name:           icewm
 BuildRequires:  autoconf
 BuildRequires:  gcc-c++
+BuildRequires:  update-alternatives
+BuildRequires:  update-desktop-files
+BuildRequires:  xorg-x11-devel
+%if %{with gnome}
 BuildRequires:  gnome-desktop-devel
 BuildRequires:  libgnomeui-devel
-BuildRequires:  update-desktop-files
-BuildRequires:  pkgconfig(gdk-pixbuf-xlib-2.0)
 BuildRequires:  pkgconfig(gnome-desktop-2.0)
 BuildRequires:  pkgconfig(libgnomeui-2.0)
+%endif
+BuildRequires:  pkgconfig(gdk-pixbuf-xlib-2.0)
 %if 0%{?suse_version} >= 1030
 BuildRequires:  fdupes
 %endif
@@ -32,6 +39,8 @@
 Requires:       desktop-data
 Requires:       icewm-bin
 Requires:       xdg-menu
+# if you have the choice, prefer the big one
+Recommends:     icewm-default
 Version:        1.3.7
 Release:        0
 Source:         
http://downloads.sourceforge.net/project/%{name}/%{name}-1.3/%{version}/%{name}-%{version}.tar.gz
@@ -61,18 +70,12 @@
 opaque move and resize, a taskbar, a window list, mailbox status, and a
 digital clock. It is fast and small.
 
-
-
-Authors:
---------
-    Marko Macek <[email protected]>
-
 %package default
 Summary:        Window Manager with a Taskbar--Default Version
 Group:          System/GUI/Other
 Provides:       icewm-bin
 Requires:       icewm
-Conflicts:      icewm-lite
+Requires:       update-alternatives
 
 %description default
 A window manager for the X Window System that can emulate the look of
@@ -81,11 +84,19 @@
 opaque move and resize, a taskbar, a window list, mailbox status, and a
 digital clock. It is fast and small.
 
+%package lite
+Summary:        Window Manager with a Taskbar -- lite version
+Group:          System/GUI/Other
+Provides:       icewm-bin
+Requires:       icewm
+Requires:       update-alternatives
 
-
-Authors:
---------
-    Marko Macek <[email protected]>
+%description lite
+A window manager for the X Window System that can emulate the look of
+Windows 95, OS/2 Warp 3, OS/2 Warp 4, and Motif and tries to take the
+best features from those systems. IceWM features multiple workspaces,
+opaque move and resize, a taskbar, a window list, mailbox status, and a
+digital clock. It is fast and small.
 
 %package gnome
 Summary:        Windowmanager with Taskbar - gnome version
@@ -100,12 +111,6 @@
 
 This package adds GNOME menu and sound support to icewm.
 
-
-
-Authors:
---------
-    Marko Macek <[email protected]>
-
 %prep
 %setup -q
 %patch1
@@ -119,49 +124,99 @@
 %patch9 -p1
 %patch10 -p1
 
+%define lites icewm icewmhint icewmbg icesh icewm-session
+
 %build
 autoconf
 export CFLAGS="$RPM_OPT_FLAGS"
 export CXXFLAGS="$RPM_OPT_FLAGS"
-# needed for 10.[12] builds in the bs
-export PKG_CONFIG_PATH=$PKG_CONFIG_PATH:/opt/gnome/%_lib/pkgconfig
-./configure --disable-silent-rules --without-debug \
+./configure --without-debug \
            --sysconfdir=/etc \
            --with-cfgdir=/etc/icewm \
            --prefix=/usr \
            --with-docdir=%{_docdir} \
            --enable-i18n \
+            --disable-nls \
+            --disable-guievents \
+            --disable-winmenu \
+            --enable-lite \
+            --disable-gnome-menus
+make %{?jobs:-j%jobs} V=1
+mkdir lite
+for i in %lites; do mv src/$i lite/$i-lite; done
+make clean
+
+./configure --disable-silent-rules --without-debug \
+           --sysconfdir=/etc \
+           --with-cfgdir=/etc/icewm \
+           --prefix=/usr \
+           --with-docdir=%{_docdir} \
            --enable-nls \
            --enable-corefonts \
            --enable-guievents \
            --enable-antialiasing \
            --enable-gradients \
            --enable-shaped-decorations \
+%if %{with gnome}
            --with-icesound=oss,esd \
            --with-imlib \
-           --enable-menus-gnome2
+           --enable-menus-gnome2 \
+%endif
+           --enable-i18n
 make %{?jobs:-j%jobs} V=1
 # patch generated lib/preferences file
 patch -p0 -i %{P:99}
 
 %install
-make DESTDIR=$RPM_BUILD_ROOT install install-docs
-mkdir -p $RPM_BUILD_ROOT/etc/icewm
+make DESTDIR=%{buildroot} install install-docs
+mkdir -p %{buildroot}/etc/icewm
 for cfgfile in keys menu preferences toolbar winoptions ; do
-       mv $RPM_BUILD_ROOT/usr/share/icewm/$cfgfile \
-       $RPM_BUILD_ROOT/etc/icewm
+       mv %{buildroot}/usr/share/icewm/$cfgfile \
+       %{buildroot}/etc/icewm
 done
 %{find_lang} icewm
-ln -s icewm.html $RPM_BUILD_ROOT/%{_docdir}/icewm/index.html
+ln -s icewm.html %{buildroot}/%{_docdir}/icewm/index.html
 # install the xsession desktop file
-mkdir -p $RPM_BUILD_ROOT/usr/share/xsessions
-cp -f %{SOURCE1} $RPM_BUILD_ROOT/usr/share/xsessions
-%suse_update_desktop_file $RPM_BUILD_ROOT/usr/share/xsessions/icewm.desktop
+mkdir -p %{buildroot}/usr/share/xsessions
+cp -f %{SOURCE1} %{buildroot}/usr/share/xsessions
+%suse_update_desktop_file %{buildroot}/usr/share/xsessions/icewm.desktop
 # link duplicate theme icons to save some space
 %{?fdupes:%fdupes %buildroot/usr/share/icewm/themes/}
+mkdir -p %{buildroot}%{_sysconfdir}/alternatives
+for i in %lites; do 
+  mv lite/$i-lite %{buildroot}/usr/bin
+  mv %{buildroot}/usr/bin/$i %{buildroot}/usr/bin/$i-default
+
+  # dummy
+  touch %{buildroot}%{_sysconfdir}/alternatives/$i
+  ln -s %{_sysconfdir}/alternatives/$i %{buildroot}%_bindir/$i
+done
 
-%clean
-rm -rf $RPM_BUILD_ROOT;
+%post lite
+/usr/sbin/update-alternatives \
+    --install %{_bindir}/icewm       icewm         %{_bindir}/icewm-lite 0 \
+    --slave %{_bindir}/icewmhint     icewmhint     %{_bindir}/icewmhint-lite \
+    --slave %{_bindir}/icewmbg       icewmbg       %{_bindir}/icewmbg-lite \
+    --slave %{_bindir}/icesh         icesh         %{_bindir}/icesh-lite \
+    --slave %{_bindir}/icewm-session icewm-session 
%{_bindir}/icewm-session-lite
+
+%preun lite
+if [ "$1" = 0 ] ; then
+  /usr/sbin/update-alternatives --remove icewm %{_bindir}/icewm-lite
+fi
+
+%post default
+/usr/sbin/update-alternatives \
+    --install %{_bindir}/icewm       icewm         %{_bindir}/icewm-default 
100 \
+    --slave %{_bindir}/icewmhint     icewmhint     
%{_bindir}/icewmhint-default \
+    --slave %{_bindir}/icewmbg       icewmbg       %{_bindir}/icewmbg-default \
+    --slave %{_bindir}/icesh         icesh         %{_bindir}/icesh-default \
+    --slave %{_bindir}/icewm-session icewm-session 
%{_bindir}/icewm-session-default
+
+%preun default
+if [ "$1" = 0 ] ; then
+  /usr/sbin/update-alternatives --remove icewm %{_bindir}/icewm-default
+fi
 
 %files -f icewm.lang
 %defattr(-,root,root)
@@ -173,18 +228,49 @@
 
 %files default
 %defattr(-,root,root)
+/usr/bin/icewm-default
+/usr/bin/icewmhint-default
+/usr/bin/icewmbg-default
+/usr/bin/icehelp
+/usr/bin/icesh-default
+/usr/bin/icewmtray
+/usr/bin/icewm-session-default
+%ghost %_sysconfdir/alternatives/icewm
+%ghost %_sysconfdir/alternatives/icewmhint
+%ghost %_sysconfdir/alternatives/icewmbg
+%ghost %_sysconfdir/alternatives/icesh
+%ghost %_sysconfdir/alternatives/icewm-session
 /usr/bin/icewm
 /usr/bin/icewmhint
 /usr/bin/icewmbg
-/usr/bin/icehelp
 /usr/bin/icesh
-/usr/bin/icewmtray
 /usr/bin/icewm-session
 
+%if %{with gnome}
 %files gnome
 %defattr(-,root,root)
-/usr/bin/icesound
 /usr/bin/icewm-menu-gnome2
+%endif
+# make those two part of -default without gnome
+/usr/bin/icesound
 /usr/bin/icewm-set-gnomewm
 
+%files lite
+%defattr(-,root,root)
+/usr/bin/icewm-lite
+/usr/bin/icewmhint-lite
+/usr/bin/icewmbg-lite
+/usr/bin/icesh-lite
+/usr/bin/icewm-session-lite
+%ghost %_sysconfdir/alternatives/icewm
+%ghost %_sysconfdir/alternatives/icewmhint
+%ghost %_sysconfdir/alternatives/icewmbg
+%ghost %_sysconfdir/alternatives/icesh
+%ghost %_sysconfdir/alternatives/icewm-session
+/usr/bin/icewm
+/usr/bin/icewmhint
+/usr/bin/icewmbg
+/usr/bin/icesh
+/usr/bin/icewm-session
+
 %changelog

-- 
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to