Qt-configure配置选项

这个页面给出了一个简短的,当使用configure脚本或configure.exe二进制构建Qt时的各种不同的可用选项。当使用默认选项构建Qt,只需如下所示的从命令行调用configure。

在Linux、Mac OS X和Unix平台下构建Qt:

. / configure

在Windows上,运行相应的可执行:

./configure.exe

如果你想定制的构建Qt,请使用下面的表中列出的选项。如要查看完整的选项列表,可调用./configure的- help命令行选项。


跨平台的选项:


编译和链接两个Qt库,调试的打开情况
OptionDescriptionNote
-buildkey <key>用指定的库和插件来构建Qt 
<key>当库加载插件,它只会加载那些有一个匹配的<key>。 
-release在调试关掉的情况下编译和链接Qt 
-debug在调试打开的情况下编译和链接Qt默认打开
-debug-and-release这个选项代表一个默认值,需要评估。如果评价成功,特点是包括。
-opensource编译和链接开源版的Qt. 
-commercial编译和链接的商业版的Qt。 
-developer-build编译和链接Qt 与 Qt 开发选项Qt(包括自动测试出口) 
-shared创建和使用共享Qt库。默认打开
-static创建和使用静态Qt库。 
-ltcg生成链接时间代码。只适用于发布版本。
-no-ltcg不生成链接时间代码。默认打开
-no-fast通过生成makefile 为Qt所配置有项目文件。默认打开
-fast快速的生成makefile为Qt只配置库和子目录。所有其他的makefile通过运行qmake来创建。
-no-exceptions不支持交叉编译平台上 
-exceptions支持交叉编译默认打开
-no-accessibility不支持访问编译窗口 
-accessibility支持访问编译窗口默认打开
-no-stl不支持STL编译 
-stl支持STL编译默认打开
-no-sql-<driver>完全禁用SQL <驱动>,默认情况下没有打开。 
-qt-sql-<driver>在Qt库中启用SQL <驱动>. 
-plugin-sql-<driver>Enable SQL <driver> as a plugin to be linked to at run time.Available values for <driver>: mysql, psql, oci, odbc, tds, db2, sqlite, sqlite2, ibase. Drivers marked with a '+' during configure have been detected as available on this system.
-system-sqliteUse sqlite from the operating system. 
-no-qt3supportDisables the Qt 3 support functionality. 
-no-openglDisables OpenGL functionality 
-opengl <api>Enable OpenGL support with specified API version.Available values for <api>: desktop - Enable support for Desktop OpenGL (Default), es1 - Enable support for OpenGL ES Common Profile, es2 - Enable support for OpenGL ES 2.0.
-no-openvgDisables OpenVG functionalityDefault value.
-openvgEnables OpenVG functionalityRequires EGL support, typically supplied by an OpenGL or other graphics implementation.
-platform <spec>The operating system and compiler you are building on.The default value is %QMAKESPEC%.
-xplatform <spec>The operating system and compiler you are cross compiling for.See the README file for a list of supported operating systems and compilers.
-system-proxiesUse system network proxies by default. 
-no-system-proxiesDo not use system network proxies by default. 
-qtnamespace <namespace>Wraps all Qt library code in 'namespace name {..} 
-qtlibinfix <infix>Renames all Qt* libs to Qt*<infix> 
-D <define>Add an explicit define to the preprocessor. 
-I <includepath>Add an explicit include path. 
-L <librarypath>Add an explicit library path. 
-l <libraryname>Add an explicit library name, residing in a librarypath. 
-graphicssystem <sys>Specify which graphics system should be used.Available values for <sys>: * raster - Software rasterizer, opengl - Using OpenGL acceleration, experimental!, openvg - Using OpenVG acceleration, experimental!
-help, -h, -?Display this information. 


Third Party Libraries

