kumquat-buildroot/package/qt5/qt5base/qt5base-0002-mkspecs-files.patch
Fatih Aşıcı 86db2a76e2 qt5base: use -device-option to set mkspec variables
Simplify our custom qmake.conf:
  - Include linux_device_{pre,post}.conf to inherit common device
    configuration.
  - Do not add $(STAGING_DIR)/usr/include to include path. It is
    redundant.

In additon to the simplification of code, this change is a preparation
to solve problems occurring when QMAKE_CXX is prepended with ccache path.

Upstream patch is needed by configure to parse device options correctly.
Another upstream patch is needed to remove ARM specific parts from
linux_device_post.conf.

Signed-off-by: Fatih Aşıcı <fatih.asici@gmail.com>
Acked-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
2013-11-28 23:05:29 +01:00

35 lines
1.2 KiB
Diff

Add a Buildroot 'device' to ease cross-compilation
Qt5 has a mechanism to support "device" profiles, so that people can
specify the compiler, compiler flags and so on for a specific device.
We leverage this mechanism in the Buildroot packaging of qt5 to
simplify cross-compilation: we have our own "device" definition, which
allows us to easily pass the cross-compiler paths and flags from our
qt5.mk.
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Index: b/mkspecs/devices/linux-buildroot-g++/qmake.conf
===================================================================
--- /dev/null
+++ b/mkspecs/devices/linux-buildroot-g++/qmake.conf
@@ -0,0 +1,11 @@
+include(../common/linux_device_pre.conf)
+
+#modifications to gcc-base.conf
+QMAKE_CFLAGS += $${BUILDROOT_COMPILER_CFLAGS}
+QMAKE_CXXFLAGS += $${BUILDROOT_COMPILER_CXXFLAGS}
+QMAKE_CXXFLAGS_RELEASE += -O3
+
+QMAKE_LIBS += -lrt -lpthread -ldl
+
+include(../common/linux_device_post.conf)
+load(qt_config)
Index: b/mkspecs/devices/linux-buildroot-g++/qplatformdefs.h
===================================================================
--- /dev/null
+++ b/mkspecs/devices/linux-buildroot-g++/qplatformdefs.h
@@ -0,0 +1 @@
+#include "../../linux-g++/qplatformdefs.h"