diff options
author | Nicola Murino | 2022-04-18 21:16:38 +0200 |
---|---|---|
committer | Nicola Murino | 2022-04-18 21:16:38 +0200 |
commit | 9deab607b42870f68bf06a03b6bb9f19cba3d296 (patch) | |
tree | 83af4a707693e45c61da18c975e1cdf398f874e7 | |
parent | 4d6c0ccbf76fa0e8bbd9f3a756bfa2849edf17eb (diff) | |
download | aur-9deab607b42870f68bf06a03b6bb9f19cba3d296.tar.gz |
update to 2.74.1
If you have issues with static builds try to add -DGLIB_STATIC_COMPILATION
and -DGOBJECT_STATIC_COMPILATION to your CFLAGS
-rw-r--r-- | .SRCINFO | 8 | ||||
-rw-r--r-- | 0001-Use-CreateFile-on-Win32-to-make-sure-g_unlink-always.patch | 18 | ||||
-rw-r--r-- | PKGBUILD | 28 | ||||
-rw-r--r-- | glib-prefer-constructors-over-DllMain.patch | 63 |
4 files changed, 28 insertions, 89 deletions
@@ -1,6 +1,6 @@ pkgbase = mingw-w64-glib2 pkgdesc = Low level core library (mingw-w64) - pkgver = 2.70.4 + pkgver = 2.72.1 pkgrel = 1 url = https://wiki.gnome.org/Projects/GLib arch = any @@ -15,12 +15,10 @@ pkgbase = mingw-w64-glib2 options = !buildflags options = staticlibs options = !emptydirs - source = git+https://gitlab.gnome.org/GNOME/glib.git?signed#tag=2.70.4 + source = git+https://gitlab.gnome.org/GNOME/glib.git?signed#tag=2.72.1 source = 0001-Use-CreateFile-on-Win32-to-make-sure-g_unlink-always.patch - source = glib-prefer-constructors-over-DllMain.patch validpgpkeys = 923B7025EE03C1C59F42684CF0942E894B2EAFA0 sha256sums = SKIP - sha256sums = c2fa65ddf9cdef61107c0c414997a1a2ec17212303b73b93b2503cb8a0cb9f5d - sha256sums = 3c9848916492435852e4e27bee608a0b2146e146c40f889d725acffd9409aae8 + sha256sums = 38d2a038b39cef7a2452ddf4b04422e17a40745cc9b1fc8297c24320cecca7f9 pkgname = mingw-w64-glib2 diff --git a/0001-Use-CreateFile-on-Win32-to-make-sure-g_unlink-always.patch b/0001-Use-CreateFile-on-Win32-to-make-sure-g_unlink-always.patch index 9893c0aa77a0..602e08c0088f 100644 --- a/0001-Use-CreateFile-on-Win32-to-make-sure-g_unlink-always.patch +++ b/0001-Use-CreateFile-on-Win32-to-make-sure-g_unlink-always.patch @@ -1,12 +1,12 @@ -diff -rupN --no-dereference glib-2.69.2/gio/tests/org.gtk.test.gschema.override.orig glib-2.69.2-new/gio/tests/org.gtk.test.gschema.override.orig ---- glib-2.69.2/gio/tests/org.gtk.test.gschema.override.orig 2021-08-19 17:15:24.712496300 +0200 -+++ glib-2.69.2-new/gio/tests/org.gtk.test.gschema.override.orig 1970-01-01 01:00:00.000000000 +0100 +diff -rupN --no-dereference glib-2.72.0/gio/tests/org.gtk.test.gschema.override.orig glib-2.72.0-new/gio/tests/org.gtk.test.gschema.override.orig +--- glib-2.72.0/gio/tests/org.gtk.test.gschema.override.orig 2022-03-17 16:01:31.000000000 +0100 ++++ glib-2.72.0-new/gio/tests/org.gtk.test.gschema.override.orig 1970-01-01 01:00:00.000000000 +0100 @@ -1,2 +0,0 @@ -[org.gtk.test.per-desktop:GNOME-Classic] -desktop = "GNOME Classic" -diff -rupN --no-dereference glib-2.69.2/gio/tests/org.gtk.test.gschema.xml.orig glib-2.69.2-new/gio/tests/org.gtk.test.gschema.xml.orig ---- glib-2.69.2/gio/tests/org.gtk.test.gschema.xml.orig 2021-08-19 17:15:24.712496300 +0200 -+++ glib-2.69.2-new/gio/tests/org.gtk.test.gschema.xml.orig 1970-01-01 01:00:00.000000000 +0100 +diff -rupN --no-dereference glib-2.72.0/gio/tests/org.gtk.test.gschema.xml.orig glib-2.72.0-new/gio/tests/org.gtk.test.gschema.xml.orig +--- glib-2.72.0/gio/tests/org.gtk.test.gschema.xml.orig 2022-03-17 16:01:31.000000000 +0100 ++++ glib-2.72.0-new/gio/tests/org.gtk.test.gschema.xml.orig 1970-01-01 01:00:00.000000000 +0100 @@ -1,222 +0,0 @@ -<schemalist> - @@ -230,9 +230,9 @@ diff -rupN --no-dereference glib-2.69.2/gio/tests/org.gtk.test.gschema.xml.orig - </schema> - -</schemalist> -diff -rupN --no-dereference glib-2.69.2/glib/gstdio.c glib-2.69.2-new/glib/gstdio.c ---- glib-2.69.2/glib/gstdio.c 2021-08-19 17:15:24.740496600 +0200 -+++ glib-2.69.2-new/glib/gstdio.c 2021-08-28 22:11:16.978513413 +0200 +diff -rupN --no-dereference glib-2.72.0/glib/gstdio.c glib-2.72.0-new/glib/gstdio.c +--- glib-2.72.0/glib/gstdio.c 2022-03-17 16:01:31.000000000 +0100 ++++ glib-2.72.0-new/glib/gstdio.c 2022-03-28 10:49:45.327804097 +0200 @@ -1045,6 +1045,11 @@ g_open (const gchar *filename, int mode) { @@ -4,7 +4,7 @@ # Contributor: Renato Silva <br.renatosilva@gmail.com> # Contributor: Martchus <martchus@gmx.net> pkgname=mingw-w64-glib2 -pkgver=2.70.4 +pkgver=2.72.1 pkgrel=1 arch=(any) pkgdesc="Low level core library (mingw-w64)" @@ -14,11 +14,9 @@ license=("LGPL2.1") options=(!strip !buildflags staticlibs !emptydirs) url="https://wiki.gnome.org/Projects/GLib" source=("git+https://gitlab.gnome.org/GNOME/glib.git?signed#tag=$pkgver" - "0001-Use-CreateFile-on-Win32-to-make-sure-g_unlink-always.patch" - "glib-prefer-constructors-over-DllMain.patch") + "0001-Use-CreateFile-on-Win32-to-make-sure-g_unlink-always.patch") sha256sums=('SKIP' - 'c2fa65ddf9cdef61107c0c414997a1a2ec17212303b73b93b2503cb8a0cb9f5d' - '3c9848916492435852e4e27bee608a0b2146e146c40f889d725acffd9409aae8') + '38d2a038b39cef7a2452ddf4b04422e17a40745cc9b1fc8297c24320cecca7f9') validpgpkeys=('923B7025EE03C1C59F42684CF0942E894B2EAFA0') # Philip Withnall (https://endlessos.org/) <pwithnall@endlessos.org> _architectures="i686-w64-mingw32 x86_64-w64-mingw32" @@ -27,17 +25,22 @@ prepare() { cd glib # https://gitlab.gnome.org/GNOME/glib/issues/539 patch -Np1 -i ../0001-Use-CreateFile-on-Win32-to-make-sure-g_unlink-always.patch - # https://gitlab.gnome.org/GNOME/glib/issues/692 - patch -Np1 -i ../glib-prefer-constructors-over-DllMain.patch } build() { for _arch in ${_architectures}; do - mkdir -p "${srcdir}/glib/build-${_arch}" - cd "${srcdir}/glib/build-${_arch}" + mkdir -p "${srcdir}/glib/build-${_arch}-static" + mkdir -p "${srcdir}/glib/build-${_arch}-shared" + + cd "${srcdir}/glib/build-${_arch}-static" + ${_arch}-meson \ + --default-library static .. + ninja + + cd "${srcdir}/glib/build-${_arch}-shared" ${_arch}-meson \ - --default-library both .. + --default-library shared .. ninja done } @@ -45,13 +48,14 @@ build() { package() { for _arch in ${_architectures}; do # fix pkg-config files (see https://github.com/mesonbuild/meson/pull/3939) - for pc_file in ${srcdir}/glib/build-${_arch}/meson-private/*.pc; do + for pc_file in ${srcdir}/glib/build-${_arch}-shared/meson-private/*.pc; do sed -i 's/-lgnulib//g' "$pc_file" sed -i 's/-lcharset//g' "$pc_file" sed -i 's/-lgiowin32//g' "$pc_file" done - DESTDIR="${pkgdir}" ninja -C "${srcdir}/glib/build-${_arch}" install + DESTDIR="${pkgdir}" ninja -C "${srcdir}/glib/build-${_arch}-static" install + DESTDIR="${pkgdir}" ninja -C "${srcdir}/glib/build-${_arch}-shared" install if [[ $NO_EXECUTABLES ]]; then find "${pkgdir}/usr/${_arch}" -name '*.exe' -delete fi diff --git a/glib-prefer-constructors-over-DllMain.patch b/glib-prefer-constructors-over-DllMain.patch deleted file mode 100644 index 4e08af083617..000000000000 --- a/glib-prefer-constructors-over-DllMain.patch +++ /dev/null @@ -1,63 +0,0 @@ -diff -rupN --no-dereference glib-2.63.5/glib/glib-init.c glib-2.63.5-new/glib/glib-init.c ---- glib-2.63.5/glib/glib-init.c 2020-02-03 15:28:28.000000000 +0100 -+++ glib-2.63.5-new/glib/glib-init.c 2020-02-11 10:12:24.070832245 +0100 -@@ -271,12 +271,14 @@ glib_init (void) - - #if defined (G_OS_WIN32) - -+HMODULE glib_dll = NULL; -+ -+#if defined (DLL_EXPORT) -+ - BOOL WINAPI DllMain (HINSTANCE hinstDLL, - DWORD fdwReason, - LPVOID lpvReserved); - --HMODULE glib_dll; -- - BOOL WINAPI - DllMain (HINSTANCE hinstDLL, - DWORD fdwReason, -@@ -286,14 +288,6 @@ DllMain (HINSTANCE hinstDLL, - { - case DLL_PROCESS_ATTACH: - glib_dll = hinstDLL; -- g_crash_handler_win32_init (); -- g_clock_win32_init (); --#ifdef THREADS_WIN32 -- g_thread_win32_init (); --#endif -- glib_init (); -- /* must go after glib_init */ -- g_console_win32_init (); - break; - - case DLL_THREAD_DETACH: -@@ -318,7 +312,10 @@ DllMain (HINSTANCE hinstDLL, - return TRUE; - } - --#elif defined (G_HAS_CONSTRUCTORS) -+#endif /* defined (DLL_EXPORT) */ -+#endif /* defined (G_OS_WIN32) */ -+ -+#if defined (G_HAS_CONSTRUCTORS) - - #ifdef G_DEFINE_CONSTRUCTOR_NEEDS_PRAGMA - #pragma G_DEFINE_CONSTRUCTOR_PRAGMA_ARGS(glib_init_ctor) -@@ -328,7 +325,15 @@ G_DEFINE_CONSTRUCTOR(glib_init_ctor) - static void - glib_init_ctor (void) - { -+#if defined (G_OS_WIN32) -+ g_clock_win32_init (); -+#ifdef THREADS_WIN32 -+ g_thread_win32_init (); -+#endif /* defined (THREADS_WIN32) */ -+#endif /* defined (G_OS_WIN32) */ - glib_init (); -+ /* must go after glib_init */ -+ g_console_win32_init (); - } - - #else |