* [Buildroot] [PATCH 0/2] package/qt5base: fix sparc compilation
@ 2017-05-16 21:13 Yann E. MORIN
2017-05-16 21:13 ` [Buildroot] [PATCH 1/2] package/qt5base: install arch-specific configuration Yann E. MORIN
2017-05-16 21:13 ` [Buildroot] [PATCH 2/2] package/qt5base: link with -latomic for sparc Yann E. MORIN
0 siblings, 2 replies; 4+ messages in thread
From: Yann E. MORIN @ 2017-05-16 21:13 UTC (permalink / raw)
To: buildroot
Hello All!
This small series aims at fixing the build of qt-5.8 on sparc.
Qt 5.8 needs atomic operations, which on some architectures are compiler
builtins, while on other archs they are provided by a helper library,
libatomic. For sparc, atomics are in libatomic.
First, we introduce a new qmake config snippet, arch.conf, which is
included from our qmake.conf.
By default, that file is empty, except on sparc, where it add -latomic
to the list of libraries to link with.
Regards,
Yann E. MORIN.
The following changes since commit 4e00f9daa04e9a84f5191f479d7236dea72fbf35
gcc: drop unused legacy arc-2016.09 patch (2017-05-16 21:24:02 +0200)
are available in the git repository at:
git://git.buildroot.org/~ymorin/git/buildroot.git
for you to fetch changes up to 628b089124e34bcc2f6cd9be57c65d567872ef1f
package/qt5base: link with -latomic for sparc (2017-05-16 23:11:23 +0200)
----------------------------------------------------------------
Yann E. MORIN (2):
package/qt5base: install arch-specific configuration
package/qt5base: link with -latomic for sparc
package/qt5/qt5base/qmake.conf | 3 +++
package/qt5/qt5base/qt5base.mk | 10 ++++++++++
2 files changed, 13 insertions(+)
--
.-----------------.--------------------.------------------.--------------------.
| Yann E. MORIN | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: |
| +33 662 376 056 | Software Designer | \ / CAMPAIGN | ___ |
| +33 223 225 172 `------------.-------: X AGAINST | \e/ There is no |
| http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL | v conspiracy. |
'------------------------------^-------^------------------^--------------------'
^ permalink raw reply [flat|nested] 4+ messages in thread
* [Buildroot] [PATCH 1/2] package/qt5base: install arch-specific configuration
2017-05-16 21:13 [Buildroot] [PATCH 0/2] package/qt5base: fix sparc compilation Yann E. MORIN
@ 2017-05-16 21:13 ` Yann E. MORIN
2017-05-16 21:13 ` [Buildroot] [PATCH 2/2] package/qt5base: link with -latomic for sparc Yann E. MORIN
1 sibling, 0 replies; 4+ messages in thread
From: Yann E. MORIN @ 2017-05-16 21:13 UTC (permalink / raw)
To: buildroot
For some architectures, it is necessary to link with additional
libraries, such as -latomic for sparc.
Add a bit of support to make that easy; actual use will be introduced in
the following patch.
Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
Cc: Julien Corjon <corjon.j@ecagroup.com>
Cc: Peter Seiderer <ps.report@gmx.net>
---
package/qt5/qt5base/qmake.conf | 3 +++
package/qt5/qt5base/qt5base.mk | 3 +++
2 files changed, 6 insertions(+)
diff --git a/package/qt5/qt5base/qmake.conf b/package/qt5/qt5base/qmake.conf
index 49cf898316..8b6debe583 100644
--- a/package/qt5/qt5base/qmake.conf
+++ b/package/qt5/qt5base/qmake.conf
@@ -21,5 +21,8 @@ CONFIG += nostrip
QMAKE_LIBS += -lrt -lpthread -ldl
QMAKE_CFLAGS_ISYSTEM =
+# Architecturespecific configuration
+include(arch.conf)
+
include(../common/linux_device_post.conf)
load(qt_config)
diff --git a/package/qt5/qt5base/qt5base.mk b/package/qt5/qt5base/qt5base.mk
index 0c088350e5..65320cbe04 100644
--- a/package/qt5/qt5base/qt5base.mk
+++ b/package/qt5/qt5base/qt5base.mk
@@ -214,12 +214,15 @@ define QT5BASE_CONFIGURE_CONFIG_FILE
endef
endif
+QT5BASE_ARCH_CONFIG_FILE = $(@D)/mkspecs/devices/linux-buildroot-g++/arch.conf
define QT5BASE_CONFIGURE_CMDS
$(INSTALL) -m 0644 -D $(QT5BASE_PKGDIR)/qmake.conf \
$(@D)/mkspecs/devices/linux-buildroot-g++/qmake.conf
$(INSTALL) -m 0644 -D $(QT5BASE_PKGDIR)/qplatformdefs.h \
$(@D)/mkspecs/devices/linux-buildroot-g++/qplatformdefs.h
$(QT5BASE_CONFIGURE_CONFIG_FILE)
+ touch $(QT5BASE_ARCH_CONFIG_FILE)
+ $(QT5BASE_ARCH_CONFIG)
(cd $(@D); \
$(TARGET_MAKE_ENV) \
PKG_CONFIG="$(PKG_CONFIG_HOST_BINARY)" \
--
2.11.0
^ permalink raw reply related [flat|nested] 4+ messages in thread
* [Buildroot] [PATCH 2/2] package/qt5base: link with -latomic for sparc
2017-05-16 21:13 [Buildroot] [PATCH 0/2] package/qt5base: fix sparc compilation Yann E. MORIN
2017-05-16 21:13 ` [Buildroot] [PATCH 1/2] package/qt5base: install arch-specific configuration Yann E. MORIN
@ 2017-05-16 21:13 ` Yann E. MORIN
2017-05-16 21:32 ` Thomas Petazzoni
1 sibling, 1 reply; 4+ messages in thread
From: Yann E. MORIN @ 2017-05-16 21:13 UTC (permalink / raw)
To: buildroot
Qt 5.8 needs atomic operations, which on sparc are provided with
-latomic.
Fixes:
http://autobuild.buildroot.org/results/49b/49bc9345b9849c9c3c53ace290c534ff7bb98683/
http://autobuild.buildroot.org/results/9f2/9f213406954be51dfcad76ebdce8b73850842180/
Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
Cc: Julien Corjon <corjon.j@ecagroup.com>
Cc: Peter Seiderer <ps.report@gmx.net>
---
package/qt5/qt5base/qt5base.mk | 7 +++++++
1 file changed, 7 insertions(+)
diff --git a/package/qt5/qt5base/qt5base.mk b/package/qt5/qt5base/qt5base.mk
index 65320cbe04..7c9ed0b4e3 100644
--- a/package/qt5/qt5base/qt5base.mk
+++ b/package/qt5/qt5base/qt5base.mk
@@ -215,6 +215,13 @@ endef
endif
QT5BASE_ARCH_CONFIG_FILE = $(@D)/mkspecs/devices/linux-buildroot-g++/arch.conf
+ifeq ($(BR2_sparc)$(BR2_PACKAGE_QT5_VERSION_LATEST),yy)
+# Qt 5.8 needs atomics, which on sparc are in -latomic
+define QT5BASE_ARCH_CONFIG
+ printf 'LIBS += -latomic\n' >$(QT5BASE_ARCH_CONFIG_FILE)
+endef
+endif
+
define QT5BASE_CONFIGURE_CMDS
$(INSTALL) -m 0644 -D $(QT5BASE_PKGDIR)/qmake.conf \
$(@D)/mkspecs/devices/linux-buildroot-g++/qmake.conf
--
2.11.0
^ permalink raw reply related [flat|nested] 4+ messages in thread
* [Buildroot] [PATCH 2/2] package/qt5base: link with -latomic for sparc
2017-05-16 21:13 ` [Buildroot] [PATCH 2/2] package/qt5base: link with -latomic for sparc Yann E. MORIN
@ 2017-05-16 21:32 ` Thomas Petazzoni
0 siblings, 0 replies; 4+ messages in thread
From: Thomas Petazzoni @ 2017-05-16 21:32 UTC (permalink / raw)
To: buildroot
Hello,
On Tue, 16 May 2017 23:13:13 +0200, Yann E. MORIN wrote:
> QT5BASE_ARCH_CONFIG_FILE = $(@D)/mkspecs/devices/linux-buildroot-g++/arch.conf
> +ifeq ($(BR2_sparc)$(BR2_PACKAGE_QT5_VERSION_LATEST),yy)
You shouldn't use BR2_sparc here, but BR2_TOOLCHAIN_HAS_LIBATOMIC
Thomas
--
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux and Kernel engineering
http://free-electrons.com
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2017-05-16 21:32 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-05-16 21:13 [Buildroot] [PATCH 0/2] package/qt5base: fix sparc compilation Yann E. MORIN
2017-05-16 21:13 ` [Buildroot] [PATCH 1/2] package/qt5base: install arch-specific configuration Yann E. MORIN
2017-05-16 21:13 ` [Buildroot] [PATCH 2/2] package/qt5base: link with -latomic for sparc Yann E. MORIN
2017-05-16 21:32 ` Thomas Petazzoni
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.