summaryrefslogtreecommitdiffstats
path: root/mkspecs
diff options
context:
space:
mode:
Diffstat (limited to 'mkspecs')
-rw-r--r--mkspecs/cmake/Qt5BasicConfig.cmake.in20
-rw-r--r--mkspecs/common/qcc-base-qnx.conf2
-rw-r--r--mkspecs/common/qcc-base.conf9
-rw-r--r--mkspecs/devices/linux-arm-amlogic-8726M-g++/qeglfs_hooks_8726m.cpp95
-rw-r--r--mkspecs/devices/linux-arm-amlogic-8726M-g++/qmake.conf36
-rw-r--r--mkspecs/devices/linux-arm-amlogic-8726M-g++/qplatformdefs.h43
-rw-r--r--mkspecs/devices/linux-mipsel-broadcom-97425-g++/qmake.conf65
-rw-r--r--mkspecs/devices/linux-mipsel-broadcom-97425-g++/qplatformdefs.h42
-rw-r--r--mkspecs/devices/linux-rasp-pi-g++/qeglfs_hooks.cpp143
-rw-r--r--mkspecs/devices/linux-rasp-pi-g++/qmake.conf56
-rw-r--r--mkspecs/devices/linux-rasp-pi-g++/qplatformdefs.h44
-rw-r--r--mkspecs/features/create_cmake.prf12
-rw-r--r--mkspecs/features/declarative_debug.prf1
-rw-r--r--mkspecs/features/device_config.prf11
-rw-r--r--mkspecs/features/qml_debug.prf1
-rw-r--r--mkspecs/features/qt_module_config.prf2
-rw-r--r--mkspecs/unsupported/qnx-armv7le-qcc/qmake.conf2
17 files changed, 561 insertions, 23 deletions
diff --git a/mkspecs/cmake/Qt5BasicConfig.cmake.in b/mkspecs/cmake/Qt5BasicConfig.cmake.in
index 0334b6f6e2..a04d2b4d4e 100644
--- a/mkspecs/cmake/Qt5BasicConfig.cmake.in
+++ b/mkspecs/cmake/Qt5BasicConfig.cmake.in
@@ -1,5 +1,5 @@
-get_filename_component(_qt5_install_prefix \"${CMAKE_CURRENT_LIST_DIR}/$${CMAKE_RELATIVE_INSTALL_DIR}\" ABSOLUTE)
+get_filename_component(_qt5$${CMAKE_MODULE_NAME}_install_prefix \"${CMAKE_CURRENT_LIST_DIR}/$${CMAKE_RELATIVE_INSTALL_DIR}\" ABSOLUTE)
set(Qt5$${CMAKE_MODULE_NAME}_VERSION_MAJOR "$$eval(QT.$${MODULE}.MAJOR_VERSION)")
set(Qt5$${CMAKE_MODULE_NAME}_VERSION_MINOR "$$eval(QT.$${MODULE}.MINOR_VERSION)")
@@ -8,7 +8,7 @@ set(Qt5$${CMAKE_MODULE_NAME}_VERSION_PATCH "$$eval(QT.$${MODULE}.PATCH_VERSION)"
set(Qt5$${CMAKE_MODULE_NAME}_LIBRARIES Qt5::$${CMAKE_MODULE_NAME})
!!IF isEmpty(CMAKE_INCLUDE_DIR_IS_ABSOLUTE)
-set(Qt5$${CMAKE_MODULE_NAME}_INCLUDE_DIRS \"${_qt5_install_prefix}/$$CMAKE_INCLUDE_DIR\" \"${_qt5_install_prefix}/$${CMAKE_INCLUDE_DIR}Qt$${CMAKE_MODULE_NAME}\")
+set(Qt5$${CMAKE_MODULE_NAME}_INCLUDE_DIRS \"${_qt5$${CMAKE_MODULE_NAME}_install_prefix}/$$CMAKE_INCLUDE_DIR\" \"${_qt5$${CMAKE_MODULE_NAME}_install_prefix}/$${CMAKE_INCLUDE_DIR}Qt$${CMAKE_MODULE_NAME}\")
!!ELSE
set(Qt5$${CMAKE_MODULE_NAME}_INCLUDE_DIRS \"$$CMAKE_INCLUDE_DIR\" \"$${CMAKE_INCLUDE_DIR}Qt$${CMAKE_MODULE_NAME}\")
!!ENDIF
@@ -35,6 +35,8 @@ if (Qt5$${CMAKE_MODULE_NAME}_EXECUTABLE_COMPILE_FLAGS)
list(REMOVE_DUPLICATES Qt5$${CMAKE_MODULE_NAME}_EXECUTABLE_COMPILE_FLAGS)
endif()
+set(Qt5$${CMAKE_MODULE_NAME}_LIB_DEPENDENCIES "$${CMAKE_QT5_MODULE_DEPS}")
+
!!IF !isEmpty(CMAKE_STATIC_TYPE)
# For static builds, we also list the dependencies of
# Qt so that consumers can build.
@@ -84,8 +86,6 @@ list(APPEND Qt5Gui_LIB_DEPENDENCIES ${JPEG_LIBRARIES})
!!ENDIF # Static
-list(APPEND Qt5$${CMAKE_MODULE_NAME}_LIB_DEPENDENCIES "$${CMAKE_QT5_MODULE_DEPS}")
-
if (NOT _Qt5$${CMAKE_MODULE_NAME}_target)
set(_Qt5$${CMAKE_MODULE_NAME}_target 1)
!!IF !isEmpty(CMAKE_STATIC_TYPE)
@@ -98,29 +98,29 @@ if (NOT _Qt5$${CMAKE_MODULE_NAME}_target)
!!ENDIF
endif()
-!!IF !isEmpty(debug_type)
+!!IF !isEmpty(CMAKE_DEBUG_TYPE)
set_property(TARGET Qt5::$${CMAKE_MODULE_NAME} APPEND PROPERTY IMPORTED_CONFIGURATIONS DEBUG)
set_target_properties(Qt5::$${CMAKE_MODULE_NAME} PROPERTIES
IMPORTED_LINK_INTERFACE_LIBRARIES_DEBUG \"${Qt5$${CMAKE_MODULE_NAME}_LIB_DEPENDENCIES}\"
!!IF isEmpty(CMAKE_LIB_DIR_IS_ABSOLUTE)
- IMPORTED_LOCATION_DEBUG \"${_qt5_install_prefix}/$${CMAKE_LIB_DIR}$${CMAKE_LIB_FILE_LOCATION_DEBUG}\"
+ IMPORTED_LOCATION_DEBUG \"${_qt5$${CMAKE_MODULE_NAME}_install_prefix}/$${CMAKE_LIB_DIR}$${CMAKE_LIB_FILE_LOCATION_DEBUG}\"
!!ELSE
IMPORTED_LOCATION_DEBUG \"$${CMAKE_LIB_DIR}$${CMAKE_LIB_FILE_LOCATION_DEBUG}\"
!!ENDIF
)
!!IF !isEmpty(CMAKE_IMPLIB_FILE_LOCATION_DEBUG)
set_target_properties(Qt5::$${CMAKE_MODULE_NAME} PROPERTIES
- IMPORTED_IMPLIB_DEBUG \"${_qt5_install_prefix}/$${CMAKE_LIB_DIR}$${CMAKE_IMPLIB_FILE_LOCATION_DEBUG}\"
+ IMPORTED_IMPLIB_DEBUG \"${_qt5$${CMAKE_MODULE_NAME}_install_prefix}/$${CMAKE_LIB_DIR}$${CMAKE_IMPLIB_FILE_LOCATION_DEBUG}\"
)
!!ENDIF
!!ENDIF
-!!IF !isEmpty(release_type)
+!!IF !isEmpty(CMAKE_RELEASE_TYPE)
set_property(TARGET Qt5::$${CMAKE_MODULE_NAME} APPEND PROPERTY IMPORTED_CONFIGURATIONS RELEASE)
set_target_properties(Qt5::$${CMAKE_MODULE_NAME} PROPERTIES
IMPORTED_LINK_INTERFACE_LIBRARIES_RELEASE \"${Qt5$${CMAKE_MODULE_NAME}_LIB_DEPENDENCIES}\"
!!IF isEmpty(CMAKE_LIB_DIR_IS_ABSOLUTE)
- IMPORTED_LOCATION_RELEASE \"${_qt5_install_prefix}/$${CMAKE_LIB_DIR}$${CMAKE_LIB_FILE_LOCATION_RELEASE}\"
+ IMPORTED_LOCATION_RELEASE \"${_qt5$${CMAKE_MODULE_NAME}_install_prefix}/$${CMAKE_LIB_DIR}$${CMAKE_LIB_FILE_LOCATION_RELEASE}\"
!!ELSE
IMPORTED_LOCATION_RELEASE \"$${CMAKE_LIB_DIR}$${CMAKE_LIB_FILE_LOCATION_RELEASE}\"
!!ENDIF
@@ -128,7 +128,7 @@ set_target_properties(Qt5::$${CMAKE_MODULE_NAME} PROPERTIES
!!IF !isEmpty(CMAKE_IMPLIB_FILE_LOCATION_RELEASE)
set_target_properties(Qt5::$${CMAKE_MODULE_NAME} PROPERTIES
!!IF isEmpty(CMAKE_LIB_DIR_IS_ABSOLUTE)
- IMPORTED_IMPLIB_RELEASE \"${_qt5_install_prefix}/$${CMAKE_LIB_DIR}$${CMAKE_IMPLIB_FILE_LOCATION_RELEASE}\"
+ IMPORTED_IMPLIB_RELEASE \"${_qt5$${CMAKE_MODULE_NAME}_install_prefix}/$${CMAKE_LIB_DIR}$${CMAKE_IMPLIB_FILE_LOCATION_RELEASE}\"
!!ELSE
IMPORTED_IMPLIB_RELEASE \"$${CMAKE_LIB_DIR}$${CMAKE_IMPLIB_FILE_LOCATION_RELEASE}\"
!!ENDIF
diff --git a/mkspecs/common/qcc-base-qnx.conf b/mkspecs/common/qcc-base-qnx.conf
index 11e8ca43a2..ec0d27873d 100644
--- a/mkspecs/common/qcc-base-qnx.conf
+++ b/mkspecs/common/qcc-base-qnx.conf
@@ -4,6 +4,8 @@
include(qcc-base.conf)
+CONFIG += qnx
+
QMAKE_LFLAGS_SHLIB += -shared
QMAKE_LFLAGS_PLUGIN += $$QMAKE_LFLAGS_SHLIB
QMAKE_LFLAGS_SONAME += -Wl,-soname,
diff --git a/mkspecs/common/qcc-base.conf b/mkspecs/common/qcc-base.conf
index a9e86efb75..a2aefc6cd3 100644
--- a/mkspecs/common/qcc-base.conf
+++ b/mkspecs/common/qcc-base.conf
@@ -3,11 +3,14 @@
#
# - The QNX qcc compiler
#
-# The only difference between this and gcc-base.conf is that -pipe is removed
-# as it's on by default in qcc (and has an analogous -nopipe option)
+# The differences between this and gcc-base.conf are that
+#
+# 1) -pipe is removed as it's on by default in qcc (and has an analogous -nopipe option)
+# 2) -Wno-psabi is added to silence harmless warnings about va_list mangling
+# 3) -fstack-protector -fstack-protector-all is added to enable stack smashing protection
#
-QMAKE_CFLAGS += -Wno-psabi
+QMAKE_CFLAGS += -Wno-psabi -fstack-protector -fstack-protector-all
QMAKE_CFLAGS_DEPS += -M
QMAKE_CFLAGS_WARN_ON += -Wall -W
QMAKE_CFLAGS_WARN_OFF += -w
diff --git a/mkspecs/devices/linux-arm-amlogic-8726M-g++/qeglfs_hooks_8726m.cpp b/mkspecs/devices/linux-arm-amlogic-8726M-g++/qeglfs_hooks_8726m.cpp
new file mode 100644
index 0000000000..06cb424e4f
--- /dev/null
+++ b/mkspecs/devices/linux-arm-amlogic-8726M-g++/qeglfs_hooks_8726m.cpp
@@ -0,0 +1,95 @@
+/****************************************************************************
+**
+** Copyright (C) 2012 Nokia Corporation and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/
+**
+** This file is part of the qmake spec of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** GNU Lesser General Public License Usage
+** This file may be used under the terms of the GNU Lesser General Public
+** License version 2.1 as published by the Free Software Foundation and
+** appearing in the file LICENSE.LGPL included in the packaging of this
+** file. Please review the following information to ensure the GNU Lesser
+** General Public License version 2.1 requirements will be met:
+** http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Nokia gives you certain additional
+** rights. These rights are described in the Nokia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU General
+** Public License version 3.0 as published by the Free Software Foundation
+** and appearing in the file LICENSE.GPL included in the packaging of this
+** file. Please review the following information to ensure the GNU General
+** Public License version 3.0 requirements will be met:
+** http://www.gnu.org/copyleft/gpl.html.
+**
+** Other Usage
+** Alternatively, this file may be used in accordance with the terms and
+** conditions contained in a signed written agreement between you and Nokia.
+**
+**
+**
+**
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include "qeglfs_hooks.h"
+#include <EGL/fbdev_window.h>
+#include <stdio.h>
+#include <sys/ioctl.h>
+#include <sys/types.h>
+#include <sys/stat.h>
+#include <fcntl.h>
+#include <linux/fb.h>
+
+void QEglFSHooks::platformInit()
+{
+}
+
+void QEglFSHooks::platformDestroy()
+{
+}
+
+EGLNativeDisplayType QEglFSHooks::platformDisplay() const
+{
+ return EGL_DEFAULT_DISPLAY;
+}
+
+QSize QEglFSHooks::screenSize() const
+{
+ int fd = open("/dev/fb0", O_RDONLY);
+ if (fd == -1) {
+ qFatal("Failed to open fb to detect screen resolution!");
+ }
+
+ struct fb_var_screeninfo vinfo;
+ if (ioctl(fd, FBIOGET_VSCREENINFO, &vinfo) == -1) {
+ qFatal("Could not get variable screen info");
+ }
+
+ close(fd);
+
+ return QSize(vinfo.xres, vinfo.yres);
+}
+
+EGLNativeWindowType QEglFSHooks::createNativeWindow(const QSize &size)
+{
+ fbdev_window *window = new fbdev_window;
+ window->width = size.width();
+ window->height = size.height();
+
+ return window;
+}
+
+void QEglFSHooks::destroyNativeWindow(EGLNativeWindowType window)
+{
+ delete window;
+}
+
+QEglFSHooks platform_hooks;
diff --git a/mkspecs/devices/linux-arm-amlogic-8726M-g++/qmake.conf b/mkspecs/devices/linux-arm-amlogic-8726M-g++/qmake.conf
new file mode 100644
index 0000000000..b0b02f32e6
--- /dev/null
+++ b/mkspecs/devices/linux-arm-amlogic-8726M-g++/qmake.conf
@@ -0,0 +1,36 @@
+#
+# qmake configuration for linux-g++
+#
+
+MAKEFILE_GENERATOR = UNIX
+TARGET_PLATFORM = unix
+TEMPLATE = app
+CONFIG += qt warn_on release incremental link_prl gdb_dwarf_index
+QT += core gui
+QMAKE_INCREMENTAL_STYLE = sublib
+
+include(../../common/linux.conf)
+include(../../common/gcc-base-unix.conf)
+include(../../common/g++-unix.conf)
+
+load(device_config)
+
+isEmpty(CROSS_COMPILE): error("CROSS_COMPILE needs to be set via -device-option CROSS_COMPILE=<path>")
+
+QMAKE_CC = $${CROSS_COMPILE}gcc
+QMAKE_CXX = $${CROSS_COMPILE}g++
+QMAKE_LINK = $${QMAKE_CXX}
+QMAKE_LINK_SHLIB = $${QMAKE_CXX}
+
+QMAKE_AR = $${CROSS_COMPILE}ar cqs
+QMAKE_OBJCOPY = $${CROSS_COMPILE}objcopy
+QMAKE_STRIP = $${CROSS_COMPILE}strip
+
+QMAKE_CFLAGS_RELEASE += -O2 -mfloat-abi=softfp -mfpu=neon -mcpu=cortex-a9
+QMAKE_CXXFLAGS_RELEASE += $$QMAKE_CFLAGS_RELEASE
+
+deviceSanityCheckCompiler()
+
+EGLFS_PLATFORM_HOOKS_SOURCES = $$PWD/qeglfs_hooks_8726m.cpp
+
+load(qt_config)
diff --git a/mkspecs/devices/linux-arm-amlogic-8726M-g++/qplatformdefs.h b/mkspecs/devices/linux-arm-amlogic-8726M-g++/qplatformdefs.h
new file mode 100644
index 0000000000..e246417223
--- /dev/null
+++ b/mkspecs/devices/linux-arm-amlogic-8726M-g++/qplatformdefs.h
@@ -0,0 +1,43 @@
+/****************************************************************************
+**
+** Copyright (C) 2012 Nokia Corporation and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/
+**
+** This file is part of the qmake spec of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** GNU Lesser General Public License Usage
+** This file may be used under the terms of the GNU Lesser General Public
+** License version 2.1 as published by the Free Software Foundation and
+** appearing in the file LICENSE.LGPL included in the packaging of this
+** file. Please review the following information to ensure the GNU Lesser
+** General Public License version 2.1 requirements will be met:
+** http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Nokia gives you certain additional
+** rights. These rights are described in the Nokia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU General
+** Public License version 3.0 as published by the Free Software Foundation
+** and appearing in the file LICENSE.GPL included in the packaging of this
+** file. Please review the following information to ensure the GNU General
+** Public License version 3.0 requirements will be met:
+** http://www.gnu.org/copyleft/gpl.html.
+**
+** Other Usage
+** Alternatively, this file may be used in accordance with the terms and
+** conditions contained in a signed written agreement between you and Nokia.
+**
+**
+**
+**
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include "../../linux-g++/qplatformdefs.h"
+
diff --git a/mkspecs/devices/linux-mipsel-broadcom-97425-g++/qmake.conf b/mkspecs/devices/linux-mipsel-broadcom-97425-g++/qmake.conf
new file mode 100644
index 0000000000..866fad639b
--- /dev/null
+++ b/mkspecs/devices/linux-mipsel-broadcom-97425-g++/qmake.conf
@@ -0,0 +1,65 @@
+#
+# qmake configuration for linux-mipsel-broadcom-97425-g++
+#
+
+MAKEFILE_GENERATOR = UNIX
+TARGET_PLATFORM = unix
+TEMPLATE = app
+CONFIG += qt warn_on release incremental link_prl gdb_dwarf_index
+QT += core gui
+QMAKE_INCREMENTAL_STYLE = sublib
+
+include(../../common/linux.conf)
+include(../../common/gcc-base-unix.conf)
+include(../../common/g++-unix.conf)
+
+load(device_config)
+
+# Modify the defaults we loaded above
+CROSS_COMPILE = mipsel-linux-
+QMAKE_CC = $${CROSS_COMPILE}gcc
+QMAKE_CXX = $${CROSS_COMPILE}g++
+QMAKE_LINK = $${QMAKE_CXX}
+QMAKE_LINK_SHLIB = $${QMAKE_CXX}
+
+QMAKE_AR = $${CROSS_COMPILE}ar cqs
+QMAKE_OBJCOPY = $${CROSS_COMPILE}objcopy
+QMAKE_STRIP = $${CROSS_COMPILE}strip
+
+QMAKE_CFLAGS_RELEASE += -O2
+QMAKE_CXXFLAGS_RELEASE += $$QMAKE_CFLAGS_RELEASE
+
+#TODO: Clean Qt to work with uclibc not calling itself GLIBC.
+#QMAKE_CFLAGS += -D__FORCE_NOGLIBC
+#QMAKE_CXXFLAGS += -D__FORCE_NOGLIBC
+
+
+BRCM_PLATFORM = 97425
+
+# Sanity checks
+deviceSanityCheckCompiler()
+isEmpty(B_REFSW_DEBUG):error("B_REFSW_DEBUG needs to be set via -device-option B_REFSW_DEBUG=(y|n).")
+isEmpty(BRCM_ROCKFORD_PATH):error("BRCM_ROCKFORD_PATH needs to be set via -device-option BRCM_ROCKFORD_PATH=path.")
+isEmpty(BRCM_APPLIBS_PATH):error("BRCM_APPLIBS_PATH needs to be set via -device-option BRCM_APPLIBS_PATH=path.")
+
+# Figure the kind of directfb build used.
+BRCM_BUILD_TYPE = debug
+contains(B_REFSW_DEBUG, [Nn]) {
+ BRCM_BUILD_TYPE = release
+}
+
+QMAKE_INCDIR_OPENGL_ES2 = $${BRCM_ROCKFORD_PATH}/middleware/v3d/interface/khronos/include
+QMAKE_LIBDIR_OPENGL_ES2 = $${BRCM_ROCKFORD_PATH}/middleware/v3d/lib_$${BRCM_PLATFORM}_$${BRCM_BUILD_TYPE}
+QMAKE_LIBS_OPENGL_ES2 = -lv3ddriver -lrt
+
+INCLUDEPATH += $${BRCM_APPLIBS_PATH}/opensource/zlib/zlib-1.2.3
+QMAKE_LIBDIR += $${BRCM_APPLIBS_PATH}/opensource/zlib/zlib-1.2.3
+
+# DirectFB, needs to be changed once -directfb is added to configure
+DIRECTFB_INCLUDEPATH = $${BRCM_APPLIBS_PATH}/opensource/directfb/bin/DirectFB-1.4.15_multi_$${BRCM_BUILD_TYPE}_build.97425B1/usr/local/include/directfb $${BRCM_ROCKFORD_PATH}/middleware/platform/directfb
+DIRECTFB_LIBS = -L$${BRCM_APPLIBS_PATH}/opensource/directfb/bin/DirectFB-1.4.15_multi_$${BRCM_BUILD_TYPE}_build.97425B1/usr/local/lib -L$${BRCM_ROCKFORD_PATH}/middleware/platform/directfb/lib_$${BRCM_PLATFORM}_$${BRCM_BUILD_TYPE} -ldirectfb -lfusion -ldirect -lpthread -lnexus -ldbpl -lz
+
+
+QMAKE_LFLAGS += -Wl,-rpath-link,$$QMAKE_LIBDIR_OPENGL_ES2 -Wl,-rpath-link,$${BRCM_APPLIBS_PATH}/opensource/zlib/zlib-1.2.3
+
+load(qt_config)
diff --git a/mkspecs/devices/linux-mipsel-broadcom-97425-g++/qplatformdefs.h b/mkspecs/devices/linux-mipsel-broadcom-97425-g++/qplatformdefs.h
new file mode 100644
index 0000000000..9e6b0f5bcc
--- /dev/null
+++ b/mkspecs/devices/linux-mipsel-broadcom-97425-g++/qplatformdefs.h
@@ -0,0 +1,42 @@
+/****************************************************************************
+**
+** Copyright (C) 2012 Nokia Corporation and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/
+**
+** This file is part of the qmake spec of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** GNU Lesser General Public License Usage
+** This file may be used under the terms of the GNU Lesser General Public
+** License version 2.1 as published by the Free Software Foundation and
+** appearing in the file LICENSE.LGPL included in the packaging of this
+** file. Please review the following information to ensure the GNU Lesser
+** General Public License version 2.1 requirements will be met:
+** http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Nokia gives you certain additional
+** rights. These rights are described in the Nokia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU General
+** Public License version 3.0 as published by the Free Software Foundation
+** and appearing in the file LICENSE.GPL included in the packaging of this
+** file. Please review the following information to ensure the GNU General
+** Public License version 3.0 requirements will be met:
+** http://www.gnu.org/copyleft/gpl.html.
+**
+** Other Usage
+** Alternatively, this file may be used in accordance with the terms and
+** conditions contained in a signed written agreement between you and Nokia.
+**
+**
+**
+**
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include "../../linux-g++/qplatformdefs.h"
diff --git a/mkspecs/devices/linux-rasp-pi-g++/qeglfs_hooks.cpp b/mkspecs/devices/linux-rasp-pi-g++/qeglfs_hooks.cpp
new file mode 100644
index 0000000000..2cbd297a90
--- /dev/null
+++ b/mkspecs/devices/linux-rasp-pi-g++/qeglfs_hooks.cpp
@@ -0,0 +1,143 @@
+/****************************************************************************
+**
+** Copyright (C) 2012 Nokia Corporation and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/
+**
+** This file is part of the qmake spec of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** GNU Lesser General Public License Usage
+** This file may be used under the terms of the GNU Lesser General Public
+** License version 2.1 as published by the Free Software Foundation and
+** appearing in the file LICENSE.LGPL included in the packaging of this
+** file. Please review the following information to ensure the GNU Lesser
+** General Public License version 2.1 requirements will be met:
+** http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Nokia gives you certain additional
+** rights. These rights are described in the Nokia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU General
+** Public License version 3.0 as published by the Free Software Foundation
+** and appearing in the file LICENSE.GPL included in the packaging of this
+** file. Please review the following information to ensure the GNU General
+** Public License version 3.0 requirements will be met:
+** http://www.gnu.org/copyleft/gpl.html.
+**
+** Other Usage
+** Alternatively, this file may be used in accordance with the terms and
+** conditions contained in a signed written agreement between you and Nokia.
+**
+**
+**
+**
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include "qeglfs_hooks.h"
+
+#include <bcm_host.h>
+
+#if 0 //fb size query
+#include <stdio.h>
+#include <sys/ioctl.h>
+#include <sys/types.h>
+#include <sys/stat.h>
+#include <fcntl.h>
+#include <linux/fb.h>
+#endif
+
+static DISPMANX_DISPLAY_HANDLE_T dispman_display = 0;
+static DISPMANX_UPDATE_HANDLE_T dispman_update = 0;
+
+void QEglFSHooks::platformInit()
+{
+ bcm_host_init();
+}
+
+EGLNativeDisplayType QEglFSHooks::platformDisplay() const
+{
+ dispman_display = vc_dispmanx_display_open(0/* LCD */);
+ return EGL_DEFAULT_DISPLAY;
+}
+
+void QEglFSHooks::platformDestroy()
+{
+ vc_dispmanx_display_close(dispman_display);
+}
+
+QSize QEglFSHooks::screenSize() const
+{
+ //both mechanisms work
+#if 1
+ uint32_t width, height;
+ graphics_get_display_size(0 /* LCD */, &width, &height);
+ return QSize(width, height);
+#else
+ int fd = open("/dev/fb0", O_RDONLY);
+ if (fd == -1) {
+ fprintf(stderr, "Failed to open fb to detect screen resolution!\n");
+ return QSize();
+ }
+
+ struct fb_var_screeninfo vinfo;
+ if (ioctl(fd, FBIOGET_VSCREENINFO, &vinfo) = -1) {
+ fprintf(stderr, "Could not query screen info variable\n");
+ close(fd);
+ return QSize();
+ }
+
+ close(fd);
+
+ return QSize(vinfo.xres, vinfo.yres);
+#endif
+}
+
+EGLNativeWindowType QEglFSHooks::createNativeWindow(const QSize &size)
+{
+ VC_RECT_T dst_rect;
+ dst_rect.x = 0;
+ dst_rect.y = 0;
+ dst_rect.width = size.width();
+ dst_rect.height = size.height();
+
+ VC_RECT_T src_rect;
+ src_rect.x = 0;
+ src_rect.y = 0;
+ src_rect.width = size.width() << 16;
+ src_rect.height = size.height() << 16;
+
+ dispman_update = vc_dispmanx_update_start(0);
+
+ VC_DISPMANX_ALPHA_T alpha;
+ alpha.flags = DISPMANX_FLAGS_ALPHA_FIXED_ALL_PIXELS;
+ alpha.opacity = 0xFF;
+ alpha.mask = 0;
+
+ DISPMANX_ELEMENT_HANDLE_T dispman_element = vc_dispmanx_element_add(
+ dispman_update, dispman_display, 0, &dst_rect, 0, &src_rect,
+ DISPMANX_PROTECTION_NONE, &alpha, (DISPMANX_CLAMP_T *)NULL, (DISPMANX_TRANSFORM_T)0);
+
+ vc_dispmanx_update_submit_sync(dispman_update);
+
+ EGL_DISPMANX_WINDOW_T *eglWindow = new EGL_DISPMANX_WINDOW_T;
+ eglWindow->element = dispman_element;
+ eglWindow->width = size.width();
+ eglWindow->height = size.height();
+
+ return eglWindow;
+}
+
+void QEglFSHooks::destroyNativeWindow(EGLNativeWindowType window)
+{
+ EGL_DISPMANX_WINDOW_T *eglWindow = static_cast<EGL_DISPMANX_WINDOW_T *>(window);
+ vc_dispmanx_element_remove(dispman_update, eglWindow->element);
+ delete eglWindow;
+}
+
+QEglFSHooks platform_hooks;
diff --git a/mkspecs/devices/linux-rasp-pi-g++/qmake.conf b/mkspecs/devices/linux-rasp-pi-g++/qmake.conf
new file mode 100644
index 0000000000..326d6b3b61
--- /dev/null
+++ b/mkspecs/devices/linux-rasp-pi-g++/qmake.conf
@@ -0,0 +1,56 @@
+#
+# qmake configuration for Broadcom's Raspberry PI
+# http://wiki.qt-project.org/Devices/RaspberryPi
+
+!exists($$[QT_SYSROOT]/usr/include/libudev.h) {
+ message("Keyboard support requires udev")
+ message("Install libudev-dev in your rootfs")
+ error()
+}
+
+MAKEFILE_GENERATOR = UNIX
+TARGET_PLATFORM = unix
+TEMPLATE = app
+CONFIG += qt warn_on release incremental link_prl gdb_dwarf_index
+QT += core gui
+QMAKE_INCREMENTAL_STYLE = sublib
+
+include(../../common/linux.conf)
+include(../../common/gcc-base-unix.conf)
+include(../../common/g++-unix.conf)
+
+load(device_config)
+
+QMAKE_CC = $${CROSS_COMPILE}gcc
+QMAKE_CXX = $${CROSS_COMPILE}g++
+QMAKE_LINK = $${QMAKE_CXX}
+QMAKE_LINK_SHLIB = $${QMAKE_CXX}
+
+# modifications to linux.conf
+QMAKE_AR = $${CROSS_COMPILE}ar cqs
+QMAKE_OBJCOPY = $${CROSS_COMPILE}objcopy
+QMAKE_STRIP = $${CROSS_COMPILE}strip
+
+#Circular dependency in GLES2 <-> EGL requires the following abomination
+QMAKE_LIBS_EGL = -L$$[QT_SYSROOT]/opt/vc/lib -lWFC -lGLESv2 -lEGL -lbcm_host -lopenmaxil
+QMAKE_LIBS_OPENGL_ES2 = $${QMAKE_LIBS_EGL}
+QMAKE_LIBS_OPENVG = $${QMAKE_LIBS_EGL}
+
+QMAKE_INCDIR_EGL = $$[QT_SYSROOT]/opt/vc/include
+QMAKE_INCDIR_OPENGL_ES2 = $${QMAKE_INCDIR_EGL}
+
+QMAKE_CFLAGS_RELEASE += \
+ -mfloat-abi=softfp \
+ -mfpu=vfp \
+ -mtune=arm1176jzf-s \
+ -march=armv6zk \
+ -mabi=aapcs-linux
+
+QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE
+
+EGLFS_PLATFORM_HOOKS_SOURCES = $$PWD/qeglfs_hooks.cpp
+
+# Sanity check
+deviceSanityCheckCompiler()
+
+load(qt_config)
diff --git a/mkspecs/devices/linux-rasp-pi-g++/qplatformdefs.h b/mkspecs/devices/linux-rasp-pi-g++/qplatformdefs.h
new file mode 100644
index 0000000000..62cbb049dd
--- /dev/null
+++ b/mkspecs/devices/linux-rasp-pi-g++/qplatformdefs.h
@@ -0,0 +1,44 @@
+/****************************************************************************
+**
+** Copyright (C) 2012 Nokia Corporation and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/
+**
+** This file is part of the qmake spec of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** GNU Lesser General Public License Usage
+** This file may be used under the terms of the GNU Lesser General Public
+** License version 2.1 as published by the Free Software Foundation and
+** appearing in the file LICENSE.LGPL included in the packaging of this
+** file. Please review the following information to ensure the GNU Lesser
+** General Public License version 2.1 requirements will be met:
+** http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Nokia gives you certain additional
+** rights. These rights are described in the Nokia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** GNU General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU General
+** Public License version 3.0 as published by the Free Software Foundation
+** and appearing in the file LICENSE.GPL included in the packaging of this
+** file. Please review the following information to ensure the GNU General
+** Public License version 3.0 requirements will be met:
+** http://www.gnu.org/copyleft/gpl.html.
+**
+** Other Usage
+** Alternatively, this file may be used in accordance with the terms and
+** conditions contained in a signed written agreement between you and Nokia.
+**
+**
+**
+**
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include "../../linux-g++/qplatformdefs.h"
+
+#define QT_QPA_DEFAULT_PLATFORM_NAME "eglfs"
diff --git a/mkspecs/features/create_cmake.prf b/mkspecs/features/create_cmake.prf
index 6a8045ab3b..b8809a236b 100644
--- a/mkspecs/features/create_cmake.prf
+++ b/mkspecs/features/create_cmake.prf
@@ -17,10 +17,6 @@ defineReplace(cmakeModuleList) {
CMAKE_MODULE_NAME = $$cmakeModuleName($${MODULE})
-CMAKE_MODULE_DEPS = $$cmakeModuleList($$eval(QT.$${MODULE}.depends))
-CMAKE_PARTIAL_MODULE_DEPS = $$replace(CMAKE_MODULE_DEPS, ";", ";Qt5::")
-!isEmpty(CMAKE_PARTIAL_MODULE_DEPS):CMAKE_QT5_MODULE_DEPS = "Qt5::$${CMAKE_PARTIAL_MODULE_DEPS}"
-
CMAKE_QT_INSTALL_PREFIX = $$replace($$list($$[QT_INSTALL_PREFIX]), \\\\, /)/
CMAKE_QT_INSTALL_PREFIX_ESCAPED = "^$$re_escape($$CMAKE_QT_INSTALL_PREFIX)"
@@ -114,11 +110,11 @@ macx {
}
}
-debug_type =
-release_type =
+CMAKE_DEBUG_TYPE =
+CMAKE_RELEASE_TYPE =
-debug_and_release|debug:debug_type = debug
-debug_and_release|release:release_type = release
+debug_and_release|debug:CMAKE_DEBUG_TYPE = debug
+debug_and_release|release:CMAKE_RELEASE_TYPE = release
INSTALLS += cmake_qt5_module_files
diff --git a/mkspecs/features/declarative_debug.prf b/mkspecs/features/declarative_debug.prf
index 59e45f662f..9125fcf33f 100644
--- a/mkspecs/features/declarative_debug.prf
+++ b/mkspecs/features/declarative_debug.prf
@@ -1 +1,2 @@
DEFINES += QT_DECLARATIVE_DEBUG
+warning("CONFIG+=declarative_debug is deprecated. Use qml_debug instead!")
diff --git a/mkspecs/features/device_config.prf b/mkspecs/features/device_config.prf
index 56059e13cf..90bf9150e9 100644
--- a/mkspecs/features/device_config.prf
+++ b/mkspecs/features/device_config.prf
@@ -25,3 +25,14 @@ exists($$DEVICE_PRI):include($$DEVICE_PRI)
unset(DEVICE_PRI)
unset(DIR)
+# Provide a function to be used by mkspecs
+defineTest(deviceSanityCheckCompiler) {
+ # Check if the binary exists, e.g. with an absolute path
+ exists($$QMAKE_CXX):return()
+
+ # Check if the compiler is in the path
+ system("which $$QMAKE_CXX > /dev/null"):return()
+
+ error("Compiler $$QMAKE_CXX not found")
+}
+
diff --git a/mkspecs/features/qml_debug.prf b/mkspecs/features/qml_debug.prf
new file mode 100644
index 0000000000..72f4f2202a
--- /dev/null
+++ b/mkspecs/features/qml_debug.prf
@@ -0,0 +1 @@
+DEFINES += QT_QML_DEBUG
diff --git a/mkspecs/features/qt_module_config.prf b/mkspecs/features/qt_module_config.prf
index 75156a1f44..ac0b635f2f 100644
--- a/mkspecs/features/qt_module_config.prf
+++ b/mkspecs/features/qt_module_config.prf
@@ -42,7 +42,7 @@ CONFIG -= fix_output_dirs
win32|mac:!macx-xcode:CONFIG += debug_and_release
linux*:QMAKE_LFLAGS += $$QMAKE_LFLAGS_NOUNDEF
-!isEmpty(MODULE):CONFIG += create_cmake
+!isEmpty(DESTDIR):CONFIG += create_cmake
contains(QT_CONFIG, reduce_exports):CONFIG += hide_symbols
unix:contains(QT_CONFIG, reduce_relocations):CONFIG += bsymbolic_functions
diff --git a/mkspecs/unsupported/qnx-armv7le-qcc/qmake.conf b/mkspecs/unsupported/qnx-armv7le-qcc/qmake.conf
index ea206e28ec..ac6da27061 100644
--- a/mkspecs/unsupported/qnx-armv7le-qcc/qmake.conf
+++ b/mkspecs/unsupported/qnx-armv7le-qcc/qmake.conf
@@ -5,7 +5,7 @@
MAKEFILE_GENERATOR = UNIX
TARGET_PLATFORM = unix
TEMPLATE = app
-CONFIG += qt warn_on release link_prl qnx
+CONFIG += qt warn_on release link_prl
QT += core gui
include(../../common/g++-unix.conf)