OptionDescriptionNote
-qt-zlibUse the zlib bundled with Qt. 
-system-zlibUse zlib from the operating system.See http://www.gzip.org/zlib
-no-gifDo not compile GIF reading support.This option denotes a default value and needs to be evaluated. If the evaluation succeeds, the feature is included.
-no-libpngDo not compile PNG support. 
-qt-libpngUse the libpng bundled with Qt.This option denotes a default value and needs to be evaluated. If the evaluation succeeds, the feature is included.
-system-libpngUse libpng from the operating system.See http://www.libpng.org/pub/png
-no-libmngDo not compile MNG support.This option denotes a default value and needs to be evaluated. If the evaluation succeeds, the feature is included.
-qt-libmngUse the libmng bundled with Qt. 
-system-libmngUse libmng from the operating system.See http://www.libmng.com
-no-libtiffDo not compile TIFF support.This option denotes a default value and needs to be evaluated. If the evaluation succeeds, the feature is included.
-qt-libtiffUse the libtiff bundled with Qt. 
-system-libtiffUse libtiff from the operating system.See http://www.libtiff.org
-no-libjpegDo not compile JPEG support.This option denotes a default value and needs to be evaluated. If the evaluation succeeds, the feature is included.
-qt-libjpegUse the libjpeg bundled with Qt. 
-system-libjpegUse libjpeg from the operating system.See http://www.ijg.org. This option denotes a default value and needs to be evaluated. If the evaluation succeeds, the feature is included.

Qt for Windows only:

OptionDescriptionNote
-no-dspDo not generate VC++ .dsp files. 
-dspGenerate VC++ .dsp files, only if spec "win32-msvc".Default value.
-no-vcprojDo not generate VC++ .vcproj files. 
-vcprojGenerate VC++ .vcproj files, only if platform "win32-msvc.net".Default value.
-no-incredibuild-xgeDo not add IncrediBuild XGE distribution commands to custom build steps. 
-incredibuild-xgeAdd IncrediBuild XGE distribution commands to custom build steps. This will distribute MOC and UIC steps, and other custom buildsteps which are added to the INCREDIBUILD_XGE variable.The IncrediBuild distribution commands are only added to Visual Studio projects. This option denotes a default value and needs to be evaluated. If the evaluation succeeds, the feature is included.
-no-plugin-manifestsDo not embed manifests in plugins. 
-plugin-manifestsEmbed manifests in plugins.Default value.
-no-qmakeDo not compile qmake. 
-qmakeCompile qmake.Default value
-dont-processDo not generate Makefiles/Project files. This will override -no-fast if specified. 
-processGenerate Makefiles/Project files.Default value.
-no-rttiDo not compile runtime type information. 
-rttiCompile runtime type information.Default value.
-no-mmxDo not compile with use of MMX instructions 
-mmxCompile with use of MMX instructionsThis option denotes a default value and needs to be evaluated. If the evaluation succeeds, the feature is included.
-no-3dnowDo not compile with use of 3DNOW instructions 
-3dnowCompile with use of 3DNOW instructionsThis option denotes a default value and needs to be evaluated. If the evaluation succeeds, the feature is included.
-no-sseDo not compile with use of SSE instructions 
-sseCompile with use of SSE instructionsThis option denotes a default value and needs to be evaluated. If the evaluation succeeds, the feature is included.
-no-sse2Do not compile with use of SSE2 instructions 
-sse2Compile with use of SSE2 instructionsThis option denotes a default value and needs to be evaluated. If the evaluation succeeds, the feature is included.
-no-opensslDo not compile in OpenSSL support 
-opensslCompile in run-time OpenSSL supportThis option denotes a default value and needs to be evaluated. If the evaluation succeeds, the feature is included.
-openssl-linkedCompile in linked OpenSSL support 
-no-dbusDo not compile in D-Bus support 
-dbusCompile in D-Bus support and load libdbus-1 dynamically.This option denotes a default value and needs to be evaluated. If the evaluation succeeds, the feature is included.
-dbus-linkedCompile in D-Bus support and link to libdbus-1 
-no-phononDo not compile in the Phonon module 
-phononCompile the Phonon module.Phonon is built if a decent C++ compiler is used. This option denotes a default value and needs to be evaluated. If the evaluation succeeds, the feature is included.
-no-phonon-backendDo not compile the platform-specific Phonon backend-plugin 
-phonon-backendCompile in the platform-specific Phonon backend-pluginDefault value.
-no-multimediaDo not compile the multimedia module 
-multimediaCompile in multimedia moduleDefault value.
-no-audio-backendDo not compile in the platform audio backend into QtMultimedia 
-audio-backendCompile in the platform audio backend into QtMultimediaThis option denotes a default value and needs to be evaluated. If the evaluation succeeds, the feature is included.
-no-webkitDo not compile in the WebKit module 
-webkitCompile in the WebKit moduleWebKit is built if a decent C++ compiler is used. This option denotes a default value and needs to be evaluated. If the evaluation succeeds, the feature is included.
-webkit-debugCompile in the WebKit module with debug symbols. 
-no-scriptDo not build the QtScript module. 
-scriptBuild the QtScript module.This option denotes a default value and needs to be evaluated. If the evaluation succeeds, the feature is included.
-no-scripttoolsDo not build the QtScriptTools module. 
-scripttoolsBuild the QtScriptTools module.This option denotes a default value and needs to be evaluated. If the evaluation succeeds, the feature is included.
-no-declarativeDo not build the declarative module 
-declarativeBuild the declarative moduleThis option denotes a default value and needs to be evaluated. If the evaluation succeeds, the feature is included.
-no-declarative-debugDo not build the declarative debugging support 
-declarative-debugBuild the declarative debugging supportDefault value.
-arch <arch>Specify an architecture.Available values for <arch>: * windows, windowsce, symbian, boundschecker, generic.
-no-style-<style>Disable <style> entirely. 
-qt-style-<style>Enable <style> in the Qt Library.Available styles: * windows, + windowsxp, + windowsvista, * plastique, * cleanlooks, * motif, * cde, windowsce, windowsmobile, s60
-no-native-gesturesDo not use native gestures on Windows 7. 
-native-gesturesUse native gestures on Windows 7.Default value.
-no-mpDo not use multiple processors for compiling with MSVCDefault value.
-mpUse multiple processors for compiling with MSVC (-MP) 
-loadconfig <config>Run configure with the parameters from file configure_<config>.cache. 
-saveconfig <config>Run configure and save the parameters in file configure_<config>.cache. 
-redoRun configure with the same parameters as last time. 

