diff options
Diffstat (limited to 'mkspecs')
94 files changed, 1280 insertions, 358 deletions
diff --git a/mkspecs/common/clang.conf b/mkspecs/common/clang.conf index ace2496f10..d58b44b295 100644 --- a/mkspecs/common/clang.conf +++ b/mkspecs/common/clang.conf @@ -13,6 +13,7 @@ QMAKE_LINK_SHLIB = $$QMAKE_CXX CONFIG += clang_pch_style QMAKE_PCH_OUTPUT_EXT = .pch +QMAKE_CFLAGS_ISYSTEM = -isystem QMAKE_CFLAGS_PRECOMPILE = -x c-header -c ${QMAKE_PCH_INPUT} -o ${QMAKE_PCH_OUTPUT} QMAKE_CFLAGS_USE_PRECOMPILE = -Xclang -include-pch -Xclang ${QMAKE_PCH_OUTPUT} QMAKE_CXXFLAGS_PRECOMPILE = -x c++-header -c ${QMAKE_PCH_INPUT} -o ${QMAKE_PCH_OUTPUT} diff --git a/mkspecs/common/gcc-base.conf b/mkspecs/common/gcc-base.conf index b1f2ad4979..e3e72741ab 100644 --- a/mkspecs/common/gcc-base.conf +++ b/mkspecs/common/gcc-base.conf @@ -40,6 +40,7 @@ QMAKE_CFLAGS_DEBUG += -g QMAKE_CFLAGS_SHLIB += -fPIC QMAKE_CFLAGS_STATIC_LIB += -fPIC QMAKE_CFLAGS_APP += -fPIE +QMAKE_CFLAGS_ISYSTEM = -isystem QMAKE_CFLAGS_YACC += -Wno-unused -Wno-parentheses QMAKE_CFLAGS_HIDESYMS += -fvisibility=hidden QMAKE_CFLAGS_EXCEPTIONS_OFF += -fno-exceptions diff --git a/mkspecs/common/mac/qplatformdefs.h b/mkspecs/common/mac/qplatformdefs.h index 7ee337cce4..aad3b2330c 100644 --- a/mkspecs/common/mac/qplatformdefs.h +++ b/mkspecs/common/mac/qplatformdefs.h @@ -87,7 +87,7 @@ #define QT_SIGNAL_IGNORE (void (*)(int))1 -#define QT_SNPRINTF ::snprintf -#define QT_VSNPRINTF ::vsnprintf +#define QT_SNPRINTF ::snprintf +#define QT_VSNPRINTF ::vsnprintf #endif // QPLATFORMDEFS_H diff --git a/mkspecs/common/wince/qplatformdefs.h b/mkspecs/common/wince/qplatformdefs.h index d46a03d5ca..b4d44c1dc5 100644 --- a/mkspecs/common/wince/qplatformdefs.h +++ b/mkspecs/common/wince/qplatformdefs.h @@ -63,48 +63,48 @@ #include <windows.h> #ifdef QT_LARGEFILE_SUPPORT -#define QT_STATBUF struct _stati64 // non-ANSI defs -#define QT_STATBUF4TSTAT struct _stati64 // non-ANSI defs -#define QT_STAT ::_stati64 -#define QT_FSTAT ::_fstati64 +#define QT_STATBUF struct _stati64 // non-ANSI defs +#define QT_STATBUF4TSTAT struct _stati64 // non-ANSI defs +#define QT_STAT ::_stati64 +#define QT_FSTAT ::_fstati64 #else -#define QT_STATBUF struct stat // non-ANSI defs -#define QT_STATBUF4TSTAT struct stat // non-ANSI defs -#define QT_STAT ::qt_wince_stat -#define QT_FSTAT ::qt_wince__fstat +#define QT_STATBUF struct stat // non-ANSI defs +#define QT_STATBUF4TSTAT struct stat // non-ANSI defs +#define QT_STAT ::qt_wince_stat +#define QT_FSTAT ::qt_wince__fstat #endif -#define QT_STAT_REG _S_IFREG -#define QT_STAT_DIR _S_IFDIR -#define QT_STAT_MASK _S_IFMT +#define QT_STAT_REG _S_IFREG +#define QT_STAT_DIR _S_IFDIR +#define QT_STAT_MASK _S_IFMT #if defined(_S_IFLNK) -# define QT_STAT_LNK _S_IFLNK +# define QT_STAT_LNK _S_IFLNK #endif -#define QT_FILENO ::qt_wince___fileno -#define QT_OPEN ::qt_wince_open -#define QT_CLOSE ::qt_wince__close +#define QT_FILENO ::qt_wince___fileno +#define QT_OPEN ::qt_wince_open +#define QT_CLOSE ::qt_wince__close #ifdef QT_LARGEFILE_SUPPORT -#define QT_LSEEK ::_lseeki64 -#define QT_TSTAT ::_tstati64 +#define QT_LSEEK ::_lseeki64 +#define QT_TSTAT ::_tstati64 #else -#define QT_LSEEK ::qt_wince__lseek -#define QT_TSTAT ::_tstat +#define QT_LSEEK ::qt_wince__lseek +#define QT_TSTAT ::_tstat #endif -#define QT_READ ::qt_wince__read -#define QT_WRITE ::qt_wince__write -#define QT_ACCESS ::qt_wince__access -#define QT_GETCWD ::_getcwd -#define QT_CHDIR ::_chdir -#define QT_MKDIR ::qt_wince__mkdir -#define QT_RMDIR ::qt_wince__rmdir -#define QT_OPEN_LARGEFILE 0 -#define QT_OPEN_RDONLY _O_RDONLY -#define QT_OPEN_WRONLY _O_WRONLY -#define QT_OPEN_RDWR _O_RDWR -#define QT_OPEN_CREAT _O_CREAT -#define QT_OPEN_TRUNC _O_TRUNC -#define QT_OPEN_APPEND _O_APPEND -# define QT_OPEN_TEXT _O_TEXT -# define QT_OPEN_BINARY _O_BINARY +#define QT_READ ::qt_wince__read +#define QT_WRITE ::qt_wince__write +#define QT_ACCESS ::qt_wince__access +#define QT_GETCWD ::_getcwd +#define QT_CHDIR ::_chdir +#define QT_MKDIR ::qt_wince__mkdir +#define QT_RMDIR ::qt_wince__rmdir +#define QT_OPEN_LARGEFILE 0 +#define QT_OPEN_RDONLY _O_RDONLY +#define QT_OPEN_WRONLY _O_WRONLY +#define QT_OPEN_RDWR _O_RDWR +#define QT_OPEN_CREAT _O_CREAT +#define QT_OPEN_TRUNC _O_TRUNC +#define QT_OPEN_APPEND _O_APPEND +# define QT_OPEN_TEXT _O_TEXT +# define QT_OPEN_BINARY _O_BINARY #define QT_FOPEN ::fopen #define QT_FSEEK ::fseek @@ -115,17 +115,17 @@ #define QT_FPOS_T fpos_t #define QT_OFF_T long -#define QT_SIGNAL_ARGS int +#define QT_SIGNAL_ARGS int #define QT_VSNPRINTF(buffer, count, format, arg) \ _vsnprintf(buffer, count, format, arg) -#define QT_SNPRINTF ::_snprintf +#define QT_SNPRINTF ::_snprintf -# define F_OK 0 -# define X_OK 1 -# define W_OK 2 -# define R_OK 4 +# define F_OK 0 +# define X_OK 1 +# define W_OK 2 +# define R_OK 4 typedef int mode_t; diff --git a/mkspecs/common/winrt_winphone/assets/logo_large.png b/mkspecs/common/winrt_winphone/assets/logo_large.png Binary files differnew file mode 100644 index 0000000000..069171ca4d --- /dev/null +++ b/mkspecs/common/winrt_winphone/assets/logo_large.png diff --git a/mkspecs/common/winrt_winphone/assets/logo_medium.png b/mkspecs/common/winrt_winphone/assets/logo_medium.png Binary files differnew file mode 100644 index 0000000000..fa0d9fb64a --- /dev/null +++ b/mkspecs/common/winrt_winphone/assets/logo_medium.png diff --git a/mkspecs/common/winrt_winphone/assets/logo_small.png b/mkspecs/common/winrt_winphone/assets/logo_small.png Binary files differnew file mode 100644 index 0000000000..2acac59e73 --- /dev/null +++ b/mkspecs/common/winrt_winphone/assets/logo_small.png diff --git a/mkspecs/common/winrt_winphone/assets/logo_splash.png b/mkspecs/common/winrt_winphone/assets/logo_splash.png Binary files differnew file mode 100644 index 0000000000..a2be79f5d7 --- /dev/null +++ b/mkspecs/common/winrt_winphone/assets/logo_splash.png diff --git a/mkspecs/common/winrt_winphone/assets/logo_store.png b/mkspecs/common/winrt_winphone/assets/logo_store.png Binary files differnew file mode 100644 index 0000000000..417ccdcb5f --- /dev/null +++ b/mkspecs/common/winrt_winphone/assets/logo_store.png diff --git a/mkspecs/common/winrt_winphone/assets/tile_iconic_medium.png b/mkspecs/common/winrt_winphone/assets/tile_iconic_medium.png Binary files differnew file mode 100644 index 0000000000..e42f8255db --- /dev/null +++ b/mkspecs/common/winrt_winphone/assets/tile_iconic_medium.png diff --git a/mkspecs/common/winrt_winphone/assets/tile_iconic_small.png b/mkspecs/common/winrt_winphone/assets/tile_iconic_small.png Binary files differnew file mode 100644 index 0000000000..c7b7ee7893 --- /dev/null +++ b/mkspecs/common/winrt_winphone/assets/tile_iconic_small.png diff --git a/mkspecs/common/winrt_winphone/manifests/8.0/AppxManifest.xml.in b/mkspecs/common/winrt_winphone/manifests/8.0/AppxManifest.xml.in new file mode 100644 index 0000000000..6a0ca444c3 --- /dev/null +++ b/mkspecs/common/winrt_winphone/manifests/8.0/AppxManifest.xml.in @@ -0,0 +1,39 @@ +<?xml version=\"1.0\" encoding=\"utf-8\"?> +<Package xmlns=\"http://schemas.microsoft.com/appx/2010/manifest\"> + <Identity + Name=\"$${WINRT_MANIFEST.identity}\" + ProcessorArchitecture=\"$${WINRT_MANIFEST.architecture}\" + Publisher=\"$${WINRT_MANIFEST.publisherid}\" + Version=\"$${WINRT_MANIFEST.version}\" /> + <Properties> + <DisplayName>$${WINRT_MANIFEST.name}</DisplayName> + <PublisherDisplayName>$${WINRT_MANIFEST.publisher}</PublisherDisplayName> + <Logo>$${WINRT_MANIFEST.logo_store}</Logo> + </Properties> + <Prerequisites> + <OSMinVersion>6.2.0</OSMinVersion> + <OSMaxVersionTested>6.3.0</OSMaxVersionTested> + </Prerequisites> + <Resources> + <Resource Language=\"en\" /> + </Resources> + <Applications> + <Application + Id=\"App\" + Executable=\"$${WINRT_MANIFEST.target}.exe\" + EntryPoint=\"$${WINRT_MANIFEST.target}.App\"> + <VisualElements + DisplayName=\"$${WINRT_MANIFEST.name}\" + Logo=\"$${WINRT_MANIFEST.logo_large}\" + SmallLogo=\"$${WINRT_MANIFEST.logo_small}\" + Description=\"$${WINRT_MANIFEST.description}\" + BackgroundColor=\"$${WINRT_MANIFEST.background}\" + ForegroundText=\"$${WINRT_MANIFEST.foreground}\"> + <SplashScreen Image=\"$${WINRT_MANIFEST.logo_splash}\" /> + </VisualElements> + </Application> + </Applications> + <Capabilities>$${WINRT_MANIFEST.capabilities}</Capabilities> + <Dependencies>$${WINRT_MANIFEST.dependencies}</Dependencies> +</Package> +<!-- Generated by qmake using the $$[QMAKE_XSPEC] mkspec. Remove this line to prevent this file from getting overwritten by qmake. --> diff --git a/mkspecs/common/winrt_winphone/manifests/8.0/WMAppManifest.xml.in b/mkspecs/common/winrt_winphone/manifests/8.0/WMAppManifest.xml.in new file mode 100644 index 0000000000..e1d3d071e9 --- /dev/null +++ b/mkspecs/common/winrt_winphone/manifests/8.0/WMAppManifest.xml.in @@ -0,0 +1,39 @@ +<?xml version=\"1.0\" encoding=\"utf-8\"?> +<Deployment xmlns=\"http://schemas.microsoft.com/windowsphone/2012/deployment\" AppPlatformVersion=\"8.0\"> + <DefaultLanguage xmlns=\"\" code=\"en-US\" /> + <App xmlns=\"\" + ProductID=\"$${WINRT_MANIFEST.identity}\" + Title=\"$${WINRT_MANIFEST.name}\" + RuntimeType=\"Modern Native\" + Version=\"$${WINRT_MANIFEST.version}\" + Genre=\"$${WINRT_MANIFEST.genre}\" + Author=\"$${WINRT_MANIFEST.author}\" + Description=\"$${WINRT_MANIFEST.description}\" + Publisher=\"$${WINRT_MANIFEST.publisher}\" + PublisherID=\"$${WINRT_MANIFEST.publisherid}\"> + <IconPath IsRelative=\"true\" IsResource=\"false\">$${WINRT_MANIFEST.logo_medium}</IconPath> + <Capabilities>$${WINRT_MANIFEST.capabilities}</Capabilities> + <Tasks> + <DefaultTask + Name=\"_default\" + ImagePath=\"$${WINRT_MANIFEST.target}.exe\" + ImageParams=\"$${WINRT_MANIFEST.arguments}\" /> + </Tasks> + <Tokens> + <PrimaryToken TokenID=\"$${WINRT_MANIFEST.target}\" TaskName=\"_default\"> + <TemplateIconic> + <SmallImageURI IsRelative=\"true\" IsResource=\"false\">$${WINRT_MANIFEST.tile_iconic_small}</SmallImageURI> + <IconImageURI IsRelative=\"true\" IsResource=\"false\">$${WINRT_MANIFEST.tile_iconic_medium}</IconImageURI> + <Title>$${WINRT_MANIFEST.name}</Title> + <BackgroundColor>$${WINRT_MANIFEST.background}</BackgroundColor> + </TemplateIconic> + </PrimaryToken> + </Tokens> + <ScreenResolutions> + <ScreenResolution Name=\"ID_RESOLUTION_WVGA\" /> + <ScreenResolution Name=\"ID_RESOLUTION_WXGA\" /> + <ScreenResolution Name=\"ID_RESOLUTION_HD720P\" /> + </ScreenResolutions> + </App> +</Deployment> +<!-- Generated by qmake using the $$[QMAKE_XSPEC] mkspec. Remove this line to prevent this file from getting overwritten by qmake. --> diff --git a/mkspecs/common/winrt_winphone/manifests/8.1/AppxManifest.xml.in b/mkspecs/common/winrt_winphone/manifests/8.1/AppxManifest.xml.in new file mode 100644 index 0000000000..8c214871e3 --- /dev/null +++ b/mkspecs/common/winrt_winphone/manifests/8.1/AppxManifest.xml.in @@ -0,0 +1,44 @@ +<?xml version=\"1.0\" encoding=\"utf-8\"?> +<Package xmlns=\"http://schemas.microsoft.com/appx/2010/manifest\" xmlns:v2=\"http://schemas.microsoft.com/appx/2013/manifest\"> + <Identity + Name=\"$${WINRT_MANIFEST.identity}\" + ProcessorArchitecture=\"$${WINRT_MANIFEST.architecture}\" + Publisher=\"$${WINRT_MANIFEST.publisherid}\" + Version=\"$${WINRT_MANIFEST.version}\" /> + <Properties> + <DisplayName>$${WINRT_MANIFEST.name}</DisplayName> + <PublisherDisplayName>$${WINRT_MANIFEST.publisher}</PublisherDisplayName> + <Logo>$${WINRT_MANIFEST.logo_store}</Logo> + </Properties> + <Prerequisites> + <OSMinVersion>6.3.0</OSMinVersion> + <OSMaxVersionTested>6.3.0</OSMaxVersionTested> + </Prerequisites> + <Resources> + <Resource Language=\"en\" /> + </Resources> + <Applications> + <Application + Id=\"App\" + Executable=\"$${WINRT_MANIFEST.target}.exe\" + EntryPoint=\"$${WINRT_MANIFEST.target}.App\"> + <v2:VisualElements + DisplayName=\"$${WINRT_MANIFEST.name}\" + Description=\"$${WINRT_MANIFEST.description}\" + BackgroundColor=\"$${WINRT_MANIFEST.background}\" + ForegroundText=\"$${WINRT_MANIFEST.foreground}\" + Square150x150Logo=\"$${WINRT_MANIFEST.logo_large}\" + Square30x30Logo=\"$${WINRT_MANIFEST.logo_small}\"> + <v2:DefaultTile> + <v2:ShowNameOnTiles> + <v2:ShowOn Tile=\"square150x150Logo\" /> + </v2:ShowNameOnTiles> + </v2:DefaultTile> + <v2:SplashScreen Image=\"$${WINRT_MANIFEST.logo_splash}\" /> + </v2:VisualElements> + </Application> + </Applications> + <Capabilities>$${WINRT_MANIFEST.capabilities}</Capabilities> + <Dependencies>$${WINRT_MANIFEST.dependencies}</Dependencies> +</Package> +<!-- Generated by qmake using the $$[QMAKE_XSPEC] mkspec. Remove this line to prevent this file from getting overwritten by qmake. --> diff --git a/mkspecs/common/winrt_winphone/qmake.conf b/mkspecs/common/winrt_winphone/qmake.conf index a8c9582c31..d7296afe95 100644 --- a/mkspecs/common/winrt_winphone/qmake.conf +++ b/mkspecs/common/winrt_winphone/qmake.conf @@ -1,16 +1,15 @@ # # qmake configuration for winrt and windows phone 8 # -# Written for Microsoft Visual C++ 2012 +# Written for Microsoft Visual C++ # MAKEFILE_GENERATOR = MSBUILD QMAKE_COMPILER = msvc QMAKE_PLATFORM = winrt win32 -CONFIG += incremental flat precompile_header autogen_precompile_source debug_and_release debug_and_release_target no_generated_target_info autogen_wmappmanifest rtti -DEFINES += UNICODE WINRT QT_LARGEFILE_SUPPORT Q_BYTE_ORDER=Q_LITTLE_ENDIAN \ +CONFIG += incremental flat precompile_header autogen_precompile_source debug_and_release debug_and_release_target no_generated_target_info package_manifest rtti +DEFINES += UNICODE WIN32 QT_LARGEFILE_SUPPORT Q_BYTE_ORDER=Q_LITTLE_ENDIAN \ QT_NO_PRINTER QT_NO_PRINTDIALOG # TODO: Remove when printing is re-enabled -QMAKE_COMPILER_DEFINES += _MSC_VER=1700 WINRT DEPLOYMENT_PLUGIN += qwinrt @@ -19,7 +18,6 @@ QMAKE_LEX = flex QMAKE_LEXFLAGS = QMAKE_YACC = byacc QMAKE_YACCFLAGS = -d -#QMAKE_CFLAGS = -nologo -Zm200 -Zc:wchar_t- QMAKE_CFLAGS = -nologo -Zm200 QMAKE_CFLAGS_WARN_ON = -W3 QMAKE_CFLAGS_WARN_OFF = -W0 @@ -64,22 +62,24 @@ QMAKE_RUN_CXX_IMP = $(CXX) -c $(CXXFLAGS) $(INCPATH) -Fo$@ $< QMAKE_RUN_CXX_IMP_BATCH = $(CXX) -c $(CXXFLAGS) $(INCPATH) -Fo$@ @<< QMAKE_LINK = link -QMAKE_LFLAGS = /NOLOGO /DYNAMICBASE /NXCOMPAT /NODEFAULTLIB:ole32.lib +QMAKE_LFLAGS = /NOLOGO /DYNAMICBASE /NXCOMPAT /NODEFAULTLIB:ole32.lib /APPCONTAINER QMAKE_LFLAGS_RELEASE = /INCREMENTAL:NO QMAKE_LFLAGS_RELEASE_WITH_DEBUGINFO = /DEBUG /OPT:REF /INCREMENTAL:NO QMAKE_LFLAGS_DEBUG = /DEBUG -QMAKE_LFLAGS_CONSOLE = /SUBSYSTEM:CONSOLE QMAKE_LFLAGS_WINDOWS = /SUBSYSTEM:WINDOWS -QMAKE_LFLAGS_EXE = /WINMD /MANIFEST:NO -QMAKE_LFLAGS_DLL = /WINMD /MANIFEST:NO /DLL /WINMDFILE:$(DESTDIR_TARGET).winmd +QMAKE_LFLAGS_EXE = /MANIFEST:NO +QMAKE_LFLAGS_DLL = /MANIFEST:NO /DLL QMAKE_LFLAGS_LTCG = /LTCG QMAKE_EXTENSION_STATICLIB = lib +QMAKE_LIBS += runtimeobject.lib QMAKE_LIBS_CORE = -QMAKE_LIBS_GUI = d3d11.lib +QMAKE_LIBS_GUI = QMAKE_LIBS_NETWORK = +QMAKE_LIBS_OPENGL_ES2 = libEGL.lib libGLESv2.lib +QMAKE_LIBS_OPENGL_ES2_DEBUG = libEGLd.lib libGLESv2d.lib -QMAKE_LIBS_QT_ENTRY = -lqtmain /ENTRY:wmainCRTStartup +QMAKE_LIBS_QT_ENTRY = -lqtmain QMAKE_IDL = midl QMAKE_LIB = lib /NOLOGO @@ -89,5 +89,6 @@ include(../shell-win32.conf) VCPROJ_EXTENSION = .vcxproj VCSOLUTION_EXTENSION = .sln -VCPROJ_KEYWORD = Qt4VSv1.0 +VCPROJ_KEYWORD = Qt4VSv1.0 +WINRT_ASSETS_PATH = $$PWD/assets load(qt_config) diff --git a/mkspecs/common/winrt_winphone/qplatformdefs.h b/mkspecs/common/winrt_winphone/qplatformdefs.h new file mode 100644 index 0000000000..96f20569d2 --- /dev/null +++ b/mkspecs/common/winrt_winphone/qplatformdefs.h @@ -0,0 +1,141 @@ +/**************************************************************************** +** +** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies). +** Contact: http://www.qt-project.org/legal +** +** This file is part of the qmake spec of the Qt Toolkit. +** +** $QT_BEGIN_LICENSE:LGPL$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and Digia. For licensing terms and +** conditions see http://qt.digia.com/licensing. For further information +** use the contact form at http://qt.digia.com/contact-us. +** +** GNU Lesser General Public License Usage +** Alternatively, 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, Digia gives you certain additional +** rights. These rights are described in the Digia 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. +** +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +#ifndef QPLATFORMDEFS_H +#define QPLATFORMDEFS_H + +#ifdef UNICODE +#ifndef _UNICODE +#define _UNICODE +#endif +#endif + +// Get Qt defines/settings + +#include "qglobal.h" +#include "qfunctions_winrt.h" + +#define _POSIX_ +#include <limits.h> +#undef _POSIX_ + +#include <tchar.h> +#include <io.h> +#include <direct.h> +#include <stdio.h> +#include <fcntl.h> +#include <errno.h> +#include <sys/stat.h> +#include <stdlib.h> + +#ifdef QT_LARGEFILE_SUPPORT +#define QT_STATBUF struct _stati64 // non-ANSI defs +#define QT_STATBUF4TSTAT struct _stati64 // non-ANSI defs +#define QT_STAT ::_stati64 +#define QT_FSTAT ::_fstati64 +#else +#define QT_STATBUF struct _stat // non-ANSI defs +#define QT_STATBUF4TSTAT struct _stat // non-ANSI defs +#define QT_STAT ::_stat +#define QT_FSTAT ::_fstat +#endif +#define QT_STAT_REG _S_IFREG +#define QT_STAT_DIR _S_IFDIR +#define QT_STAT_MASK _S_IFMT +#if defined(_S_IFLNK) +# define QT_STAT_LNK _S_IFLNK +#endif +#define QT_FILENO _fileno +#define QT_OPEN ::_open +#define QT_CLOSE ::_close +#ifdef QT_LARGEFILE_SUPPORT +#define QT_LSEEK ::_lseeki64 +#define QT_TSTAT ::_tstati64 +#else +#define QT_LSEEK ::_lseek +#define QT_TSTAT ::_tstat +#endif +#define QT_READ ::_read +#define QT_WRITE ::_write +#define QT_ACCESS ::_access +#define QT_GETCWD ::_getcwd +#define QT_CHDIR ::_chdir +#define QT_MKDIR ::_mkdir +#define QT_RMDIR ::_rmdir +#define QT_OPEN_LARGEFILE 0 +#define QT_OPEN_RDONLY _O_RDONLY +#define QT_OPEN_WRONLY _O_WRONLY +#define QT_OPEN_RDWR _O_RDWR +#define QT_OPEN_CREAT _O_CREAT +#define QT_OPEN_TRUNC _O_TRUNC +#define QT_OPEN_APPEND _O_APPEND +#if defined(O_TEXT) +# define QT_OPEN_TEXT _O_TEXT +# define QT_OPEN_BINARY _O_BINARY +#endif + +#include "../common/c89/qplatformdefs.h" + +#ifdef QT_LARGEFILE_SUPPORT +#undef QT_FSEEK +#undef QT_FTELL +#undef QT_OFF_T + +#define QT_FSEEK ::_fseeki64 +#define QT_FTELL ::_ftelli64 +#define QT_OFF_T __int64 +#endif + +#define QT_SIGNAL_ARGS int + +#define QT_VSNPRINTF(buffer, count, format, arg) \ + vsnprintf_s(buffer, count, count-1, format, arg) + +#define QT_SNPRINTF ::_snprintf + +# define F_OK 0 +# define X_OK 1 +# define W_OK 2 +# define R_OK 4 + +typedef int mode_t; + +#endif // QPLATFORMDEFS_H diff --git a/mkspecs/cygwin-g++/qplatformdefs.h b/mkspecs/cygwin-g++/qplatformdefs.h index e7255a9342..b3ecc0f84d 100644 --- a/mkspecs/cygwin-g++/qplatformdefs.h +++ b/mkspecs/cygwin-g++/qplatformdefs.h @@ -73,7 +73,7 @@ #include <sys/ioctl.h> // Cygwin does not provide <sys/ipc.h> and <sys/shm.h> because it // doesn't support SysV IPC or shared memory. See for example: -// http://afni.nimh.nih.gov/afni/afniboard/messages/1725.html +// http://afni.nimh.nih.gov/afni/afniboard/messages/1725.html #include <sys/time.h> #include <sys/socket.h> #include <sys/stat.h> @@ -88,8 +88,8 @@ #define QT_OPEN_LARGEFILE 0 #if defined(_XOPEN_SOURCE) && (_XOPEN_SOURCE >= 500) -#define QT_SNPRINTF ::snprintf -#define QT_VSNPRINTF ::vsnprintf +#define QT_SNPRINTF ::snprintf +#define QT_VSNPRINTF ::vsnprintf #endif #endif // QPLATFORMDEFS_H diff --git a/mkspecs/darwin-g++/qplatformdefs.h b/mkspecs/darwin-g++/qplatformdefs.h index 20ffac9e5b..f89d4bee80 100644 --- a/mkspecs/darwin-g++/qplatformdefs.h +++ b/mkspecs/darwin-g++/qplatformdefs.h @@ -79,7 +79,7 @@ #undef QT_OPEN_LARGEFILE #define QT_OPEN_LARGEFILE 0 -#define QT_SNPRINTF ::snprintf -#define QT_VSNPRINTF ::vsnprintf +#define QT_SNPRINTF ::snprintf +#define QT_VSNPRINTF ::vsnprintf #endif // QPLATFORMDEFS_H diff --git a/mkspecs/devices/linux-rasp-pi-g++/qeglfshooks_pi.cpp b/mkspecs/devices/linux-rasp-pi-g++/qeglfshooks_pi.cpp index 5e57ba382a..c4737a4559 100644 --- a/mkspecs/devices/linux-rasp-pi-g++/qeglfshooks_pi.cpp +++ b/mkspecs/devices/linux-rasp-pi-g++/qeglfshooks_pi.cpp @@ -40,7 +40,6 @@ ****************************************************************************/ #include "qeglfshooks.h" -#include "qeglfscursor.h" #include <QtDebug> @@ -107,12 +106,6 @@ static void moveDispmanxLayer(EGLNativeWindowType window, const QPoint &pos) 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; - DISPMANX_UPDATE_HANDLE_T dispman_update = vc_dispmanx_update_start(0); vc_dispmanx_element_change_attributes(dispman_update, eglWindow->element, diff --git a/mkspecs/devices/linux-tegra2-g++/qmake.conf b/mkspecs/devices/linux-tegra2-g++/qmake.conf index 320e1b8a21..adadc4d5b0 100644 --- a/mkspecs/devices/linux-tegra2-g++/qmake.conf +++ b/mkspecs/devices/linux-tegra2-g++/qmake.conf @@ -6,9 +6,7 @@ # A typical configure line looks like this: # <path-to-qt-src>/configure -opensource -confirm-license -make libs -prefix /usr/local/Qt-5.0.0/Qt5-tegra2 # -device tegra2 -device-option CROSS_COMPILE=<path-to-crosstoolchain>/bin/arm-none-linux-gnueabi- \ -# -sysroot <path-to-rootfs> -no-neon - -# CAUTION: The Tegra2 chips don't support neon, make sure it will not be used (-no-neon) +# -sysroot <path-to-rootfs> include(../common/linux_device_pre.conf) diff --git a/mkspecs/features/configure.prf b/mkspecs/features/configure.prf index 39144e7216..fe41c541a2 100644 --- a/mkspecs/features/configure.prf +++ b/mkspecs/features/configure.prf @@ -53,6 +53,12 @@ defineTest(qtCompileTest) { # Disable qmake features which are typically counterproductive for tests qmake_configs = "\"CONFIG -= qt debug_and_release app_bundle lib_bundle\"" + # On WinRT we need to change the entry point as we cannot create windows + # applications + winrt { + qmake_configs += " \"QMAKE_LFLAGS+=/ENTRY:main\"" + } + # Clean up after previous run exists($$test_out_dir/Makefile):qtRunLoggedCommand("$$test_cmd_base $$QMAKE_MAKE distclean") diff --git a/mkspecs/features/create_cmake.prf b/mkspecs/features/create_cmake.prf index 19b26460a0..82e2812f3b 100644 --- a/mkspecs/features/create_cmake.prf +++ b/mkspecs/features/create_cmake.prf @@ -195,7 +195,7 @@ mac { CMAKE_LIB_FILE_LOCATION_DEBUG = $${CMAKE_QT_STEM}d.dll CMAKE_LIB_FILE_LOCATION_RELEASE = $${CMAKE_QT_STEM}.dll - win32-g++ { + mingw { CMAKE_WINMAIN_FILE_LOCATION_DEBUG = libqtmain$${QT_LIBINFIX}d.a CMAKE_WINMAIN_FILE_LOCATION_RELEASE = libqtmain$${QT_LIBINFIX}.a diff --git a/mkspecs/features/ctest_testcase_common.prf b/mkspecs/features/ctest_testcase_common.prf index a9461eb4ae..a2b7e8e72b 100644 --- a/mkspecs/features/ctest_testcase_common.prf +++ b/mkspecs/features/ctest_testcase_common.prf @@ -51,7 +51,7 @@ load(cmake_functions) CMAKE_BUILD_TYPE = Debug CONFIG(release, debug|release):CMAKE_BUILD_TYPE = Release -win32-g++*:isEmpty(CROSS_COMPILE):CMAKE_GENERATOR = -G \"MinGW Makefiles\" +mingw:isEmpty(CROSS_COMPILE):CMAKE_GENERATOR = -G \"MinGW Makefiles\" win32:equals(QT_ARCH, x86_64) { win32-msvc2010:CMAKE_GENERATOR = -G \"Visual Studio 10 Win64\" win32-msvc2012:CMAKE_GENERATOR = -G \"Visual Studio 11 Win64\" diff --git a/mkspecs/features/default_post.prf b/mkspecs/features/default_post.prf index ee0fdfef48..dd2923f9be 100644 --- a/mkspecs/features/default_post.prf +++ b/mkspecs/features/default_post.prf @@ -82,5 +82,7 @@ breakpad { !isEmpty(QMAKE_STRIP):QMAKE_POST_LINK = $$QMAKE_POST_LINK$$escape_expand(\\n\\t)$$quote($$QMAKE_STRIP $$DEBUGFILENAME) } +!precompile_header: SOURCES += $$NO_PCH_SOURCES + QMAKE_INCDIR += $$QMAKE_INCDIR_POST QMAKE_LIBDIR += $$QMAKE_LIBDIR_POST diff --git a/mkspecs/features/mac/default_post.prf b/mkspecs/features/mac/default_post.prf index c3addf9319..da3e22b5f3 100644 --- a/mkspecs/features/mac/default_post.prf +++ b/mkspecs/features/mac/default_post.prf @@ -15,8 +15,26 @@ qt:!isEmpty(QT_CONFIG) { contains(QT_CONFIG, x86_64):!contains(QT_CONFIG, x86):CONFIG += x86_64 } - # Ensure that C++11 is always used when linking against a static Qt build - contains(QT_CONFIG, static):contains(QT_CONFIG, c++11): CONFIG += c++11 + contains(QT_CONFIG, static) { + # C++11 support means using libc++ instead of libstd++. As the + # two libraries are incompatible we need to ensure the end user + # project is built using the same C++11 support/no support as Qt. + contains(QT_CONFIG, c++11) { + CONFIG += c++11 + } else: c++11 { + warning("Qt was not built with C++11 enabled, disabling feature") + CONFIG -= c++11 + } + + !c++11 { + # Explicitly use libstdc++ if C++11 support is not enabled, + # as otherwise the compiler will choose the standard library + # based on the deployment target, which for iOS 7 and OS X 10.9 + # is libc++, and we can't mix and match the two. + QMAKE_CXXFLAGS += -stdlib=libstdc++ + QMAKE_LFLAGS += -stdlib=libstdc++ + } + } } cache(QMAKE_XCODE_DEVELOPER_PATH, stash) diff --git a/mkspecs/features/moc.prf b/mkspecs/features/moc.prf index 59ac9db05b..100edc2d98 100644 --- a/mkspecs/features/moc.prf +++ b/mkspecs/features/moc.prf @@ -5,49 +5,34 @@ isEmpty(MOC_DIR):MOC_DIR = . isEmpty(QMAKE_H_MOD_MOC):QMAKE_H_MOD_MOC = moc_ isEmpty(QMAKE_EXT_CPP_MOC):QMAKE_EXT_CPP_MOC = .moc +MOC_INCLUDEPATH = +for (inc, INCLUDEPATH): \ + MOC_INCLUDEPATH += $$absolute_path($$inc, $$_PRO_FILE_PWD_) +MOC_INCLUDEPATH = $$QMAKESPEC $$_PRO_FILE_PWD_ $$MOC_INCLUDEPATH $$QMAKE_DEFAULT_INCDIRS + # On Windows, put the includes into a .inc file which moc will read, if the project # has too many includes. We do this to overcome a command-line limit on Win < XP -INCLUDETEMP= WIN_INCLUDETEMP= -win32:count(INCLUDEPATH, 40, >) { - INCLUDETEMP = $$MOC_DIR/mocinclude.tmp - - WIN_INCLUDETEMP=$$INCLUDETEMP - - EOC = $$escape_expand(\\n\\t) +win32:count(MOC_INCLUDEPATH, 40, >) { + WIN_INCLUDETEMP = $$MOC_DIR/mocinclude.tmp - contains(TEMPLATE, "vc.*") { - # the VCPROJ generator will replace the \r\h with the coded \r\n: 
 - EOC = $$escape_expand(\\r\\h) - } - - unset(INCFILELIST) - RET = - for(incfile, INCLUDEPATH) { - INCFILELIST = -I$$incfile - isEmpty(RET): RET += @echo $$INCFILELIST> $$WIN_INCLUDETEMP $$EOC - else: RET += @echo $$INCFILELIST>> $$WIN_INCLUDETEMP $$EOC - } - !isEmpty(INCFILELIST):RET += @echo $$INCFILELIST>> $$WIN_INCLUDETEMP $$EOC - - build_pass|isEmpty(BUILDS) { - mocinclude.target = $$INCLUDETEMP - mocinclude.commands = $$RET - QMAKE_EXTRA_TARGETS += mocinclude - } + WIN_INCLUDETEMP_CONT = + for (inc, MOC_INCLUDEPATH): \ + WIN_INCLUDETEMP_CONT += -I$$inc + write_file($$absolute_path($$WIN_INCLUDETEMP, $$OUT_PWD), WIN_INCLUDETEMP_CONT)|error("Aborting.") } defineReplace(mocCmdBase) { RET = !isEmpty(WIN_INCLUDETEMP) { - contains(TEMPLATE, "vc.*") { - RET += $$mocinclude.commands - } incvar = @$$WIN_INCLUDETEMP } else { - incvar = $(INCPATH) + incvar = + for (inc, MOC_INCLUDEPATH): \ + incvar += -I$$shell_quote($$inc) + incvar += $$QMAKE_FRAMEWORKPATH_FLAGS } - RET += $$QMAKE_MOC $(DEFINES) $$join(QMAKE_COMPILER_DEFINES, " -D", -D) $$incvar $$join(QMAKE_DEFAULT_INCDIRS, " -I", -I) $$QMAKE_MOC_OPTIONS + RET += $$QMAKE_MOC $(DEFINES) $$join(QMAKE_COMPILER_DEFINES, " -D", -D) $$incvar $$QMAKE_MOC_OPTIONS return($$RET) } @@ -59,9 +44,7 @@ moc_header.output = $$MOC_DIR/$${QMAKE_H_MOD_MOC}${QMAKE_FILE_BASE}$${first(QMAK moc_header.input = HEADERS moc_header.variable_out = SOURCES moc_header.name = MOC ${QMAKE_FILE_IN} -!contains(TEMPLATE, "vc.*") { - !isEmpty(INCLUDETEMP):moc_header.depends += $$INCLUDETEMP -} +moc_header.depends += $$WIN_INCLUDETEMP silent:moc_header.commands = @echo moc ${QMAKE_FILE_IN} && $$moc_header.commands QMAKE_EXTRA_COMPILERS += moc_header INCREDIBUILD_XGE += moc_header @@ -73,9 +56,7 @@ moc_source.commands = ${QMAKE_FUNC_mocCmdBase} ${QMAKE_FILE_IN} -o ${QMAKE_FILE_ moc_source.output = $$MOC_DIR/$${QMAKE_CPP_MOD_MOC}${QMAKE_FILE_BASE}$${QMAKE_EXT_CPP_MOC} moc_source.input = SOURCES OBJECTIVE_SOURCES moc_source.name = MOC ${QMAKE_FILE_IN} -!contains(TEMPLATE, "vc.*") { - !isEmpty(INCLUDETEMP):moc_source.depends += $$INCLUDETEMP -} +moc_source.depends += $$WIN_INCLUDETEMP silent:moc_source.commands = @echo moc ${QMAKE_FILE_IN} && $$moc_source.commands QMAKE_EXTRA_COMPILERS += moc_source INCREDIBUILD_XGE += moc_source diff --git a/mkspecs/features/precompile_header.prf b/mkspecs/features/precompile_header.prf new file mode 100644 index 0000000000..9b233dd872 --- /dev/null +++ b/mkspecs/features/precompile_header.prf @@ -0,0 +1,24 @@ +# +# W A R N I N G +# ------------- +# +# This file is not part of the Qt API. It exists purely as an +# implementation detail. It may change from version to version +# without notice, or even be removed. +# +# We mean it. +# + +# +# Set up extra compiler for PCH disabled sources +# +no_pch_compiler.commands = $$QMAKE_CXX -c $(CXXFLAGS) $(INCPATH) ${QMAKE_FILE_IN} +msvc: no_pch_compiler.commands += -Fo${QMAKE_FILE_OUT} +else: no_pch_compiler.commands += -o ${QMAKE_FILE_OUT} +no_pch_compiler.dependency_type = TYPE_C +no_pch_compiler.output = ${QMAKE_VAR_OBJECTS_DIR}${QMAKE_FILE_BASE}$${first(QMAKE_EXT_OBJ)} +no_pch_compiler.input = NO_PCH_SOURCES +no_pch_compiler.variable_out = OBJECTS +no_pch_compiler.name = compiling[no_pch] ${QMAKE_FILE_IN} +silent: no_pch_compiler.commands = @echo compiling[no_pch] ${QMAKE_FILE_IN} && $$no_pch_compiler.commands +QMAKE_EXTRA_COMPILERS += no_pch_compiler diff --git a/mkspecs/features/qlalr.prf b/mkspecs/features/qlalr.prf new file mode 100644 index 0000000000..e5e4b87802 --- /dev/null +++ b/mkspecs/features/qlalr.prf @@ -0,0 +1,49 @@ +qtPrepareTool(QMAKE_QLALR, qlalr) + +isEmpty(QLALR_DIR): QLALR_DIR = . + +!isEmpty(QLALRSOURCES) { + INCLUDEPATH += $$absolute_path($$QLALR_DIR, $$OUT_PWD) +} + +for (s, QLALRSOURCES) { + sf = $$absolute_path($$s, $$_PRO_FILE_PWD_) + QMAKE_INTERNAL_INCLUDED_FILES += $$sf + sfl = $$cat($$sf, lines) + parser = $$lower($$member($$list($$find(sfl, "^%parser\\s")), 1)) + isEmpty(parser): error("Could not extract %parser from $$sf") + decl = $$member($$list($$find(sfl, "^%decl\\s")), 1) + isEmpty(decl): error("Could not extract %decl from $$sf") + impl = $$member($$list($$find(sfl, "^%impl\\s")), 1) + isEmpty(impl): error("Could not extract %impl from $$sf") + base = qlalr_$$replace(sf, ^.*/([^./]+)[^/]*$, \\1) + + invar = $$upper($$base)_SOURCES + $$invar = $$sf + $${base}.input = $$invar + $${base}.output = $$QLALR_DIR/$${parser}.cpp + $${base}.variable_out = GENERATED_SOURCES + $${base}.commands = $$QMAKE_QLALR $$QMAKE_QLALRFLAGS ${QMAKE_FILE_IN} + silent: $${base}.commands = @echo qlalr ${QMAKE_FILE_IN} && $${base}.commands + $${base}.name = QLALR ${QMAKE_FILE_IN} + + $${base}_h.input = $$invar + $${base}_h.output = $$QLALR_DIR/$${parser}_p.h + $${base}_h.CONFIG = no_link + $${base}_h.depends = $$QLALR_DIR/$${parser}.cpp + $${base}_h.commands = $$escape_expand(\\n) # force creation of rule + + $${base}_decl.input = $$invar + $${base}_decl.output = $$QLALR_DIR/$${decl} + $${base}_decl.CONFIG = no_link + $${base}_decl.depends = $$QLALR_DIR/$${parser}.cpp + $${base}_decl.commands = $$escape_expand(\\n) # force creation of rule + + $${base}_impl.input = $$invar + $${base}_impl.output = $$QLALR_DIR/$${impl} + $${base}_impl.variable_out = GENERATED_SOURCES + $${base}_impl.depends = $$QLALR_DIR/$${parser}.cpp + $${base}_impl.commands = $$escape_expand(\\n) # force creation of rule + + QMAKE_EXTRA_COMPILERS += $$base $${base}_h $${base}_decl $${base}_impl +} diff --git a/mkspecs/features/qml_plugin.prf b/mkspecs/features/qml_plugin.prf index af941058db..f3739572c7 100644 --- a/mkspecs/features/qml_plugin.prf +++ b/mkspecs/features/qml_plugin.prf @@ -101,7 +101,7 @@ load(qt_common) load(qml_module) -unix|win32-g++* { +unix|mingw { !isEmpty(_QMAKE_SUPER_CACHE_): \ lib_replace.match = $$dirname(_QMAKE_SUPER_CACHE_)/[^/][^/]*/lib else: \ diff --git a/mkspecs/features/qt_common.prf b/mkspecs/features/qt_common.prf index 22d66e8907..051420e4f1 100644 --- a/mkspecs/features/qt_common.prf +++ b/mkspecs/features/qt_common.prf @@ -27,11 +27,15 @@ warnings_are_errors:warning_clean { # This setting is compiler-dependent anyway because it depends on the version of the # compiler. clang { - # Apple clang 4.0-4.2 - # Regular clang is not tested - ver = $${QT_APPLE_CLANG_MAJOR_VERSION}.$${QT_APPLE_CLANG_MINOR_VERSION} - contains(ver, "4\\.[012]") { - QMAKE_CXXFLAGS += -Werror -Wno-error=\\$${LITERAL_HASH}warnings -Wno-error=deprecated-declarations $$WERROR + # Apple clang 4.0-4.2,5.0 + # Regular clang 3.3 & 3.4 + apple_ver = $${QT_APPLE_CLANG_MAJOR_VERSION}.$${QT_APPLE_CLANG_MINOR_VERSION} + reg_ver = $${QT_CLANG_MAJOR_VERSION}.$${QT_CLANG_MINOR_VERSION} + contains(apple_ver, "4\\.[012]|5\\.0")|contains(reg_ver, "3\\.[34]") { + QMAKE_CXXFLAGS_WARN_ON += -Werror -Wno-error=\\$${LITERAL_HASH}warnings -Wno-error=deprecated-declarations $$WERROR + + # glibc's bswap_XX macros use the "register" keyword + linux:equals(reg_ver, "3.4"): QMAKE_CXXFLAGS_WARN_ON += -Wno-error=deprecated-register } } else:intel_icc:linux { # Intel CC 13.0 - 14.0, on Linux only @@ -43,20 +47,20 @@ warnings_are_errors:warning_clean { # 1478: function "entity" (declared at line N) was declared deprecated # 1881: argument must be a constant null pointer value # (NULL in C++ is usually a literal 0) - QMAKE_CXXFLAGS += -Werror -ww177,1224,1478,1881 $$WERROR + QMAKE_CXXFLAGS_WARN_ON += -Werror -ww177,1224,1478,1881 $$WERROR } } else:gcc:!clang:!intel_icc { # GCC 4.6-4.8 ver = $${QT_GCC_MAJOR_VERSION}.$${QT_GCC_MINOR_VERSION} contains(ver, "4\\.[678]") { - QMAKE_CXXFLAGS += -Werror -Wno-error=cpp -Wno-error=deprecated-declarations $$WERROR + QMAKE_CXXFLAGS_WARN_ON += -Werror -Wno-error=cpp -Wno-error=deprecated-declarations $$WERROR # GCC prints this bogus warning, after it has inlined a lot of code # error: assuming signed overflow does not occur when assuming that (X + c) < X is always false - QMAKE_CXXFLAGS += -Wno-error=strict-overflow + QMAKE_CXXFLAGS_WARN_ON += -Wno-error=strict-overflow # Work-around for bug https://code.google.com/p/android/issues/detail?id=58135 - android: QMAKE_CXXFLAGS += -Wno-error=literal-suffix + android: QMAKE_CXXFLAGS_WARN_ON += -Wno-error=literal-suffix } } unset(ver) diff --git a/mkspecs/features/qt_module.prf b/mkspecs/features/qt_module.prf index c6369732c1..2134077ed3 100644 --- a/mkspecs/features/qt_module.prf +++ b/mkspecs/features/qt_module.prf @@ -134,6 +134,33 @@ aix-g++* { QMAKE_CXXFLAGS += -mminimal-toc } +sse2:!contains(QT_CPU_FEATURES.$$QT_ARCH, sse2):!host_build:!if(static:contains(QT_CONFIG, shared)) { + # If the compiler supports SSE2, enable it unconditionally in all of Qt shared libraries + # (and only the libraries). This is not expected to be a problem because: + # - on Windows, sharing of libraries is uncommon + # - on Mac OS X, all x86 CPUs already have SSE2 support (we won't even reach here) + # - on Linux, the dynamic loader can find the libraries on LIBDIR/sse2/ + # The last guarantee does not apply to executables and plugins, so we can't enable for them. + QT_CPU_FEATURES.$$QT_ARCH += sse sse2 + QMAKE_CFLAGS += $$QMAKE_CFLAGS_SSE2 + QMAKE_CXXFLAGS += $$QMAKE_CFLAGS_SSE2 +} + +clang { + apple_clang_ver = $${QT_APPLE_CLANG_MAJOR_VERSION}.$${QT_APPLE_CLANG_MINOR_VERSION} + reg_clang_ver = $${QT_CLANG_MAJOR_VERSION}.$${QT_CLANG_MINOR_VERSION} + !lessThan(apple_clang_ver, "5.1")|!lessThan(reg_clang_ver, "3.4"): \ + CONFIG += compiler_supports_fpmath +} else: gcc { + CONFIG += compiler_supports_fpmath +} + +equals(QT_ARCH, i386):contains(QT_CPU_FEATURES.$$QT_ARCH, sse2):compiler_supports_fpmath { + # Turn on SSE-based floating-point math + QMAKE_CFLAGS += -mfpmath=sse + QMAKE_CXXFLAGS += -mfpmath=sse +} + android: CONFIG += qt_android_deps #install directives @@ -154,7 +181,7 @@ else: \ lib_replace.CONFIG = path QMAKE_PRL_INSTALL_REPLACE += include_replace lib_replace -unix|win32-g++* { +unix|mingw { CONFIG += create_pc QMAKE_PKGCONFIG_LIBDIR = $$lib_replace.replace QMAKE_PKGCONFIG_INCDIR = $$include_replace.replace @@ -169,7 +196,7 @@ unix { QMAKE_LIBTOOL_INSTALL_REPLACE += include_replace lib_replace } -unix|win32-g++* { +unix|mingw { QMAKE_PKGCONFIG_NAME = $$replace(TARGET, ^Qt, "Qt$$section(VERSION, ., 0, 0) ") QMAKE_PKGCONFIG_FILE = $$replace(TARGET, ^Qt, Qt$$section(VERSION, ., 0, 0)) for(i, MODULE_DEPENDS): \ diff --git a/mkspecs/features/qt_parts.prf b/mkspecs/features/qt_parts.prf index ed028d59d3..fee711aeb8 100644 --- a/mkspecs/features/qt_parts.prf +++ b/mkspecs/features/qt_parts.prf @@ -60,7 +60,7 @@ exists($$_PRO_FILE_PWD_/tests/tests.pro) { sub_tests.CONFIG = no_default_install !contains(QT_BUILD_PARTS, tests) { sub_tests.CONFIG += no_default_target - } else { + } else: !ios { # Make sure these are there in case we need them sub_tools.CONFIG -= no_default_target sub_examples.CONFIG -= no_default_target diff --git a/mkspecs/features/qt_plugin.prf b/mkspecs/features/qt_plugin.prf index c9fe22688b..f710bbff43 100644 --- a/mkspecs/features/qt_plugin.prf +++ b/mkspecs/features/qt_plugin.prf @@ -55,7 +55,7 @@ load(qt_common) wince*:LIBS += $$QMAKE_LIBS_GUI QMAKE_LFLAGS += $$QMAKE_LFLAGS_NOUNDEF -unix|win32-g++* { +unix|mingw { !isEmpty(_QMAKE_SUPER_CACHE_): \ rplbase = $$dirname(_QMAKE_SUPER_CACHE_)/[^/][^/]* else: \ diff --git a/mkspecs/features/simd.prf b/mkspecs/features/simd.prf index ad8c545819..a8ce097b64 100644 --- a/mkspecs/features/simd.prf +++ b/mkspecs/features/simd.prf @@ -289,7 +289,7 @@ QT_CPU_FEATURES = $$eval(QT_CPU_FEATURES.$$QT_ARCH) avx2 { HEADERS += $$AVX2_HEADERS - avx2_compiler.commands = $$QMAKE_CXX -c $(CXXFLAGS) -D_M_AVX2 + avx2_compiler.commands = $$QMAKE_CXX -c $(CXXFLAGS) !contains(QT_CPU_FEATURES, avx):avx2_compiler.commands += $$QMAKE_CFLAGS_AVX2 avx2_compiler.commands += $(INCPATH) ${QMAKE_FILE_IN} -Fo${QMAKE_FILE_OUT} avx2_compiler.dependency_type = TYPE_C diff --git a/mkspecs/features/win32/windows.prf b/mkspecs/features/win32/windows.prf index d0b59e05e0..82e0ebe1b5 100644 --- a/mkspecs/features/win32/windows.prf +++ b/mkspecs/features/win32/windows.prf @@ -1,7 +1,7 @@ CONFIG -= console contains(TEMPLATE, ".*app"){ QMAKE_LFLAGS += $$QMAKE_LFLAGS_WINDOWS $$QMAKE_LFLAGS_EXE - win32-g++:DEFINES += QT_NEEDS_QMAIN + mingw:DEFINES += QT_NEEDS_QMAIN qt:for(entryLib, $$list($$unique(QMAKE_LIBS_QT_ENTRY))) { isEqual(entryLib, -lqtmain): { diff --git a/mkspecs/features/winrt/console.prf b/mkspecs/features/winrt/console.prf new file mode 100644 index 0000000000..c4afe5b96e --- /dev/null +++ b/mkspecs/features/winrt/console.prf @@ -0,0 +1,5 @@ +# This is an empty prf file to overwrite the win32 version. +# On Windows RT all applications need to be windows applications +# and also link to winmain. Inside winmain we create the launch +# arguments and also initialize the UI. + diff --git a/mkspecs/features/winrt/package_manifest.prf b/mkspecs/features/winrt/package_manifest.prf new file mode 100644 index 0000000000..969a6780ce --- /dev/null +++ b/mkspecs/features/winrt/package_manifest.prf @@ -0,0 +1,121 @@ +# This performs basic variable replacement on the contents of the WinRT manifest template, as +# specified by WINRT_MANIFEST. The resulting manifest file is written to the output directory. +# While the most common options are covered by the default template, the developer is expected +# to make an application-level copy of the template in order to customize the manifest further. +# Afterwards, they can override the default template by assigning their template to WINRT_MANIFEST. +# +# All subkeys in WINRT_MANIFEST will be replaced if defined/found, so new variables can be easily +# added. The following keys have default values and are present in the default templates: +# WINRT_MANIFEST: The name of the input manifest file. Defaults to a file defined by the mkspec. +# WINRT_MANIFEST.target: The name of the target (.exe). Defaults to TARGET. +# WINRT_MANIFEST.identity: The unique ID of the app. Defaults to reusing the existing generated manifest's UUID, or generates a new UUID if none is present. +# WINRT_MANIFEST.name: The name of the package as displayed to the user. Defaults to TARGET. +# WINRT_MANIFEST.architecture: The target architecture. Defaults to VCPROJ_ARCH. +# WINRT_MANIFEST.version: The version number of the package. Defaults to "1.0.0.0". +# WINRT_MANIFEST.arguments: Allows arguments to be passed to the executable. +# WINRT_MANIFEST.publisher: Display name of the publisher. Defaults to "Default publisher display name". +# WINRT_MANIFEST.publisher_id: On Windows 8/RT, the publisher's distinguished name (default: CN=MyCN). On Windows Phone, the publisher's UUID (default: invalid UUID string). +# WINRT_MANIFEST.description: Package description. Defaults to "Default package description". +# WINRT_MANIFEST.author: Package author (Windows Phone only). Defaults to "Default package author". +# WINRT_MANIFEST.genre: Package genre (Windows Phone only). Defaults to "apps.normal". +# WINRT_MANIFEST.background: Tile background color. Defaults to "green". +# WINRT_MANIFEST.foreground: Tile foreground (text) color (Windows 8/RT only). Defaults to "light". +# WINRT_MANIFEST.logo_store: Logo image file for Windows Store. Default provided by the mkspec. +# WINRT_MANIFEST.logo_small: Small logo image file. Default provided by the mkspec. +# WINRT_MANIFEST.logo_medium: Medium logo image file. Default provided by the mkspec. +# WINRT_MANIFEST.logo_large: Large logo image file. Default provided by the mkspec. +# WINRT_MANIFEST.splash_screen: Splash screen image file. Default provided by the mkspec. +# WINRT_MANIFEST.iconic_tile_icon: Image file for the "iconic" tile template icon. Default provided by the mkspec. +# WINRT_MANIFEST.iconic_tile_small: Image file for the small "iconic" tile template logo. Default provided by the mkspec. +# WINRT_MANIFEST.capabilities: Specifies capabilities to add to the capability list. +# WINRT_MANIFEST.dependencies: Specifies dependencies required by the package. + +# The manifest is generated for each build pass for normal apps, and only once for vcapps. +# - Normal apps have their package root directory in the same place as the target (one for each build pass). +# - Visual Studio requires a design-mode manifest in the same location as the vcproj. +!isEmpty(WINRT_MANIFEST): \ + if(build_pass:equals(TEMPLATE, "app"))| \ + if(!build_pass:equals(TEMPLATE, "vcapp")) { + + manifest_file.input = $$WINRT_MANIFEST + + load(resolve_target) + BUILD_DIR = $$dirname(QMAKE_RESOLVED_TARGET) + winphone: \ + manifest_file.output = $$BUILD_DIR/WMAppManifest.xml + else: contains(TEMPLATE, "vc.*"): \ + manifest_file.output = $$BUILD_DIR/Package.appxmanifest + else: \ + manifest_file.output = $$BUILD_DIR/AppxManifest.xml + + # Provide the C-runtime dependency + equals(TEMPLATE, "app") { + VCLIBS = Microsoft.VCLibs.$$replace(MSVC_VER, \\., ).00 + CONFIG(debug, debug|release): \ + WINRT_MANIFEST.dependencies += $${VCLIBS}.Debug + else: \ + WINRT_MANIFEST.dependencies += $$VCLIBS + } + + # Provide default values for required variables + isEmpty(WINRT_MANIFEST.target): WINRT_MANIFEST.target = $$TARGET + isEmpty(WINRT_MANIFEST.identity) { + # Reuse the existing UUID if possible + UUID_CACHE = $$OUT_PWD/.qmake.winrt_uuid_$$TARGET + exists($$UUID_CACHE) { + include($$UUID_CACHE) + } else { + WINRT_UUID = "WINRT_MANIFEST.identity = $$system(uuidgen)" + write_file($$UUID_CACHE, WINRT_UUID)|error("Unable to write the UUID cache; aborting.") + eval($$WINRT_UUID) + } + winphone: WINRT_MANIFEST.identity = {$$WINRT_MANIFEST.identity} + } + isEmpty(WINRT_MANIFEST.name): WINRT_MANIFEST.name = $$TARGET + isEmpty(WINRT_MANIFEST.architecture): WINRT_MANIFEST.architecture = $$VCPROJ_ARCH + isEmpty(WINRT_MANIFEST.version): WINRT_MANIFEST.version = 1.0.0.0 + isEmpty(WINRT_MANIFEST.publisher): WINRT_MANIFEST.publisher = Default publisher display name + isEmpty(WINRT_MANIFEST.publisherid) { + winphone: WINRT_MANIFEST.publisherid = {00000000-0000-0000-0000-000000000000} + else: WINRT_MANIFEST.publisherid = CN=$$(USERNAME) + } + isEmpty(WINRT_MANIFEST.description): WINRT_MANIFEST.description = Default package description + isEmpty(WINRT_MANIFEST.author): WINRT_MANIFEST.author = Default package author + isEmpty(WINRT_MANIFEST.genre): WINRT_MANIFEST.genre = apps.normal + isEmpty(WINRT_MANIFEST.background): WINRT_MANIFEST.background = green + isEmpty(WINRT_MANIFEST.foreground): WINRT_MANIFEST.foreground = light + + winphone: INDENT = "$$escape_expand(\\r\\n) " + else: INDENT = "$$escape_expand(\\r\\n) " + # Capabilities are given as a string list and may change with the configuration (network, sensors, etc.) + WINRT_MANIFEST.capabilities = $$unique(WINRT_MANIFEST.capabilities) + for(CAPABILITY, WINRT_MANIFEST.capabilities): \ + MANIFEST_CAPABILITIES += " <Capability Name=\"$$CAPABILITY\" />" + WINRT_MANIFEST.capabilities = $$join(MANIFEST_CAPABILITIES, $$INDENT, $$INDENT, $$INDENT) + # Dependencies are given as a string list. The CRT dependency is added automatically above. + WINRT_MANIFEST.dependencies = $$unique(WINRT_MANIFEST.dependencies) + for(DEPENDENCY, WINRT_MANIFEST.dependencies): \ + MANIFEST_DEPENDENCIES += " <PackageDependency Name=\"$$DEPENDENCY\" />" + WINRT_MANIFEST.dependencies = $$join(MANIFEST_DEPENDENCIES, $$INDENT, $$INDENT, $$INDENT) + + # Provide default icons where needed + isEmpty(WINRT_ASSETS_PATH): WINRT_ASSETS_PATH = $$[QT_HOST_DATA/get]/mkspecs/common/winrt_winphone/assets + TEMPLATE_CONTENTS = $$cat($$WINRT_MANIFEST, lines) + ICONS_FOUND = $$find(TEMPLATE_CONTENTS, \\\$\\\$\\{WINRT_MANIFEST\\.(logo|tile)_) + ICONS_FOUND ~= s/.*\\\$\\\$\\{WINRT_MANIFEST\\.((logo|tile)_[^\}]+)\\}.*/\\1/g + for (ICON_NAME, ICONS_FOUND) { + ICON_FILE = $$eval(WINRT_MANIFEST.$$ICON_NAME) + isEmpty(ICON_FILE) { + icon_$${ICON_NAME}.input = $$WINRT_ASSETS_PATH/$${ICON_NAME}.png + icon_$${ICON_NAME}.output = $$BUILD_DIR/assets/$${ICON_NAME}.png + WINRT_MANIFEST.$${ICON_NAME} = assets/$${ICON_NAME}.png + } else { + icon_$${ICON_NAME}.input = $$ICON_FILE + icon_$${ICON_NAME}.output = $$BUILD_DIR/$$ICON_FILE + } + icon_$${ICON_NAME}.CONFIG = verbatim + QMAKE_SUBSTITUTES += icon_$${ICON_NAME} + } + + QMAKE_SUBSTITUTES += manifest_file +} diff --git a/mkspecs/freebsd-g++/qplatformdefs.h b/mkspecs/freebsd-g++/qplatformdefs.h index 329c46e8d6..358e93aaf9 100644 --- a/mkspecs/freebsd-g++/qplatformdefs.h +++ b/mkspecs/freebsd-g++/qplatformdefs.h @@ -82,7 +82,7 @@ #define QT_OPEN_LARGEFILE 0 -#define QT_SNPRINTF ::snprintf -#define QT_VSNPRINTF ::vsnprintf +#define QT_SNPRINTF ::snprintf +#define QT_VSNPRINTF ::vsnprintf #endif // QPLATFORMDEFS_H diff --git a/mkspecs/hurd-g++/qplatformdefs.h b/mkspecs/hurd-g++/qplatformdefs.h index 8b47450abe..a6642eb83a 100644 --- a/mkspecs/hurd-g++/qplatformdefs.h +++ b/mkspecs/hurd-g++/qplatformdefs.h @@ -85,8 +85,8 @@ #include "../common/posix/qplatformdefs.h" #if defined(_XOPEN_SOURCE) && (_XOPEN_SOURCE >= 500) -#define QT_SNPRINTF ::snprintf -#define QT_VSNPRINTF ::vsnprintf +#define QT_SNPRINTF ::snprintf +#define QT_VSNPRINTF ::vsnprintf #endif #endif // QPLATFORMDEFS_H diff --git a/mkspecs/irix-cc-64/qplatformdefs.h b/mkspecs/irix-cc-64/qplatformdefs.h index 5d8a792950..7338595bc8 100644 --- a/mkspecs/irix-cc-64/qplatformdefs.h +++ b/mkspecs/irix-cc-64/qplatformdefs.h @@ -88,8 +88,8 @@ // Irix 6.5 and better #if defined(_SGIAPI) -#define QT_SNPRINTF ::snprintf -#define QT_VSNPRINTF ::vsnprintf +#define QT_SNPRINTF ::snprintf +#define QT_VSNPRINTF ::vsnprintf #endif #endif // QPLATFORMDEFS_H diff --git a/mkspecs/irix-cc/qplatformdefs.h b/mkspecs/irix-cc/qplatformdefs.h index 5d8a792950..7338595bc8 100644 --- a/mkspecs/irix-cc/qplatformdefs.h +++ b/mkspecs/irix-cc/qplatformdefs.h @@ -88,8 +88,8 @@ // Irix 6.5 and better #if defined(_SGIAPI) -#define QT_SNPRINTF ::snprintf -#define QT_VSNPRINTF ::vsnprintf +#define QT_SNPRINTF ::snprintf +#define QT_VSNPRINTF ::vsnprintf #endif #endif // QPLATFORMDEFS_H diff --git a/mkspecs/irix-g++/qplatformdefs.h b/mkspecs/irix-g++/qplatformdefs.h index 38d107e1e0..90c3349c21 100644 --- a/mkspecs/irix-g++/qplatformdefs.h +++ b/mkspecs/irix-g++/qplatformdefs.h @@ -95,8 +95,8 @@ // Irix 6.5 and better #if defined(_SGIAPI) -#define QT_SNPRINTF ::snprintf -#define QT_VSNPRINTF ::vsnprintf +#define QT_SNPRINTF ::snprintf +#define QT_VSNPRINTF ::vsnprintf #endif #endif // QPLATFORMDEFS_H diff --git a/mkspecs/linux-clang/qplatformdefs.h b/mkspecs/linux-clang/qplatformdefs.h index bdf4d5056d..7366ca9bfa 100644 --- a/mkspecs/linux-clang/qplatformdefs.h +++ b/mkspecs/linux-clang/qplatformdefs.h @@ -87,14 +87,14 @@ #undef QT_SOCKLEN_T #if defined(__GLIBC__) && (__GLIBC__ >= 2) -#define QT_SOCKLEN_T socklen_t +#define QT_SOCKLEN_T socklen_t #else -#define QT_SOCKLEN_T int +#define QT_SOCKLEN_T int #endif #if defined(_XOPEN_SOURCE) && (_XOPEN_SOURCE >= 500) -#define QT_SNPRINTF ::snprintf -#define QT_VSNPRINTF ::vsnprintf +#define QT_SNPRINTF ::snprintf +#define QT_VSNPRINTF ::vsnprintf #endif #endif // QPLATFORMDEFS_H diff --git a/mkspecs/linux-cxx/qplatformdefs.h b/mkspecs/linux-cxx/qplatformdefs.h index a948d169f0..ed36408e2e 100644 --- a/mkspecs/linux-cxx/qplatformdefs.h +++ b/mkspecs/linux-cxx/qplatformdefs.h @@ -94,8 +94,8 @@ #endif #if defined(_XOPEN_SOURCE) && (_XOPEN_SOURCE >= 500) -#define QT_SNPRINTF ::snprintf -#define QT_VSNPRINTF ::vsnprintf +#define QT_SNPRINTF ::snprintf +#define QT_VSNPRINTF ::vsnprintf #endif #endif // QPLATFORMDEFS_H diff --git a/mkspecs/linux-g++/qplatformdefs.h b/mkspecs/linux-g++/qplatformdefs.h index 82d0e1663c..0e3e6077e3 100644 --- a/mkspecs/linux-g++/qplatformdefs.h +++ b/mkspecs/linux-g++/qplatformdefs.h @@ -93,8 +93,8 @@ #endif #if defined(_XOPEN_SOURCE) && (_XOPEN_SOURCE >= 500) -#define QT_SNPRINTF ::snprintf -#define QT_VSNPRINTF ::vsnprintf +#define QT_SNPRINTF ::snprintf +#define QT_VSNPRINTF ::vsnprintf #endif #endif // QPLATFORMDEFS_H diff --git a/mkspecs/linux-icc/qmake.conf b/mkspecs/linux-icc/qmake.conf index ee5f1f0ea4..d0ca604f07 100644 --- a/mkspecs/linux-icc/qmake.conf +++ b/mkspecs/linux-icc/qmake.conf @@ -22,6 +22,7 @@ QMAKE_CFLAGS_DEBUG = -O0 -g QMAKE_CFLAGS_SHLIB = -fPIC -fno-jump-tables QMAKE_CFLAGS_STATIC_LIB = $$QMAKE_CFLAGS_SHLIB QMAKE_CFLAGS_YACC = +QMAKE_CFLAGS_ISYSTEM = -isystem QMAKE_CFLAGS_THREAD = -D_REENTRANT QMAKE_CFLAGS_SSE2 += -xSSE2 diff --git a/mkspecs/linux-kcc/qplatformdefs.h b/mkspecs/linux-kcc/qplatformdefs.h index a491e7ed6c..dbad004602 100644 --- a/mkspecs/linux-kcc/qplatformdefs.h +++ b/mkspecs/linux-kcc/qplatformdefs.h @@ -97,8 +97,8 @@ #endif #if defined(_XOPEN_SOURCE) && (_XOPEN_SOURCE >= 500) -#define QT_SNPRINTF ::snprintf -#define QT_VSNPRINTF ::vsnprintf +#define QT_SNPRINTF ::snprintf +#define QT_VSNPRINTF ::vsnprintf #endif #endif // QPLATFORMDEFS_H diff --git a/mkspecs/linux-llvm/qplatformdefs.h b/mkspecs/linux-llvm/qplatformdefs.h index cbbe04e80c..6dae1a8ae5 100644 --- a/mkspecs/linux-llvm/qplatformdefs.h +++ b/mkspecs/linux-llvm/qplatformdefs.h @@ -94,8 +94,8 @@ #endif #if defined(_XOPEN_SOURCE) && (_XOPEN_SOURCE >= 500) -#define QT_SNPRINTF ::snprintf -#define QT_VSNPRINTF ::vsnprintf +#define QT_SNPRINTF ::snprintf +#define QT_VSNPRINTF ::vsnprintf #endif #endif // QPLATFORMDEFS_H diff --git a/mkspecs/linux-lsb-g++/qplatformdefs.h b/mkspecs/linux-lsb-g++/qplatformdefs.h index 5060e1a222..a4855bcde5 100644 --- a/mkspecs/linux-lsb-g++/qplatformdefs.h +++ b/mkspecs/linux-lsb-g++/qplatformdefs.h @@ -105,8 +105,8 @@ #endif #if defined(_XOPEN_SOURCE) && (_XOPEN_SOURCE >= 500) -#define QT_SNPRINTF ::snprintf -#define QT_VSNPRINTF ::vsnprintf +#define QT_SNPRINTF ::snprintf +#define QT_VSNPRINTF ::vsnprintf #endif #endif // QPLATFORMDEFS_H diff --git a/mkspecs/linux-pgcc/qplatformdefs.h b/mkspecs/linux-pgcc/qplatformdefs.h index a948d169f0..ed36408e2e 100644 --- a/mkspecs/linux-pgcc/qplatformdefs.h +++ b/mkspecs/linux-pgcc/qplatformdefs.h @@ -94,8 +94,8 @@ #endif #if defined(_XOPEN_SOURCE) && (_XOPEN_SOURCE >= 500) -#define QT_SNPRINTF ::snprintf -#define QT_VSNPRINTF ::vsnprintf +#define QT_SNPRINTF ::snprintf +#define QT_VSNPRINTF ::vsnprintf #endif #endif // QPLATFORMDEFS_H diff --git a/mkspecs/lynxos-g++/qplatformdefs.h b/mkspecs/lynxos-g++/qplatformdefs.h index 469d032299..314c61443f 100644 --- a/mkspecs/lynxos-g++/qplatformdefs.h +++ b/mkspecs/lynxos-g++/qplatformdefs.h @@ -86,8 +86,8 @@ #endif #if defined(_XOPEN_SOURCE) && (_XOPEN_SOURCE >= 500) -#define QT_SNPRINTF ::snprintf -#define QT_VSNPRINTF ::vsnprintf +#define QT_SNPRINTF ::snprintf +#define QT_VSNPRINTF ::vsnprintf #endif #endif // QPLATFORMDEFS_H diff --git a/mkspecs/macx-ios-clang/features/default_post.prf b/mkspecs/macx-ios-clang/features/default_post.prf index 3428823624..28ad095da7 100644 --- a/mkspecs/macx-ios-clang/features/default_post.prf +++ b/mkspecs/macx-ios-clang/features/default_post.prf @@ -7,6 +7,9 @@ contains(QMAKE_MAC_SDK, ^iphonesimulator.*) { CONFIG += iphonesimulator } +iphonesimulator_and_iphoneos:iphonesimulator: \ + QMAKE_MAC_SDK ~= s,^iphoneos,iphonesimulator, + # Resolve config so we don't need to use CONFIG() later on CONFIG(iphonesimulator, iphonesimulator|iphoneos) { CONFIG -= iphoneos @@ -118,15 +121,6 @@ equals(TEMPLATE, app) { iphonesimulator.name = Simulator iphoneos.name = Device addExclusiveBuilds(iphonesimulator, iphoneos) - - iphonesimulator_and_iphoneos:iphonesimulator { - QT_ARCH = i386 - QMAKE_MAC_SDK ~= s,^iphoneos,iphonesimulator, - - # Since the CPU feature detection done by configure is limited to one - # target at the moment, we disable SIMD support for simulator. - CONFIG -= simd - } } else: equals(TEMPLATE, subdirs) { # Prevent recursion into host_builds for(subdir, SUBDIRS) { @@ -184,15 +178,6 @@ macx-xcode { launch_images.files = $$copy_image.output QMAKE_BUNDLE_DATA += launch_images - !c++11 { - # Explicitly use libstdc++ if C++11 support is not enabled, - # as otherwise Xcode will choose the compiler default based - # on the deployment target, which for iOS 7 is libc++. This - # breaks compilation since Qt was built against libstdc++. - QMAKE_CXXFLAGS += -stdlib=libstdc++ - QMAKE_LFLAGS += -stdlib=libstdc++ - } - # Make the default debug information format for debug builds # DWARF instead of DWARF with dSYM. This cuts down build times # for application debug builds significantly, as Xcode doesn't diff --git a/mkspecs/macx-ios-clang/features/default_pre.prf b/mkspecs/macx-ios-clang/features/default_pre.prf index 3501f5eae0..7b8f9c9b5d 100644 --- a/mkspecs/macx-ios-clang/features/default_pre.prf +++ b/mkspecs/macx-ios-clang/features/default_pre.prf @@ -8,3 +8,12 @@ load(default_pre) # Check for supported Xcode versions lessThan(QMAKE_XCODE_VERSION, "4.3"): \ error("This mkspec requires Xcode 4.3 or later") + +iphonesimulator_and_iphoneos:iphonesimulator { + # For a iphonesimulator_and_iphoneos build all the config tests + # are based on the iPhoneOS ARM SDK, but we know that the simulator + # is i386 and that we support SSE/SSE2. + QT_ARCH = i386 + QT_CPU_FEATURES.i386 = sse sse2 + DEFINES += QT_COMPILER_SUPPORTS_SSE2 +} diff --git a/mkspecs/macx-ios-clang/features/qt_parts.prf b/mkspecs/macx-ios-clang/features/qt_parts.prf new file mode 100644 index 0000000000..81814a62b0 --- /dev/null +++ b/mkspecs/macx-ios-clang/features/qt_parts.prf @@ -0,0 +1,5 @@ + +# Disable tests for anything but qtbase for now +!equals(TARGET, qtbase): QT_BUILD_PARTS -= tests + +load(qt_parts) diff --git a/mkspecs/netbsd-g++/qplatformdefs.h b/mkspecs/netbsd-g++/qplatformdefs.h index af7d0acf24..5388141931 100644 --- a/mkspecs/netbsd-g++/qplatformdefs.h +++ b/mkspecs/netbsd-g++/qplatformdefs.h @@ -84,8 +84,8 @@ // NetBSD 1.0 - 1.3.3 int // NetBSD 1.4 - 1.5 socklen_t -#define QT_SNPRINTF ::snprintf -#define QT_VSNPRINTF ::vsnprintf +#define QT_SNPRINTF ::snprintf +#define QT_VSNPRINTF ::vsnprintf // Older NetBSD versions may still use the a.out format instead of ELF. #ifndef __ELF__ diff --git a/mkspecs/openbsd-g++/qplatformdefs.h b/mkspecs/openbsd-g++/qplatformdefs.h index 9901bc632f..51844ee657 100644 --- a/mkspecs/openbsd-g++/qplatformdefs.h +++ b/mkspecs/openbsd-g++/qplatformdefs.h @@ -85,8 +85,8 @@ // OpenBSD 2.2 - 2.4 int // OpenBSD 2.5 - 2.8 socklen_t -#define QT_SNPRINTF ::snprintf -#define QT_VSNPRINTF ::vsnprintf +#define QT_SNPRINTF ::snprintf +#define QT_VSNPRINTF ::vsnprintf // 1003.1c-1995 says on page 38 (2.9.3, paragraph 3) that if _POSIX_THREADS // is defined, then _POSIX_THREAD_SAFE_FUNCTIONS must also be defined. diff --git a/mkspecs/qnx-armv7le-qcc/qplatformdefs.h b/mkspecs/qnx-armv7le-qcc/qplatformdefs.h index 2fac2ae3d2..b47aecde0d 100644 --- a/mkspecs/qnx-armv7le-qcc/qplatformdefs.h +++ b/mkspecs/qnx-armv7le-qcc/qplatformdefs.h @@ -83,8 +83,15 @@ #include <arpa/inet.h> #define QT_USE_XOPEN_LFS_EXTENSIONS +#if !defined(__EXT_QNX__READDIR64_R) #define QT_NO_READDIR64 +#endif #include "../common/posix/qplatformdefs.h" +#if defined(__EXT_QNX__READDIR64_R) +#define QT_EXT_QNX_READDIR_R ::_readdir64_r +#elif defined(__EXT_QNX__READDIR_R) +#define QT_EXT_QNX_READDIR_R ::_readdir_r +#endif #define QT_SNPRINTF ::snprintf #define QT_VSNPRINTF ::vsnprintf diff --git a/mkspecs/qnx-x86-qcc/qplatformdefs.h b/mkspecs/qnx-x86-qcc/qplatformdefs.h index 2fac2ae3d2..b47aecde0d 100644 --- a/mkspecs/qnx-x86-qcc/qplatformdefs.h +++ b/mkspecs/qnx-x86-qcc/qplatformdefs.h @@ -83,8 +83,15 @@ #include <arpa/inet.h> #define QT_USE_XOPEN_LFS_EXTENSIONS +#if !defined(__EXT_QNX__READDIR64_R) #define QT_NO_READDIR64 +#endif #include "../common/posix/qplatformdefs.h" +#if defined(__EXT_QNX__READDIR64_R) +#define QT_EXT_QNX_READDIR_R ::_readdir64_r +#elif defined(__EXT_QNX__READDIR_R) +#define QT_EXT_QNX_READDIR_R ::_readdir_r +#endif #define QT_SNPRINTF ::snprintf #define QT_VSNPRINTF ::vsnprintf diff --git a/mkspecs/sco-cc/qplatformdefs.h b/mkspecs/sco-cc/qplatformdefs.h index a880f4579b..5d039f6b3b 100644 --- a/mkspecs/sco-cc/qplatformdefs.h +++ b/mkspecs/sco-cc/qplatformdefs.h @@ -81,7 +81,7 @@ #undef QT_SOCKLEN_T #define QT_SOCKLEN_T size_t -#define QT_SNPRINTF ::snprintf -#define QT_VSNPRINTF ::vsnprintf +#define QT_SNPRINTF ::snprintf +#define QT_VSNPRINTF ::vsnprintf #endif // QPLATFORMDEFS_H diff --git a/mkspecs/sco-g++/qplatformdefs.h b/mkspecs/sco-g++/qplatformdefs.h index f0e5eb8293..cff39e6d1a 100644 --- a/mkspecs/sco-g++/qplatformdefs.h +++ b/mkspecs/sco-g++/qplatformdefs.h @@ -85,7 +85,7 @@ #undef QT_SOCKLEN_T #define QT_SOCKLEN_T int -#define QT_SNPRINTF ::snprintf -#define QT_VSNPRINTF ::vsnprintf +#define QT_SNPRINTF ::snprintf +#define QT_VSNPRINTF ::vsnprintf #endif // QPLATFORMDEFS_H diff --git a/mkspecs/solaris-cc-64/qplatformdefs.h b/mkspecs/solaris-cc-64/qplatformdefs.h index acdc14c81b..a0560c0157 100644 --- a/mkspecs/solaris-cc-64/qplatformdefs.h +++ b/mkspecs/solaris-cc-64/qplatformdefs.h @@ -87,8 +87,8 @@ static inline int qt_socket_connect(int s, struct sockaddr *addr, QT_SOCKLEN_T a { return ::connect(s, addr, addrlen); } // Only Solaris 7 and better support 64-bit -#define QT_SNPRINTF ::snprintf -#define QT_VSNPRINTF ::vsnprintf +#define QT_SNPRINTF ::snprintf +#define QT_VSNPRINTF ::vsnprintf #ifdef connect #undef connect diff --git a/mkspecs/solaris-cc/qplatformdefs.h b/mkspecs/solaris-cc/qplatformdefs.h index f905ad55c3..0b72174c6f 100644 --- a/mkspecs/solaris-cc/qplatformdefs.h +++ b/mkspecs/solaris-cc/qplatformdefs.h @@ -113,8 +113,8 @@ extern "C" int gethostname(char *, int); #if defined(_XOPEN_UNIX) // Solaris 2.6 and better -#define QT_SNPRINTF ::snprintf -#define QT_VSNPRINTF ::vsnprintf +#define QT_SNPRINTF ::snprintf +#define QT_VSNPRINTF ::vsnprintf #endif #ifdef connect diff --git a/mkspecs/solaris-g++-64/qplatformdefs.h b/mkspecs/solaris-g++-64/qplatformdefs.h index 4d408bf89e..11f25a5fc7 100644 --- a/mkspecs/solaris-g++-64/qplatformdefs.h +++ b/mkspecs/solaris-g++-64/qplatformdefs.h @@ -100,7 +100,7 @@ static inline int qt_socket_bind(int s, struct sockaddr *addr, QT_SOCKLEN_T addr #endif // Only Solaris 7 and better support 64-bit -#define QT_SNPRINTF ::snprintf -#define QT_VSNPRINTF ::vsnprintf +#define QT_SNPRINTF ::snprintf +#define QT_VSNPRINTF ::vsnprintf #endif // QPLATFORMDEFS_H diff --git a/mkspecs/solaris-g++/qplatformdefs.h b/mkspecs/solaris-g++/qplatformdefs.h index 44ab7bbb53..a1cd5797fa 100644 --- a/mkspecs/solaris-g++/qplatformdefs.h +++ b/mkspecs/solaris-g++/qplatformdefs.h @@ -128,8 +128,8 @@ extern "C" int gethostname(char *, int); #if defined(_XOPEN_UNIX) // Solaris 2.6 and better -#define QT_SNPRINTF ::snprintf -#define QT_VSNPRINTF ::vsnprintf +#define QT_SNPRINTF ::snprintf +#define QT_VSNPRINTF ::vsnprintf #endif #endif // QPLATFORMDEFS_H diff --git a/mkspecs/tru64-cxx/qplatformdefs.h b/mkspecs/tru64-cxx/qplatformdefs.h index 0ff0aa83e7..71e9bb4ace 100644 --- a/mkspecs/tru64-cxx/qplatformdefs.h +++ b/mkspecs/tru64-cxx/qplatformdefs.h @@ -102,8 +102,8 @@ extern "C" int usleep(useconds_t); #if defined(_XOPEN_SOURCE) && (_XOPEN_SOURCE-0 >= 400) // Tru64 5.0 and better -#define QT_SNPRINTF ::snprintf -#define QT_VSNPRINTF ::vsnprintf +#define QT_SNPRINTF ::snprintf +#define QT_VSNPRINTF ::vsnprintf #endif #endif // QPLATFORMDEFS_H diff --git a/mkspecs/tru64-g++/qplatformdefs.h b/mkspecs/tru64-g++/qplatformdefs.h index 0ff0aa83e7..71e9bb4ace 100644 --- a/mkspecs/tru64-g++/qplatformdefs.h +++ b/mkspecs/tru64-g++/qplatformdefs.h @@ -102,8 +102,8 @@ extern "C" int usleep(useconds_t); #if defined(_XOPEN_SOURCE) && (_XOPEN_SOURCE-0 >= 400) // Tru64 5.0 and better -#define QT_SNPRINTF ::snprintf -#define QT_VSNPRINTF ::vsnprintf +#define QT_SNPRINTF ::snprintf +#define QT_VSNPRINTF ::vsnprintf #endif #endif // QPLATFORMDEFS_H diff --git a/mkspecs/unixware-cc/qplatformdefs.h b/mkspecs/unixware-cc/qplatformdefs.h index 795e7cc98e..73e25a3b79 100644 --- a/mkspecs/unixware-cc/qplatformdefs.h +++ b/mkspecs/unixware-cc/qplatformdefs.h @@ -85,7 +85,7 @@ #define QT_OFF_T off_t #define QT_SOCKLEN_T size_t -#define QT_SNPRINTF ::snprintf -#define QT_VSNPRINTF ::vsnprintf +#define QT_SNPRINTF ::snprintf +#define QT_VSNPRINTF ::vsnprintf #endif // QPLATFORMDEFS_H diff --git a/mkspecs/unixware-g++/qplatformdefs.h b/mkspecs/unixware-g++/qplatformdefs.h index 795e7cc98e..73e25a3b79 100644 --- a/mkspecs/unixware-g++/qplatformdefs.h +++ b/mkspecs/unixware-g++/qplatformdefs.h @@ -85,7 +85,7 @@ #define QT_OFF_T off_t #define QT_SOCKLEN_T size_t -#define QT_SNPRINTF ::snprintf -#define QT_VSNPRINTF ::vsnprintf +#define QT_SNPRINTF ::snprintf +#define QT_VSNPRINTF ::vsnprintf #endif // QPLATFORMDEFS_H diff --git a/mkspecs/unsupported/freebsd-clang/qmake.conf b/mkspecs/unsupported/freebsd-clang/qmake.conf new file mode 100644 index 0000000000..0769983097 --- /dev/null +++ b/mkspecs/unsupported/freebsd-clang/qmake.conf @@ -0,0 +1,38 @@ +# +# qmake configuration for freebsd-clang +# + +MAKEFILE_GENERATOR = UNIX +QMAKE_PLATFORM = freebsd bsd +CONFIG += gdb_dwarf_index + +QMAKE_CFLAGS_THREAD = -pthread -D_THREAD_SAFE + +QMAKE_CXXFLAGS_THREAD = $$QMAKE_CFLAGS_THREAD + +# Addon software goes into /usr/local on the BSDs, by default we will look there +QMAKE_INCDIR = /usr/local/include +QMAKE_LIBDIR = /usr/local/lib +QMAKE_INCDIR_X11 = /usr/X11R6/include +QMAKE_LIBDIR_X11 = /usr/X11R6/lib +QMAKE_INCDIR_OPENGL = /usr/X11R6/include +QMAKE_LIBDIR_OPENGL = /usr/X11R6/lib + +QMAKE_LFLAGS_THREAD = -pthread + +QMAKE_LIBS = +QMAKE_LIBS_DYNLOAD = +QMAKE_LIBS_X11 = -lXext -lX11 -lm +QMAKE_LIBS_OPENGL = -lGL +QMAKE_LIBS_THREAD = + +QMAKE_AR = ar cqs +QMAKE_OBJCOPY = objcopy +QMAKE_NM = nm -P +QMAKE_RANLIB = + +include(../../common/unix.conf) +include(../../common/gcc-base-unix.conf) +include(../../common/g++-unix.conf) +include(../../common/clang.conf) +load(qt_config) diff --git a/mkspecs/unsupported/freebsd-clang/qplatformdefs.h b/mkspecs/unsupported/freebsd-clang/qplatformdefs.h new file mode 100644 index 0000000000..4743a28b99 --- /dev/null +++ b/mkspecs/unsupported/freebsd-clang/qplatformdefs.h @@ -0,0 +1,42 @@ +/**************************************************************************** +** +** Copyright (C) 2014 Digia Plc and/or its subsidiary(-ies). +** Contact: http://www.qt-project.org/legal +** +** This file is part of the qmake spec of the Qt Toolkit. +** +** $QT_BEGIN_LICENSE:LGPL$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and Digia. For licensing terms and +** conditions see http://qt.digia.com/licensing. For further information +** use the contact form at http://qt.digia.com/contact-us. +** +** GNU Lesser General Public License Usage +** Alternatively, 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, Digia gives you certain additional +** rights. These rights are described in the Digia 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. +** +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +#include "../../freebsd-g++/qplatformdefs.h" diff --git a/mkspecs/unsupported/integrity-ghs/qplatformdefs.h b/mkspecs/unsupported/integrity-ghs/qplatformdefs.h index 75b2c59972..ab0c134138 100644 --- a/mkspecs/unsupported/integrity-ghs/qplatformdefs.h +++ b/mkspecs/unsupported/integrity-ghs/qplatformdefs.h @@ -110,37 +110,37 @@ #define QT_OFF_T long #endif -#define QT_STAT_REG S_IFREG -#define QT_STAT_DIR S_IFDIR -#define QT_STAT_MASK S_IFMT -#define QT_STAT_LNK S_IFLNK -#define QT_SOCKET_CONNECT ::connect -#define QT_SOCKET_BIND ::bind -#define QT_FILENO fileno +#define QT_STAT_REG S_IFREG +#define QT_STAT_DIR S_IFDIR +#define QT_STAT_MASK S_IFMT +#define QT_STAT_LNK S_IFLNK +#define QT_SOCKET_CONNECT ::connect +#define QT_SOCKET_BIND ::bind +#define QT_FILENO fileno #ifndef QT_CLOSE -#define QT_CLOSE ::close +#define QT_CLOSE ::close #endif #ifndef QT_READ -#define QT_READ ::read +#define QT_READ ::read #endif #ifndef QT_WRITE -#define QT_WRITE ::write +#define QT_WRITE ::write #endif -#define QT_ACCESS ::access -#define QT_GETCWD ::getcwd -#define QT_CHDIR ::chdir -#define QT_MKDIR ::mkdir -#define QT_RMDIR ::rmdir -#define QT_OPEN_RDONLY O_RDONLY -#define QT_OPEN_WRONLY O_WRONLY -#define QT_OPEN_RDWR O_RDWR -#define QT_OPEN_CREAT O_CREAT -#define QT_OPEN_TRUNC O_TRUNC -#define QT_OPEN_APPEND O_APPEND - -#define QT_SIGNAL_RETTYPE void -#define QT_SIGNAL_ARGS int -#define QT_SIGNAL_IGNORE SIG_IGN +#define QT_ACCESS ::access +#define QT_GETCWD ::getcwd +#define QT_CHDIR ::chdir +#define QT_MKDIR ::mkdir +#define QT_RMDIR ::rmdir +#define QT_OPEN_RDONLY O_RDONLY +#define QT_OPEN_WRONLY O_WRONLY +#define QT_OPEN_RDWR O_RDWR +#define QT_OPEN_CREAT O_CREAT +#define QT_OPEN_TRUNC O_TRUNC +#define QT_OPEN_APPEND O_APPEND + +#define QT_SIGNAL_RETTYPE void +#define QT_SIGNAL_ARGS int +#define QT_SIGNAL_IGNORE SIG_IGN #define QT_MMAP ::mmap @@ -166,8 +166,8 @@ #define QT_SOCKLEN_T socklen_t #if defined(_XOPEN_SOURCE) && (_XOPEN_SOURCE >= 500) -#define QT_SNPRINTF ::snprintf -#define QT_VSNPRINTF ::vsnprintf +#define QT_SNPRINTF ::snprintf +#define QT_VSNPRINTF ::vsnprintf #endif // INTEGRITY doesn't enable the declaration in _POSIX_SOURCE mode, diff --git a/mkspecs/unsupported/linux-armcc/qplatformdefs.h b/mkspecs/unsupported/linux-armcc/qplatformdefs.h index 2f023824ec..c1066ee9a2 100644 --- a/mkspecs/unsupported/linux-armcc/qplatformdefs.h +++ b/mkspecs/unsupported/linux-armcc/qplatformdefs.h @@ -93,8 +93,8 @@ #endif #if defined(_XOPEN_SOURCE) && (_XOPEN_SOURCE >= 500) -#define QT_SNPRINTF ::snprintf -#define QT_VSNPRINTF ::vsnprintf +#define QT_SNPRINTF ::snprintf +#define QT_VSNPRINTF ::vsnprintf #endif #endif // QPLATFORMDEFS_H diff --git a/mkspecs/unsupported/linux-libc++-clang/qmake.conf b/mkspecs/unsupported/linux-libc++-clang/qmake.conf new file mode 100644 index 0000000000..bf0abb2a54 --- /dev/null +++ b/mkspecs/unsupported/linux-libc++-clang/qmake.conf @@ -0,0 +1,20 @@ +# +# qmake configuration for linux-clang +# + +MAKEFILE_GENERATOR = UNIX +CONFIG += incremental + +QMAKE_INCREMENTAL_STYLE = sublib + +include(../../common/linux.conf) +include(../../common/gcc-base-unix.conf) +include(../../common/clang.conf) + +QMAKE_CFLAGS_RELEASE = -Os +QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE + +QMAKE_CXXFLAGS_CXX11 += -std=c++11 -stdlib=libc++ +QMAKE_LFLAGS_CXX11 += -stdlib=libc++ -lc++abi + +load(qt_config) diff --git a/mkspecs/unsupported/linux-libc++-clang/qplatformdefs.h b/mkspecs/unsupported/linux-libc++-clang/qplatformdefs.h new file mode 100644 index 0000000000..c1066ee9a2 --- /dev/null +++ b/mkspecs/unsupported/linux-libc++-clang/qplatformdefs.h @@ -0,0 +1,100 @@ +/**************************************************************************** +** +** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies). +** Contact: http://www.qt-project.org/legal +** +** This file is part of the qmake spec of the Qt Toolkit. +** +** $QT_BEGIN_LICENSE:LGPL$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and Digia. For licensing terms and +** conditions see http://qt.digia.com/licensing. For further information +** use the contact form at http://qt.digia.com/contact-us. +** +** GNU Lesser General Public License Usage +** Alternatively, 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, Digia gives you certain additional +** rights. These rights are described in the Digia 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. +** +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +#ifndef QPLATFORMDEFS_H +#define QPLATFORMDEFS_H + +// Get Qt defines/settings + +#include "qglobal.h" + +// Set any POSIX/XOPEN defines at the top of this file to turn on specific APIs + +// 1) need to reset default environment if _BSD_SOURCE is defined +// 2) need to specify POSIX thread interfaces explicitly in glibc 2.0 +// 3) it seems older glibc need this to include the X/Open stuff +#ifndef _GNU_SOURCE +# define _GNU_SOURCE +#endif + +#include <unistd.h> + + +// We are hot - unistd.h should have turned on the specific APIs we requested + +#include <features.h> +#include <pthread.h> +#include <dirent.h> +#include <fcntl.h> +#include <grp.h> +#include <pwd.h> +#include <signal.h> + +#include <sys/types.h> +#include <sys/ioctl.h> +#include <sys/ipc.h> +#include <sys/time.h> +#include <sys/shm.h> +#include <sys/socket.h> +#include <sys/stat.h> +#include <sys/wait.h> +#include <netinet/in.h> +#ifndef QT_NO_IPV6IFNAME +#include <net/if.h> +#endif + +#define QT_USE_XOPEN_LFS_EXTENSIONS +#include "../../common/posix/qplatformdefs.h" + +#undef QT_SOCKLEN_T + +#if defined(__GLIBC__) && (__GLIBC__ >= 2) +#define QT_SOCKLEN_T socklen_t +#else +#define QT_SOCKLEN_T int +#endif + +#if defined(_XOPEN_SOURCE) && (_XOPEN_SOURCE >= 500) +#define QT_SNPRINTF ::snprintf +#define QT_VSNPRINTF ::vsnprintf +#endif + +#endif // QPLATFORMDEFS_H diff --git a/mkspecs/unsupported/qnx-X11-g++/qplatformdefs.h b/mkspecs/unsupported/qnx-X11-g++/qplatformdefs.h index b75598f12f..9e902ebfcd 100644 --- a/mkspecs/unsupported/qnx-X11-g++/qplatformdefs.h +++ b/mkspecs/unsupported/qnx-X11-g++/qplatformdefs.h @@ -84,8 +84,8 @@ #define QT_USE_XOPEN_LFS_EXTENSIONS #include "../../common/posix/qplatformdefs.h" -#define QT_SNPRINTF ::snprintf -#define QT_VSNPRINTF ::vsnprintf +#define QT_SNPRINTF ::snprintf +#define QT_VSNPRINTF ::vsnprintf // QNX6 doesn't have getpagesize() inline int getpagesize() diff --git a/mkspecs/unsupported/win32-msvc2003/qplatformdefs.h b/mkspecs/unsupported/win32-msvc2003/qplatformdefs.h index da924e4631..21f9399f33 100644 --- a/mkspecs/unsupported/win32-msvc2003/qplatformdefs.h +++ b/mkspecs/unsupported/win32-msvc2003/qplatformdefs.h @@ -68,49 +68,49 @@ #define Q_FS_FAT #ifdef QT_LARGEFILE_SUPPORT -#define QT_STATBUF struct _stati64 // non-ANSI defs -#define QT_STATBUF4TSTAT struct _stati64 // non-ANSI defs -#define QT_STAT ::_stati64 -#define QT_FSTAT ::_fstati64 +#define QT_STATBUF struct _stati64 // non-ANSI defs +#define QT_STATBUF4TSTAT struct _stati64 // non-ANSI defs +#define QT_STAT ::_stati64 +#define QT_FSTAT ::_fstati64 #else -#define QT_STATBUF struct _stat // non-ANSI defs -#define QT_STATBUF4TSTAT struct _stat // non-ANSI defs -#define QT_STAT ::_stat -#define QT_FSTAT ::_fstat +#define QT_STATBUF struct _stat // non-ANSI defs +#define QT_STATBUF4TSTAT struct _stat // non-ANSI defs +#define QT_STAT ::_stat +#define QT_FSTAT ::_fstat #endif -#define QT_STAT_REG _S_IFREG -#define QT_STAT_DIR _S_IFDIR -#define QT_STAT_MASK _S_IFMT +#define QT_STAT_REG _S_IFREG +#define QT_STAT_DIR _S_IFDIR +#define QT_STAT_MASK _S_IFMT #if defined(_S_IFLNK) -# define QT_STAT_LNK _S_IFLNK +# define QT_STAT_LNK _S_IFLNK #endif -#define QT_FILENO _fileno -#define QT_OPEN ::_open -#define QT_CLOSE ::_close +#define QT_FILENO _fileno +#define QT_OPEN ::_open +#define QT_CLOSE ::_close #ifdef QT_LARGEFILE_SUPPORT -#define QT_LSEEK ::_lseeki64 -#define QT_TSTAT ::_tstati64 +#define QT_LSEEK ::_lseeki64 +#define QT_TSTAT ::_tstati64 #else -#define QT_LSEEK ::_lseek -#define QT_TSTAT ::_tstat +#define QT_LSEEK ::_lseek +#define QT_TSTAT ::_tstat #endif -#define QT_READ ::_read -#define QT_WRITE ::_write -#define QT_ACCESS ::_access -#define QT_GETCWD ::_getcwd -#define QT_CHDIR ::_chdir -#define QT_MKDIR ::_mkdir -#define QT_RMDIR ::_rmdir +#define QT_READ ::_read +#define QT_WRITE ::_write +#define QT_ACCESS ::_access +#define QT_GETCWD ::_getcwd +#define QT_CHDIR ::_chdir +#define QT_MKDIR ::_mkdir +#define QT_RMDIR ::_rmdir #define QT_OPEN_LARGEFILE 0 -#define QT_OPEN_RDONLY _O_RDONLY -#define QT_OPEN_WRONLY _O_WRONLY -#define QT_OPEN_RDWR _O_RDWR -#define QT_OPEN_CREAT _O_CREAT -#define QT_OPEN_TRUNC _O_TRUNC -#define QT_OPEN_APPEND _O_APPEND +#define QT_OPEN_RDONLY _O_RDONLY +#define QT_OPEN_WRONLY _O_WRONLY +#define QT_OPEN_RDWR _O_RDWR +#define QT_OPEN_CREAT _O_CREAT +#define QT_OPEN_TRUNC _O_TRUNC +#define QT_OPEN_APPEND _O_APPEND #if defined(O_TEXT) -# define QT_OPEN_TEXT _O_TEXT -# define QT_OPEN_BINARY _O_BINARY +# define QT_OPEN_TEXT _O_TEXT +# define QT_OPEN_BINARY _O_BINARY #endif #include "../../common/c89/qplatformdefs.h" @@ -125,15 +125,15 @@ #define QT_OFF_T __int64 #endif -#define QT_SIGNAL_ARGS int +#define QT_SIGNAL_ARGS int #define QT_VSNPRINTF ::_vsnprintf -#define QT_SNPRINTF ::_snprintf +#define QT_SNPRINTF ::_snprintf -# define F_OK 0 -# define X_OK 1 -# define W_OK 2 -# define R_OK 4 +# define F_OK 0 +# define X_OK 1 +# define W_OK 2 +# define R_OK 4 typedef int mode_t; diff --git a/mkspecs/win32-g++/qplatformdefs.h b/mkspecs/win32-g++/qplatformdefs.h index 4f339cbea6..a5401075ab 100644 --- a/mkspecs/win32-g++/qplatformdefs.h +++ b/mkspecs/win32-g++/qplatformdefs.h @@ -79,57 +79,57 @@ typedef enum { #endif #ifdef QT_LARGEFILE_SUPPORT -#define QT_STATBUF struct _stati64 // non-ANSI defs -#define QT_STATBUF4TSTAT struct _stati64 // non-ANSI defs -#define QT_STAT ::_stati64 -#define QT_FSTAT ::_fstati64 +#define QT_STATBUF struct _stati64 // non-ANSI defs +#define QT_STATBUF4TSTAT struct _stati64 // non-ANSI defs +#define QT_STAT ::_stati64 +#define QT_FSTAT ::_fstati64 #else -#define QT_STATBUF struct _stat // non-ANSI defs -#define QT_STATBUF4TSTAT struct _stat // non-ANSI defs -#define QT_STAT ::_stat -#define QT_FSTAT ::_fstat +#define QT_STATBUF struct _stat // non-ANSI defs +#define QT_STATBUF4TSTAT struct _stat // non-ANSI defs +#define QT_STAT ::_stat +#define QT_FSTAT ::_fstat #endif -#define QT_STAT_REG _S_IFREG -#define QT_STAT_DIR _S_IFDIR -#define QT_STAT_MASK _S_IFMT +#define QT_STAT_REG _S_IFREG +#define QT_STAT_DIR _S_IFDIR +#define QT_STAT_MASK _S_IFMT #if defined(_S_IFLNK) -# define QT_STAT_LNK _S_IFLNK +# define QT_STAT_LNK _S_IFLNK #endif -#define QT_FILENO _fileno -#define QT_OPEN ::_open -#define QT_CLOSE ::_close +#define QT_FILENO _fileno +#define QT_OPEN ::_open +#define QT_CLOSE ::_close #ifdef QT_LARGEFILE_SUPPORT -#define QT_LSEEK ::_lseeki64 +#define QT_LSEEK ::_lseeki64 #ifndef UNICODE -#define QT_TSTAT ::_stati64 +#define QT_TSTAT ::_stati64 #else -#define QT_TSTAT ::_wstati64 +#define QT_TSTAT ::_wstati64 #endif #else -#define QT_LSEEK ::_lseek +#define QT_LSEEK ::_lseek #ifndef UNICODE -#define QT_TSTAT ::_stat +#define QT_TSTAT ::_stat #else -#define QT_TSTAT ::_wstat +#define QT_TSTAT ::_wstat #endif #endif -#define QT_READ ::_read -#define QT_WRITE ::_write -#define QT_ACCESS ::_access -#define QT_GETCWD ::_getcwd -#define QT_CHDIR ::_chdir -#define QT_MKDIR ::_mkdir -#define QT_RMDIR ::_rmdir +#define QT_READ ::_read +#define QT_WRITE ::_write +#define QT_ACCESS ::_access +#define QT_GETCWD ::_getcwd +#define QT_CHDIR ::_chdir +#define QT_MKDIR ::_mkdir +#define QT_RMDIR ::_rmdir #define QT_OPEN_LARGEFILE 0 -#define QT_OPEN_RDONLY _O_RDONLY -#define QT_OPEN_WRONLY _O_WRONLY -#define QT_OPEN_RDWR _O_RDWR -#define QT_OPEN_CREAT _O_CREAT -#define QT_OPEN_TRUNC _O_TRUNC -#define QT_OPEN_APPEND _O_APPEND +#define QT_OPEN_RDONLY _O_RDONLY +#define QT_OPEN_WRONLY _O_WRONLY +#define QT_OPEN_RDWR _O_RDWR +#define QT_OPEN_CREAT _O_CREAT +#define QT_OPEN_TRUNC _O_TRUNC +#define QT_OPEN_APPEND _O_APPEND #if defined(O_TEXT) -# define QT_OPEN_TEXT _O_TEXT -# define QT_OPEN_BINARY _O_BINARY +# define QT_OPEN_TEXT _O_TEXT +# define QT_OPEN_BINARY _O_BINARY #endif #include "../common/c89/qplatformdefs.h" @@ -144,15 +144,15 @@ typedef enum { #define QT_OFF_T off64_t #endif -#define QT_SIGNAL_ARGS int +#define QT_SIGNAL_ARGS int -#define QT_VSNPRINTF ::_vsnprintf -#define QT_SNPRINTF ::_snprintf +#define QT_VSNPRINTF ::_vsnprintf +#define QT_SNPRINTF ::_snprintf -# define F_OK 0 -# define X_OK 1 -# define W_OK 2 -# define R_OK 4 +# define F_OK 0 +# define X_OK 1 +# define W_OK 2 +# define R_OK 4 #endif // QPLATFORMDEFS_H diff --git a/mkspecs/win32-msvc2005/qplatformdefs.h b/mkspecs/win32-msvc2005/qplatformdefs.h index c7370f1c63..f621d08956 100644 --- a/mkspecs/win32-msvc2005/qplatformdefs.h +++ b/mkspecs/win32-msvc2005/qplatformdefs.h @@ -66,51 +66,51 @@ #include <stdlib.h> #ifdef QT_LARGEFILE_SUPPORT -#define QT_STATBUF struct _stati64 // non-ANSI defs -#define QT_STATBUF4TSTAT struct _stati64 // non-ANSI defs -#define QT_STAT ::_stati64 -#define QT_FSTAT ::_fstati64 +#define QT_STATBUF struct _stati64 // non-ANSI defs +#define QT_STATBUF4TSTAT struct _stati64 // non-ANSI defs +#define QT_STAT ::_stati64 +#define QT_FSTAT ::_fstati64 #else -#define QT_STATBUF struct _stat // non-ANSI defs -#define QT_STATBUF4TSTAT struct _stat // non-ANSI defs -#define QT_STAT ::_stat -#define QT_FSTAT ::_fstat +#define QT_STATBUF struct _stat // non-ANSI defs +#define QT_STATBUF4TSTAT struct _stat // non-ANSI defs +#define QT_STAT ::_stat +#define QT_FSTAT ::_fstat #endif -#define QT_STAT_REG _S_IFREG -#define QT_STAT_DIR _S_IFDIR -#define QT_STAT_MASK _S_IFMT +#define QT_STAT_REG _S_IFREG +#define QT_STAT_DIR _S_IFDIR +#define QT_STAT_MASK _S_IFMT #if defined(_S_IFLNK) -# define QT_STAT_LNK _S_IFLNK +# define QT_STAT_LNK _S_IFLNK #else -# define QT_STAT_LNK 0120000 +# define QT_STAT_LNK 0120000 #endif -#define QT_FILENO _fileno -#define QT_OPEN ::_open -#define QT_CLOSE ::_close +#define QT_FILENO _fileno +#define QT_OPEN ::_open +#define QT_CLOSE ::_close #ifdef QT_LARGEFILE_SUPPORT -#define QT_LSEEK ::_lseeki64 -#define QT_TSTAT ::_tstati64 +#define QT_LSEEK ::_lseeki64 +#define QT_TSTAT ::_tstati64 #else -#define QT_LSEEK ::_lseek -#define QT_TSTAT ::_tstat +#define QT_LSEEK ::_lseek +#define QT_TSTAT ::_tstat #endif -#define QT_READ ::_read -#define QT_WRITE ::_write -#define QT_ACCESS ::_access -#define QT_GETCWD ::_getcwd -#define QT_CHDIR ::_chdir -#define QT_MKDIR ::_mkdir -#define QT_RMDIR ::_rmdir +#define QT_READ ::_read +#define QT_WRITE ::_write +#define QT_ACCESS ::_access +#define QT_GETCWD ::_getcwd +#define QT_CHDIR ::_chdir +#define QT_MKDIR ::_mkdir +#define QT_RMDIR ::_rmdir #define QT_OPEN_LARGEFILE 0 -#define QT_OPEN_RDONLY _O_RDONLY -#define QT_OPEN_WRONLY _O_WRONLY -#define QT_OPEN_RDWR _O_RDWR -#define QT_OPEN_CREAT _O_CREAT -#define QT_OPEN_TRUNC _O_TRUNC -#define QT_OPEN_APPEND _O_APPEND +#define QT_OPEN_RDONLY _O_RDONLY +#define QT_OPEN_WRONLY _O_WRONLY +#define QT_OPEN_RDWR _O_RDWR +#define QT_OPEN_CREAT _O_CREAT +#define QT_OPEN_TRUNC _O_TRUNC +#define QT_OPEN_APPEND _O_APPEND #if defined(O_TEXT) -# define QT_OPEN_TEXT _O_TEXT -# define QT_OPEN_BINARY _O_BINARY +# define QT_OPEN_TEXT _O_TEXT +# define QT_OPEN_BINARY _O_BINARY #endif #include "../common/c89/qplatformdefs.h" @@ -125,17 +125,17 @@ #define QT_OFF_T __int64 #endif -#define QT_SIGNAL_ARGS int +#define QT_SIGNAL_ARGS int #define QT_VSNPRINTF(buffer, count, format, arg) \ vsnprintf_s(buffer, count, count-1, format, arg) -#define QT_SNPRINTF ::_snprintf +#define QT_SNPRINTF ::_snprintf -# define F_OK 0 -# define X_OK 1 -# define W_OK 2 -# define R_OK 4 +# define F_OK 0 +# define X_OK 1 +# define W_OK 2 +# define R_OK 4 typedef int mode_t; diff --git a/mkspecs/winphone-arm-msvc2012/qmake.conf b/mkspecs/winphone-arm-msvc2012/qmake.conf index 1e31ac51d0..c4e3d2bab7 100644 --- a/mkspecs/winphone-arm-msvc2012/qmake.conf +++ b/mkspecs/winphone-arm-msvc2012/qmake.conf @@ -5,6 +5,7 @@ # include(../common/winrt_winphone/qmake.conf) +QMAKE_COMPILER_DEFINES += _MSC_VER=1700 QMAKE_PLATFORM = winphone $$QMAKE_PLATFORM DEFINES += WINAPI_FAMILY=WINAPI_FAMILY_PHONE_APP ARM __ARM__ __arm__ QT_NO_CURSOR @@ -13,3 +14,7 @@ QMAKE_LFLAGS += /MACHINE:ARM QMAKE_LIBS += WindowsPhoneCore.lib PhoneAppModelHost.lib ws2_32.lib VCPROJ_ARCH = ARM +MSVC_VER = 11.0 +WINSDK_VER = 8.0 +WINTARGET_VER = WP80 +WINRT_MANIFEST = $$PWD/../common/winrt_winphone/manifests/8.0/WMAppManifest.xml.in diff --git a/mkspecs/winphone-arm-msvc2012/qplatformdefs.h b/mkspecs/winphone-arm-msvc2012/qplatformdefs.h index e03bce8e6c..781107b2dc 100644 --- a/mkspecs/winphone-arm-msvc2012/qplatformdefs.h +++ b/mkspecs/winphone-arm-msvc2012/qplatformdefs.h @@ -39,4 +39,4 @@ ** ****************************************************************************/ -#include "../win32-msvc2005/qplatformdefs.h" +#include "../common/winrt_winphone/qplatformdefs.h" diff --git a/mkspecs/winphone-x86-msvc2012/qmake.conf b/mkspecs/winphone-x86-msvc2012/qmake.conf index 8836de58cf..1329370900 100644 --- a/mkspecs/winphone-x86-msvc2012/qmake.conf +++ b/mkspecs/winphone-x86-msvc2012/qmake.conf @@ -5,6 +5,7 @@ # include(../common/winrt_winphone/qmake.conf) +QMAKE_COMPILER_DEFINES += _MSC_VER=1700 QMAKE_PLATFORM = winphone $$QMAKE_PLATFORM DEFINES += WINAPI_FAMILY=WINAPI_FAMILY_PHONE_APP X86 __X86__ __x86__ QT_NO_CURSOR @@ -13,3 +14,7 @@ QMAKE_LFLAGS += /MACHINE:X86 QMAKE_LIBS += WindowsPhoneCore.lib PhoneAppModelHost.lib ws2_32.lib VCPROJ_ARCH = x86 +MSVC_VER = 11.0 +WINSDK_VER = 8.0 +WINTARGET_VER = WP80 +WINRT_MANIFEST = $$PWD/../common/winrt_winphone/manifests/8.0/WMAppManifest.xml.in diff --git a/mkspecs/winphone-x86-msvc2012/qplatformdefs.h b/mkspecs/winphone-x86-msvc2012/qplatformdefs.h index e03bce8e6c..781107b2dc 100644 --- a/mkspecs/winphone-x86-msvc2012/qplatformdefs.h +++ b/mkspecs/winphone-x86-msvc2012/qplatformdefs.h @@ -39,4 +39,4 @@ ** ****************************************************************************/ -#include "../win32-msvc2005/qplatformdefs.h" +#include "../common/winrt_winphone/qplatformdefs.h" diff --git a/mkspecs/winrt-arm-msvc2012/qmake.conf b/mkspecs/winrt-arm-msvc2012/qmake.conf index cafdbf4a93..41594a3547 100644 --- a/mkspecs/winrt-arm-msvc2012/qmake.conf +++ b/mkspecs/winrt-arm-msvc2012/qmake.conf @@ -5,6 +5,7 @@ # include(../common/winrt_winphone/qmake.conf) +QMAKE_COMPILER_DEFINES += _MSC_VER=1700 DEFINES += WINAPI_FAMILY=WINAPI_FAMILY_APP ARM __ARM__ __arm__ QMAKE_LFLAGS += /MACHINE:ARM @@ -12,3 +13,7 @@ QMAKE_LFLAGS += /MACHINE:ARM QMAKE_LIBS += windowscodecs.lib kernel32.lib ole32.lib VCPROJ_ARCH = ARM +MSVC_VER = 11.0 +WINSDK_VER = 8.0 +WINTARGET_VER = win8 +WINRT_MANIFEST = $$PWD/../common/winrt_winphone/manifests/8.0/AppxManifest.xml.in diff --git a/mkspecs/winrt-arm-msvc2012/qplatformdefs.h b/mkspecs/winrt-arm-msvc2012/qplatformdefs.h index e03bce8e6c..781107b2dc 100644 --- a/mkspecs/winrt-arm-msvc2012/qplatformdefs.h +++ b/mkspecs/winrt-arm-msvc2012/qplatformdefs.h @@ -39,4 +39,4 @@ ** ****************************************************************************/ -#include "../win32-msvc2005/qplatformdefs.h" +#include "../common/winrt_winphone/qplatformdefs.h" diff --git a/mkspecs/winrt-arm-msvc2013/qmake.conf b/mkspecs/winrt-arm-msvc2013/qmake.conf new file mode 100644 index 0000000000..83ab228d7f --- /dev/null +++ b/mkspecs/winrt-arm-msvc2013/qmake.conf @@ -0,0 +1,21 @@ +# +# qmake configuration for winrt-arm-msvc2013 +# +# Written for Microsoft Visual C++ 2013 +# + +include(../common/winrt_winphone/qmake.conf) +QMAKE_COMPILER_DEFINES += _MSC_VER=1800 +DEFINES += WINAPI_FAMILY=WINAPI_FAMILY_APP ARM __ARM__ __arm__ + +QMAKE_CFLAGS += -FS +QMAKE_CXXFLAGS += -FS +QMAKE_LFLAGS += /MACHINE:ARM + +QMAKE_LIBS += windowscodecs.lib kernel32.lib ole32.lib + +VCPROJ_ARCH = ARM +MSVC_VER = 12.0 +WINSDK_VER = 8.1 +WINTARGET_VER = winv6.3 +WINRT_MANIFEST = $$PWD/../common/winrt_winphone/manifests/8.1/AppxManifest.xml.in diff --git a/mkspecs/winrt-arm-msvc2013/qplatformdefs.h b/mkspecs/winrt-arm-msvc2013/qplatformdefs.h new file mode 100644 index 0000000000..781107b2dc --- /dev/null +++ b/mkspecs/winrt-arm-msvc2013/qplatformdefs.h @@ -0,0 +1,42 @@ +/**************************************************************************** +** +** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies). +** Contact: http://www.qt-project.org/legal +** +** This file is part of the qmake spec of the Qt Toolkit. +** +** $QT_BEGIN_LICENSE:LGPL$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and Digia. For licensing terms and +** conditions see http://qt.digia.com/licensing. For further information +** use the contact form at http://qt.digia.com/contact-us. +** +** GNU Lesser General Public License Usage +** Alternatively, 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, Digia gives you certain additional +** rights. These rights are described in the Digia 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. +** +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +#include "../common/winrt_winphone/qplatformdefs.h" diff --git a/mkspecs/winrt-x64-msvc2012/qmake.conf b/mkspecs/winrt-x64-msvc2012/qmake.conf index 784d0ccb7e..f6e360ae12 100644 --- a/mkspecs/winrt-x64-msvc2012/qmake.conf +++ b/mkspecs/winrt-x64-msvc2012/qmake.conf @@ -5,6 +5,7 @@ # include(../common/winrt_winphone/qmake.conf) +QMAKE_COMPILER_DEFINES += _MSC_VER=1700 DEFINES += WINAPI_FAMILY=WINAPI_FAMILY_APP X64 __X64__ __x64__ QMAKE_LFLAGS += /MACHINE:X64 @@ -12,3 +13,7 @@ QMAKE_LFLAGS += /MACHINE:X64 QMAKE_LIBS += windowscodecs.lib kernel32.lib ole32.lib VCPROJ_ARCH = x64 +MSVC_VER = 11.0 +WINSDK_VER = 8.0 +WINTARGET_VER = win8 +WINRT_MANIFEST = $$PWD/../common/winrt_winphone/manifests/8.0/AppxManifest.xml.in diff --git a/mkspecs/winrt-x64-msvc2012/qplatformdefs.h b/mkspecs/winrt-x64-msvc2012/qplatformdefs.h index e03bce8e6c..781107b2dc 100644 --- a/mkspecs/winrt-x64-msvc2012/qplatformdefs.h +++ b/mkspecs/winrt-x64-msvc2012/qplatformdefs.h @@ -39,4 +39,4 @@ ** ****************************************************************************/ -#include "../win32-msvc2005/qplatformdefs.h" +#include "../common/winrt_winphone/qplatformdefs.h" diff --git a/mkspecs/winrt-x64-msvc2013/qmake.conf b/mkspecs/winrt-x64-msvc2013/qmake.conf new file mode 100644 index 0000000000..2c01450ed4 --- /dev/null +++ b/mkspecs/winrt-x64-msvc2013/qmake.conf @@ -0,0 +1,21 @@ +# +# qmake configuration for winrt-x64-msvc2013 +# +# Written for Microsoft Visual C++ 2013 +# + +include(../common/winrt_winphone/qmake.conf) +QMAKE_COMPILER_DEFINES += _MSC_VER=1800 +DEFINES += WINAPI_FAMILY=WINAPI_FAMILY_APP X64 __X64__ __x64__ + +QMAKE_CFLAGS += -FS +QMAKE_CXXFLAGS += -FS +QMAKE_LFLAGS += /MACHINE:X64 + +QMAKE_LIBS += windowscodecs.lib kernel32.lib ole32.lib + +VCPROJ_ARCH = x64 +MSVC_VER = 12.0 +WINSDK_VER = 8.1 +WINTARGET_VER = winv6.3 +WINRT_MANIFEST = $$PWD/../common/winrt_winphone/manifests/8.1/AppxManifest.xml.in diff --git a/mkspecs/winrt-x64-msvc2013/qplatformdefs.h b/mkspecs/winrt-x64-msvc2013/qplatformdefs.h new file mode 100644 index 0000000000..781107b2dc --- /dev/null +++ b/mkspecs/winrt-x64-msvc2013/qplatformdefs.h @@ -0,0 +1,42 @@ +/**************************************************************************** +** +** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies). +** Contact: http://www.qt-project.org/legal +** +** This file is part of the qmake spec of the Qt Toolkit. +** +** $QT_BEGIN_LICENSE:LGPL$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and Digia. For licensing terms and +** conditions see http://qt.digia.com/licensing. For further information +** use the contact form at http://qt.digia.com/contact-us. +** +** GNU Lesser General Public License Usage +** Alternatively, 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, Digia gives you certain additional +** rights. These rights are described in the Digia 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. +** +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +#include "../common/winrt_winphone/qplatformdefs.h" diff --git a/mkspecs/winrt-x86-msvc2012/qmake.conf b/mkspecs/winrt-x86-msvc2012/qmake.conf index 559c9b5d05..664212624c 100644 --- a/mkspecs/winrt-x86-msvc2012/qmake.conf +++ b/mkspecs/winrt-x86-msvc2012/qmake.conf @@ -5,10 +5,15 @@ # include(../common/winrt_winphone/qmake.conf) +QMAKE_COMPILER_DEFINES += _MSC_VER=1700 DEFINES += WINAPI_FAMILY=WINAPI_FAMILY_APP X86 __X86__ __x86__ -QMAKE_LFLAGS += /MACHINE:X86 +QMAKE_LFLAGS += /SAFESEH /MACHINE:X86 QMAKE_LIBS += windowscodecs.lib kernel32.lib ole32.lib VCPROJ_ARCH = x86 +MSVC_VER = 11.0 +WINSDK_VER = 8.0 +WINTARGET_VER = win8 +WINRT_MANIFEST = $$PWD/../common/winrt_winphone/manifests/8.0/AppxManifest.xml.in diff --git a/mkspecs/winrt-x86-msvc2012/qplatformdefs.h b/mkspecs/winrt-x86-msvc2012/qplatformdefs.h index e03bce8e6c..781107b2dc 100644 --- a/mkspecs/winrt-x86-msvc2012/qplatformdefs.h +++ b/mkspecs/winrt-x86-msvc2012/qplatformdefs.h @@ -39,4 +39,4 @@ ** ****************************************************************************/ -#include "../win32-msvc2005/qplatformdefs.h" +#include "../common/winrt_winphone/qplatformdefs.h" diff --git a/mkspecs/winrt-x86-msvc2013/qmake.conf b/mkspecs/winrt-x86-msvc2013/qmake.conf new file mode 100644 index 0000000000..384b51a1e6 --- /dev/null +++ b/mkspecs/winrt-x86-msvc2013/qmake.conf @@ -0,0 +1,21 @@ +# +# qmake configuration for winrt-x86-msvc2013 +# +# Written for Microsoft Visual C++ 2013 +# + +include(../common/winrt_winphone/qmake.conf) +QMAKE_COMPILER_DEFINES += _MSC_VER=1800 _WIN32 +DEFINES += WINAPI_FAMILY=WINAPI_FAMILY_APP X86 __X86__ __x86__ + +QMAKE_CFLAGS += -FS +QMAKE_CXXFLAGS += -FS +QMAKE_LFLAGS += /SAFESEH /MACHINE:X86 + +QMAKE_LIBS += windowscodecs.lib kernel32.lib ole32.lib + +VCPROJ_ARCH = x86 +MSVC_VER = 12.0 +WINSDK_VER = 8.1 +WINTARGET_VER = winv6.3 +WINRT_MANIFEST = $$PWD/../common/winrt_winphone/manifests/8.1/AppxManifest.xml.in diff --git a/mkspecs/winrt-x86-msvc2013/qplatformdefs.h b/mkspecs/winrt-x86-msvc2013/qplatformdefs.h new file mode 100644 index 0000000000..781107b2dc --- /dev/null +++ b/mkspecs/winrt-x86-msvc2013/qplatformdefs.h @@ -0,0 +1,42 @@ +/**************************************************************************** +** +** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies). +** Contact: http://www.qt-project.org/legal +** +** This file is part of the qmake spec of the Qt Toolkit. +** +** $QT_BEGIN_LICENSE:LGPL$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and Digia. For licensing terms and +** conditions see http://qt.digia.com/licensing. For further information +** use the contact form at http://qt.digia.com/contact-us. +** +** GNU Lesser General Public License Usage +** Alternatively, 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, Digia gives you certain additional +** rights. These rights are described in the Digia 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. +** +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +#include "../common/winrt_winphone/qplatformdefs.h" |