From: ericonr <ericonr@users.noreply.github.com>
To: ml@inbox.vuxu.org
Subject: [PR PATCH] [WIP] remove libglib-static, build shared and static libraries in glib, use those in qemu-user-static
Date: Wed, 13 Jan 2021 16:49:50 +0100 [thread overview]
Message-ID: <gh-mailinglist-notifications-41a7ca26-5023-4802-975b-f1789d68868e-void-packages-27894@inbox.vuxu.org> (raw)
[-- Attachment #1: Type: text/plain, Size: 456 bytes --]
There is a new pull request by ericonr against master on the void-packages repository
https://github.com/ericonr/void-packages glib
https://github.com/void-linux/void-packages/pull/27894
[WIP] remove libglib-static, build shared and static libraries in glib, use those in qemu-user-static
WIP because of linking issues :/
I'm not sure why they are happening.
A patch file from https://github.com/void-linux/void-packages/pull/27894.patch is attached
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-glib-27894.patch --]
[-- Type: text/x-diff, Size: 8620 bytes --]
From ff1be5a25988dee0d91853ac887ac223546b6465 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=C3=89rico=20Rolim?= <erico.erc@gmail.com>
Date: Wed, 13 Jan 2021 11:35:37 -0300
Subject: [PATCH 1/3] glib: also build static libraries.
---
srcpkgs/glib/template | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/srcpkgs/glib/template b/srcpkgs/glib/template
index 0d6de76ea88..9ac4b7734fd 100644
--- a/srcpkgs/glib/template
+++ b/srcpkgs/glib/template
@@ -1,10 +1,11 @@
# Template file for 'glib'
pkgname=glib
version=2.66.2
-revision=1
+revision=2
build_style=meson
+# static version is necessary for qemu-user-static
configure_args="-Dfam=false -Dman=true -Dselinux=disabled
- $(vopt_bool gtk_doc gtk_doc)"
+ $(vopt_bool gtk_doc gtk_doc) --default-library=both"
hostmakedepends="gettext pkg-config libxslt docbook-xsl $(vopt_if gtk_doc gtk-doc)"
makedepends="zlib-devel pcre-devel libffi-devel dbus-devel elfutils-devel libmount-devel"
checkdepends="desktop-file-utils shared-mime-info tzdata dbus"
@@ -36,6 +37,7 @@ libglib-devel_package() {
vmove usr/lib/glib-2.0
vmove usr/lib/pkgconfig
vmove "usr/lib/*.so"
+ vmove "usr/lib/*.a"
}
}
From 810738c867390476cb71c3a7397a14b320793934 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=C3=89rico=20Rolim?= <erico.erc@gmail.com>
Date: Wed, 13 Jan 2021 11:36:06 -0300
Subject: [PATCH 2/3] qemu-user-static: revbump to link against new glib
version.
Also, move from libglib-static to libglib-devel, which now includes
static versions of each library.
---
srcpkgs/qemu-user-static/template | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/srcpkgs/qemu-user-static/template b/srcpkgs/qemu-user-static/template
index 608dc27d982..dc2b3922e72 100644
--- a/srcpkgs/qemu-user-static/template
+++ b/srcpkgs/qemu-user-static/template
@@ -1,10 +1,10 @@
# Template file for 'qemu-user-static'
pkgname=qemu-user-static
version=5.1.0
-revision=1
+revision=2
wrksrc="qemu-${version}"
hostmakedepends="pkg-config automake python3"
-makedepends="dtc-devel libglib-static pixman-devel libuuid-devel"
+makedepends="dtc-devel libglib-devel pixman-devel libuuid-devel"
short_desc="QEMU User-mode emulators (statically compiled)"
maintainer="Orphaned <orphan@voidlinux.org>"
license="GPL-2.0-or-later, LGPL-2.1-or-later"
From 0eef039c3ed7e819c58c0f2ca446c23824174310 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=C3=89rico=20Rolim?= <erico.erc@gmail.com>
Date: Wed, 13 Jan 2021 11:37:04 -0300
Subject: [PATCH 3/3] libglib-static: remove package.
No longer necessary, now that glib includes static libraries.
---
.../patches/gobject_init_on_demand.patch | 91 -------------------
.../patches/quark_init_on_demand.patch | 37 --------
srcpkgs/libglib-static/template | 49 ----------
3 files changed, 177 deletions(-)
delete mode 100644 srcpkgs/libglib-static/patches/gobject_init_on_demand.patch
delete mode 100644 srcpkgs/libglib-static/patches/quark_init_on_demand.patch
delete mode 100644 srcpkgs/libglib-static/template
diff --git a/srcpkgs/libglib-static/patches/gobject_init_on_demand.patch b/srcpkgs/libglib-static/patches/gobject_init_on_demand.patch
deleted file mode 100644
index bcc3cabfbcd..00000000000
--- a/srcpkgs/libglib-static/patches/gobject_init_on_demand.patch
+++ /dev/null
@@ -1,91 +0,0 @@
-Initialize the gobject system on demand, i.e. before it is
-expected to be initialized. Do this only once by checking
-a local static variable gobject_initialized.
-
---- gobject/gtype.c 2016-08-17 17:20:47.000000000 +0200
-+++ gobject/gtype.c 2016-09-01 21:56:31.777406646 +0200
-@@ -209,6 +209,9 @@
- static gboolean type_node_is_a_L (TypeNode *node,
- TypeNode *iface_node);
-
-+#if !defined(__GLIBC__)
-+static void gobject_init (void);
-+#endif
-
- /* --- enumeration --- */
-
-@@ -2631,7 +2634,10 @@
- GTypeFlags flags)
- {
- TypeNode *node;
--
-+
-+#if !defined(__GLIBC__)
-+ gobject_init();
-+#endif
- g_assert_type_system_initialized ();
- g_return_val_if_fail (type_id > 0, 0);
- g_return_val_if_fail (type_name != NULL, 0);
-@@ -2749,6 +2755,9 @@
- TypeNode *pnode, *node;
- GType type = 0;
-
-+#if !defined(__GLIBC__)
-+ gobject_init();
-+#endif
- g_assert_type_system_initialized ();
- g_return_val_if_fail (parent_type > 0, 0);
- g_return_val_if_fail (type_name != NULL, 0);
-@@ -2804,6 +2813,9 @@
- TypeNode *pnode, *node;
- GType type;
-
-+#if !defined(__GLIBC__)
-+ gobject_init();
-+#endif
- g_assert_type_system_initialized ();
- g_return_val_if_fail (parent_type > 0, 0);
- g_return_val_if_fail (type_name != NULL, 0);
-@@ -3319,6 +3331,9 @@
- {
- TypeNode *node;
-
-+#if !defined(__GLIBC__)
-+ gobject_init();
-+#endif
- g_assert_type_system_initialized ();
-
- node = lookup_type_node_I (type);
-@@ -4343,6 +4358,9 @@
- void
- g_type_init_with_debug_flags (GTypeDebugFlags debug_flags)
- {
-+#if !defined(__GLIBC__)
-+ gobject_init();
-+#endif
- g_assert_type_system_initialized ();
-
- if (debug_flags)
-@@ -4361,6 +4379,9 @@
- void
- g_type_init (void)
- {
-+#if !defined(__GLIBC__)
-+ gobject_init();
-+#endif
- g_assert_type_system_initialized ();
- }
-
-@@ -4372,6 +4393,12 @@
- TypeNode *node;
- GType type;
-
-+#if !defined(__GLIBC__)
-+ static int gobject_initialized = 0;
-+ if (gobject_initialized)
-+ return;
-+ gobject_initialized = 1;
-+#endif
- /* Ensure GLib is initialized first, see
- * https://bugzilla.gnome.org/show_bug.cgi?id=756139
- */
diff --git a/srcpkgs/libglib-static/patches/quark_init_on_demand.patch b/srcpkgs/libglib-static/patches/quark_init_on_demand.patch
deleted file mode 100644
index 458a2adab43..00000000000
--- a/srcpkgs/libglib-static/patches/quark_init_on_demand.patch
+++ /dev/null
@@ -1,37 +0,0 @@
-musl does not run ctors in the assumed order that glib-2.46 expects.
-Call g_quark_init() where it is expected to have been called.
-
-
---- glib/gquark.c 2016-08-17 17:20:47.000000000 +0200
-+++ glib/gquark.c 2016-08-30 07:49:13.298234757 +0200
-@@ -57,6 +57,9 @@
- void
- g_quark_init (void)
- {
-+ if (quark_ht)
-+ return;
-+
- g_assert (quark_seq_id == 0);
- quark_ht = g_hash_table_new (g_str_hash, g_str_equal);
- quarks = g_new (gchar*, QUARK_BLOCK_SIZE);
-@@ -138,9 +141,12 @@
- return 0;
-
- G_LOCK (quark_global);
-+#if !defined(__GLIBC__)
-+ g_quark_init ();
-+#endif
- quark = GPOINTER_TO_UINT (g_hash_table_lookup (quark_ht, string));
- G_UNLOCK (quark_global);
-
- return quark;
- }
-
-@@ -280,6 +286,7 @@
- GQuark quark;
- gchar **quarks_new;
-
-+ g_quark_init ();
- if (quark_seq_id % QUARK_BLOCK_SIZE == 0)
- {
- quarks_new = g_new (gchar*, quark_seq_id + QUARK_BLOCK_SIZE);
diff --git a/srcpkgs/libglib-static/template b/srcpkgs/libglib-static/template
deleted file mode 100644
index 83dc7323082..00000000000
--- a/srcpkgs/libglib-static/template
+++ /dev/null
@@ -1,49 +0,0 @@
-# Template file for 'libglib-static'
-#
-# This is only used for qemu-user-static until meson figures out building static
-# glib 2.60.0 via meson.
-#
-pkgname=libglib-static
-version=2.58.3
-revision=5
-wrksrc="glib-${version}"
-build_style=gnu-configure
-configure_args="--enable-libelf --disable-fam --disable-shared --with-pcre=system
- --enable-static"
-hostmakedepends="automake gettext libtool pkg-config python3 libxslt docbook-xsl"
-makedepends="zlib-devel pcre-devel libffi-devel dbus-devel elfutils-devel libmount-devel"
-depends="$makedepends"
-short_desc="GNU library of C routines"
-maintainer="Enno Boland <gottox@voidlinux.org>"
-license="LGPL-2.1-or-later"
-homepage="https://wiki.gnome.org/Projects/GLib"
-changelog="https://gitlab.gnome.org/GNOME/glib/raw/master/NEWS"
-distfiles="${GNOME_SITE}/glib/${version%.*}/glib-${version}.tar.xz"
-checksum=8f43c31767e88a25da72b52a40f3301fefc49a665b56dc10ee7cc9565cbe7481
-conflicts="libglib-devel>=0"
-
-if [ "$CROSS_BUILD" ]; then
- hostmakedepends+=" glib-devel"
- case "$XBPS_TARGET_MACHINE" in
- mips*|ppc|ppc-musl) # It seems mips/ppc autoconf cache is not read?
- configure_args+=" glib_cv_stack_grows=no glib_cv_rtldglobal_broken=no glib_cv_uscore=no" ;;
- esac
-fi
-
-post_patch() {
- # Better to just rm -rf /usr/lib/locale in post_install?
- vsed -i -e "s,localedir=.*,localedir=/usr/share/locale," \
- -e "s,DATADIRNAME=lib,DATADIRNAME=share," \
- m4macros/glib-gettext.m4
- vsed -i -e "s,^localedir =.*,localedir = /usr/share/locale," \
- po/Makefile.in.in
-}
-
-pre_configure() {
- NOCONFIGURE=1 ./autogen.sh
-}
-
-post_install() {
- rm -r $DESTDIR/usr/bin
- rm -r $DESTDIR/usr/share
-}
next reply other threads:[~2021-01-13 15:49 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-01-13 15:49 ericonr [this message]
2021-01-13 19:48 ` [PR PATCH] [Updated] " ericonr
2021-02-11 2:32 ` ericonr
2021-02-11 2:50 ` ericonr
2021-02-11 3:14 ` ericonr
2021-02-11 6:21 ` ericonr
2021-02-11 6:28 ` ericonr
2021-02-11 18:22 ` [PR PATCH] [Merged]: Remove " ericonr
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=gh-mailinglist-notifications-41a7ca26-5023-4802-975b-f1789d68868e-void-packages-27894@inbox.vuxu.org \
--to=ericonr@users.noreply.github.com \
--cc=ml@inbox.vuxu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).