2020-07-01 15:42:07 +00:00
|
|
|
The following table describes the mapping of configure options to CMake arguments.
|
|
|
|
Note that not everything is implemented in configure/configure.bat yet.
|
|
|
|
The effort of this is tracked in QTBUG-85373 and QTBUG-85349.
|
|
|
|
|
|
|
|
| configure | cmake | Notes |
|
|
|
|
|---------------------------------------|---------------------------------------------------|-----------------------------------------------------------------|
|
|
|
|
| -prefix /opt/qt6 | -DCMAKE_INSTALL_PREFIX=/opt/qta6 | |
|
|
|
|
| -extprefix /opt/qt6 | -DCMAKE_STAGING_PREFIX=/opt/qt6 | |
|
|
|
|
| -hostprefix /where/ever | n/a | When cross-building Qt, we do not build for host system anymore |
|
|
|
|
| -external-hostbindir /path/to/host/qt | -DQT_HOST_PATH=/path/to/host/qt | |
|
|
|
|
| -bindir <dir> | -DINSTALL_BINDIR=<dir> | similar for -headerdir -libdir and so on |
|
|
|
|
| -host*dir <dir> | n/a | |
|
2020-07-02 09:25:28 +00:00
|
|
|
| -help | n/a | Handled by configure[.bat]. |
|
2020-07-01 15:42:07 +00:00
|
|
|
| -verbose | | |
|
|
|
|
| -continue | | |
|
2020-07-02 09:25:28 +00:00
|
|
|
| -redo | n/a | Handled by configure[.bat]. |
|
2020-07-01 15:42:07 +00:00
|
|
|
| -recheck [test,...] | | |
|
|
|
|
| -feature-foo | -DFEATURE_foo=ON | |
|
|
|
|
| -no-feature-foo | -DFEATURE_foo=OFF | |
|
|
|
|
| -list-features | | At the moment: configure with cmake once, |
|
|
|
|
| | | then use ccmake or cmake-gui to inspect the features. |
|
|
|
|
| -list-libraries | | |
|
|
|
|
| -opensource | | |
|
|
|
|
| -commercial | | |
|
|
|
|
| -confirm-license | | |
|
2020-07-02 09:25:28 +00:00
|
|
|
| -release | -DCMAKE_BUILD_TYPE=Release | |
|
|
|
|
| -debug | -DCMAKE_BUILD_TYPE=Debug | |
|
|
|
|
| -debug-and-release | -G "Ninja Multi-Config" | |
|
|
|
|
| | -DCMAKE_CONFIGURATION_TYPES=Release;Debug | |
|
2020-08-20 13:19:07 +00:00
|
|
|
| -optimize-debug | -DFEATURE_optimize_debug=ON | |
|
2020-08-21 06:40:54 +00:00
|
|
|
| -optimize-size | -DFEATURE_optimize_size=ON | |
|
2020-08-20 13:19:07 +00:00
|
|
|
| -optimized-tools | n/a | This affects only host tools. |
|
2020-07-02 09:25:28 +00:00
|
|
|
| -force-debug-info | Use the RelWithDebInfo build config. | |
|
|
|
|
| -separate-debug-info | -DFEATURE_separate_debug_info=ON | |
|
2020-08-21 07:22:23 +00:00
|
|
|
| -gdb-index | -DFEATURE_enable_gdb_index=ON | |
|
2020-08-21 19:33:07 +00:00
|
|
|
| -strip | cmake --install . --strip | This affects the install targets generated by qmake. |
|
2020-07-02 09:25:28 +00:00
|
|
|
| -gc-binaries | -DFEATURE_gc_binaries=ON | |
|
2020-08-24 08:39:49 +00:00
|
|
|
| -force-asserts | -DFEATURE_force_asserts=ON | |
|
2020-07-02 09:25:28 +00:00
|
|
|
| -developer-build | -DFEATURE_developer_build=ON | |
|
|
|
|
| -shared | -DBUILD_SHARED_LIBS=ON | |
|
|
|
|
| -static | -DBUILD_SHARED_LIBS=OFF | |
|
|
|
|
| -framework | -DFEATURE_framework=ON | |
|
|
|
|
| -platform <target> | -DQT_QMAKE_TARGET_MKSPEC=<mkspec> | |
|
|
|
|
| -xplatform <target> | -DQT_QMAKE_TARGET_MKSPEC=<mkspec> | Only used for generating qmake-compatibility files. |
|
2020-07-01 15:42:07 +00:00
|
|
|
| -device <name> | equivalent to -xplatform devices/<name> | |
|
|
|
|
| -device-option <key=value> | -DQT_QMAKE_DEVICE_OPTIONS=key1=value1;key2=value2 | Only used for generation qmake-compatibility files. |
|
|
|
|
| | | The device options are written into mkspecs/qdevice.pri. |
|
2020-08-21 19:33:07 +00:00
|
|
|
| -appstore-compliant | -DFEATURE_appstore_compliant=ON | |
|
2020-07-02 09:25:28 +00:00
|
|
|
| -qtnamespace <name> | -DQT_NAMESPACE=<name> | |
|
2020-09-21 13:45:28 +00:00
|
|
|
| -qtlibinfix <infix> | -DQT_LIBINFIX=<infix> | |
|
2020-07-01 15:42:07 +00:00
|
|
|
| -testcocoon | | |
|
|
|
|
| -gcov | | |
|
2020-08-24 19:05:05 +00:00
|
|
|
| -trace [backend] | -DINPUT_trace=yes or -DINPUT_trace=<backend> | |
|
|
|
|
| | or -DFEATURE_<backend> | |
|
2020-07-02 09:25:28 +00:00
|
|
|
| -sanitize <arg> | -DFEATURE_sanitize_<arg> | |
|
|
|
|
| -coverage <arg> | | |
|
|
|
|
| -c++std c++2a | -DFEATURE_cxx2a=ON | |
|
2020-08-21 19:33:07 +00:00
|
|
|
| -sse2/-sse3/-ssse3/-sse4.1 | -DFEATURE_sse4=ON | |
|
|
|
|
| -mips_dsp/-mips_dspr2 | -DFEATURE_mips_dsp=ON | |
|
2020-08-18 08:59:03 +00:00
|
|
|
| -qreal <type> | -DQT_COORD_TYPE=<type> | |
|
2020-07-02 09:25:28 +00:00
|
|
|
| -R <string> | -DQT_EXTRA_RPATHS=path1;path2 | |
|
|
|
|
| -rpath | negative CMAKE_SKIP_BUILD_RPATH | |
|
|
|
|
| | negative CMAKE_SKIP_INSTALL_RPATH | |
|
2020-07-01 15:42:07 +00:00
|
|
|
| -reduce-exports | | |
|
2020-07-02 09:25:28 +00:00
|
|
|
| -reduce-relocations | -DFEATURE_reduce_relocations=ON | |
|
2020-07-01 15:42:07 +00:00
|
|
|
| -plugin-manifests | | |
|
2020-07-02 09:25:28 +00:00
|
|
|
| -static-runtime | -DFEATURE_static_runtime=ON | |
|
|
|
|
| -pch | -DBUILD_WITH_PCH=ON | |
|
2020-08-27 12:11:00 +00:00
|
|
|
| -ltcg | -DCMAKE_INTERPROCEDURAL_OPTIMIZATION=ON or | |
|
|
|
|
| | -DCMAKE_INTERPROCEDURAL_OPTIMIZATION_<CONFIG>=ON | |
|
2020-08-20 07:06:16 +00:00
|
|
|
| -linker [bfd,gold,lld] | -DINPUT_linker=<name> or | |
|
|
|
|
| | -DFEATURE_use_<name>_linker=ON | |
|
2020-08-21 19:33:07 +00:00
|
|
|
| -incredibuild-xge | n/a | This option enables remote distribution of Visual Studio |
|
|
|
|
| | | custom build steps for moc, uic, and rcc. |
|
|
|
|
| | | This lacks support in CMake. |
|
2020-07-01 15:42:07 +00:00
|
|
|
| -ccache | -DQT_USE_CCACHE=ON | |
|
|
|
|
| -make-tool <tool> | n/a | |
|
|
|
|
| -mp | n/a | |
|
2020-07-02 09:25:28 +00:00
|
|
|
| -warnings-are-errors | -DWARNINGS_ARE_ERRORS=ON or | |
|
|
|
|
| | -DFEATURE_warnings_are_errors=ON | |
|
|
|
|
| -silent | n/a | |
|
2020-07-01 15:42:07 +00:00
|
|
|
| -sysroot <dir> | -DCMAKE_SYSROOT=<dir> | Should be provided by a toolchain file that's |
|
|
|
|
| | | passed via -DCMAKE_TOOLCHAIN_FILE=<filename> |
|
2020-08-21 19:33:07 +00:00
|
|
|
| -no-gcc-sysroot | n/a | The corresponding CMake variables are CMAKE_SYSROOT_LINK |
|
|
|
|
| | | and CMAKE_SYSROOT_COMPILE. |
|
|
|
|
| | | They are usually set in a toolchain file. |
|
|
|
|
| -no-pkg-config | -DFEATURE_pkg_config=OFF | |
|
2020-08-13 12:36:50 +00:00
|
|
|
| -D <string> | -DQT_EXTRA_DEFINES=<string1>;<string2> | |
|
|
|
|
| -I <string> | -DQT_EXTRA_INCLUDEPATHS=<string1>;<string2> | |
|
|
|
|
| -L <string> | -DQT_EXTRA_LIBDIRS=<string1>;<string2> | |
|
|
|
|
| -F <string> | -DQT_EXTRA_FRAMEWORKPATHS=<string1>;<string2> | |
|
2020-07-01 15:42:07 +00:00
|
|
|
| -sdk <sdk> | | |
|
|
|
|
| -android-sdk path | | |
|
|
|
|
| -android-ndk path | | |
|
|
|
|
| -android-ndk-platform | | |
|
|
|
|
| -android-ndk-host | | |
|
|
|
|
| -android-abis | | |
|
|
|
|
| -android-style-assets | | |
|
2020-09-11 17:28:01 +00:00
|
|
|
| -android-javac-source | -DQT_ANDROID_JAVAC_SOURCE=7 | Set the javac build source version. |
|
|
|
|
| -android-javac-target | -DQT_ANDROID_JAVAC_TARGET=7 | Set the javac build target version. |
|
2020-07-02 09:25:28 +00:00
|
|
|
| -skip <repo> | -DBUILD_<repo>=OFF | |
|
|
|
|
| -make <part> | -DBUILD_TESTING=ON | A way to turn on tools explicitly is missing. |
|
|
|
|
| | -DBUILD_EXAMPLES=ON | |
|
|
|
|
| -nomake <part> | -DBUILD_TESTING=OFF | A way to turn off tools explicitly is missing. |
|
|
|
|
| | -DBUILD_EXAMPLES=OFF | |
|
2020-08-21 19:33:07 +00:00
|
|
|
| -no-gui | | |
|
|
|
|
| -no-widgets | -DFEATURE_widgets=OFF | |
|
|
|
|
| -no-dbus | -DFEATURE_dbus=OFF | |
|
|
|
|
| -dbus [linked/runtime] | -DINPUT_dbus=[linked/runtime] | |
|
|
|
|
| -dbus-linked | -DINPUT_dbus=linked | |
|
|
|
|
| -dbus-runtime | -DINPUT_dbus=runtime | |
|
|
|
|
| -accessibility | -DFEATURE_accessibility=ON | |
|
|
|
|
| -doubleconversion | -DFEATURE_doubleconversion=ON | |
|
|
|
|
| | -DFEATURE_system_doubleconversion=ON/OFF | |
|
|
|
|
| -glib | -DFEATURE_glib=ON | |
|
|
|
|
| -eventfd | -DFEATURE_eventfd=ON | |
|
|
|
|
| -inotify | -DFEATURE_inotify=ON | |
|
|
|
|
| -icu | -DFEATURE_icu=ON | |
|
|
|
|
| -pcre | -DFEATURE_pcre2=ON | |
|
|
|
|
| -pcre [system/qt] | -DFEATURE_system_pcre2=ON/OFF | |
|
|
|
|
| -pps | n/a | QNX feature. Not available for 6.0. |
|
|
|
|
| -zlib [system/qt] | -DFEATURE_system_zlib=ON/OFF | |
|
|
|
|
| -ssl | -DFEATURE_ssl=ON | |
|
|
|
|
| -openssl [no/yes/linked/runtime] | -DINPUT_openssl=no/yes/linked/runtime | |
|
|
|
|
| -openssl-linked | -DINPUT_openssl=linked | |
|
|
|
|
| -openssl-runtime | -DINPUT_openssl=runtime | |
|
|
|
|
| -schannel | -DFEATURE_schannel=ON | |
|
|
|
|
| -securetransport | -DFEATURE_securetransport=ON | |
|
|
|
|
| -sctp | -DFEATURE_sctp=ON | |
|
|
|
|
| -libproxy | -DFEATURE_libproxy=ON | |
|
|
|
|
| -system-proxies | -DFEATURE_system_proxies=ON | |
|
|
|
|
| -cups | -DFEATURE_cups=ON | |
|
|
|
|
| -fontconfig | -DFEATURE_fontconfig=ON | |
|
|
|
|
| -freetype [no/qt/system] | -DFEATURE_freetype=ON/OFF | |
|
|
|
|
| | -DFEATURE_system_freetype=ON/OFF | |
|
|
|
|
| -harfbuzz [no/qt/system] | -DFEATURE_harfbuzz=ON | |
|
|
|
|
| | -DFEATURE_system_harfbuzz=ON/OFF | |
|
|
|
|
| -gtk | -DFEATURE_gtk3=ON | |
|
|
|
|
| -lgmon | n/a | QNX-specific |
|
2020-07-01 15:42:07 +00:00
|
|
|
| -no-opengl | | |
|
|
|
|
| -opengl <api> | | |
|
|
|
|
| -opengles3 | | |
|
|
|
|
| -egl | | |
|
2020-08-28 13:38:30 +00:00
|
|
|
| -qpa <name> | -DQT_QPA_DEFAULT_PLATFORM=<name> | |
|
2020-08-21 19:33:07 +00:00
|
|
|
| -xcb-xlib | -DFEATURE_xcb_xlib=ON | |
|
|
|
|
| -direct2d | -DFEATURE_direct2d=ON | |
|
|
|
|
| -directfb | -DFEATURE_directfb=ON | |
|
|
|
|
| -eglfs | -DFEATURE_eglfs=ON | |
|
|
|
|
| -gbm | -DFEATURE_gbm=ON | |
|
|
|
|
| -kms | -DFEATURE_kms=ON | |
|
|
|
|
| -linuxfb | -DFEATURE_linuxfb=ON | |
|
|
|
|
| -xcb | -DFEATURE_xcb=ON | |
|
|
|
|
| -libudev | -DFEATURE_libudev=ON | |
|
|
|
|
| -evdev | -DFEATURE_evdev=ON | |
|
|
|
|
| -imf | n/a | QNX-specific |
|
|
|
|
| -libinput | -DFEATURE_libinput=ON | |
|
|
|
|
| -mtdev | -DFEATURE_mtdev=ON | |
|
2020-08-20 13:19:07 +00:00
|
|
|
| -tslib | -DFEATURE_tslib=ON | |
|
2020-08-21 19:33:07 +00:00
|
|
|
| -bundled-xcb-xinput | -DFEATURE_system_xcb_xinput=OFF | |
|
|
|
|
| -xkbcommon | -DFEATURE_xkbcommon=ON | |
|
|
|
|
| -gif | -DFEATURE_gif=ON | |
|
|
|
|
| -ico | -DFEATURE_ico=ON | |
|
|
|
|
| -libpng | -DFEATURE_libpng=ON | |
|
|
|
|
| -libjpeg | -DFEATURE_libjpeg=ON | |
|
|
|
|
| -sql-<driver> | -DFEATURE_sql_<driver>=ON | |
|
|
|
|
| -sqlite [qt/system] | -DFEATURE_system_sqlite=OFF/ON | |
|