2007-01-05 16:49:20 +01:00
#
2022-03-01 11:10:45 +01:00
# spec file
2007-01-05 16:49:20 +01:00
#
2023-01-23 19:25:51 +01:00
# Copyright (c) 2023 SUSE LLC
2007-01-05 16:49:20 +01:00
#
2008-08-13 23:29:18 +02:00
# 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.
2018-09-27 09:41:44 +02:00
# Please submit bugfixes or comments via https://bugs.opensuse.org/
2007-01-05 16:49:20 +01:00
#
2012-02-08 11:55:24 +01:00
2022-03-01 11:10:45 +01:00
%global flavor @BUILD_FLAVOR@%{nil}
%if "%{flavor}" == "doc"
%global psuffix -doc
%else
%global psuffix %{nil}
%endif
%define libver 2_0-0
%define libgio libgio-%{libver}
%define libglib libglib-%{libver}
%define libgmodule libgmodule-%{libver}
%define libgobject libgobject-%{libver}
%define libgthread libgthread-%{libver}
2022-04-04 15:39:19 +02:00
%bcond_without systemtap
2022-03-01 11:10:45 +01:00
Name : glib2%{psuffix}
2023-12-07 15:03:54 +01:00
Version : 2.78.3
2011-12-21 05:10:18 +01:00
Release : 0
2010-10-15 12:36:52 +02:00
Summary : General-Purpose Utility Library
2018-03-09 11:10:43 +01:00
License : LGPL-2.1-or-later
2017-09-14 13:45:01 +02:00
Group : Development/Libraries/C and C++
2023-09-12 10:20:17 +02:00
URL : https://gitlab.gnome.org/GNOME/glib/
Source0 : https://download.gnome.org/sources/glib/2.78/glib-%{version} .tar.xz
2007-01-05 16:49:20 +01:00
Source1 : glib2.sh
Source2 : glib2.csh
2011-07-07 09:44:57 +02:00
# Not upstream file. Only proposes upstream packages:
2008-04-09 21:41:41 +02:00
Source4 : glib2-upstream-gnome_defaults.conf
2011-07-07 09:44:57 +02:00
# Some documentation for people writing branding packages, shipped in the branding-upstream package
Source5 : README.Gsettings-overrides
Source6 : macros.glib2
2015-09-04 13:33:06 +02:00
# zsh completion from https://github.com/jmatsuzawa/zsh-comp-gsettings
2015-09-10 11:05:51 +02:00
Source8 : gsettings.zsh
2014-07-18 11:24:31 +02:00
Source98 : glib2-rpmlintrc
2009-12-18 12:36:58 +01:00
Source99 : baselibs.conf
2009-02-06 17:03:35 +01:00
# PATCH-FEATURE-UPSTREAM glib2-bgo569829-gettext-gkeyfile.patch fate300461 bgo569829 vuntz@novell.com -- Look for translation of desktop entry strings via gettext, part that we share with Ubuntu and try to push upstream
2018-09-22 00:43:51 +02:00
Patch0 : glib2-bgo569829-gettext-gkeyfile.patch
2009-02-06 17:03:35 +01:00
# PATCH-FEATURE-OPENSUSE glib2-fate300461-gettext-gkeyfile-suse.patch fate300461 vuntz@novell.com -- Look for translation of desktop entry strings via gettext, part that deals with the openSUSE specific infrastructure (with desktop_translations)
2018-09-22 00:43:51 +02:00
Patch1 : glib2-fate300461-gettext-gkeyfile-suse.patch
2012-06-09 12:31:02 +02:00
# PATCH-FIX-OPENSUSE glib2-suppress-schema-deprecated-path-warning.patch rh#814053 badshah400@gmail.com -- Suppress the deprecated path warning since it fills up screen unnecessarily during package installations/upgrade.
2018-09-22 00:43:51 +02:00
Patch2 : glib2-suppress-schema-deprecated-path-warning.patch
2017-06-28 11:40:28 +02:00
# PATCH-FIX-OPENSUSE glib2-gdbus-codegen-version.patch olaf@aepfle.de -- Remove version string from files generated by gdbus-codegen
2018-09-22 00:43:51 +02:00
Patch4 : glib2-gdbus-codegen-version.patch
2022-10-31 09:00:38 +01:00
2012-09-07 17:28:34 +02:00
BuildRequires : docbook-xsl-stylesheets
2009-12-08 10:34:05 +01:00
BuildRequires : fdupes
BuildRequires : gcc-c++
2010-08-09 15:47:13 +02:00
BuildRequires : libselinux-devel
2018-09-22 00:43:51 +02:00
BuildRequires : m4
2022-09-13 09:32:50 +02:00
BuildRequires : meson >= 0.60.0
2017-08-31 09:45:56 +02:00
BuildRequires : pkgconfig
Accepting request 792948 from GNOME:Next
Glib is supposed to be backwards compatible, so lets put that to the test - move at least to GF for now, and quite possibly even into TW.
- Update to version 2.64.2:
+ Bugs fixed: glgo#GNOME/GLib#2067, glgo#GNOME/GLib#2081,
glgo#GNOME/GLib!1421, glgo#GNOME/GLib!1438,
glgo#GNOME/GLib!1424, glgo#GNOME/GLib!1428,
glgo#GNOME/GLib!1429, glgo#GNOME/GLib !1431,
glgo#GNOME/GLib!1432, glgo#GNOME/GLib!1435,
glgo#GNOME/GLib!1447.
+ Updated translations.
- Update to version 2.64.1:
+ Fix memory monitor tests to only be installed if
installed-tests are enabled, and to be skipped if
GObject-Introspection is too old.
+ Bugs fixed: glgo#GNOME/GLib#1986, glgo#GNOME/GLib#1988,
glgo#GNOME/GLib!1407, glgo#GNOME/GLib!1412.
+ Updated translations.
- Update to version 2.64.0:
+ Use `posix_spawn()` to speed up launching test D-Bus instances.
+ Bugs fixed: glgo#GNOME/GLib#1783, glgo#GNOME/GLib#2049,
glgo#GNOME/GLib!1384, glgo#GNOME/GLib!1386,
glgo#GNOME/GLib!1387, glgo#GNOME/GLib!1388,
glgo#GNOME/GLib!1389.
+ Updated translations.
- Update to version 2.63.6:
+ Fix potential relative read when calling g_printerr(), which
could lead to a denial of service from a setuid-root process
being used to block access to the TTY for another user.
+ Fix SOCKS proxy resolver sometimes not being used when
resolving addresses via Happy Eyeballs (CVE-2020-6750).
+ Several other Happy Eyeballs fixes for address resolution.
+ Various race fixes in `GDBusConnection` and its unit tests.
+ Fix a race condition with D-Bus name ownership.
+ Drop `gio-launch-desktop` helper application in favour of
calling `sh` directly.
+ Fix win32 exception handling with C# exceptions.
+ Fix thread safety of `GUnixMountMonitor`.
+ Additional fixes to new thread pool attribute behaviour from
GLib 2.63.4 to check if sched_setattr() is allowed by system
policies before depending on it.
+ Fix memory leaks and corruption when freeing `GSource`s while
freeing a `GMainContext`.
+ Drop inappropriate installation of object manager example
documentation.
+ Varioius other bugs and fixes.
+ Updated translations.
- Update to version 2.63.5:
+ Fix behaviour of `g_file_move()` fallback code to not follow
symlinks.
+ Rename `--glib-min-version` argument of `gdbus-codegen` to
`--glib-min-required`.
+ Add gtk-doc checks to CI and fix a number of documentation
issues.
+ Add a debug message if `g_setenv()` or `g_unsetenv()` are used
after any threads have been spawned — this will be upgraded to
a warning in future.
+ Skip memory monitor tests if xdg-desktop-portal or dbusmock are
not available.
+ Change the `libmount` configure option from a boolean to a
Meson `feature`.
+ Do not return `target-uri` from `g_file_peek_path()` when
called on trash/recent files.
+ Drop new TLS certificate API for PKCS #11 backed certificates,
as the implementation is not ready yet (this is not an API
break as the API was added earlier in the 2.63 cycle).
+ Updated translations.
+ For changes from earlier in the dev cycle see the NEWS file.
- Rebase glib2-gdbus-codegen-version.patch.
OBS-URL: https://build.opensuse.org/request/show/792948
OBS-URL: https://build.opensuse.org/package/show/GNOME:Factory/glib2?expand=0&rev=424
2020-04-14 12:19:37 +02:00
BuildRequires : python3-base >= 3.5
2018-09-22 00:43:51 +02:00
# gdbus-codegen is run during the build, so we need python3-xml
2017-11-30 10:57:30 +01:00
BuildRequires : python3-xml
2017-08-31 09:45:56 +02:00
BuildRequires : xsltproc
# Needed for gresource
BuildRequires : pkgconfig(libelf) >= 0.8.12
2018-03-09 11:10:43 +01:00
BuildRequires : pkgconfig(libffi) >= 3.0.0
2022-09-13 09:32:50 +02:00
BuildRequires : pkgconfig(libpcre2-8) >= 10.32
2018-03-09 11:10:43 +01:00
BuildRequires : pkgconfig(mount) >= 2.28
2017-08-31 09:45:56 +02:00
BuildRequires : pkgconfig(zlib)
2022-03-01 11:10:45 +01:00
%if "%{flavor}" == "doc"
2022-04-04 15:39:19 +02:00
# Split-provides
Provides : glib2-devel:%{_datadir} /gtk-doc/html/gobject/index.html
%endif
%if "%{flavor}" == "doc"
2022-03-01 11:10:45 +01:00
BuildRequires : glib2-devel
2021-02-22 17:49:46 +01:00
BuildRequires : gtk-doc >= 1.32
%endif
2019-02-04 19:44:21 +01:00
%if %{with systemtap}
2019-11-07 11:53:51 +01:00
BuildRequires : systemtap-dtrace
BuildRequires : systemtap-headers
2019-02-04 19:44:21 +01:00
%endif
2007-01-05 16:49:20 +01:00
%description
2010-10-15 12:36:52 +02:00
GLib is a general-purpose utility library, which provides many useful
data types, macros, type conversions, string utilities, file utilities,
a main loop abstraction, and so on.
2007-01-05 16:49:20 +01:00
2022-03-01 11:10:45 +01:00
%if %{with doc}
This package provides the documentation for the GLib library.
%endif
2021-02-22 17:49:46 +01:00
2010-08-09 15:47:13 +02:00
%package tools
2017-09-14 13:45:01 +02:00
Summary : Tools from glib2, a general-purpose utility library
2020-11-17 10:48:10 +01:00
# ensure libgio-2_0-0 is updated before glib2-tools' ensures glib-compile-schema to
# be functional when the file trigger fires (boo#1178713)
2010-08-09 15:47:13 +02:00
Group : Development/Libraries/C and C++
2021-02-22 17:49:46 +01:00
Requires(post) : %{libgio} = %{version}
2010-08-09 15:47:13 +02:00
%description tools
2010-10-15 12:36:52 +02:00
GLib is a general-purpose utility library, which provides many useful
data types, macros, type conversions, string utilities, file utilities,
a main loop abstraction, and so on.
2010-08-09 15:47:13 +02:00
2011-07-07 09:44:57 +02:00
%package -n gio-branding-upstream
Summary : Upstream definitions of default settings and applications
2010-10-15 12:36:52 +02:00
Group : System/Libraries
2021-02-22 17:49:46 +01:00
Requires : %{libgio} = %{version}
Supplements: (%{libgio} and branding-upstream)
2018-03-09 11:10:43 +01:00
Conflicts : gio-branding
2011-07-07 09:44:57 +02:00
Provides : %{name} -branding-upstream = %{version}
Obsoletes : %{name} -branding-upstream < %{version}
Provides : gio-branding = %{version}
BuildArch : noarch
2008-04-09 21:41:41 +02:00
#BRAND: The /etc/gnome_defaults.conf allows to define arbitrary
#BRAND: applications as preferred defaults.
2011-07-07 11:14:15 +02:00
#BRAND: A /usr/share/glib-2.0/schemas/$NAME.gschema.override file can
#BRAND: be used to override the default value for GSettings keys. See
#BRAND: README.Gsettings-overrides for more details. The branding
#BRAND: package should then have proper Requires for features changed
#BRAND: with such an override file.
2008-04-09 21:41:41 +02:00
# NOTE: gnome_defaults is not an upstream feature, but a SuSE
# enhancement, but to conform branding conventions, the package is named
2011-07-07 09:44:57 +02:00
# as gio-branding-upstream.
2008-04-09 21:41:41 +02:00
2011-07-07 09:44:57 +02:00
%description -n gio-branding-upstream
This package provides upstream defaults for settings stored with
GSettings and applications used by the MIME system.
2008-04-09 21:41:41 +02:00
2007-01-05 16:49:20 +01:00
%package devel
2017-09-14 13:45:01 +02:00
Summary : Development files for glib, a general-purpose utility library
2008-04-06 05:42:23 +02:00
# Now require the subpackages too
2017-08-31 09:45:56 +02:00
Group : Development/Libraries/C and C++
2021-02-22 17:49:46 +01:00
Requires : %{libgio} = %{version}
Requires : %{libglib} = %{version}
Requires : %{libgmodule} = %{version}
Requires : %{libgobject} = %{version}
Requires : %{libgthread} = %{version}
2010-08-09 15:47:13 +02:00
Requires : glib2-tools = %{version}
2017-08-31 09:45:56 +02:00
Requires : glibc-devel
Requires : pkgconfig
2011-06-16 16:22:41 +02:00
# Required by gdbus-codegen
2017-11-30 10:57:30 +01:00
Requires : python3-xml
2023-10-11 13:43:33 +02:00
# GDbusTest launches dbus-daemon with a special env to not interfere with
# the real session bus.
Requires : %{_bindir} /dbus-daemon
2008-11-28 14:40:37 +01:00
#
2007-01-05 16:49:20 +01:00
%description devel
2010-10-15 12:36:52 +02:00
GLib is a general-purpose utility library, which provides many useful
data types, macros, type conversions, string utilities, file utilities,
a main loop abstraction, and so on.
2010-10-14 09:46:51 +02:00
2010-10-15 12:36:52 +02:00
This package contains the development files for GLib.
2010-10-14 09:46:51 +02:00
2010-10-15 12:36:52 +02:00
%package devel-static
2017-09-14 13:45:01 +02:00
Summary : Static libraries for glib, a general-purpose utility library
2010-10-15 12:36:50 +02:00
Group : Development/Libraries/C and C++
2017-08-31 09:45:56 +02:00
Requires : %{name} -devel = %{version}
2010-10-15 12:36:52 +02:00
%description devel-static
GLib is a general-purpose utility library, which provides many useful
data types, macros, type conversions, string utilities, file utilities,
a main loop abstraction, and so on.
This package contains static versions of the GLib libraries.
2021-02-22 17:49:46 +01:00
%package -n %{libglib}
2010-10-15 12:36:52 +02:00
Summary : General-Purpose Utility Library
Group : System/Libraries
2010-08-09 15:47:13 +02:00
Provides : %{name} = %{version}
Obsoletes : %{name} < %{version}
2008-11-28 14:40:37 +01:00
#
2008-04-06 05:42:23 +02:00
2021-02-22 17:49:46 +01:00
%description -n %{libglib}
2010-10-15 12:36:52 +02:00
GLib is a general-purpose utility library, which provides many useful
data types, macros, type conversions, string utilities, file utilities,
a main loop abstraction, and so on.
2008-04-06 05:42:23 +02:00
2021-02-22 17:49:46 +01:00
%package -n %{libgmodule}
2010-10-15 12:36:52 +02:00
Summary : General-Purpose Utility Library -- Library for Modules
Group : System/Libraries
2008-04-06 05:42:23 +02:00
2021-02-22 17:49:46 +01:00
%description -n %{libgmodule}
2010-10-15 12:36:52 +02:00
GLib is a general-purpose utility library, which provides many useful
data types, macros, type conversions, string utilities, file utilities,
a main loop abstraction, and so on.
The libgmodule library provides a portable way to dynamically load
object files (commonly known as 'plug-ins' ).
2008-04-06 05:42:23 +02:00
2021-02-22 17:49:46 +01:00
%package -n %{libgio}
2017-09-14 13:45:01 +02:00
Summary : A virtual file system library API
2022-04-04 15:39:19 +02:00
Group : System/Libraries
2019-03-14 11:25:20 +01:00
# The tools are useful for people having libgio
2018-09-22 00:43:51 +02:00
# bnc#555605: shared-mime-info is required by libgio to properly detect mime types, but not during build
#!BuildIgnore: shared-mime-info
2017-08-31 09:45:56 +02:00
Requires : %{name} -tools
# bnc#678518: libgio interacts with others by means of dbus-launch
2023-10-11 13:43:33 +02:00
Requires : %{_bindir} /dbus-launch
2011-07-07 09:44:57 +02:00
Requires : gio-branding = %{version}
2010-09-27 16:06:20 +02:00
Requires : shared-mime-info
2011-07-07 09:44:57 +02:00
# Needed for branding packages
Provides : gio = %{version}
2008-04-06 05:42:23 +02:00
# Temporarily disable this, pending further discussion
# Recommends: gvfs
2021-02-22 17:49:46 +01:00
%description -n %{libgio}
2010-10-15 12:36:52 +02:00
GLib is a general-purpose utility library, which provides many useful
data types, macros, type conversions, string utilities, file utilities,
a main loop abstraction, and so on.
GIO provides a modern, easy-to-use VFS API.
2008-04-06 05:42:23 +02:00
2021-02-22 17:49:46 +01:00
%package -n %{libgthread}
2017-09-14 13:45:01 +02:00
Summary : Portable API from glib wrapping system threads
2010-10-15 12:36:52 +02:00
Group : System/Libraries
2008-04-06 05:42:23 +02:00
2021-02-22 17:49:46 +01:00
%description -n %{libgthread}
2010-10-15 12:36:52 +02:00
GLib is a general-purpose utility library, which provides many useful
data types, macros, type conversions, string utilities, file utilities,
a main loop abstraction, and so on.
The libgthread library provides a portable way to write multi-threaded
software.
2008-04-06 05:42:23 +02:00
2021-02-22 17:49:46 +01:00
%package -n %{libgobject}
2017-09-14 13:45:01 +02:00
Summary : Object-Oriented Framework for C
2010-10-15 12:36:52 +02:00
Group : System/Libraries
2008-04-06 05:42:23 +02:00
2021-02-22 17:49:46 +01:00
%description -n %{libgobject}
2010-10-15 12:36:52 +02:00
GLib is a general-purpose utility library, which provides many useful
data types, macros, type conversions, string utilities, file utilities,
a main loop abstraction, and so on.
The GObject library provides an object-oriented framework for C.
2008-04-06 05:42:23 +02:00
2020-11-26 13:22:38 +01:00
%package tests-devel
2019-03-14 11:25:20 +01:00
Summary : Tests for the glib2 package
Group : Development/Libraries/C and C++
Requires : %{name} -devel = %{version}
2021-02-22 17:49:46 +01:00
Requires : %{name} -tests = %{version} -%{release}
Provides : %{name} -tests = %{version} -%{release}
Obsoletes : %{name} -tests < %{version} -%{release}
2019-03-14 11:25:20 +01:00
2020-11-26 13:22:38 +01:00
%description tests-devel
The glib2-tests-devel package contains tests that can be used to verify
2019-03-14 11:25:20 +01:00
the functionality of the installed glib2 package.
2007-08-09 15:25:12 +02:00
%lang_package
2017-08-31 09:45:56 +02:00
2007-01-05 16:49:20 +01:00
%prep
2023-11-28 14:23:55 +01:00
%autosetup -p1 -n glib-%{version}
2023-01-23 19:25:51 +01:00
2017-08-31 09:45:56 +02:00
cp -a %{SOURCE1} %{SOURCE2} %{SOURCE5} .
cp -a %{SOURCE4} gnome_defaults.conf
2018-03-09 11:10:43 +01:00
# replace /usr/bin/env shebangs
2018-09-22 00:43:51 +02:00
# /usr/bin/env @PYTHON@ -> /usr/bin/python3
grep " %{_bindir} / e n v @ P Y T H O N @ " . -rl | xargs sed -i " s | %{_bindir} / e n v @ P Y T H O N @ | %{_bindir} / p y t h o n 3 | g "
2020-10-22 14:22:00 +02:00
sed -i " s / 1 . 3 2 . 1 / 1 . 3 2 / " docs/reference/meson.build
2010-12-14 19:22:06 +01:00
2007-01-05 16:49:20 +01:00
%build
2019-11-07 11:53:51 +01:00
%if %{with systemtap}
%global _lto_cflags %{nil}
%else
2019-05-01 23:22:30 +02:00
%global _lto_cflags %{_lto_cflags} -ffat-lto-objects
2019-11-07 11:53:51 +01:00
%endif
2018-09-22 00:43:51 +02:00
%meson \
2019-03-14 11:25:20 +01:00
--default-library=both \
-Dselinux=enabled \
-Dman=true \
2022-03-01 11:10:45 +01:00
%if "%{flavor}" == "doc"
2020-02-19 13:28:58 +01:00
-Dgtk_doc=true \
2020-10-22 10:50:43 +02:00
%endif
2019-02-04 19:44:21 +01:00
%if %{with systemtap}
2019-03-14 11:25:20 +01:00
-Dsystemtap=true \
-Ddtrace=true \
2018-09-22 00:43:51 +02:00
%else
2019-03-14 11:25:20 +01:00
-Dsystemtap=false \
-Ddtrace=false \
2019-02-13 11:33:55 +01:00
%endif
2019-03-14 11:25:20 +01:00
-Dinstalled_tests=true \
%{nil}
%meson_build
2019-02-13 11:33:55 +01:00
2007-01-05 16:49:20 +01:00
%install
2018-09-22 00:43:51 +02:00
%meson_install
2022-03-01 11:10:45 +01:00
%if "%{flavor}" == "doc"
find %{buildroot} /%{_prefix} -not -path " * %{_datadir} / g t k - d o c / * " -delete || :
%else
2018-09-22 00:43:51 +02:00
%find_lang glib20 %{?no_lang_C}
2010-10-15 12:36:52 +02:00
mkdir -p %{buildroot} %{_sysconfdir} /profile.d
install -D -m0644 glib2.sh %{buildroot} %{_sysconfdir} /profile.d/zzz-glib2.sh
install -D -m0644 glib2.csh %{buildroot} %{_sysconfdir} /profile.d/zzz-glib2.csh
install -D -m0644 gnome_defaults.conf %{buildroot} %{_sysconfdir} /gnome_defaults.conf
2010-02-11 19:05:05 +01:00
# default apps magic
2010-10-15 12:36:52 +02:00
mkdir -p %{buildroot} %{_localstatedir} /cache/gio-2.0 %{buildroot} %{_datadir} /applications
2021-02-22 17:49:46 +01:00
>> %{buildroot} %{_localstatedir} /cache/gio-2.0/gnome-mimeapps.list
>> %{buildroot} %{_localstatedir} /cache/gio-2.0/xfce-mimeapps.list
>> %{buildroot} %{_localstatedir} /cache/gio-2.0/lxde-mimeapps.list
2021-09-09 10:49:48 +02:00
>> %{buildroot} %{_localstatedir} /cache/gio-2.0/pantheon-mimeapps.list
2022-03-25 19:37:46 +01:00
>> %{buildroot} %{_localstatedir} /cache/gio-2.0/budgie-mimeapps.list
2023-04-21 09:20:00 +02:00
>> %{buildroot} %{_localstatedir} /cache/gio-2.0/mate-mimeapps.list
2016-02-18 16:27:47 +01:00
ln -s %{_localstatedir} /cache/gio-2.0/gnome-mimeapps.list %{buildroot} %{_datadir} /applications/gnome-mimeapps.list
2010-02-11 19:05:05 +01:00
# gio-querymodules magic
%if "%{_lib}" == "lib64"
2021-02-22 17:49:46 +01:00
mv -T %{buildroot} %{_bindir} /gio-querymodules %{buildroot} %{_bindir} /gio-querymodules-64
2023-10-24 16:12:11 +02:00
sed -i -e " / ^ g i o _ q u e r y m o d u l e s = / s / g i o - q u e r y m o d u l e s / g i o - q u e r y m o d u l e s - 6 4 / " %{buildroot} %{_libdir} /pkgconfig/gio-2.0.pc
2010-02-11 19:05:05 +01:00
%endif
2018-09-22 00:43:51 +02:00
mkdir -p %{buildroot} %{_libdir} /gio/modules
2021-02-22 17:49:46 +01:00
>> %{buildroot} %{_libdir} /gio/modules/giomodule.cache
2010-08-09 15:47:13 +02:00
# gsettings magic
2021-02-22 17:49:46 +01:00
>> %{buildroot} %{_datadir} /glib-2.0/schemas/gschemas.compiled
2010-08-09 15:47:13 +02:00
# Install rpm macros
2019-05-09 22:25:35 +02:00
mkdir -p %{buildroot} %{_rpmmacrodir}
2021-02-22 17:49:46 +01:00
cp -t%{buildroot} %{_rpmmacrodir} %{SOURCE6}
2015-09-04 13:33:06 +02:00
# Install zsh completion for gsettings
mkdir -p %{buildroot} %{_datadir} /zsh/site-functions/
2021-02-22 17:49:46 +01:00
cp -T %{SOURCE8} %{buildroot} %{_datadir} /zsh/site-functions/_gsettings
2020-10-22 10:50:43 +02:00
mkdir -p %{buildroot} %{_datadir} /gtk-doc/html
2017-09-14 13:45:01 +02:00
%fdupes %{buildroot} /%{_prefix}
2009-07-31 19:21:51 +02:00
2019-05-27 09:46:23 +02:00
# Too many users complain about schemas compiled with wrong permissions
2022-03-01 11:10:45 +01:00
# when in fact the system just honours their umask setting
2021-02-22 17:49:46 +01:00
# subshell restores umask for paranoia mode
%define compile_schemas \
(umask 022 && %{_bindir} /glib-compile-schemas %{_datadir} /glib-2.0/schemas)
%filetriggerin -n glib2-tools -- %{_datadir} /glib-2.0/schemas
%{compile_schemas}
2017-08-31 09:45:56 +02:00
%filetriggerpostun -n glib2-tools -- %{_datadir} /glib-2.0/schemas
2021-02-22 17:49:46 +01:00
%{compile_schemas}
%post -n %{libglib} -p /sbin/ldconfig
%post -n %{libgobject} -p /sbin/ldconfig
%post -n %{libgthread} -p /sbin/ldconfig
2021-04-22 09:43:06 +02:00
2021-02-22 17:49:46 +01:00
%post -n %{libgio}
%{ldconfig}
2023-04-21 09:20:00 +02:00
for ENV in gnome xfce lxde pantheon mate
2021-02-22 17:49:46 +01:00
do mimeapps=" %{_localstatedir} / c a c h e / g i o - 2 . 0 / $ E N V - m i m e a p p s . l i s t " &&
2021-07-19 09:43:27 +02:00
2>/dev/null <" $ { m i m e a p p s } " || cat >" $ { m i m e a p p s } " <<EOF
2021-02-22 17:49:46 +01:00
# Dummy file. Install desktop-file-utils to get better defaults.
2017-10-04 18:11:44 +02:00
[Default Applications]
EOF
done
2022-03-01 11:10:45 +01:00
%endif
2008-04-06 05:42:23 +02:00
2019-03-14 11:25:20 +01:00
%check
### FIXME ### Figure out how to run the "stable tests" only ref info from upstream.
#%%meson_test
2008-04-06 05:42:23 +02:00
%post -n libgmodule-2_0-0 -p /sbin/ldconfig
2021-02-22 17:49:46 +01:00
%postun -n %{libglib} -p %{ldconfig}
%postun -n %{libgobject} -p %{ldconfig}
%postun -n %{libgthread} -p %{ldconfig}
%postun -n %{libgio} -p %{ldconfig}
%postun -n %{libgmodule} -p %{ldconfig}
2021-04-22 09:43:06 +02:00
2022-03-01 11:10:45 +01:00
%if "%{flavor}" == "doc"
%files
%{_datadir} /gtk-doc/html/gio
%{_datadir} /gtk-doc/html/glib
%{_datadir} /gtk-doc/html/gobject
%else
2010-08-09 15:47:13 +02:00
%files tools
2023-03-20 13:47:33 +01:00
%license LICENSES/LGPL-2.1-or-later.txt
2022-09-13 09:32:50 +02:00
%doc README.md
2014-04-03 22:37:43 +02:00
%{_bindir} /gapplication
2010-08-09 15:47:13 +02:00
%{_bindir} /gdbus
2016-09-08 23:24:14 +02:00
%{_bindir} /gio
2010-08-09 15:47:12 +02:00
%{_bindir} /gio-querymodules*
2010-08-09 15:47:13 +02:00
%{_bindir} /glib-compile-schemas
2012-02-08 11:55:24 +01:00
%{_bindir} /gresource
2010-08-09 15:47:13 +02:00
%{_bindir} /gsettings
2022-09-13 09:32:50 +02:00
%{_libexecdir} /gio-launch-desktop
2012-09-07 17:28:34 +02:00
%dir %{_datadir} /bash-completion
%dir %{_datadir} /bash-completion/completions
2014-04-03 22:37:43 +02:00
%{_datadir} /bash-completion/completions/gapplication
2012-09-07 17:28:34 +02:00
%{_datadir} /bash-completion/completions/gdbus
2018-09-22 00:43:51 +02:00
%{_datadir} /bash-completion/completions/gio
2012-09-07 17:28:34 +02:00
%{_datadir} /bash-completion/completions/gresource
%{_datadir} /bash-completion/completions/gsettings
2015-09-04 13:33:06 +02:00
%dir %{_datadir} /zsh
%dir %{_datadir} /zsh/site-functions
%{_datadir} /zsh/site-functions/_gsettings
2014-04-03 22:37:43 +02:00
%{_mandir} /man1/gapplication.1%{?ext_man}
%{_mandir} /man1/gdbus.1%{?ext_man}
2016-09-08 23:24:14 +02:00
%{_mandir} /man1/gio.1%{?ext_man}
2014-04-03 22:37:43 +02:00
%{_mandir} /man1/gio-querymodules.1%{?ext_man}
%{_mandir} /man1/glib-compile-schemas.1%{?ext_man}
%{_mandir} /man1/gresource.1%{?ext_man}
%{_mandir} /man1/gsettings.1%{?ext_man}
2010-08-09 15:47:13 +02:00
# We put those files here, but they don't really belong here. They just don't
# have a better home... The zzz-glib2 scripts could arguably be in
# libglib-2_0-0 but that would break the shared library policy.
%{_sysconfdir} /profile.d/zzz-glib2.*
2008-04-09 21:41:41 +02:00
2011-07-07 09:44:57 +02:00
%files -n gio-branding-upstream
2023-03-20 13:47:33 +01:00
%license LICENSES/LGPL-2.1-or-later.txt
2011-07-07 09:44:57 +02:00
%doc README.Gsettings-overrides
2008-04-06 05:42:23 +02:00
%config (noreplace) %{_sysconfdir} /gnome_defaults.conf
2021-02-22 17:49:46 +01:00
%files -n %{libglib}
2023-03-20 13:47:33 +01:00
%license LICENSES/LGPL-2.1-or-later.txt
2022-09-13 09:32:50 +02:00
%doc NEWS
2011-06-16 16:22:41 +02:00
%{_libdir} /libglib*.so.*
2008-04-06 05:42:23 +02:00
2021-02-22 17:49:46 +01:00
%files -n %{libgmodule}
2023-03-20 13:47:33 +01:00
%license LICENSES/LGPL-2.1-or-later.txt
2011-06-16 16:22:41 +02:00
%{_libdir} /libgmodule*.so.*
2008-04-06 05:42:23 +02:00
2021-02-22 17:49:46 +01:00
%files -n %{libgobject}
2023-03-20 13:47:33 +01:00
%license LICENSES/LGPL-2.1-or-later.txt
2011-06-16 16:22:41 +02:00
%{_libdir} /libgobject*.so.*
2008-04-06 05:42:23 +02:00
2021-02-22 17:49:46 +01:00
%files -n %{libgthread}
2023-03-20 13:47:33 +01:00
%license LICENSES/LGPL-2.1-or-later.txt
2011-06-16 16:22:41 +02:00
%{_libdir} /libgthread*.so.*
2008-04-06 05:42:23 +02:00
2021-02-22 17:49:46 +01:00
%files -n %{libgio}
2023-03-20 13:47:33 +01:00
%license LICENSES/LGPL-2.1-or-later.txt
2011-06-16 16:22:41 +02:00
%{_libdir} /libgio*.so.*
2010-07-21 11:18:09 +02:00
%dir %{_libdir} /gio
%dir %{_libdir} /gio/modules
%ghost %{_libdir} /gio/modules/giomodule.cache
2010-08-09 15:47:13 +02:00
%dir %{_datadir} /glib-2.0/
%dir %{_datadir} /glib-2.0/schemas/
%ghost %{_datadir} /glib-2.0/schemas/gschemas.compiled
2016-02-18 16:27:47 +01:00
%{_datadir} /applications/gnome-mimeapps.list
2008-04-02 19:05:41 +02:00
%dir %{_localstatedir} /cache/gio-2.0
2016-01-21 15:20:02 +01:00
%ghost %{_localstatedir} /cache/gio-2.0/gnome-mimeapps.list
%ghost %{_localstatedir} /cache/gio-2.0/xfce-mimeapps.list
%ghost %{_localstatedir} /cache/gio-2.0/lxde-mimeapps.list
2021-09-09 10:49:48 +02:00
%ghost %{_localstatedir} /cache/gio-2.0/pantheon-mimeapps.list
2022-03-25 19:37:46 +01:00
%ghost %{_localstatedir} /cache/gio-2.0/budgie-mimeapps.list
2023-04-21 09:20:00 +02:00
%ghost %{_localstatedir} /cache/gio-2.0/mate-mimeapps.list
2007-01-05 16:49:20 +01:00
%files devel
2023-03-20 13:47:33 +01:00
%license LICENSES/LGPL-2.1-or-later.txt
2011-06-16 16:22:41 +02:00
%{_bindir} /gdbus-codegen
2012-01-17 17:07:41 +01:00
%{_bindir} /glib-compile-resources
2010-08-09 15:47:13 +02:00
%{_bindir} /glib-genmarshal
%{_bindir} /glib-gettextize
%{_bindir} /glib-mkenums
%{_bindir} /gobject-query
%{_bindir} /gtester
%{_bindir} /gtester-report
2018-03-09 11:10:43 +01:00
%{_mandir} /man?/gdbus-codegen*%{ext_man}
%{_mandir} /man?/glib-compile-resources*%{ext_man}
%{_mandir} /man?/glib-genmarshal*%{ext_man}
%{_mandir} /man?/glib-gettextize*%{ext_man}
%{_mandir} /man?/glib-mkenums*%{ext_man}
%{_mandir} /man?/gobject-query*%{ext_man}
%{_mandir} /man?/gtester*%{ext_man}
2011-12-22 21:35:05 +01:00
%dir %{_datadir} /aclocal
%{_datadir} /aclocal/glib-2.0.m4
%{_datadir} /aclocal/glib-gettext.m4
%{_datadir} /aclocal/gsettings.m4
2016-02-19 16:01:43 +01:00
%dir %{_datadir} /gettext/its/
%{_datadir} /gettext/its/gschema*
2010-08-09 15:47:13 +02:00
%dir %{_datadir} /glib-2.0/
2023-09-12 10:20:17 +02:00
%{_datadir} /glib-2.0/dtds/
2010-08-09 15:47:13 +02:00
%{_datadir} /glib-2.0/gdb/
%{_datadir} /glib-2.0/gettext/
2013-03-13 23:57:57 +01:00
%{_datadir} /glib-2.0/codegen/
2010-08-09 15:47:13 +02:00
%{_datadir} /glib-2.0/schemas/gschema.dtd
2017-02-22 21:40:29 +01:00
%{_datadir} /glib-2.0/valgrind/
2007-01-05 16:49:20 +01:00
%{_includedir} /glib-2.0
2008-01-23 20:59:47 +01:00
%{_includedir} /gio-unix-2.0
2007-01-05 16:49:20 +01:00
%{_libdir} /lib*.so
2010-08-09 15:47:13 +02:00
%dir %{_libdir} /glib-2.0/
%{_libdir} /glib-2.0/include/
2007-01-05 16:49:20 +01:00
%{_libdir} /pkgconfig/*.pc
2011-06-16 16:22:41 +02:00
%{_datadir} /gdb/auto-load/%{_libdir} /*-gdb.py
2019-02-04 19:44:21 +01:00
%if %{with systemtap}
2019-11-07 11:53:51 +01:00
%dir %{_datadir} /systemtap
%dir %{_datadir} /systemtap/tapset
2018-09-22 00:43:51 +02:00
%dir %{_datadir} /systemtap/tapset/*
%{_datadir} /systemtap/tapset/*/libgio-*.so.*.stp
%{_datadir} /systemtap/tapset/*/libglib-*.so.*.stp
%{_datadir} /systemtap/tapset/*/libgobject-*.so.*.stp
2019-02-04 19:44:21 +01:00
%endif
2019-05-09 22:25:35 +02:00
%{_rpmmacrodir} /macros.glib2
2018-09-22 00:43:51 +02:00
# Own these directories to avoid build requirement on gdb
# only for directories ownership
2009-10-05 22:26:56 +02:00
%dir %{_datadir} /gdb
%dir %{_datadir} /gdb/auto-load
2011-06-16 16:22:41 +02:00
%dir %{_datadir} /gdb/auto-load%{_prefix}
%dir %{_datadir} /gdb/auto-load%{_libdir}
2022-03-01 11:10:45 +01:00
# Own these directories to not avoid breakages throughout the project
%dir %{_datadir} /gtk-doc
%dir %{_datadir} /gtk-doc/html
2010-10-15 12:36:52 +02:00
%files devel-static
2023-03-20 13:47:33 +01:00
%license LICENSES/LGPL-2.1-or-later.txt
2010-10-15 12:36:52 +02:00
%{_libdir} /lib*.a
2007-11-29 22:04:32 +01:00
2018-09-22 00:43:51 +02:00
%files lang -f glib20.lang
2023-03-20 13:47:33 +01:00
%license LICENSES/LGPL-2.1-or-later.txt
2018-09-22 00:43:51 +02:00
2020-11-26 13:22:38 +01:00
%files tests-devel
2023-03-20 13:47:33 +01:00
%license LICENSES/LGPL-2.1-or-later.txt
2019-03-14 11:25:20 +01:00
%{_libexecdir} /installed-tests
2022-03-01 11:10:45 +01:00
%attr (0755 - -) %{_libexecdir} /installed-tests/glib/taptestrunner.py
%attr (0755 - -) %{_libexecdir} /installed-tests/glib/x-content/unix-software/autorun.sh
2019-03-14 11:25:20 +01:00
%{_datadir} /installed-tests
2022-03-01 11:10:45 +01:00
%endif
2019-03-14 11:25:20 +01:00
2007-02-19 21:31:30 +01:00
%changelog