Qt for Windows CE only:

OptionDescriptionNote
-no-iwmmxtDo not compile with use of IWMMXT instructions 
-iwmmxtDo compile with use of IWMMXT instructions.This is for Qt for Windows CE on Arm only. This option denotes a default value and needs to be evaluated. If the evaluation succeeds, the feature is included.
-no-crtDo not add the C runtime to default deployment rules.Default value.
-qt-crtQt identifies C runtime during project generation 
-crt <path>Specify path to C runtime used for project generation. 
-no-cetestDo not compile Windows CE remote test application 
-cetestCompile Windows CE remote test applicationThis option denotes a default value and needs to be evaluated. If the evaluation succeeds, the feature is included.
-signature <file>Use file for signing the target project 
-phonon-wince-ds9Enable Phonon Direct Show 9 backend for Windows CEDefault value

Qt for Symbian OS only:

OptionDescriptionNote
-no-freetypeDo not compile in Freetype2 support.Default value.
-qt-freetypeUse the libfreetype bundled with Qt. 
-fpu <flags>VFP type on ARM, supported options: softvfp(default) |vfpv2 | softvfp+vfpv2 
-no-s60Do not compile in S60 support. 
-s60Compile with support for the S60 UI FrameworkDefault value.
-no-usedeffilesDisable the usage of DEF files. 
-usedeffilesEnable the usage of DEF files. 

  • 1
    点赞
  • 7
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
### 回答1: Qt Configure Project是一个用于配置Qt项目的工具。它可以帮助开发者在不同的平台上配置和构建Qt项目,包括Windows、Linux、Mac OS X等。使用Qt Configure Project可以方便地设置Qt库的路径、编译器、构建选项等参数,以满足不同的需求。同时,Qt Configure Project还支持自定义配置,可以根据项目的具体情况进行灵活的配置。 ### 回答2: Qt是一款非常优秀的跨平台应用程序开发框架,其提供了许多强大的工具和函数库,可以使程序开发变得更加简便和高效。 在使用Qt开发应用程序时,我们需要使用Qt配置工具,来对我们的项目进行一些基本的配置,以确保程序的稳定性和兼容性。 Qt配置工具主要有两种方式:一种是使用Qt Creator自带的配置工具,另外一种是使用命令行工具来进行配置。下面将简单介绍Qt项目的配置过程。 1.使用Qt Creator配置工具 在使用Qt Creator开发项目时,我们可以直接使用其自带的配置工具。具体操作步骤如下: 打开Qt Creator,选择File -> New File or Project -> Qt Console Application(或者其他类型的Qt项目),然后点击Next。 在Name and Location下,输入项目的名称和存储的位置,然后点击Next。 在Kit Selection下,选择你的Kit,然后点击Next。 在Project Settings下,主要配置以下内容: 选择Build System,可以选择使用qmake或者CMake进行项目构建。 配置C++编译器和调试器,选择预定义的或者自定义的编译器和调试器。 设置构建的文件夹和构建类型,可以选择Debug或Release模式。 配置构建步骤,例如添加自定义编译命令等。 设置项目Custom Executable,为项目添加可执行文件路径,用于在Qt Creator中执行程序。 最后,点击Finish按钮,完成Qt项目的基本配置。 2.使用命令行工具配置 在使用命令行工具进行Qt项目的配置时,主要使用的是qmake命令。下面是一些基本的操作命令: qmake:生成Makefile文件。 make:使用Makefile文件进行编译项目。 make clean:清除编译出的对象文件和可执行文件。 qmake可以根据.pro文件自动生成Makefile文件,同时还可以指定构建类型和生成的目标文件夹等选项,在使用时需要进行相应的配置和参数设置。 总的来说,Qt配置工具能够对我们的开发过程产生很大的帮助,如果我们能够根据实际需要合理地配置项目,那么就可以提高项目的开发效率和质量。 ### 回答3: Qt 是一个跨平台的 C++ 开发框架,Qt 项目的配置是开发 Qt 应用程序的一部分。Qt 项目的配置可以通过 Qt Creator 集成开发环境或命令行进行。这里主要介绍通过命令行进行 Qt 项目配置的过程。 Qt 项目配置的基本命令是 ./configure。在 Linux 系统中,通常需要在终端中进入 Qt 的源代码根目录,然后输入 ./configure 命令来配置 Qt 项目。但是在 Windows 系统中,需要先打开 Qt 开发者命令提示符,然后进入 Qt 的源代码根目录,最后输入 ./configure 命令来进行配置。 ./configure 命令有很多选项,可以根据不同的需求进行配置。比如,可以指定 Qt 的安装路径、编译选项、平台选项、功能选项等等。其中一些常用的选项包括: -prefix:指定 Qt 的安装路径。 -debug:指定 Qt 的调试版本编译选项。 -release:指定 Qt 的发布版本编译选项。 -opensource:指定 Qt 开放源代码编译选项。 -no-gui:指定不编译 Qt 的图形界面模块。 -platform:指定 Qt 的编译平台。 -qt-sqlite:指定 Qt 使用 SQLite 数据库模块。 -qt-zlib:指定 Qt 使用 zlib 压缩模块。 -qt-libpng:指定 Qt 使用 libpng 图像处理库模块。 -qt-libjpeg:指定 Qt 使用 libjpeg 图像处理库模块。 -qt-freetype:指定 Qt 使用 FreeType 字体处理库模块。 -qt-harfbuzz:指定 Qt 使用 HarfBuzz 字体处理库模块。 -qt-xcb:指定 Qt 使用 XCB 驱动模块。 -qt-xkbcommon:指定 Qt 使用 XKBCommon 模块。 配置完成后,可以通过 make 命令编译 Qt 项目。在 Linux 系统中,需要在终端中进入 Qt 的源代码根目录,然后输入 make 命令来编译 Qt 项目。在 Windows 系统中,同样需要先打开 Qt 开发者命令提示符,然后进入 Qt 的源代码根目录,最后输入 make 命令来进行编译。 总之,Qt 项目配置是开发 Qt 应用程序过程中的重要环节,通过配置可以灵活地控制 Qt 库的编译选项和功能模块,从而达到更好的开发效果。

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值