kumquat-buildroot/package/qt5/qt5base/qt5base-0002-mkspecs-files.patch
Fatih Aşıcı 5d85af61b7 qt5: bump to 5.1.1
Following patches are removed since they are upstreamed:
  - qt5base/qt5base-0001-eglconvenience-add-egl-to-CONFIG-to-get-correct-incl.patch
  - qt5jsbackend/qt5jsbackend-0002-fix-uclibc.patch

Remove "-nomake demos" from configure options since "demos" directory is
merged into examples.

Signed-off-by: Fatih Aşıcı <fatih.asici@gmail.com>
Tested-by: Ezequiel Garcia <ezequiel@vanguardiasur.com.ar>
Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
2013-10-26 14:00:54 +02:00

68 lines
2.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,44 @@
+MAKEFILE_GENERATOR = UNIX
+CONFIG += incremental gdb_dwarf_index
+QMAKE_INCREMENTAL_STYLE = sublib
+
+include(../../common/linux.conf)
+include(../../common/gcc-base-unix.conf)
+include(../../common/g++-unix.conf)
+
+load(device_config)
+
+QT_QPA_DEFAULT_PLATFORM = eglfs
+
+BUILDROOT_CROSS_COMPILE =
+BUILDROOT_COMPILER_CFLAGS =
+BUILDROOT_COMPILER_CXXFLAGS =
+BUILDROOT_INCLUDE_PATH =
+
+# modifications to g++.conf
+QMAKE_CC = $${BUILDROOT_CROSS_COMPILE}gcc
+QMAKE_CXX = $${BUILDROOT_CROSS_COMPILE}g++
+QMAKE_LINK = $${QMAKE_CXX}
+QMAKE_LINK_SHLIB = $${QMAKE_CXX}
+
+# modifications to linux.conf
+QMAKE_AR = $${BUILDROOT_CROSS_COMPILE}ar cqs
+QMAKE_OBJCOPY = $${BUILDROOT_CROSS_COMPILE}objcopy
+QMAKE_NM = $${BUILDROOT_CROSS_COMPILE}nm -P
+QMAKE_STRIP = $${BUILDROOT_CROSS_COMPILE}strip
+
+#modifications to gcc-base.conf
+QMAKE_CFLAGS += $${BUILDROOT_COMPILER_CFLAGS}
+QMAKE_CXXFLAGS += $${BUILDROOT_COMPILER_CXXFLAGS}
+QMAKE_CXXFLAGS_RELEASE += -O3
+INCLUDEPATH += $${BUILDROOT_INCLUDE_PATH}
+
+QMAKE_LIBS += -lrt -lpthread -ldl
+
+# device specific glue code
+EGLFS_PLATFORM_HOOKS_SOURCES =
+
+# Sanity check
+deviceSanityCheckCompiler()
+
+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"