* [Buildroot] [PATCH 1/1] package/shared-mime-info: link with -latomic if needed
@ 2023-08-20 15:40 Bernd Kuhls
2023-08-20 21:45 ` Thomas Petazzoni via buildroot
0 siblings, 1 reply; 2+ messages in thread
From: Bernd Kuhls @ 2023-08-20 15:40 UTC (permalink / raw)
To: buildroot
Buildroot commit 3f9622fe3d85b4d9f734b879abc1d485afea19b2 added an
optional dependency to libatomic for libglib2 which caused the build
error fixed with this patch since glib-2.0.pc does not contain any
information about libatomic.
Fixes:
http://autobuild.buildroot.net/results/d25/d2563ce649188cec2025e4fc6e58c4bbd98ff939/
Signed-off-by: Bernd Kuhls <bernd@kuhls.net>
---
package/shared-mime-info/shared-mime-info.mk | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/package/shared-mime-info/shared-mime-info.mk b/package/shared-mime-info/shared-mime-info.mk
index 9932bd2db0..a9713ee639 100644
--- a/package/shared-mime-info/shared-mime-info.mk
+++ b/package/shared-mime-info/shared-mime-info.mk
@@ -25,6 +25,11 @@ SHARED_MIME_INFO_LICENSE_FILES = COPYING
HOST_SHARED_MIME_INFO_DEPENDENCIES = \
host-pkgconf host-intltool host-libxml2 host-libglib2
+# Uses __atomic_compare_exchange_4 from libglib2
+ifeq ($(BR2_TOOLCHAIN_HAS_LIBATOMIC),y)
+SHARED_MIME_INFO_CONF_ENV += LIBS=-latomic
+endif
+
define SHARED_MIME_INFO_INSTALL_TARGET_CMDS
$(HOST_MAKE_ENV) $(SHARED_MIME_INFO_HOST_BINARY) $(STAGING_DIR)/usr/share/mime
$(INSTALL) -D $(STAGING_DIR)/usr/share/mime/mime.cache $(TARGET_DIR)/usr/share/mime/mime.cache
--
2.39.2
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [Buildroot] [PATCH 1/1] package/shared-mime-info: link with -latomic if needed
2023-08-20 15:40 [Buildroot] [PATCH 1/1] package/shared-mime-info: link with -latomic if needed Bernd Kuhls
@ 2023-08-20 21:45 ` Thomas Petazzoni via buildroot
0 siblings, 0 replies; 2+ messages in thread
From: Thomas Petazzoni via buildroot @ 2023-08-20 21:45 UTC (permalink / raw)
To: Bernd Kuhls; +Cc: buildroot
On Sun, 20 Aug 2023 17:40:41 +0200
Bernd Kuhls <bernd@kuhls.net> wrote:
> Buildroot commit 3f9622fe3d85b4d9f734b879abc1d485afea19b2 added an
> optional dependency to libatomic for libglib2 which caused the build
> error fixed with this patch since glib-2.0.pc does not contain any
> information about libatomic.
>
> Fixes:
> http://autobuild.buildroot.net/results/d25/d2563ce649188cec2025e4fc6e58c4bbd98ff939/
>
> Signed-off-by: Bernd Kuhls <bernd@kuhls.net>
> ---
> package/shared-mime-info/shared-mime-info.mk | 5 +++++
> 1 file changed, 5 insertions(+)
>
> diff --git a/package/shared-mime-info/shared-mime-info.mk b/package/shared-mime-info/shared-mime-info.mk
> index 9932bd2db0..a9713ee639 100644
> --- a/package/shared-mime-info/shared-mime-info.mk
> +++ b/package/shared-mime-info/shared-mime-info.mk
> @@ -25,6 +25,11 @@ SHARED_MIME_INFO_LICENSE_FILES = COPYING
> HOST_SHARED_MIME_INFO_DEPENDENCIES = \
> host-pkgconf host-intltool host-libxml2 host-libglib2
>
> +# Uses __atomic_compare_exchange_4 from libglib2
> +ifeq ($(BR2_TOOLCHAIN_HAS_LIBATOMIC),y)
> +SHARED_MIME_INFO_CONF_ENV += LIBS=-latomic
> +endif
Thanks, but I continue to think that this is not the proper way of
fixing this. The proper way is for glib-2.0.pc to list -latomic in its
Libs.private, so that it gets picked-up by shared-mime-info when
statically linking.
Thomas
--
Thomas Petazzoni, co-owner and CEO, Bootlin
Embedded Linux and Kernel engineering and training
https://bootlin.com
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2023-08-20 21:45 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-08-20 15:40 [Buildroot] [PATCH 1/1] package/shared-mime-info: link with -latomic if needed Bernd Kuhls
2023-08-20 21:45 ` Thomas Petazzoni via buildroot
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.