#!/usr/bin/bash # JOBoRun : Jwm OpenBox Obarun RUNit # Maintainer : Joe Bo Run # PkgSource : url="https://git.disroot.org/joborun-pkg/jobcore/src/branch/main/$pkgname" # Website : https://pozol.eu #-----------------------------------------| DESCRIPTION |--------------------------------------- pkgbase=glib2 pkgname=(glib2 glib2-devel) # glib2-docs) pkgver=2.80.4 pkgrel=01 pkgdesc="Low level core library" #url="https://wiki.gnome.org/Projects/GLib" url="https://gitlab.gnome.org/GNOME/glib" depends=(bash glibc libffi pcre2 util-linux-libs zlib) # libsysprof-capture makedepends=(gettext git gobject-introspection python-packaging libelf meson python shared-mime-info util-linux libxslt) # gi-docgen dconf for glib2-docs checkdepends=(desktop-file-utils glib2) #options=(debug staticlibs) ### uncomment this to have the debug pkg produced options=(staticlibs) # _commit=763cc3b238398614c20069fd67642730e3a6519b # tags/2.80.0^0 source=( # "git+https://gitlab.gnome.org/GNOME/glib.git#commit=$_commit" "git+https://gitlab.gnome.org/GNOME/glib.git?signed#tag=$pkgver" "git+https://gitlab.gnome.org/GNOME/gvdb.git" 0001-glib-compile-schemas-Remove-noisy-deprecation-warnin.patch gio-querymodules.hook glib-compile-schemas.hook) #pkgver() { # cd glib # git describe --tags | sed 's/[^-]*-g/r&/;s/-/+/g' #} prepare() { cd glib # Suppress noise from glib-compile-schemas.hook git apply -3 ../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 -c protocol.allow=never submodule update } build() { # 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" arch-meson glib build \ --default-library both \ -D glib_debug=disabled \ -D selinux=disabled \ -D sysprof=disabled \ -D documentation=false \ -D introspection=enabled \ -D man-pages=enabled meson compile -C build } # Read ./note about the reason of the failing test, it is because we refuse to let dbus run! #check() { # meson test -C build --no-suite flaky --no-suite slow --print-errorlogs #} # # You can run this check, get the 2 failured listed in "note" comment this and rerun makepkg without -f # _pick() { local p="$1" f d; shift for f; do d="$srcdir/$p/${f#$pkgdir/}" mkdir -p "$(dirname "$d")" mv "$f" "$d" rmdir -p --ignore-fail-on-non-empty "$(dirname "$f")" done } package_glib2() { depends+=(libmount.so libffi.so) provides+=(libg{lib,io,irepository,module,object,thread}-2.0.so) optdepends=('python: gdbus-codegen, glib-genmarshal, glib-mkenums, gtester-report' 'dconf: GSettings storage backend' 'glib2-devel: development tools' 'libelf: gresource inspection tool' 'python-packaging: gdbus-codegen') meson install -C build --destdir "$pkgdir" install -Dt "$pkgdir/usr/share/libalpm/hooks" -m644 *.hook touch "$pkgdir/usr/lib/gio/modules/.keep" python -m compileall -d /usr/share/glib-2.0/codegen \ "$pkgdir/usr/share/glib-2.0/codegen" python -O -m compileall -d /usr/share/glib-2.0/codegen \ "$pkgdir/usr/share/glib-2.0/codegen" # BUILT THIS WITH gtk-docs disabled above, since we are borrowing the docs pkg from Arch instead of # building it. The following is to split the gtk-doc part into a separate pkg. cd "$pkgdir" # Split docs # if not produced/disabled nothing to pick # _pick docs usr/share/doc # Split devel _pick devel usr/bin/gdbus-codegen _pick devel usr/bin/glib-{mkenums,genmarshal} _pick devel usr/bin/gresource _pick devel usr/bin/gtester{,-report} _pick devel usr/share/gdb/ _pick devel usr/share/glib-2.0/gdb/ _pick devel usr/share/glib-2.0/codegen/ _pick devel usr/share/bash-completion/completions/gresource _pick devel usr/share/man/man1/gdbus-codegen.1 _pick devel usr/share/man/man1/glib-{mkenums,genmarshal}.1 _pick devel usr/share/man/man1/gresource.1 _pick devel usr/share/man/man1/gtester{,-report}.1 } package_glib2-devel() { pkgdesc+=" - development files" depends=( glib2 glibc libelf python python-packaging ) mv devel/* "$pkgdir" } #package_glib2-docs() { # pkgdesc="Documentation for GLib" # depends=() # license+=(LicenseRef-Public-Domain) # mv docs/* "$pkgdir" # install -Dt "$pkgdir/usr/share/licenses/$pkgname" -m644 glib/docs/reference/COPYING #} #---- arch license gpg-key & sha256sums ---- arch=(x86_64) license=(LGPL-2.1-or-later) validpgpkeys=(923B7025EE03C1C59F42684CF0942E894B2EAFA0) # Philip Withnall b2sums=('ec233c9dd6836fb362e45092cd8122757e9faaff2ed910818ecc9e88359777a5935a93f6ed26a649437c9014354bad1cc122716462c92335a280d685cf3ffc71' 'SKIP' '94c73ca7070c239494873dd52d6ee09382bbb5b1201f7afd737cfa140b1a2fb0744b2c2831baf3943d1d072550c35888d21ce6f19f89481ff9d1a60d9a0b30e0' '14c9211c0557f6d8d9a914f1b18b7e0e23f79f4abde117cb03ab119b95bf9fa9d7a712aa0a29beb266468aeb352caa3a9e4540503cfc9fe0bbaf764371832a96' 'acc2f474139e535f4bdd70ac22a9150f786b3395e679b14d0d3fbb9361d511bb1b5069d95b2a7ac9c0f3d901b03a0c037eb273446ba00764191b30a777bd2bc9') sha256sums=(7d2cdd34057fa78d5ad97d6b966ec60b63e7b76e1775280f339b3eb33aab2c1e # glib SKIP # gvdb 7f8ee5db60987f0d0feba84643e1cf988c98a294a681fb8d4fce1a5b2c25d1d3 # 0001-glib-compile-schemas-Remove-noisy-deprecation-warnin.patch 557c88177f011ced17bdeac1af3f882b2ca33b386a866fdf900b35f927a2bbe8 # gio-querymodules.hook fe31399eb057d24a37062bcae6f88ca0778a91b85737f8110a03baa8bfc64fec) # glib-compile-schemas.hook ## db32471da9d6d049aaff669a48863010061bc265c8763746001e9678ae6cf042 glib2-2.80.4-01-x86_64.pkg.tar.lz ## fd76873d4fff709327bf3d5400c90f80e1cf9ce01b5773516c70446d647f670c glib2-devel-2.80.4-01-x86_64.pkg.tar.lz