diff options
author | João Abecasis <joao.abecasis@nokia.com> | 2011-02-16 18:01:17 (GMT) |
---|---|---|
committer | João Abecasis <joao.abecasis@nokia.com> | 2011-02-16 18:01:17 (GMT) |
commit | 9db05f0b7bf68392dc925d4047aa74dac88b348a (patch) | |
tree | 3690ea636187c9af9459ff3bfd4cab3e2af97c57 /mkspecs | |
parent | 0df215e5afc780c1fddd9e410f7ef0814ac1307c (diff) | |
parent | 5a1676af979ab75c8939e53e0223ccbea7708de4 (diff) | |
download | Qt-9db05f0b7bf68392dc925d4047aa74dac88b348a.zip Qt-9db05f0b7bf68392dc925d4047aa74dac88b348a.tar.gz Qt-9db05f0b7bf68392dc925d4047aa74dac88b348a.tar.bz2 |
Merge branch earth-team/master into earth-staging
Conflicts:
doc/src/development/qmake-manual.qdoc
Diffstat (limited to 'mkspecs')
-rw-r--r-- | mkspecs/common/armcc.conf | 1 | ||||
-rw-r--r-- | mkspecs/common/symbian/symbian-makefile.conf | 20 | ||||
-rw-r--r-- | mkspecs/common/symbian/symbian.conf | 6 | ||||
-rw-r--r-- | mkspecs/common/symbian/symbianincludes.h | 58 | ||||
-rw-r--r-- | mkspecs/features/link_pkgconfig.prf | 7 | ||||
-rw-r--r-- | mkspecs/features/qt_functions.prf | 21 | ||||
-rw-r--r-- | mkspecs/features/symbian/symbian_building.prf | 136 | ||||
-rw-r--r-- | mkspecs/symbian-armcc/qmake.conf | 5 | ||||
-rw-r--r-- | mkspecs/symbian-gcce/qmake.conf | 18 | ||||
-rw-r--r-- | mkspecs/unsupported/linux-armcc/qmake.conf | 32 | ||||
-rw-r--r-- | mkspecs/unsupported/linux-armcc/qplatformdefs.h | 100 | ||||
-rw-r--r-- | mkspecs/win32-g++/qmake.conf | 2 |
12 files changed, 334 insertions, 72 deletions
diff --git a/mkspecs/common/armcc.conf b/mkspecs/common/armcc.conf index 2c765bc..4f178d7 100644 --- a/mkspecs/common/armcc.conf +++ b/mkspecs/common/armcc.conf @@ -37,5 +37,6 @@ QMAKE_LFLAGS_PLUGIN += $$QMAKE_LFLAGS_SHLIB QMAKE_LFLAGS_THREAD += QMAKE_AR = armar --create +QMAKE_LIB = armar --create QMAKE_RANLIB = diff --git a/mkspecs/common/symbian/symbian-makefile.conf b/mkspecs/common/symbian/symbian-makefile.conf index 899f8c2..cffc859 100644 --- a/mkspecs/common/symbian/symbian-makefile.conf +++ b/mkspecs/common/symbian/symbian-makefile.conf @@ -2,7 +2,11 @@ # qmake configuration for makefile based symbian # -MAKEFILE_GENERATOR = SYMBIAN_UNIX +contains(QMAKE_HOST.os,Windows) { + MAKEFILE_GENERATOR = SYMBIAN_MINGW +} else { + MAKEFILE_GENERATOR = SYMBIAN_UNIX +} include(symbian.conf) @@ -24,10 +28,18 @@ CONFIG *= no_plugin_name_prefix QMAKE_PREFIX_STATICLIB = QMAKE_SYMBIAN_SHLIB = 1 +QMAKE_LINK_OBJECT_SCRIPT = objects + is_using_gnupoc { - DEFINES *= __PRODUCT_INCLUDE__=\"<$${EPOCROOT}epoc32/include/variant/symbian_os.hrh>\" -} else { - DEFINES *= __PRODUCT_INCLUDE__=\"<$${EPOCROOT}epoc32/include/variant/Symbian_OS.hrh>\" + DEFINES *= __QT_PRODUCT_INCLUDE_IS_LOWERCASE__ +} +QMAKE_SYMBIAN_INCLUDES = $$[QT_INSTALL_DATA]/mkspecs/common/symbian/symbianincludes.h +symbian-armcc { + QMAKE_CFLAGS += --preinclude $$QMAKE_SYMBIAN_INCLUDES + QMAKE_CXXFLAGS += --preinclude $$QMAKE_SYMBIAN_INCLUDES +} else:symbian-gcce { + QMAKE_CFLAGS += -include $$QMAKE_SYMBIAN_INCLUDES + QMAKE_CXXFLAGS += -include $$QMAKE_SYMBIAN_INCLUDES } DEFINES *= \ __SYMBIAN32__ \ diff --git a/mkspecs/common/symbian/symbian.conf b/mkspecs/common/symbian/symbian.conf index 3644bc6..63db511 100644 --- a/mkspecs/common/symbian/symbian.conf +++ b/mkspecs/common/symbian/symbian.conf @@ -118,11 +118,11 @@ contains(QMAKE_HOST.os,Windows) { } QMAKE_IDL = midl -QMAKE_LIB = ar -ru -QMAKE_RC = windres QMAKE_ZIP = zip -r -9 QMAKE_UNZIP = unzip -o +QMAKE_WRITE_DEFAULT_RC = 1 + QMAKE_TAR = tar -cf QMAKE_GZIP = gzip -9f @@ -239,7 +239,7 @@ defineTest(matchSymbianLanguages) { language = $$replace(translation, "^(.*/)?[^/]+_(([^_]{2,3}_)?[^_]{2,3})\\.ts$", \\2) contains(SYMBIAN_SUPPORTED_LANGUAGES, $$language) { SYMBIAN_MATCHED_LANGUAGES += $$language - SYMBIAN_MATCHED_TRANSLATIONS += $$translation + SYMBIAN_MATCHED_TRANSLATIONS += $$_PRO_FILE_PWD_/$$translation } } diff --git a/mkspecs/common/symbian/symbianincludes.h b/mkspecs/common/symbian/symbianincludes.h new file mode 100644 index 0000000..5d7f488 --- /dev/null +++ b/mkspecs/common/symbian/symbianincludes.h @@ -0,0 +1,58 @@ +/**************************************************************************** +** +** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies). +** All rights reserved. +** Contact: Nokia Corporation (qt-info@nokia.com) +** +** This file is part of the mkspecs of the Qt Toolkit. +** +** $QT_BEGIN_LICENSE:LGPL$ +** No Commercial Usage +** This file contains pre-release code and may not be distributed. +** You may use this file in accordance with the terms and conditions +** contained in the Technology Preview License Agreement accompanying +** this package. +** +** 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, Nokia gives you certain additional +** rights. These rights are described in the Nokia Qt LGPL Exception +** version 1.1, included in the file LGPL_EXCEPTION.txt in this package. +** +** If you have questions regarding the use of this file, please contact +** Nokia at qt-info@nokia.com. +** +** +** +** +** +** +** +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +#ifndef __PRODUCT_INCLUDE__ +# ifdef __QT_PRODUCT_INCLUDE_IS_LOWERCASE__ +# define __PRODUCT_INCLUDE__ <variant/symbian_os.hrh> +# else +# define __PRODUCT_INCLUDE__ <variant/Symbian_OS.hrh> +# endif +#endif + +#ifndef __QT_SYMBIAN_RESOURCE__ +# if defined(__ARMCC__) || defined(__CC_ARM) +# ifdef __QT_RVCT_HEADER_IS_2_2__ +# include <rvct2_2.h> +# else +# include <rvct.h> +# endif +# endif +#endif diff --git a/mkspecs/features/link_pkgconfig.prf b/mkspecs/features/link_pkgconfig.prf index d70e5de..a3dbd1f 100644 --- a/mkspecs/features/link_pkgconfig.prf +++ b/mkspecs/features/link_pkgconfig.prf @@ -1,7 +1,12 @@ # handle pkg-config files -isEmpty(PKG_CONFIG):PKG_CONFIG = pkg-config +isEmpty(PKG_CONFIG):PKG_CONFIG = pkg-config # keep consistent with qt_functions.prf too! + for(PKGCONFIG_LIB, $$list($$unique(PKGCONFIG))) { + # don't proceed if the .pro asks for a package we don't have! + !packagesExist($$PKGCONFIG_LIB):error("Package $$PKGCONFIG_LIB not found") + QMAKE_CXXFLAGS += $$system($$PKG_CONFIG --cflags $$PKGCONFIG_LIB) QMAKE_CFLAGS += $$system($$PKG_CONFIG --cflags $$PKGCONFIG_LIB) LIBS += $$system($$PKG_CONFIG --libs $$PKGCONFIG_LIB) } + diff --git a/mkspecs/features/qt_functions.prf b/mkspecs/features/qt_functions.prf index 964e13b..1fb6298 100644 --- a/mkspecs/features/qt_functions.prf +++ b/mkspecs/features/qt_functions.prf @@ -46,7 +46,12 @@ defineTest(qtAddLibrary) { } } symbian { - isEqual(LIB_NAME, QtGui) { + isEqual(LIB_NAME, QtCore) { + #workaround for dependency from f32file.h on e32svr.h which has moved location in symbian3 + contains(SYMBIAN_VERSION, Symbian3) { + INCLUDEPATH *= $$OS_LAYER_SYSTEMINCLUDE + } + } else:isEqual(LIB_NAME, QtGui) { # Needed for #include <QtGui> because qs60mainapplication.h includes aknapp.h INCLUDEPATH *= $$MW_LAYER_SYSTEMINCLUDE } else:isEqual(LIB_NAME, QtWebKit) { @@ -103,3 +108,17 @@ defineTest(qtPrepareTool) { } export($$1) } + +defineTest(packagesExist) { + # this can't be done in global scope here because qt_functions is loaded + # before the .pro is parsed, so if the .pro set PKG_CONFIG, we wouldn't know it + # yet. oops. + isEmpty(PKG_CONFIG):PKG_CONFIG = pkg-config # keep consistent with link_pkgconfig.prf! too + + for(package, ARGS) { + !system($$PKG_CONFIG --exists $$package):return(false) + } + + return(true) +} + diff --git a/mkspecs/features/symbian/symbian_building.prf b/mkspecs/features/symbian/symbian_building.prf index 9288583..678838c 100644 --- a/mkspecs/features/symbian/symbian_building.prf +++ b/mkspecs/features/symbian/symbian_building.prf @@ -1,6 +1,11 @@ symbian-armcc { QMAKE_CFLAGS += $$QMAKE_CFLAGS.ARMCC QMAKE_CXXFLAGS += $$QMAKE_CXXFLAGS.ARMCC + # This is to prevent inclusion of the shipped RVCT headers, which are often in the + # environment variable RVCTxxINC by default. -J prevents the searching of that location, + # but needs a path, so just specify somewhere guaranteed not to contain header files. + QMAKE_CFLAGS += -J$${EPOCROOT}epoc32/ignore_this_path + QMAKE_CXXFLAGS += -J$${EPOCROOT}epoc32/ignore_this_path } else:symbian-gcce { QMAKE_CFLAGS += $$QMAKE_CFLAGS.GCCE QMAKE_CXXFLAGS += $$QMAKE_CXXFLAGS.GCCE @@ -235,13 +240,9 @@ contains(TEMPLATE, app):!contains(QMAKE_LINK, "^@:.*") { } # Symbian resource files -symbian-armcc: { - SYMBIAN_RVCT22INC=$$(RVCT22INC) - !isEmpty(SYMBIAN_RVCT22INC):symbian_resources_INCLUDES = -I$${SYMBIAN_RVCT22INC} -} -symbian_resources_INCLUDES = $$replace(symbian_resources_INCLUDES, ",", " -I") -symbian_resources_INCLUDES += $$join(INCLUDEPATH, " -I", "-I") +symbian_resources_INCLUDES = $$join(INCLUDEPATH, " -I", "-I") symbian_resources_DEFINES = $$join(DEFINES, " -D", "-D") +symbian_resources_DEFINES += -D__QT_SYMBIAN_RESOURCE__ symbian_resources_RCC_DIR = $$replace(RCC_DIR, "/$", "") symbian_resources_INCLUDES += "-I$$symbian_resources_RCC_DIR" @@ -256,6 +257,7 @@ for(symbian_resource, SYMBIAN_RESOURCES) { symbianresources.input = SYMBIAN_RESOURCES symbianresources.output = $$symbian_resources_RCC_DIR/${QMAKE_FILE_BASE}$${QT_LIBINFIX}.rsg symbianresources.commands = cpp -nostdinc -undef \ + -include $$QMAKE_SYMBIAN_INCLUDES \ $$symbian_resources_INCLUDES \ $$symbian_resources_DEFINES \ ${QMAKE_FILE_NAME} \ @@ -271,46 +273,79 @@ symbianresources.CONFIG = no_link target_predeps QMAKE_EXTRA_COMPILERS += symbianresources +# This section generates the rsg and rsc files for symbian. contains(TEMPLATE, "app"):!contains(CONFIG, "no_icon") { - # Make our own extra target in order to get dependencies for generated - # files right. This also avoids the warning about files not found. - symbianGenResource.target = $${symbian_resources_RCC_DIR}/$${baseTarget}.rsg - symbianGenResource.commands = cpp -nostdinc -undef \ - $$symbian_resources_INCLUDES \ - $$symbian_resources_DEFINES \ - $${baseTarget}.rss \ - > $${symbian_resources_RCC_DIR}/$${baseTarget}.rpp \ - && rcomp -u -m045,046,047 \ - -s$${symbian_resources_RCC_DIR}/$${baseTarget}.rpp \ - -o$${symbianDestdir}/$${baseTarget}.rsc \ - -h$${symbian_resources_RCC_DIR}/$${baseTarget}.rsg \ - -i$${baseTarget}.rss - silent:symbianGenResource.commands = @echo rcomp $${baseTarget}.rss && $$symbianGenResource.commands - symbianGenResource.depends = $${baseTarget}.rss - PRE_TARGETDEPS += $${symbian_resources_RCC_DIR}/$${baseTarget}.rsg - QMAKE_CLEAN += $${symbian_resources_RCC_DIR}/$${baseTarget}.rsg - QMAKE_CLEAN += $${symbian_resources_RCC_DIR}/$${baseTarget}.rpp - QMAKE_DISTCLEAN += $${baseTarget}.rss - QMAKE_DISTCLEAN += $${symbianDestdir}/$${baseTarget}.rsc - - symbianGenRegResource.target = $${symbian_resources_RCC_DIR}/$${baseTarget}_reg.rsg - symbianGenRegResource.commands = cpp -nostdinc -undef \ - $$symbian_resources_INCLUDES \ - $$symbian_resources_DEFINES \ - $${baseTarget}_reg.rss \ - > $${symbian_resources_RCC_DIR}/$${baseTarget}_reg.rpp \ - && rcomp -u -m045,046,047 \ - -s$${symbian_resources_RCC_DIR}/$${baseTarget}_reg.rpp \ - -o$${symbianDestdir}/$${baseTarget}_reg.rsc \ - -h$${symbian_resources_RCC_DIR}/$${baseTarget}_reg.rsg \ - -i$${baseTarget}_reg.rss - silent:symbianGenRegResource.commands = @echo rcomp $${baseTarget}_reg.rss && $$symbianGenRegResource.commands - symbianGenRegResource.depends = $${baseTarget}_reg.rss $${symbian_resources_RCC_DIR}/$${baseTarget}.rsg - PRE_TARGETDEPS += $${symbian_resources_RCC_DIR}/$${baseTarget}_reg.rsg - QMAKE_CLEAN += $${symbian_resources_RCC_DIR}/$${baseTarget}_reg.rsg - QMAKE_CLEAN += $${symbian_resources_RCC_DIR}/$${baseTarget}_reg.rpp - QMAKE_DISTCLEAN += $${baseTarget}_reg.rss - QMAKE_DISTCLEAN += $${symbianDestdir}/$${baseTarget}_reg.rsc + # Look for extra languages for the resources, and then generate a target for each one. + localize_deployment:symbianGenResourceLanguages = $$SYMBIAN_MATCHED_LANGUAGES default + else:symbianGenResourceLanguages = default + for(language, symbianGenResourceLanguages) { + # Special languages get their language number appended to the filename. + contains(language, default) { + symbianGenResource_DEFINES = $$symbian_resources_DEFINES + rpp = $${symbian_resources_RCC_DIR}/$${baseTarget}.rpp + rsc = $${symbianDestdir}/$${baseTarget}.rsc + rsg = $${symbian_resources_RCC_DIR}/$${baseTarget}.rsg + } else { + languageNo = $$eval(SYMBIAN_LANG.$$language) + symbianGenResource_DEFINES = $$symbian_resources_DEFINES -DLANGUAGE_$${languageNo} + rpp = $${symbian_resources_RCC_DIR}/$${baseTarget}_$${languageNo}.rpp + rsc = $${symbianDestdir}/$${baseTarget}.r$${languageNo} + rsg = $${symbian_resources_RCC_DIR}/$${baseTarget}_$${languageNo}.rsg + } + + # Make our own extra target in order to get dependencies for generated + # files right. This also avoids the warning about files not found. + eval(symbianGenResource_$${language}.target = $$rsg) + eval(symbianGenResource_$${language}.commands = cpp -nostdinc -undef \ + -include $$QMAKE_SYMBIAN_INCLUDES \ + $$symbian_resources_INCLUDES \ + $$symbianGenResource_DEFINES \ + $${baseTarget}.rss \ + > $$rpp \ + && rcomp -u -m045,046,047 \ + -s$$rpp \ + -o$$rsc \ + -h$$rsg \ + -i$${baseTarget}.rss) + silent:eval(symbianGenResource_$${language}.commands = @echo rcomp $${baseTarget}.rss && $$eval(symbianGenResource_$${language}.commands)) + eval(symbianGenResource_$${language}.depends = $${baseTarget}.rss) + PRE_TARGETDEPS += $$rsg + QMAKE_CLEAN += $$rsg $$rpp + QMAKE_DISTCLEAN += $$rsc + + QMAKE_EXTRA_TARGETS += symbianGenResource_$${language} + + # Note that we depend on the base rsg file, even if dealing with a specific language. + # hence we don't use $$rsg on the next line. + eval(symbianGenRegResource_$${language}.depends = $${baseTarget}_reg.rss $${symbian_resources_RCC_DIR}/$${baseTarget}.rsg) + contains(language, default) { + rpp = $${symbian_resources_RCC_DIR}/$${baseTarget}_reg.rpp + rsc = $${symbianDestdir}/$${baseTarget}_reg.rsc + rsg = $${symbian_resources_RCC_DIR}/$${baseTarget}_reg.rsg + } else { + rpp = $${symbian_resources_RCC_DIR}/$${baseTarget}_reg_$${languageNo}.rpp + rsc = $${symbianDestdir}/$${baseTarget}_reg.r$${languageNo} + rsg = $${symbian_resources_RCC_DIR}/$${baseTarget}_reg_$${languageNo}.rsg + } + eval(symbianGenRegResource_$${language}.target = $$rsg) + eval(symbianGenRegResource_$${language}.commands = cpp -nostdinc -undef \ + -include $$QMAKE_SYMBIAN_INCLUDES \ + $$symbian_resources_INCLUDES \ + $$symbianGenResource_DEFINES \ + $${baseTarget}_reg.rss \ + > $$rpp \ + && rcomp -u -m045,046,047 \ + -s$$rpp \ + -o$$rsc \ + -h$$rsg \ + -i$${baseTarget}_reg.rss) + silent:eval(symbianGenRegResource_$${language}.commands = @echo rcomp $${baseTarget}_reg.rss && $$eval(symbianGenRegResource_$${language}.commands)) + PRE_TARGETDEPS += $$rsg + QMAKE_CLEAN += $$rsg $$rpp + QMAKE_DISTCLEAN += $$rsc + + QMAKE_EXTRA_TARGETS += symbianGenRegResource_$${language} + } # Trick to get qmake to create the RCC_DIR for us. symbianRccDirCreation.input = SOURCES @@ -318,14 +353,15 @@ contains(TEMPLATE, "app"):!contains(CONFIG, "no_icon") { symbianRccDirCreation.output = $${symbian_resources_RCC_DIR}/symbian_resource_dummy symbianRccDirCreation.CONFIG = no_link combine - QMAKE_EXTRA_TARGETS += symbianGenResource symbianGenRegResource QMAKE_EXTRA_COMPILERS += symbianRccDirCreation - QMAKE_DISTCLEAN += $${baseTarget}.loc + QMAKE_DISTCLEAN += $${baseTarget}.rss \ + $${baseTarget}_reg.rss \ + $${baseTarget}.loc } # Generated pkg files -QMAKE_DISTCLEAN += $${baseTarget}_template.pkg -QMAKE_DISTCLEAN += $${baseTarget}_installer.pkg -QMAKE_DISTCLEAN += $${baseTarget}_stub.pkg +QMAKE_DISTCLEAN += $${baseTarget}_template.pkg \ + $${baseTarget}_installer.pkg \ + $${baseTarget}_stub.pkg diff --git a/mkspecs/symbian-armcc/qmake.conf b/mkspecs/symbian-armcc/qmake.conf index be6af39..77a1966 100644 --- a/mkspecs/symbian-armcc/qmake.conf +++ b/mkspecs/symbian-armcc/qmake.conf @@ -53,10 +53,7 @@ INCLUDEPATH = $${EPOCROOT}epoc32/include \ exists($${EPOCROOT}epoc32/include/rvct2_2) { INCLUDEPATH += $${EPOCROOT}epoc32/include/rvct2_2 - QMAKE_CFLAGS += --preinclude rvct2_2.h - QMAKE_CXXFLAGS += --preinclude rvct2_2.h + DEFINES *= __QT_RVCT_HEADER_IS_2_2__ } else { INCLUDEPATH += $${EPOCROOT}epoc32/include/rvct - QMAKE_CFLAGS += --preinclude rvct.h - QMAKE_CXXFLAGS += --preinclude rvct.h } diff --git a/mkspecs/symbian-gcce/qmake.conf b/mkspecs/symbian-gcce/qmake.conf index 9eee43d..1d1053c 100644 --- a/mkspecs/symbian-gcce/qmake.conf +++ b/mkspecs/symbian-gcce/qmake.conf @@ -72,16 +72,16 @@ QMAKE_LFLAGS += --target1-abs \ QMAKE_LIBDIR += $${EPOCROOT}epoc32/release/armv5/udeb/ # g++ knows the path to the gcc-shipped-libs, ld doesn't. So cache the full path in the generate Makefile -QMAKE_GCC_SEARCH_DIRS =$$system($$QMAKE_CXX -print-search-dirs) -for(line, QMAKE_GCC_SEARCH_DIRS) { - contains(line, "libraries:") { - foundIt="1" - } else { - contains(foundIt, "1") { - QMAKE_LFLAGS += $$replace(line, "[=:]", " -L") - } - } +QMAKE_GCC_SEARCH_DIRS = $$system($$QMAKE_CXX -print-search-dirs) +QMAKE_GCC_SEARCH_DIRS = "$$join(QMAKE_GCC_SEARCH_DIRS, " ")" +QMAKE_GCC_SEARCH_DIRS = $$replace(QMAKE_GCC_SEARCH_DIRS, ".*libraries: *", "") +QMAKE_GCC_SEARCH_DIRS = $$replace(QMAKE_GCC_SEARCH_DIRS, "=", "") +contains(QMAKE_HOST.os,Windows) { + QMAKE_GCC_SEARCH_DIRS = $$split(QMAKE_GCC_SEARCH_DIRS, ;) +} else { + QMAKE_GCC_SEARCH_DIRS = $$split(QMAKE_GCC_SEARCH_DIRS, :) } +for(line, QMAKE_GCC_SEARCH_DIRS):QMAKE_LIBDIR += $$line QMAKE_LIBDIR += $${EPOCROOT}epoc32/release/armv5/lib diff --git a/mkspecs/unsupported/linux-armcc/qmake.conf b/mkspecs/unsupported/linux-armcc/qmake.conf new file mode 100644 index 0000000..77891c3 --- /dev/null +++ b/mkspecs/unsupported/linux-armcc/qmake.conf @@ -0,0 +1,32 @@ +# +# qmake configuration for linux-armcc +# + +MAKEFILE_GENERATOR = UNIX +TARGET_PLATFORM = unix +TEMPLATE = app +CONFIG += qt warn_on release incremental link_prl armcc_linker +QT += core gui +QMAKE_INCREMENTAL_STYLE = sublib + +include(../../common/linux.conf) +include(../../common/armcc.conf) +load(qt_config) + +# use armcc for linking since armlink doesn't understand the arm_linux_config_file option +QMAKE_LINK = armcc +QMAKE_LINK_SHLIB = armcc +QMAKE_LINK_C = armcc +QMAKE_LINK_C_SHLIB = armcc + +QMAKE_LFLAGS_SHLIB += --apcs=/fpic --shared +QMAKE_LFLAGS_PLUGIN = $$QMAKE_LFLAGS_SHLIB + +QMAKE_LIBS += libstdc++.so librt.so + +CONFIG -= rvct_linker + +QMAKE_CFLAGS += --gnu --arm_linux --dllimport_runtime --thumb --cpu Cortex-A9 --arm_linux_config_file="$(HOME)/qt_rvct_config" --arm-linux-paths --apcs=/interwork --visibility_inlines_hidden --diag_suppress 1300,2523 +QMAKE_CXXFLAGS += $$QMAKE_CFLAGS --cpp + +QMAKE_LFLAGS += --diag_suppress 6331,6780,6439 --arm_linux_config_file="$(HOME)/qt_rvct_config" --arm-linux-paths diff --git a/mkspecs/unsupported/linux-armcc/qplatformdefs.h b/mkspecs/unsupported/linux-armcc/qplatformdefs.h new file mode 100644 index 0000000..a1ce6a1 --- /dev/null +++ b/mkspecs/unsupported/linux-armcc/qplatformdefs.h @@ -0,0 +1,100 @@ +/**************************************************************************** +** +** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). +** All rights reserved. +** Contact: Nokia Corporation (qt-info@nokia.com) +** +** This file is part of the qmake spec of the Qt Toolkit. +** +** $QT_BEGIN_LICENSE:LGPL$ +** No Commercial Usage +** This file contains pre-release code and may not be distributed. +** You may use this file in accordance with the terms and conditions +** contained in the Technology Preview License Agreement accompanying +** this package. +** +** 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, Nokia gives you certain additional +** rights. These rights are described in the Nokia Qt LGPL Exception +** version 1.1, included in the file LGPL_EXCEPTION.txt in this package. +** +** If you have questions regarding the use of this file, please contact +** Nokia at qt-info@nokia.com. +** +** +** +** +** +** +** +** +** $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/win32-g++/qmake.conf b/mkspecs/win32-g++/qmake.conf index 65ae590..da65727 100644 --- a/mkspecs/win32-g++/qmake.conf +++ b/mkspecs/win32-g++/qmake.conf @@ -62,6 +62,8 @@ QMAKE_LFLAGS_WINDOWS = -Wl,-subsystem,windows QMAKE_LFLAGS_DLL = -shared QMAKE_LINK_OBJECT_MAX = 10 QMAKE_LINK_OBJECT_SCRIPT= object_script +QMAKE_PREFIX_STATICLIB = lib +QMAKE_EXTENSION_STATICLIB = a QMAKE_LIBS = |