libpeas1/libpeas1.spec
David King 40c464aefe Initial version
This is the initial version of libpeas1, which replaces the libpeas 1
API that used to provided by the libpeas package. libpeas 2 (1.99.0)
continues as the 2.0 API and is found in the libpeas package. Some care
needs to be taken when changing the Obsoletes and Provides, bearing in
mind that libpeas 2 no longer has a GTK dependency (and so no gtk
subpackage). Additionally, there is a Python (3) loader for libpeas 2,
found in the libpeas-loader-python, as well as a new GJS loader with no
libpeas 1 equivalent.
2023-08-22 14:35:39 +01:00

129 lines
4.1 KiB
RPMSpec

%global apiver 1.0
%global tarball_name libpeas
Name: libpeas1
Version: 1.36.0
Release: %autorelease
Summary: Plug-ins implementation convenience library, API version 1
License: LGPL-2.1-or-later
URL: https://wiki.gnome.org/Projects/Libpeas
Source0: https://download.gnome.org/sources/%{tarball_name}/1.36/%{tarball_name}-%{version}.tar.xz
BuildRequires: gcc
BuildRequires: gettext
BuildRequires: gi-docgen
BuildRequires: meson
BuildRequires: pkgconfig(gio-2.0)
BuildRequires: pkgconfig(gladeui-2.0)
BuildRequires: pkgconfig(glib-2.0)
BuildRequires: pkgconfig(gmodule-2.0)
BuildRequires: pkgconfig(gobject-2.0)
BuildRequires: pkgconfig(gobject-introspection-1.0)
BuildRequires: pkgconfig(gtk+-3.0)
BuildRequires: pkgconfig(pygobject-3.0)
BuildRequires: python3-devel
%description
libpeas1 is a convenience library making adding plug-ins support
to glib-based applications. For the version based on newer GLib, see the
libpeas package.
%package gtk
Summary: GTK+ 3 plug-ins support for libpeas1
Requires: %{name}%{?_isa} = %{version}-%{release}
# As this package was renamed after 1.36.0, obsolete the original package name
# of its first version (libpeas 2, in other words, 1.99.0).
Obsoletes: libpeas-gtk < 1.99.0-1
# Provide the original version 1 API package name. libpeas 2 does not provide a
# GTK API, so there is no overlap here.
Provides: libpeas-gtk = %{version}-%{release}
%description gtk
libpeas1-gtk is a convenience library making adding plug-ins support
to GTK+ 3-based applications.
%package loader-python3
Summary: Python 3 loader for libpeas1
Requires: %{name}%{?_isa} = %{version}-%{release}
Requires: python3-gobject
# As this package was renamed after 1.36.0, obsolete the original package name
# of its first version (libpeas 2, in other words, 1.99.0).
Obsoletes: libpeas-loader-python3 < 1.99.0-1
# Provide only the version 1 API package name. Nothing in Fedora depends on the
# unversioned package name, anyway.
Provides: libpeas1-loader-python3 = %{version}-%{release}
%description loader-python3
This package contains the Python 3 loader that is needed to
run Python 3 plugins that use libpeas1.
%package devel
Summary: Development files for libpeas1
Requires: %{name}%{?_isa} = %{version}-%{release}
Requires: %{name}-gtk%{?_isa} = %{version}-%{release}
# Because web fonts from upstream are not bundled in the gi-docgen package,
# packages containing documentation generated with gi-docgen should depend on
# this metapackage to ensure the proper system fonts are present.
Recommends: gi-docgen-fonts
# As this package was renamed after 1.36.0, obsolete the original package name
# of its first version (libpeas 2, in other words, 1.99.0).
Obsoletes: libpeas-devel < 1.99.0-1
# Not a direct replacement, so no Provides.
%description devel
This package contains development libraries and header files
that are needed to write applications that use libpeas1.
%prep
%autosetup -p1 -n %{tarball_name}-%{version}
%build
%meson \
-Ddemos=false \
-Dvapi=true \
-Dgtk_doc=true
%meson_build
%install
%meson_install
%find_lang libpeas-%{apiver}
%files -f libpeas-%{apiver}.lang
%doc AUTHORS NEWS README
%license COPYING
%{_libdir}/libpeas-%{apiver}.so.0*
%dir %{_libdir}/libpeas-%{apiver}/
%dir %{_libdir}/libpeas-%{apiver}/loaders
%dir %{_libdir}/girepository-1.0
%{_libdir}/girepository-1.0/Peas-%{apiver}.typelib
%{_datadir}/icons/hicolor/*/actions/libpeas-plugin.*
%files gtk
%{_libdir}/libpeas-gtk-%{apiver}.so.0*
%{_libdir}/girepository-1.0/PeasGtk-%{apiver}.typelib
%files loader-python3
%{_libdir}/libpeas-%{apiver}/loaders/libpython3loader.so
%files devel
%{_includedir}/libpeas-%{apiver}/
%{_docdir}/libpeas-1.0
%{_docdir}/libpeas-gtk-1.0
%{_libdir}/libpeas-%{apiver}.so
%{_libdir}/libpeas-gtk-%{apiver}.so
%dir %{_datadir}/gir-1.0
%{_datadir}/gir-1.0/Peas-%{apiver}.gir
%{_datadir}/gir-1.0/PeasGtk-%{apiver}.gir
%{_libdir}/pkgconfig/libpeas-%{apiver}.pc
%{_libdir}/pkgconfig/libpeas-gtk-%{apiver}.pc
%{_datadir}/glade/catalogs/libpeas-gtk.xml
%changelog
%autochangelog