[gnome-chemistry-utils] Split each application to a separate subpackage
Kalev Lember
kalev at fedoraproject.org
Wed Jul 9 15:51:24 UTC 2014
commit ece6efa4c50407c3a9b4a3f6cc173331431fd1a9
Author: Kalev Lember <kalevlember at gmail.com>
Date: Wed Jul 9 15:38:39 2014 +0200
Split each application to a separate subpackage
This makes it possible for application-based installers to install each
of the apps separately. For distro upgrades and for people who want to
install the whole suite at once, we're keeping a gnome-chemistry-utils
metapackage pulling in all the new subpackages.
https://bugzilla.redhat.com/show_bug.cgi?id=1117905
gnome-chemistry-utils.spec | 268 ++++++++++++++++++++++++++++++++++++--------
1 files changed, 222 insertions(+), 46 deletions(-)
---
diff --git a/gnome-chemistry-utils.spec b/gnome-chemistry-utils.spec
index 413bbdc..3660cd7 100644
--- a/gnome-chemistry-utils.spec
+++ b/gnome-chemistry-utils.spec
@@ -1,6 +1,6 @@
Name: gnome-chemistry-utils
Version: 0.14.8
-Release: 4%{?dist}
+Release: 5%{?dist}
Summary: A set of chemical utilities
#openbabel/* is GPLv2+
@@ -24,12 +24,16 @@ BuildRequires: man-pages-reader
BuildRequires: openbabel-devel >= 2.1.0
BuildRequires: perl(XML::Parser)
-Requires: bodr
-Requires: chemical-mime-data
-Requires: hicolor-icon-theme
+Requires: gchem3d%{?_isa} = %{version}-%{release}
+Requires: gchemcalc%{?_isa} = %{version}-%{release}
+Requires: gchempaint%{?_isa} = %{version}-%{release}
+Requires: gchemtable%{?_isa} = %{version}-%{release}
+Requires: gcrystal%{?_isa} = %{version}-%{release}
+Requires: gspectrum%{?_isa} = %{version}-%{release}
%description
-This package is a set of chemical utils. Several programs are available:
+This is a meta-package for applications in the GNOME Chemistry Utils suite:
+
* A 3D molecular structure viewer (GChem3D).
* A Chemical calculator (GChemCalc).
* A 2D structure editor (GChemPaint).
@@ -37,9 +41,19 @@ This package is a set of chemical utils. Several programs are available:
* A crystalline structure editor (GCrystal).
* A spectra viewer (GSpectrum).
+
+%package libs
+Summary: GNOME Chemistry Utils libraries
+Requires: bodr
+Requires: chemical-mime-data
+
+%description libs
+This package contains common libraries for the GNOME Chemistry Utils suite.
+
+
%package gnumeric
Summary: Gnome Chemistry Utils plugin for Gnumeric
-Requires: %{name}%{?_isa} = %{version}-%{release}
+Requires: %{name}-libs%{?_isa} = %{version}-%{release}
%description gnumeric
This package is a set of chemical utils. Several programs are available:
@@ -52,9 +66,70 @@ This package is a set of chemical utils. Several programs are available:
This package contains a plugin adding a few chemistry-related functions to
gnumeric.
+
+%package -n gchem3d
+Summary: 3D molecular structure viewer
+Requires: %{name}-libs%{?_isa} = %{version}-%{release}
+Requires: hicolor-icon-theme
+
+%description -n gchem3d
+This package contains GChem3D, a 3D molecular structure viewer that is part of
+the GNOME Chemistry Utils.
+
+
+%package -n gchemcalc
+Summary: Chemical calculator
+Requires: %{name}-libs%{?_isa} = %{version}-%{release}
+Requires: hicolor-icon-theme
+
+%description -n gchemcalc
+This package contains GChemCalc, a chemical calculator that is part of
+the GNOME Chemistry Utils.
+
+
+%package -n gchempaint
+Summary: 2D chemical structure editor
+Requires: %{name}-libs%{?_isa} = %{version}-%{release}
+Requires: hicolor-icon-theme
+
+%description -n gchempaint
+This package contains GChemPaint, a 2D chemical structure editor that is part of
+the GNOME Chemistry Utils.
+
+
+%package -n gchemtable
+Summary: Periodic table of the chemical elements
+Requires: %{name}-libs%{?_isa} = %{version}-%{release}
+Requires: hicolor-icon-theme
+
+%description -n gchemtable
+This package contains GChemTable, an application for displaying the periodic
+table of the chemical elements. It's part of the GNOME Chemistry Utils.
+
+
+%package -n gcrystal
+Summary: Crystalline structure editor
+Requires: %{name}-libs%{?_isa} = %{version}-%{release}
+Requires: hicolor-icon-theme
+
+%description -n gcrystal
+This package contains GCrystal, a crystalline structure editor that is part of
+the GNOME Chemistry Utils.
+
+
+%package -n gspectrum
+Summary: Spectrum viewer
+Requires: %{name}-libs%{?_isa} = %{version}-%{release}
+Requires: hicolor-icon-theme
+
+%description -n gspectrum
+This package contains GSpectrum, a spectrum viewer that is part of
+the GNOME Chemistry Utils.
+
+
%package mozplugin
Summary: Gnome Chemistry Utils plugin for Mozilla
-Requires: %{name}%{?_isa} = %{version}-%{release}
+Requires: %{name}-libs%{?_isa} = %{version}-%{release}
Requires: mozilla-filesystem
%description mozplugin
@@ -85,7 +160,14 @@ make INSTALL="install -p" install DESTDIR=$RPM_BUILD_ROOT
desktop-file-install \
--delete-original --dir $RPM_BUILD_ROOT%{_datadir}/applications \
$RPM_BUILD_ROOT%{_datadir}/applications/{gchem3d,gchemcalc,gchempaint,gchemtable,gcrystal,gspectrum}-0.14.desktop
+
%find_lang gchemutils-0.14
+%find_lang gchem3d-0.14 --with-gnome
+%find_lang gchemcalc-0.14 --with-gnome
+%find_lang gchempaint-0.14 --with-gnome
+%find_lang gchemtable-0.14 --with-gnome
+%find_lang gcrystal-0.14 --with-gnome
+%find_lang gspectrum-0.14 --with-gnome
#kill libtool archives
find $RPM_BUILD_ROOT -name '*.la' -exec rm -f {} ';'
@@ -131,45 +213,163 @@ rm -rf $RPM_BUILD_ROOT%{_libdir}/libgcu-0.14.so
rm -rf $RPM_BUILD_ROOT%{_libdir}/libgcugtk-0.14.so
-%post
-update-desktop-database &> /dev/null ||:
+%post libs
update-mime-database %{_datadir}/mime &> /dev/null || :
-touch --no-create %{_datadir}/icons/hicolor &>/dev/null || :
/sbin/ldconfig
-
-%postun
+%postun libs
if [ $1 -eq 0 ] ; then
- glib-compile-schemas %{_datadir}/glib-2.0/schemas &> /dev/null || :
+ glib-compile-schemas %{_datadir}/glib-2.0/schemas &> /dev/null || :
fi
-update-desktop-database &> /dev/null ||:
update-mime-database %{_datadir}/mime &> /dev/null || :
+/sbin/ldconfig
+
+%posttrans libs
+glib-compile-schemas %{_datadir}/glib-2.0/schemas &> /dev/null || :
+
+
+%post -n gchem3d
+touch --no-create %{_datadir}/icons/hicolor &>/dev/null || :
+
+%postun -n gchem3d
if [ $1 -eq 0 ] ; then
touch --no-create %{_datadir}/icons/hicolor &>/dev/null
gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || :
+ update-mime-database -n %{_datadir}/mime &>/dev/null || :
fi
-/sbin/ldconfig
+%posttrans -n gchem3d
+gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || :
+update-mime-database -n %{_datadir}/mime &>/dev/null || :
+
+
+%post -n gchemcalc
+touch --no-create %{_datadir}/icons/hicolor &>/dev/null || :
-%posttrans
+%postun -n gchemcalc
+if [ $1 -eq 0 ] ; then
+ touch --no-create %{_datadir}/icons/hicolor &>/dev/null
+ gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || :
+fi
+
+%posttrans -n gchemcalc
+gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || :
+
+
+%post -n gchempaint
+touch --no-create %{_datadir}/icons/hicolor &>/dev/null || :
+
+%postun -n gchempaint
+if [ $1 -eq 0 ] ; then
+ touch --no-create %{_datadir}/icons/hicolor &>/dev/null
+ gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || :
+ glib-compile-schemas %{_datadir}/glib-2.0/schemas &> /dev/null || :
+ update-mime-database -n %{_datadir}/mime &>/dev/null || :
+fi
+
+%posttrans -n gchempaint
+gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || :
glib-compile-schemas %{_datadir}/glib-2.0/schemas &> /dev/null || :
+update-mime-database -n %{_datadir}/mime &>/dev/null || :
+
+
+%post -n gchemtable
+touch --no-create %{_datadir}/icons/hicolor &>/dev/null || :
+
+%postun -n gchemtable
+if [ $1 -eq 0 ] ; then
+ touch --no-create %{_datadir}/icons/hicolor &>/dev/null
+ gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || :
+fi
+
+%posttrans -n gchemtable
gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || :
-%files -f gchemutils-0.14.lang
+%post -n gcrystal
+touch --no-create %{_datadir}/icons/hicolor &>/dev/null || :
+
+%postun -n gcrystal
+if [ $1 -eq 0 ] ; then
+ touch --no-create %{_datadir}/icons/hicolor &>/dev/null
+ gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || :
+ glib-compile-schemas %{_datadir}/glib-2.0/schemas &> /dev/null || :
+ update-mime-database -n %{_datadir}/mime &>/dev/null || :
+fi
+
+%posttrans -n gcrystal
+gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || :
+glib-compile-schemas %{_datadir}/glib-2.0/schemas &> /dev/null || :
+update-mime-database -n %{_datadir}/mime &>/dev/null || :
+
+
+%post -n gspectrum
+touch --no-create %{_datadir}/icons/hicolor &>/dev/null || :
+
+%postun -n gspectrum
+if [ $1 -eq 0 ] ; then
+ touch --no-create %{_datadir}/icons/hicolor &>/dev/null
+ gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || :
+ update-mime-database -n %{_datadir}/mime &>/dev/null || :
+fi
+
+%posttrans -n gspectrum
+gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || :
+update-mime-database -n %{_datadir}/mime &>/dev/null || :
+
+
+%files
%doc AUTHORS ChangeLog COPYING INSTALL NEWS README TODO
+
+%files -n gchem3d -f gchem3d-0.14.lang
%{_bindir}/gchem3d-0.14
%{_bindir}/gchem3d
+%{_datadir}/applications/gchem3d-0.14.desktop
+%{_mandir}/man1/gchem3d.1*
+%{_datadir}/icons/hicolor/scalable/apps/gchem3d.svg
+
+%files -n gchemcalc -f gchemcalc-0.14.lang
%{_bindir}/gchemcalc-0.14
%{_bindir}/gchemcalc
+%{_datadir}/applications/gchemcalc-0.14.desktop
+%{_mandir}/man1/gchemcalc.1*
+%{_datadir}/icons/hicolor/scalable/apps/gchemcalc.svg
+
+%files -n gchempaint -f gchempaint-0.14.lang
%{_bindir}/gchempaint-0.14
%{_bindir}/gchempaint
+%{_datadir}/applications/gchempaint-0.14.desktop
+%{_datadir}/glib-2.0/schemas/org.gnome.gchemutils.paint.gschema.xml
+%{_datadir}/glib-2.0/schemas/org.gnome.gchemutils.paint.plugins.arrows.gschema.xml
+%{_mandir}/man1/gchempaint.1*
+%{_datadir}/icons/hicolor/scalable/apps/gchempaint.svg
+%{_datadir}/icons/hicolor/scalable/mimetypes/application-x-gchempaint.svg
+
+%files -n gchemtable -f gchemtable-0.14.lang
%{_bindir}/gchemtable-0.14
%{_bindir}/gchemtable
+%{_datadir}/applications/gchemtable-0.14.desktop
+%{_mandir}/man1/gchemtable.1*
+%{_datadir}/icons/hicolor/scalable/apps/gchemtable.svg
+
+%files -n gcrystal -f gcrystal-0.14.lang
%{_bindir}/gcrystal-0.14
%{_bindir}/gcrystal
+%{_datadir}/applications/gcrystal-0.14.desktop
+%{_datadir}/glib-2.0/schemas/org.gnome.gchemutils.crystal.gschema.xml
+%{_mandir}/man1/gcrystal.1*
+%{_datadir}/icons/hicolor/scalable/apps/gcrystal.svg
+%{_datadir}/icons/hicolor/scalable/mimetypes/application-x-gcrystal.svg
+
+%files -n gspectrum -f gspectrum-0.14.lang
%{_bindir}/gspectrum-0.14
%{_bindir}/gspectrum
+%{_datadir}/applications/gspectrum-0.14.desktop
+%{_mandir}/man1/gspectrum.1*
+%{_datadir}/icons/hicolor/scalable/apps/gspectrum.svg
+
+%files libs -f gchemutils-0.14.lang
+%doc COPYING
%{_libdir}/gchemutils
%{_libdir}/goffice/*/plugins/gchemutils
%{_libdir}/libgccv-0.14.so.*
@@ -178,46 +378,22 @@ gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || :
%{_libdir}/libgcu-0.14.so.*
%{_libdir}/libgcugtk-0.14.so.*
%{_libexecdir}/babelserver
-%{_libexecdir}/chem-viewer
-%{_datadir}/applications/*gchem3d-0.14.desktop
-%{_datadir}/applications/*gchemcalc-0.14.desktop
-%{_datadir}/applications/*gchempaint-0.14.desktop
-%{_datadir}/applications/*gchemtable-0.14.desktop
-%{_datadir}/applications/*gcrystal-0.14.desktop
-%{_datadir}/applications/*gspectrum-0.14.desktop
%{_datadir}/gchemutils
-%{_datadir}/glib-2.0/schemas/org.gnome.gchemutils.*
-%{_datadir}/gnome/help/gchem3d-0.14
-%{_datadir}/gnome/help/gchemcalc-0.14
-%{_datadir}/gnome/help/gchempaint-0.14
-%{_datadir}/gnome/help/gchemtable-0.14
-%{_datadir}/gnome/help/gcrystal-0.14
-%{_datadir}/gnome/help/gspectrum-0.14
-%{_datadir}/icons/hicolor/scalable/apps/*.svg
-%{_datadir}/icons/hicolor/scalable/mimetypes/application-x-gchempaint.svg
-%{_datadir}/icons/hicolor/scalable/mimetypes/application-x-gcrystal.svg
-%{_mandir}/man1/gchem3d.1*
-%{_mandir}/man1/gchemcalc.1*
-%{_mandir}/man1/gchempaint.1*
-%{_mandir}/man1/gchemtable.1*
-%{_mandir}/man1/gcrystal.1*
-%{_mandir}/man1/gspectrum.1*
+%{_datadir}/glib-2.0/schemas/org.gnome.gchemutils.gschema.xml
%{_datadir}/mime/packages/gchemutils.xml
-%{_datadir}/omf/gchem3d-0.14
-%{_datadir}/omf/gchemcalc-0.14
-%{_datadir}/omf/gchempaint-0.14
-%{_datadir}/omf/gchemtable-0.14
-%{_datadir}/omf/gcrystal-0.14
-%{_datadir}/omf/gspectrum-0.14
%files gnumeric
%{_libdir}/gnumeric/*/plugins/gchemutils
%files mozplugin
%{_libdir}/mozilla/plugins/libmozgcu.so
+%{_libexecdir}/chem-viewer
%changelog
+* Wed Jul 09 2014 Kalev Lember <kalevlember at gmail.com> - 0.14.8-5
+- Split each application to a separate subpackage (#1117905)
+
* Thu Jun 12 2014 Julian Sikorski <belegdol at fedoraproject.org> - 0.14.8-4
- Rebuilt for gnumeric-1.12.17
More information about the scm-commits
mailing list