2024-04-29 14:51:04 +08:00
|
|
|
# Maintainer: Future Linux Team <futurelinux@163.com>
|
|
|
|
|
|
|
|
pkgname=glib2
|
|
|
|
pkgver=2.80.0
|
2024-04-29 15:01:12 +08:00
|
|
|
pkgrel=2
|
2024-04-29 14:51:04 +08:00
|
|
|
pkgdesc="Low level core library"
|
|
|
|
arch=('x86_64')
|
|
|
|
url="https://gitlab.gnome.org/GNOME/glib"
|
|
|
|
license=('LGPL-2.1-or-later')
|
|
|
|
depends=('libffi' 'pcre2' 'util-linux' 'zlib' 'python-packaging')
|
2024-04-29 15:01:12 +08:00
|
|
|
makedepends=('dbus' 'gettext' 'libelf' 'meson' 'python-docutils' 'libxslt' 'git' 'gobject-introspection')
|
|
|
|
source=(git+https://gitlab.com/future-linux/clone/glib.git#tag=${pkgver}
|
|
|
|
git+https://gitlab.com/future-linux/clone/gvdb.git
|
|
|
|
0001-glib-compile-schemas-Remove-noisy-deprecation-warnin.patch
|
2024-04-29 14:51:04 +08:00
|
|
|
gio-querymodules.hook
|
|
|
|
glib-compile-schemas.hook)
|
2024-04-29 15:01:12 +08:00
|
|
|
sha256sums=(SKIP
|
|
|
|
SKIP
|
|
|
|
7f8ee5db60987f0d0feba84643e1cf988c98a294a681fb8d4fce1a5b2c25d1d3
|
2024-04-29 14:51:04 +08:00
|
|
|
b6fb5f07643c234bd0bde6c4899001effd270c17132e546cec535cb15771d269
|
|
|
|
64ae5597dda3cc160fc74be038dbe6267d41b525c0c35da9125fbf0de27f9b25)
|
|
|
|
|
|
|
|
prepare() {
|
2024-04-29 15:01:12 +08:00
|
|
|
cd glib
|
|
|
|
|
|
|
|
git apply -3 ${srcdir}/0001-glib-compile-schemas-Remove-noisy-deprecation-warnin.patch
|
|
|
|
|
|
|
|
git submodule init
|
|
|
|
git submodule set-url subprojects/gvdb ${srcdir}/gvdb
|
|
|
|
git -c protocol.file.allow=always submodule update
|
2024-04-29 14:51:04 +08:00
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
build() {
|
2024-04-29 15:01:12 +08:00
|
|
|
cd glib
|
2024-04-29 14:51:04 +08:00
|
|
|
|
|
|
|
# Produce more debug info: GLib has a lot of useful macros
|
|
|
|
CFLAGS+=" -g3"
|
|
|
|
CXXFLAGS+=" -g3"
|
|
|
|
|
|
|
|
# use fat LTO objects for static libraries
|
|
|
|
CFLAGS+=" -ffat-lto-objects"
|
|
|
|
CXXFLAGS+=" -ffat-lto-objects"
|
|
|
|
|
2024-04-29 15:01:12 +08:00
|
|
|
meson setup build \
|
|
|
|
--prefix=/usr \
|
|
|
|
--libdir=/usr/lib64 \
|
|
|
|
--buildtype=release \
|
|
|
|
-Dintrospection=enabled \
|
|
|
|
-Dman-pages=enabled
|
2024-04-29 14:51:04 +08:00
|
|
|
|
|
|
|
meson compile -C build
|
|
|
|
}
|
|
|
|
|
|
|
|
package() {
|
2024-04-29 15:01:12 +08:00
|
|
|
cd glib
|
2024-04-29 14:51:04 +08:00
|
|
|
|
|
|
|
meson install -C build --destdir ${pkgdir}
|
|
|
|
|
|
|
|
install -Dt ${pkgdir}/usr/share/libalpm/hooks -m644 ${srcdir}/*.hook
|
2024-04-29 15:01:12 +08:00
|
|
|
|
|
|
|
touch ${pkgdir}/usr/lib64/gio/modules/.keep
|
|
|
|
|
|
|
|
python3 -m compileall -d /usr/share/glib-2.0/codegen ${pkgdir}/usr/share/glib-2.0/codegen
|
|
|
|
python3 -O -m compileall -d /usr/share/glib-2.0/codegen ${pkgdir}/usr/share/glib-2.0/codegen
|
|
|
|
|
2024-04-29 14:51:04 +08:00
|
|
|
}
|