From fbc3b6f405a6f4c364e0d025f462f00f634568d0 Mon Sep 17 00:00:00 2001 From: Timur Pocheptsov Date: Thu, 13 Aug 2015 09:17:13 +0200 Subject: Fix a typo 'Do', not 'dot' in the help's text. Change-Id: Ib0ccdd50ae62085571c5f932650b9209fa966d79 Reviewed-by: Richard J. Moore --- configure | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'configure') diff --git a/configure b/configure index 472fb02dbc..9c207bbbda 100755 --- a/configure +++ b/configure @@ -2725,7 +2725,7 @@ MacOS/iOS options: * -securetransport ... Use SecureTransport instead of OpenSSL - -no-securetransport Do not use SecureTransport, either use OpenSSL or dot not use any SSL backend + -no-securetransport Do not use SecureTransport, either use OpenSSL or do not use any SSL backend at all (if combined with -no-openssl). -sdk ......... Build Qt using Apple provided SDK . The argument should be -- cgit v1.2.3 From 55bc1ddc76deca1d20ff0febb51550db69c37fce Mon Sep 17 00:00:00 2001 From: Louai Al-Khanji Date: Mon, 24 Aug 2015 11:30:12 +0300 Subject: Improve description of configure script's -kms switch Change-Id: I05e69d10ca0df9f99dca2c172e1791371124e75c Reviewed-by: Laszlo Agocs --- configure | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'configure') diff --git a/configure b/configure index 8540659acc..d3e1f2e743 100755 --- a/configure +++ b/configure @@ -2649,15 +2649,15 @@ Additional options: -no-eglfs .......... Do not compile EGLFS (EGL Full Screen/Single Surface) support. * -eglfs ............. Compile EGLFS support. + -no-kms ............ Do not compile EGLFS KMS backend. + * -kms ............... Compile EGLFS KMS backend. + -no-directfb ....... Do not compile DirectFB support. * -directfb .......... Compile DirectFB support. -no-linuxfb ........ Do not compile Linux Framebuffer support. * -linuxfb ........... Compile Linux Framebuffer support. - -no-kms ............ Do not compile KMS support. - * -kms ............... Compile KMS support (Requires EGL). - * -no-mirclient....... Do not compile Mir client support. -mirclient.......... Compile Mir client support. -- cgit v1.2.3 From 3accdb8086cca78fc006cfbe0d8b6eb66ebcc307 Mon Sep 17 00:00:00 2001 From: Thiago Macieira Date: Sat, 1 Aug 2015 13:31:35 -0700 Subject: Detect which C++ standard edition the compiler defaults to Change-Id: I2991557a5cc74cd18e88ffff13f670bf25d5423e Reviewed-by: Kai Koehne --- configure | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) (limited to 'configure') diff --git a/configure b/configure index d3e1f2e743..afe741c303 100755 --- a/configure +++ b/configure @@ -4343,6 +4343,21 @@ if [ "$CFG_CXX11" != "no" ]; then fi fi +# Detect which edition of the C++ standard the compiler defaults to +CFG_STDCXX_DEFAULT=199711 +if compileTest common/c++default "default C++ standard edition"; then + if [ -e "$outpath/config.tests/common/c++default/c++default.ii" ]; then + CFG_STDCXX_DEFAULT=`sed -n '/^[0-9]/s/L//p' "$outpath/config.tests/common/c++default/c++default.ii"` + else + if [ "$OPT_VERBOSE" = "yes" ]; then + echo "Failed to run the preprocessor, something is wrong with your compiler" + fi + if [ "$CFG_CONFIGURE_EXIT_ON_ERROR" = "yes" ]; then + exit 101 + fi + fi +fi + # detect sse2 support if [ "${CFG_SSE2}" = "auto" ]; then if compileTest common/sse2 "sse2"; then @@ -6894,6 +6909,7 @@ fi if [ -n "$RPATH_FLAGS" ]; then echo "QMAKE_RPATHDIR += $RPATH_FLAGS" >> "$QTCONFIG.tmp" fi +echo "QT_COMPILER_STDCXX = $CFG_STDCXX_DEFAULT" >> "$QTCONFIG.tmp" if [ -n "$QT_GCC_MAJOR_VERSION" ]; then echo "QT_GCC_MAJOR_VERSION = $QT_GCC_MAJOR_VERSION" >> "$QTCONFIG.tmp" echo "QT_GCC_MINOR_VERSION = $QT_GCC_MINOR_VERSION" >> "$QTCONFIG.tmp" -- cgit v1.2.3 From e6a2ba708931d353bad4f399180d46116404aa2c Mon Sep 17 00:00:00 2001 From: Yoann Lopes Date: Tue, 25 Aug 2015 17:28:13 +0200 Subject: Prefer GStreamer 1.0 on Linux. As planned for 5.6, QtMultimedia now uses GStreamer 1.0 over 0.10 when available. This means the binary packages will be based on GStreamer 1.0. Task-number: QTBUG-47920 Change-Id: I9a18569ff96902116f0f6a759c185a5896f520d5 Reviewed-by: Lars Knoll --- configure | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'configure') diff --git a/configure b/configure index afe741c303..7f65377ac3 100755 --- a/configure +++ b/configure @@ -2690,7 +2690,7 @@ Additional options: -no-gstreamer ....... Do not support GStreamer. + -gstreamer Enable GStreamer support With no parameter, this will attempt to auto-detect GStreamer 0.10 and - 1.0. GStreamer 0.10 is used by default when available. + 1.0. GStreamer 1.0 is used by default when available. Use 0.10 or 1.0 for to override auto-detection. * -no-system-proxies .. Do not use system network proxies by default. @@ -6043,12 +6043,12 @@ fi # detect GStreamer support if [ "$CFG_GSTREAMER" = "auto" ] || [ "$CFG_GSTREAMER" = "yes" ]; then - if compileTest unix/gstreamer "GStreamer 0.10" -config gst-0.10; then - CFG_GSTREAMER=yes - CFG_GSTREAMER_VERSION=0.10 - elif compileTest unix/gstreamer "GStreamer 1.0" -config gst-1.0; then + if compileTest unix/gstreamer "GStreamer 1.0" -config gst-1.0; then CFG_GSTREAMER=yes CFG_GSTREAMER_VERSION=1.0 + elif compileTest unix/gstreamer "GStreamer 0.10" -config gst-0.10; then + CFG_GSTREAMER=yes + CFG_GSTREAMER_VERSION=0.10 else if [ "$CFG_GSTREAMER" = "yes" ]; then echo "GStreamer support cannot be enabled due to functionality tests!" -- cgit v1.2.3 From 4684c1afe5fdb3774d56d85a52b2feaab1b8de2c Mon Sep 17 00:00:00 2001 From: Thiago Macieira Date: Wed, 8 Jul 2015 17:21:30 -0700 Subject: Add detection of C++14 and C++1z compiler features [ChangeLog][General Improvements] Qt's buildsystem now detects whether the compiler supports C++14 and experimental support for C++1z. If the compiler supports it, then Qt is automatically compiled using that support. \ This does not apply to user applications built using qmake: those are still built with C++11 support only. To enable support for C++14 in your application, add to your .pro file: CONFIG += c++14 (similarly for C++1z). Change-Id: Ib056b47dde3341ef9a52ffff13ef1f5d01c42596 Reviewed-by: Lars Knoll --- configure | 97 ++++++++++++++++++++++++++++++++++++++++++++++++--------------- 1 file changed, 74 insertions(+), 23 deletions(-) (limited to 'configure') diff --git a/configure b/configure index 7f65377ac3..b188055143 100755 --- a/configure +++ b/configure @@ -769,7 +769,7 @@ CFG_SANITIZE_MEMORY=no CFG_SANITIZE_UNDEFINED=no CFG_PCRE=auto QPA_PLATFORM_GUARD=yes -CFG_CXX11=auto +CFG_STDCXX=auto CFG_DIRECTWRITE=no CFG_WERROR=auto CFG_HEADERSCLEAN=auto @@ -935,6 +935,7 @@ while [ "$#" -gt 0 ]; do -sdk| \ -arch| \ -host-arch| \ + -c++std | \ -mysql_config| \ -psql_config| \ -qpa| \ @@ -2234,12 +2235,31 @@ while [ "$#" -gt 0 ]; do fi ;; c++11) - if [ "$VAL" = "yes" ] || [ "$VAL" = "no" ]; then - CFG_CXX11="$VAL" + if [ "$VAL" = "yes" ]; then + CFG_STDCXX="c++11" + elif [ "$VAL" = "no" ]; then + CFG_STDCXX="c++98" else UNKNOWN_OPT=yes fi ;; + c++std) + case "$VAL" in + c++98|c++11|c++14|c++1z|auto) + CFG_STDCXX="$VAL" + ;; + 98|11|14|1z) + CFG_STDCXX="c++$VAL" + ;; + 1y|c++1y) + CFG_STDCXX="c++14" + ;; + *) + echo >&2 "Invalid C++ edition: $VAL; valid options are: c++98 c++11 c++14 c++1z auto" + ERROR=yes + ;; + esac + ;; system-proxies) if [ "$VAL" = "yes" ] || [ "$VAL" = "no" ]; then CFG_SYSTEM_PROXIES="$VAL" @@ -2411,8 +2431,8 @@ Configure options: -confirm-license ... Automatically acknowledge the license (use with either -opensource or -commercial) - -no-c++11 .......... Do not compile Qt with C++11 support enabled. - + -c++11 ............. Compile Qt with C++11 support enabled. + -c++std .. Compile Qt with C++ standard edition (c++98, c++11, c++14, c++1z) + Default: highest supported * -shared ............ Create and use shared Qt libraries. -static ............ Create and use static Qt libraries. @@ -4323,24 +4343,47 @@ if [ "$CFG_SEPARATE_DEBUG_INFO" = "yes" ]; then fi fi -# Detect C++11 support -if [ "$CFG_CXX11" != "no" ]; then - # Configure detects compiler features based on cross compiler, so we need - # to explicitly disable C++11 on Mac to avoid breaking builds where the - # host compiler does not support it. - if [ "$BUILD_ON_MAC" = "yes" ] && [ "$XPLATFORM_ANDROID" = "yes" ]; then - CFG_CXX11="no" - elif compileTest common/c++11 "C++11"; then - CFG_CXX11="yes" - elif [ "$CFG_CXX11" != "auto" ] && [ "$CFG_CONFIGURE_EXIT_ON_ERROR" = "yes" ]; then - echo "C++11 support cannot be enabled due to functionality tests!" - echo " Turn on verbose messaging (-v) to $0 to see the final report." - echo " If you believe this message is in error you may use the continue" - echo " switch (-continue) to $0 to continue." - exit 101 +# Detect C++11 & up support +# Configure detects compiler features based on cross compiler, so we need +# to explicitly disable C++11 on Mac to avoid breaking builds where the +# host compiler does not support it. +stdcxx_error=false +if [ "$BUILD_ON_MAC" = "yes" ] && [ "$XPLATFORM_ANDROID" = "yes" ]; then + CFG_STDCXX="c++98" +elif [ "$CFG_STDCXX" = "c++98" ]; then + : # CFG_STDCXX is correct +elif ! compileTest common/c++11 "C++11"; then + if [ "$CFG_STDCXX" != "auto" ]; then + stdcxx_error=true + else + CFG_STDCXX="c++98" + fi +elif [ "$CFG_STDCXX" = "c++11" ]; then + : # CFG_STDCXX is correct +elif ! compileTest common/c++14 "C++14"; then + if [ "$CFG_STDCXX" != "auto" ]; then + stdcxx_error=true else - CFG_CXX11="no" + CFG_STDCXX="c++11" fi +elif [ "$CFG_STDCXX" = "c++14" ]; then + : # CFG_STDCXX is correct +elif ! compileTest common/c++1z "C++1z"; then + if [ "$CFG_STDCXX" != "auto" ]; then + stdcxx_error=true + else + CFG_STDCXX="c++14" + fi +else + CFG_STDCXX="c++1z" +fi + +if $stdcxx_error && [ "$CFG_CONFIGURE_EXIT_ON_ERROR" = "yes" ]; then + echo "$CFG_STDCXX support cannot be enabled due to functionality tests!" + echo " Turn on verbose messaging (-v) to $0 to see the final report." + echo " If you believe this message is in error you may use the continue" + echo " switch (-continue) to $0 to continue." + exit 101 fi # Detect which edition of the C++ standard the compiler defaults to @@ -6086,7 +6129,15 @@ fi # ask for all that hasn't been auto-detected or specified in the arguments #------------------------------------------------------------------------------- -[ "$CFG_CXX11" = "yes" ] && QT_CONFIG="$QT_CONFIG c++11" +if [ "$CFG_STDCXX" != "c++98" ]; then + QT_CONFIG="$QT_CONFIG c++11" + if [ "$CFG_STDCXX" != "c++11" ]; then + QT_CONFIG="$QT_CONFIG c++14" + if [ "$CFG_STDCXX" != "c++14" ]; then + QT_CONFIG="$QT_CONFIG c++1z" + fi + fi +fi if [ "$CFG_SILENT" = "yes" ]; then QMAKE_CONFIG="$QMAKE_CONFIG silent" @@ -7104,7 +7155,7 @@ else fi unset build_mode release echo " Using sanitizer(s)...... $CFG_SANITIZERS" -echo " Using C++11 ............ $CFG_CXX11" +echo " Using C++ standard ..... $CFG_STDCXX" echo " Using gold linker....... $CFG_USE_GOLD_LINKER" echo " Using new DTAGS ........ $CFG_ENABLE_NEW_DTAGS" echo " Using PCH .............. $CFG_PRECOMPILE" -- cgit v1.2.3 From f58e95f098c8d78a5f2db7729606126fe093cbdf Mon Sep 17 00:00:00 2001 From: Oswald Buddenhagen Date: Thu, 4 Jun 2015 18:55:55 +0200 Subject: remove some mac multiarch vestiges ppc/ppc64 and 32-bit x86 have been dead for a while. consequently, the legacy macx-g++-64 spec was most probably not used. which in turn meant that NATIVE_64_ARCH was never set (in particular on windows hosts ...), which means that the android ndk host auto-detection was effectively broken. the arch code in mac/default_post.prf was also never triggered, so nuke it as well. Change-Id: Ic0775e40b273a22e0a15808cac328e0df33c2155 Reviewed-by: Joerg Bornemann Reviewed-by: Oswald Buddenhagen --- configure | 16 ++-------------- 1 file changed, 2 insertions(+), 14 deletions(-) (limited to 'configure') diff --git a/configure b/configure index b188055143..86571546fc 100755 --- a/configure +++ b/configure @@ -1404,18 +1404,6 @@ while [ "$#" -gt 0 ]; do unixware7-g++) PLATFORM=unixware-g++ ;; - macx-g++-64) - PLATFORM=macx-g++ - NATIVE_64_ARCH= - case `uname -p` in - i386) NATIVE_64_ARCH="x86_64" ;; - powerpc) NATIVE_64_ARCH="ppc64" ;; - *) echo "WARNING: Can't detect CPU architecture for macx-g++-64" ;; - esac - if [ ! -z "$NATIVE_64_ARCH" ]; then - QTCONFIG_CONFIG="$QTCONFIG_CONFIG $NATIVE_64_ARCH" - fi - ;; esac ;; xplatform) @@ -3199,13 +3187,13 @@ if [ "$XPLATFORM_ANDROID" = "yes" ]; then ;; macx-*) CFG_DEFAULT_ANDROID_NDK_HOST=darwin-x86 - if [ ! -z "$NATIVE_64_ARCH" ] && [ -d "$CFG_DEFAULT_ANDROID_NDK_ROOT/toolchains/arm-linux-androideabi-$CFG_DEFAULT_ANDROID_NDK_TOOLCHAIN_VERSION/prebuilt/darwin-x86_64" ]; then + if [ -d "$CFG_DEFAULT_ANDROID_NDK_ROOT/toolchains/arm-linux-androideabi-$CFG_DEFAULT_ANDROID_NDK_TOOLCHAIN_VERSION/prebuilt/darwin-x86_64" ]; then CFG_DEFAULT_ANDROID_NDK_HOST=darwin-x86_64 fi ;; win32-*) CFG_DEFAULT_ANDROID_NDK_HOST=windows - if [ ! -z "$NATIVE_64_ARCH" ] && [ -d "$CFG_DEFAULT_ANDROID_NDK_ROOT/toolchains/arm-linux-androideabi-$CFG_DEFAULT_ANDROID_NDK_TOOLCHAIN_VERSION/prebuilt/windows-x86_64" ]; then + if [ -d "$CFG_DEFAULT_ANDROID_NDK_ROOT/toolchains/arm-linux-androideabi-$CFG_DEFAULT_ANDROID_NDK_TOOLCHAIN_VERSION/prebuilt/windows-x86_64" ]; then CFG_DEFAULT_ANDROID_NDK_HOST=windows-x86_64 fi ;; -- cgit v1.2.3 From 3d7586b760550b7d89594c8d7462fc30b868ecc6 Mon Sep 17 00:00:00 2001 From: Thiago Macieira Date: Tue, 8 Sep 2015 20:35:33 -0300 Subject: Auto-detect whether 64-bit std::atomic really works The C++ standard says it must, but some badly-configured toolchains seem to be lacking support. In particular, for some 32-bit platforms without native support for them, GCC implements 64-bit atomics via out-of-line functions in libatomic. If that library is missing... well, then std::atomic 64-bit doesn't work and we mustn't try to use it. This was found when trying to compile Qt 5.6 for MIPS 32-bit: Linking library libQt5Core.so.5.6.0 .obj/qsimd.o: In function `std::__atomic_base::load(std::memory_order) const': /opt/poky/1.7/sysroots/mips32r2-poky-linux/usr/include/c++/4.9.1/bits/atomic_base.h:500: undefined reference to `__atomic_load_8' .obj/qsimd.o: In function `std::__atomic_base::store(unsigned long long, std::memory_order)': /opt/poky/1.7/sysroots/mips32r2-poky-linux/usr/include/c++/4.9.1/bits/atomic_base.h:478: undefined reference to `__atomic_store_8' Yocto bug report: https://bugzilla.yoctoproject.org/show_bug.cgi?id=8274 Change-Id: I42e7ef1a481840699a8dffff140224d6614e5c36 Reviewed-by: Oswald Buddenhagen Reviewed-by: Lars Knoll Reviewed-by: Thiago Macieira --- configure | 20 +++++++++++++++++++- 1 file changed, 19 insertions(+), 1 deletion(-) (limited to 'configure') diff --git a/configure b/configure index 86571546fc..fcfe8b957f 100755 --- a/configure +++ b/configure @@ -2,7 +2,7 @@ ############################################################################# ## ## Copyright (C) 2015 The Qt Company Ltd. -## Copyright (C) 2013 Intel Corporation. +## Copyright (C) 2015 Intel Corporation. ## Contact: http://www.qt.io/licensing/ ## ## This file is the build configuration utility of the Qt Toolkit. @@ -662,6 +662,7 @@ CFG_SYSTEM_PROXIES=no CFG_ANDROID_STYLE_ASSETS=yes CFG_GSTREAMER=auto CFG_GSTREAMER_VERSION="" +CFG_ATOMIC64=auto # Target architecture CFG_ARCH= @@ -4389,6 +4390,15 @@ if compileTest common/c++default "default C++ standard edition"; then fi fi +# Detect whether 64-bit std::atomic works -- some 32-bit platforms require extra library support +if compileTest common/atomic64 "64-bit std::atomic"; then + CFG_ATOMIC64=yes +elif compileTest common/atomic64 "64-bit std::atomic in -latomic" -latomic; then + CFG_ATOMIC64=libatomic +else + CFG_ATOMIC64=no +fi + # detect sse2 support if [ "${CFG_SSE2}" = "auto" ]; then if compileTest common/sse2 "sse2"; then @@ -6127,6 +6137,10 @@ if [ "$CFG_STDCXX" != "c++98" ]; then fi fi +if [ "$CFG_ATOMIC64" = "libatomic" ]; then + QMAKE_CONFIG="$QMAKE_CONFIG atomic64-libatomic" +fi + if [ "$CFG_SILENT" = "yes" ]; then QMAKE_CONFIG="$QMAKE_CONFIG silent" fi @@ -6681,6 +6695,10 @@ else echo "#define QT_POINTER_SIZE $?" >>"$outpath/src/corelib/global/qconfig.h.new" fi +if [ "$CFG_ATOMIC64" = "no" ]; then + echo "#define QT_NO_STD_ATOMIC64" >> "$outpath/src/corelib/global/qconfig.h.new" +fi + #REDUCE_RELOCATIONS is a elf/unix only thing, so not in windows configure.exe if [ "$CFG_REDUCE_RELOCATIONS" = "yes" ]; then echo "#define QT_REDUCE_RELOCATIONS" >>"$outpath/src/corelib/global/qconfig.h.new" -- cgit v1.2.3