QT的pro文件编写,高效简洁,,路径设置 有空格 引入系统环境变量等

首先给出以下我程序配置好的 可以运行的
vs中  
在属性页中包含路径及lib路径,
在cpp中添加以下程序
#DEFINES += _USING_V110_SDK71_
#   include <dshow.h>
#pragma comment(lib, “strmiids.lib”)  这样写  就不用再属性页连接器那里 输入strmiids.lib了
#pragma comment(lib, “quartz.lib”)
#pragma comment(lib, “strmbase.lib”)
#pragma comment(lib, “ole32.lib”)


qt中

#zkl  ok  绝对路径
#INCLUDEPATH += $$quote(C:/Program</span><span style="color:rgb(192,192,192);"> </span><span style="color:rgb(0,128,0);">Files</span><span style="color:rgb(192,192,192);"> </span><span style="color:rgb(0,128,0);">(x86)/Windows</span><span style="color:rgb(192,192,192);"> </span><span style="color:rgb(0,128,0);">Kits/8.1/Include/um)</span></pre>
<pre><span style="color:rgb(0,128,0);">#INCLUDEPATH</span><span style="color:rgb(192,192,192);"> </span><span style="color:rgb(0,128,0);">+=</span><span style="color:rgb(192,192,192);"> </span><span style="color:rgb(0,128,0);">$$quote(C:/Program Files (x86)/Windows Kits/8.1/Include/shared)
#INCLUDEPATH +=$$quote(C:/Program</span><span style="color:rgb(192,192,192);"> </span><span style="color:rgb(0,128,0);">Files</span><span style="color:rgb(192,192,192);"> </span><span style="color:rgb(0,128,0);">(x86)/Windows</span><span style="color:rgb(192,192,192);"> </span><span style="color:rgb(0,128,0);">Kits/8.1/Include/winrt)</span></pre>
<pre><span style="color:rgb(0,128,0);">#LIBS</span><span style="color:rgb(192,192,192);"> </span><span style="color:rgb(0,128,0);">+=</span><span style="color:rgb(192,192,192);"> </span><span style="color:rgb(0,128,0);">-L$$"C:/Program Files (x86)/Windows Kits/8.1/Lib/winv6.3/um/x64"
#LIBS+= -lquartz  -lole32 -lstrmiids -lVfw32 -lstrmbase
 
 
#已经设置环境变量 怎么引入环境变量
INCLUDEPATH += $$(WinSDK_Inc)/um<span style="color:rgb(192,192,192);">  </span>$$(WinSDK_Inc)/shared  $$(WinSDK_Inc)/winrt</pre>
<pre><span style="color:rgb(128,0,128);">LIBS</span><span style="color:rgb(192,192,192);"> </span>+=<span style="color:rgb(192,192,192);"> </span>-L$$quote(WinSDk_Lib)
LIBS += -lquartz  -lole32 -lstrmiids -lVfw32 -lstrmbase


下面是qt下配置opencv的  这个配置耳目一新  比网站上常见的配置方法要容易扩展

#zkl opencv249
win32:OPENCV_DIR = E:/opencv-2.4.9/opencv/build
win32:OPENCV_LIB_DIR = $${OPENCV_DIR}/x64/vc11/lib</pre>
<pre>win32:CV_VER<span style="color:#646482;"> </span>=<span style="color:#646482;"> </span>249</pre>
<pre></pre>
<pre><span style="color:#cd8b00;">#opencv30</span><span style="color:#646482;"> </span><span style="color:#cd8b00;">动态链接库</span></pre>
<pre><span style="color:#cd8b00;">#CV_LIB_NAMES</span><span style="color:#646482;"> </span><span style="color:#cd8b00;">=</span><span style="color:#646482;"> </span><span style="color:#cd8b00;">ts</span><span style="color:#646482;"> </span><span style="color:#cd8b00;">world</span></pre>
<pre>CV_LIB_NAMES<span style="color:#646482;"> </span>=<span style="color:#646482;"> </span>core<span style="color:#646482;"> </span>imgproc<span style="color:#646482;"> </span>highgui<span style="color:#646482;"> </span>calib3d<span style="color:#646482;"> </span>feature2d<span style="color:#646482;"> </span>flann</pre>
<pre><span style="color:#808bed;">for</span>(lib,CV_LIB_NAMES){</pre>
<pre><span style="color:#646482;">    </span>CV_LIBS<span style="color:#646482;"> </span>+=-lopencv_$$lib</pre>
<pre>}</pre>
<pre></pre>
<pre><span style="color:#ff8bff;">CONFIG</span>(release,<span style="color:#646482;"> </span>debug|release){</pre>
<pre><span style="color:#646482;">    </span>CV_LIB_PREFIX<span style="color:#646482;"> </span>=$$CV_VER</pre>
<pre>}</pre>
<pre>else{</pre>
<pre><span style="color:#646482;">    </span>CV_LIB_PREFIX<span style="color:#646482;"> </span>=<span style="color:#646482;"> </span>$${CV_VER}d</pre>
<pre><span style="color:#646482;">    </span><span style="color:#ff8bff;">CONFIG</span><span style="color:#646482;"> </span>+=console</pre>
<pre>}</pre>
<pre></pre>
<pre><span style="color:#808bed;">for</span>(lib,CV_LIBS){</pre>
<pre><span style="color:#646482;">    </span>CV_LIBS_NEW<span style="color:#646482;"> </span>+=<span style="color:#646482;"> </span>$$lib$$CV_LIB_PREFIX</pre>
<pre>}</pre>
<pre><span style="color:#cd8b00;">#opencv_objdetect249d</span></pre>
<pre>CV_LIBS<span style="color:#646482;"> </span>=<span style="color:#646482;"> </span>$$CV_LIBS_NEW $$CV_EXT_LIBS<span style="color:#646482;">   </span></pre>
<pre></pre>
<pre></pre>
<pre><span style="color:#ff8bff;">LIBS</span><span style="color:#646482;"> </span>+=<span style="color:#646482;"> </span>-L$$OPENCV_LIB_DIR $$CV_LIBS</pre>
<pre><span style="color:#ff8bff;">INCLUDEPATH</span><span style="color:#646482;"> </span>+=<span style="color:#646482;"> </span>$$OPENCV_DIR/include


从网上下载别人的程序,遇到的问题大都都是配置问题,有的程序调用windows的函数,比如 window.h  dshow.h,,视频处理方面的 用dxd directshow接口时,配置很麻烦,

缺少某个lib,ok你可以去下载然后放到qt或vs的软件安装的lib文件下,但这种方式毕竟不是根本,,明明缺少的lib库  像gdi32.lib,glu.lib,其实window都给你已经安装到了c盘下

,包含配置下就可以了,但是,但是window也是坑很多的系统,

C:/Program Files (x86)/Microsoft SDKs/Windows/v7.1A/Lib
C:/Program Files (x86)/Windows Kits/8.1/Lib/winv6.3/um/x64

程序中遇到的lib 包含文件,都能在c盘搜到,是以上两个文件下,微软,你过来,我问你,你让我包含哪一个,哪个是最确保万无一失的, 只好自己试试,不然  包含v7.1A,好纳闷,我系统是8.1的啊,,但是我笔记本是win7的,把 8.0 8.1全都删除了之后,所有的vs程序几乎都不能运行了,难道说不管你系统装的是win10  win7,这些文件夹都存在的是,7.0 7.1  8.0 8.1不以系统意志为转移啊,,,包含v7.1在vs下可以 vs2012             其中 vs2015 不用包含就没问题,qt5.2.0的包含有问题,,后来又在网上搜搜,

包含v8.1    并且是WindowsKits下的8.1,,,sdk中7.1是老版本的

幸之,vs12 15  qt三个都完美运行,gl的问题也随之解决,,

看来就是几乎大部分的开源代码的问题就是你的配置问题。

再说下sdk 和kit关系

Microsoft SDKs包含了Windows Kits、Azure SDK、Kinect SDK,等。win8以前winsdk还是放在Microsoft SDKs目录下的,以后就单独弄了个Windows Kits目录出来


pro中 LIBS INCLUDEPATH 引入三方库的,空格处理有两种方式:都可以

INCLUDEPATH +=$$<span style="color:#808000;">quote</span>(C:/Program<span style="color:#c0c0c0;"> </span>Files<span style="color:#c0c0c0;"> </span>(x86)/Windows<span style="color:#c0c0c0;"> </span>Kits/8.1/Include/winrt)</pre>
<pre><span style="color:#800080;">LIBS</span><span style="color:#c0c0c0;"> </span>+=<span style="color:#c0c0c0;"> </span>-L$$"C:/Program Files (x86)/Windows Kits/8.1/Lib/winv6.3/um/x64"
LIBS+= -lquartz  -lole32 -lstrmiids -lVfw32 -lstrmbase

pro中引入环境变量




 

Qt中Pro文件变量详细说明

学习Qt时,发现有些知识看了不经常用就忘了,以下是书本上写的一些关于qmake的相关知识,自己看后,打算把一些经常用到的记下来,整理整理。

Qt程序一般使用Qt提供的qmake工具来编译。

qmake工具可以使用与平台无关的.pro文件生成与平台相关的makefile。该工具包含了调用Qt内置代码生成工具(mocuicrcc)的必要逻辑规则。

 

可以在命令行下,输入qmake -project来生成平台无关的pro文件。

工程文件pro主要分为三种:app(单独的应用程序),lib(静态和动态库),subdirs(递归编译)。工程类型可以使用TEMPLATE变量来指定。

如: TEMPLATE = app(默认不指定的情况下是app工程)

 

对于app工程或者lib工程,有以下这些经常使用的变量:

HEADERS:指定C++头文件

SOURCES:指定C++实现文件

FORMS:指定需要uic处理的ui文件

RESOURCES:指定需要rcc处理的qrc文件

DEFINES:指定预定义预处理器符号

INCLUDEPATH:指定C++编译器搜索头文件路径

LIBS:指定工程要链接的库

CONFIG:指定工程配置和编译参数

QT:指定工程所要使用的Qt模块

VERSION:指定目标库版本号

TARGET:指定可执行文件或库的基本文件名,默认为当前目录名

DESTDIR:指定可执行文件放置的目录

DLLDESTDIR:指定目标库文件放置的目录

 

CONFIG:指定工程配置和编译参数

以下对CONFIG变量做主要介绍:

debug:编译有调试信息的可执行文件或则库

release:编译不具有调试信息可执行文件或者库(如果同时指定debug release时,只有debug有效)

warn_off:关闭大量警告,默认是打开的

qt:指应用程序使用Qt

dll:动态编译库

staticlib:静态编译库

plugin:编译一个插件

console:应用程序需要写控制台

当我们写CONFIG变量时,可以使用

如:CONFIG = qt release warn_off

或者CONFIG = qt

      CONFIG += release

      CONFIG += warn_off

当想要移除某个设置时:CONFIG -= warn_off

 

 

在pro文件里,可以使

{varName}来访问自己定义的变量,如

 

MyVersion = 1.2

FILE = 1.cpp

TARGET = improve

MyVersion</p><pstyle="lineheight:1.5;">SOURCES= M y V e r s i o n < / p >< p s t y l e =" l i n e − h e i g h t : 1.5 ; "> S O U R C E S =
FILE

 

pro文件里,访问环境变量的用法是:$(varName)

pro文件里,访问Qt配置参数的用法:

[varName]</p>
<p style="line-height:1.5;">&nbsp;</p>
<p style="line-height:1.5;">在不同的编译平台上编译时,需要设定条件。如:</p>
<p style="line-height:1.5;">win32{</p>
<p style="line-height:1.5;">&nbsp;SOURCES += 1.cpp</p>
<p style="line-height:1.5;">}else{</p>
<p style="line-height:1.5;">&nbsp;SOURCES += 2.cpp</p>
<p style="line-height:1.5;">}</p>
<p style="line-height:1.5;">或者</p>
<p style="line-height:1.5;">win32:SOURCES += 3.cpp</p>
<p style="line-height:1.5;">&nbsp;转自:http://www.cnblogs.com/braver/articles/1935891.html</p>
</div>
<br><p></p>
<p>http://blog.csdn.net/dbzhang800/article/details/6758204<br></p>
<p></p>
<ul style="color:rgb(51,51,51);font-family:Arial;font-size:14px;line-height:26px;"><li style="list-style-type:none;">不想太深入地去看qmake,可是,左等,右等,总不见Qt新的构建系统有什么新消息。还是整理一下qmake吧,由于没什么主题,还不知道本文最终会乱到什么程度。<span class="anchor" id="line-2-6"></span><span class="anchor" id="line-3-5"></span></li></ul><p></p>
<p class="line874" style="color:rgb(51,51,51);font-family:Arial;font-size:14px;line-height:26px;">
注:你可能会对下面的内容感兴趣。<span class="anchor" id="line-4-3"></span></p>
<ul style="color:rgb(51,51,51);font-family:Arial;font-size:14px;line-height:26px;"><li>
<p class="line891"><a class="http" href="http://blog.csdn.net/dbzhang800/article/details/6348432" rel="nofollow" style="color:rgb(4,115,7);text-decoration:none;border:0px;" target="_blank">浅谈 qmake 之 pro、pri、prf、prl文件</a><span class="anchor" id="line-5-1"></span></p>
</li><li>
<p class="line891"><a class="http" href="http://blog.csdn.net/dbzhang800/article/details/6343838" rel="nofollow" style="color:rgb(4,115,7);text-decoration:none;border:0px;" target="_blank">浅谈 qmake 之 shadow
 build</a><span class="anchor" id="line-6-1"></span></p>
</li><li>
<p class="line891"><a class="http" href="http://hi.baidu.com/cyclone/blog/item/d77a8618608448b94bedbc0b.html" rel="nofollow" style="color:rgb(4,115,7);text-decoration:none;border:0px;" target="_blank">qmake
 之 CONFIG(debug, debug|release)</a><span class="anchor" id="line-7-1"></span></p>
</li><li>
<p class="line891"><a class="http" href="http://hi.baidu.com/cyclone/blog/item/d299af511bed309f8c5430c3.html" rel="nofollow" style="color:rgb(4,115,7);text-decoration:none;border:0px;" target="_blank">qmake
 之 CONFIG 与 QT 乱谈</a><span class="anchor" id="line-8-1"></span><span class="anchor" id="line-9"></span></p>
</li></ul><h2 id="A.2BU9iRzw-" style="color:rgb(51,51,51);font-family:Arial;line-height:26px;border-bottom:3px solid rgb(4,115,7);"><a name="t1"></a>
<a name="t0" style="color:rgb(51,102,153);" target="_blank"></a>变量</h2>
<span class="anchor" id="line-10" style="color:rgb(51,51,51);font-family:Arial;font-size:14px;line-height:26px;"></span><span class="anchor" id="line-11" style="color:rgb(51,51,51);font-family:Arial;font-size:14px;line-height:26px;"></span><span style="color:rgb(51,51,51);font-family:Arial;font-size:14px;line-height:26px;"></span>
<div style="color:rgb(51,51,51);font-family:Arial;font-size:14px;line-height:26px;">
<table style="border-collapse:collapse;"><tbody><tr><td style="border:1px solid rgb(4,115,7);">
<p class="line891">
<tt>
[varName]</p><p style="line-height:1.5;">&nbsp;</p><p style="line-height:1.5;">在不同的编译平台上编译时,需要设定条件。如:</p><p style="line-height:1.5;">win32{</p><p style="line-height:1.5;">&nbsp;SOURCES += 1.cpp</p><p style="line-height:1.5;">}else{</p><p style="line-height:1.5;">&nbsp;SOURCES += 2.cpp</p><p style="line-height:1.5;">}</p><p style="line-height:1.5;">或者</p><p style="line-height:1.5;">win32:SOURCES += 3.cpp</p><p style="line-height:1.5;">&nbsp;转自:http://www.cnblogs.com/braver/articles/1935891.html</p></div><br><p></p><p>http://blog.csdn.net/dbzhang800/article/details/6758204<br></p><p></p><ul style="color:rgb(51,51,51);font-family:Arial;font-size:14px;line-height:26px;"><li style="list-style-type:none;">不想太深入地去看qmake,可是,左等,右等,总不见Qt新的构建系统有什么新消息。还是整理一下qmake吧,由于没什么主题,还不知道本文最终会乱到什么程度。<span class="anchor" id="line-2-6"></span><span class="anchor" id="line-3-5"></span></li></ul><p></p><p class="line874" style="color:rgb(51,51,51);font-family:Arial;font-size:14px;line-height:26px;">注:你可能会对下面的内容感兴趣。<span class="anchor" id="line-4-3"></span></p><ul style="color:rgb(51,51,51);font-family:Arial;font-size:14px;line-height:26px;"><li><p class="line891"><a class="http" href="http://blog.csdn.net/dbzhang800/article/details/6348432" rel="nofollow" style="color:rgb(4,115,7);text-decoration:none;border:0px;" target="_blank">浅谈 qmake 之 pro、pri、prf、prl文件</a><span class="anchor" id="line-5-1"></span></p></li><li><p class="line891"><a class="http" href="http://blog.csdn.net/dbzhang800/article/details/6343838" rel="nofollow" style="color:rgb(4,115,7);text-decoration:none;border:0px;" target="_blank">浅谈 qmake 之 shadow build</a><span class="anchor" id="line-6-1"></span></p></li><li><p class="line891"><a class="http" href="http://hi.baidu.com/cyclone/blog/item/d77a8618608448b94bedbc0b.html" rel="nofollow" style="color:rgb(4,115,7);text-decoration:none;border:0px;" target="_blank">qmake 之 CONFIG(debug, debug|release)</a><span class="anchor" id="line-7-1"></span></p></li><li><p class="line891"><a class="http" href="http://hi.baidu.com/cyclone/blog/item/d299af511bed309f8c5430c3.html" rel="nofollow" style="color:rgb(4,115,7);text-decoration:none;border:0px;" target="_blank">qmake 之 CONFIG 与 QT 乱谈</a><span class="anchor" id="line-8-1"></span><span class="anchor" id="line-9"></span></p></li></ul><h2 id="A.2BU9iRzw-" style="color:rgb(51,51,51);font-family:Arial;line-height:26px;border-bottom:3px solid rgb(4,115,7);"><a name="t1"></a><a name="t0" style="color:rgb(51,102,153);" target="_blank"></a>变量</h2><span class="anchor" id="line-10" style="color:rgb(51,51,51);font-family:Arial;font-size:14px;line-height:26px;"></span><span class="anchor" id="line-11" style="color:rgb(51,51,51);font-family:Arial;font-size:14px;line-height:26px;"></span><span style="color:rgb(51,51,51);font-family:Arial;font-size:14px;line-height:26px;"></span><div style="color:rgb(51,51,51);font-family:Arial;font-size:14px;line-height:26px;"><table style="border-collapse:collapse;"><tbody><tr><td style="border:1px solid rgb(4,115,7);"><p class="line891"><tt>
varName
varName</tt></p></td><tdstyle="border:1pxsolidrgb(4,115,7);"><pclass="line862">qmake</p></td></tr><tr><tdstyle="border:1pxsolidrgb(4,115,7);"><spanclass="anchor"id="line12"></span><pclass="line891"><tt> v a r N a m e < / t t > < / p >< / t d >< t d s t y l e =" b o r d e r : 1 p x s o l i d r g b ( 4 , 115 , 7 ) ; ">< p c l a s s =" l i n e 862 "> q m a k e 工 程 文 件 内 定 义 变 量 的 值 < / p >< / t d >< / t r >< t r >< t d s t y l e =" b o r d e r : 1 p x s o l i d r g b ( 4 , 115 , 7 ) ; ">< s p a n c l a s s =" a n c h o r " i d =" l i n e − 12 ">< / s p a n >< p c l a s s =" l i n e 891 ">< t t >
(varName)

qmake运行时,环境变量的值

$(varName)

makefile被处理时,环境变量的值

[varName]</p></td><tdstyle="border:1pxsolidrgb(4,115,7);"><pclass="line862">Qt</p></td></tr><tr><tdstyle="border:1pxsolidrgb(4,115,7);"><spanclass="anchor"></span><pclass="line862">$varName</p></td><tdstyle="border:1pxsolidrgb(4,115,7);"><pclass="line862">西</p></td></tr></tbody></table></div><spanclass="anchor"id="line15"style="color:rgb(51,51,51);fontfamily:Arial;fontsize:14px;lineheight:26px;"></span><spanclass="anchor"id="line16"style="color:rgb(51,51,51);fontfamily:Arial;fontsize:14px;lineheight:26px;"></span><spanstyle="color:rgb(51,51,51);fontfamily:Arial;fontsize:14px;lineheight:26px;"></span><pclass="line874"style="color:rgb(51,51,51);fontfamily:Arial;fontsize:14px;lineheight:26px;">4...<spanclass="anchor"id="line17"></span><spanclass="anchor"id="line18"></span></p><h3id="A.24.24varName"style="color:rgb(51,51,51);fontfamily:Arial;lineheight:26px;borderbottom:3pxsolidrgb(4,115,7);"><aname="t2"></a><aname="t1"style="color:rgb(51,102,153);"target="blank"></a> [ v a r N a m e ] < / p >< / t d >< t d s t y l e =" b o r d e r : 1 p x s o l i d r g b ( 4 , 115 , 7 ) ; ">< p c l a s s =" l i n e 862 "> Q t 配 置 选 项 的 值 < / p >< / t d >< / t r >< t r >< t d s t y l e =" b o r d e r : 1 p x s o l i d r g b ( 4 , 115 , 7 ) ; ">< s p a n c l a s s =" a n c h o r ">< / s p a n >< p c l a s s =" l i n e 862 "> $ v a r N a m e < / p >< / t d >< t d s t y l e =" b o r d e r : 1 p x s o l i d r g b ( 4 , 115 , 7 ) ; ">< p c l a s s =" l i n e 862 "> 你 可 能 见 过 这 个 用 法 , 但 本 文 不 讨 论 这 个 东 西 , 以 后 用 到 时 会 提 及 < / p >< / t d >< / t r >< / t b o d y >< / t a b l e >< / d i v >< s p a n c l a s s =" a n c h o r " i d =" l i n e − 15 " s t y l e =" c o l o r : r g b ( 51 , 51 , 51 ) ; f o n t − f a m i l y : A r i a l ; f o n t − s i z e : 14 p x ; l i n e − h e i g h t : 26 p x ; ">< / s p a n >< s p a n c l a s s =" a n c h o r " i d =" l i n e − 16 " s t y l e =" c o l o r : r g b ( 51 , 51 , 51 ) ; f o n t − f a m i l y : A r i a l ; f o n t − s i z e : 14 p x ; l i n e − h e i g h t : 26 p x ; ">< / s p a n >< s p a n s t y l e =" c o l o r : r g b ( 51 , 51 , 51 ) ; f o n t − f a m i l y : A r i a l ; f o n t − s i z e : 14 p x ; l i n e − h e i g h t : 26 p x ; ">< / s p a n >< p c l a s s =" l i n e 874 " s t y l e =" c o l o r : r g b ( 51 , 51 , 51 ) ; f o n t − f a m i l y : A r i a l ; f o n t − s i z e : 14 p x ; l i n e − h e i g h t : 26 p x ; "> 这 4 中 用 法 区 别 何 在 ? 没 有 例 子 我 还 真 说 不 明 白 . . . < s p a n c l a s s =" a n c h o r " i d =" l i n e − 17 ">< / s p a n >< s p a n c l a s s =" a n c h o r " i d =" l i n e − 18 ">< / s p a n >< / p >< h 3 i d =" A .24 .24 v a r N a m e " s t y l e =" c o l o r : r g b ( 51 , 51 , 51 ) ; f o n t − f a m i l y : A r i a l ; l i n e − h e i g h t : 26 p x ; b o r d e r − b o t t o m : 3 p x s o l i d r g b ( 4 , 115 , 7 ) ; ">< a n a m e =" t 2 ">< / a >< a n a m e =" t 1 " s t y l e =" c o l o r : r g b ( 51 , 102 , 153 ) ; " t a r g e t = " b l a n k ">< / a >
varName

例子:

  • test.pro

projectname = dbzhang
FULL1 = $$projectname/800
<span class="anchor" id="line-3"></span>FULL2 = $${projectname}800
!build_pass:message($$FULL2)</pre>
<span class="anchor" id="line-27" style="color:rgb(51,51,51);font-family:Arial;font-size:14px;line-height:26px;"></span><span style="color:rgb(51,51,51);font-family:Arial;font-size:14px;line-height:26px;"></span>
<p class="line874" style="color:rgb(51,51,51);font-family:Arial;font-size:14px;line-height:26px;">
运行qmake时,输出结果是<span class="anchor" id="line-28"></span><span class="anchor" id="line-29"></span><span class="anchor" id="line-30"></span></p>
<pre style="color:rgb(51,51,51);font-size:14px;line-height:26px;font-family:courier, monospace;border:1pt solid rgb(192,192,192);background-color:rgb(240,236,230);"><span class="anchor" id="line-1-1"></span>Project MESSAGE: dbzhang/800 dbzhang800</pre>
<span class="anchor" id="line-31" style="color:rgb(51,51,51);font-family:Arial;font-size:14px;line-height:26px;"></span><span style="color:rgb(51,51,51);font-family:Arial;font-size:14px;line-height:26px;"></span>
<ul style="color:rgb(51,51,51);font-family:Arial;font-size:14px;line-height:26px;"><li>何时加大括号?当变量和后面的字符连接到一块的时候。<span class="anchor" id="line-32"></span></li><li>build_pass 干嘛用的?自己试试看吧,如果没有它,同样的消息在windows下会被输出3次(因为会生成3个makefile文件,每个一次)。<span class="anchor" id="line-33"></span><span class="anchor" id="line-34"></span></li></ul><h3 id="A.24.24.28varName.29" style="color:rgb(51,51,51);font-family:Arial;line-height:26px;border-bottom:3px solid rgb(4,115,7);"><a name="t3"></a>
<a name="t2" style="color:rgb(51,102,153);" target="_blank"></a>$$(varName)

环境变量,就是大家通常说得环境变量。例子:

  • test.pro

message($$(PATH))</pre>
<span class="anchor" id="line-41" style="color:rgb(51,51,51);font-family:Arial;font-size:14px;line-height:26px;"></span><span style="color:rgb(51,51,51);font-family:Arial;font-size:14px;line-height:26px;"></span>
<p class="line874" style="color:rgb(51,51,51);font-family:Arial;font-size:14px;line-height:26px;">
运行qmake时,结果:<span class="anchor" id="line-42"></span><span class="anchor" id="line-43"></span><span class="anchor" id="line-44"></span></p>
<pre style="color:rgb(51,51,51);font-size:14px;line-height:26px;font-family:courier, monospace;border:1pt solid rgb(192,192,192);background-color:rgb(240,236,230);"><span class="anchor" id="line-1-3"></span>Project MESSAGE: /usr/bin:/home/debao/qt-labs/qt5/qtbase/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games</pre>
<span class="anchor" id="line-45" style="color:rgb(51,51,51);font-family:Arial;font-size:14px;line-height:26px;"></span><span class="anchor" id="line-46" style="color:rgb(51,51,51);font-family:Arial;font-size:14px;line-height:26px;"></span><span style="color:rgb(51,51,51);font-family:Arial;font-size:14px;line-height:26px;"></span>
<h3 id="A.24.28varName.29" style="color:rgb(51,51,51);font-family:Arial;line-height:26px;border-bottom:3px solid rgb(4,115,7);"><a name="t4"></a>
<a name="t3" style="color:rgb(51,102,153);" target="_blank"></a>$(varName)</h3>
<span class="anchor" id="line-47" style="color:rgb(51,51,51);font-family:Arial;font-size:14px;line-height:26px;"></span><span style="color:rgb(51,51,51);font-family:Arial;font-size:14px;line-height:26px;"></span>
<p class="line874" style="color:rgb(51,51,51);font-family:Arial;font-size:14px;line-height:26px;">
makefile被处理时,环境变量的值?如何理解??<span class="anchor" id="line-48"></span><span class="anchor" id="line-49"></span></p>
<p class="line874" style="color:rgb(51,51,51);font-family:Arial;font-size:14px;line-height:26px;">
看例子:<span class="anchor" id="line-50"></span><span class="anchor" id="line-51"></span></p>
<ul style="color:rgb(51,51,51);font-family:Arial;font-size:14px;line-height:26px;"><li>test.pro<span class="anchor" id="line-52"></span></li></ul><p class="line867" style="color:rgb(51,51,51);font-family:Arial;font-size:14px;line-height:26px;">
<span class="anchor" id="line-53"></span><span class="anchor" id="line-54"></span></p>
<pre style="color:rgb(51,51,51);font-size:14px;line-height:26px;font-family:courier, monospace;border:1pt solid rgb(192,192,192);background-color:rgb(240,236,230);"><span class="anchor" id="line-1-4"></span>INCLUDEPATH += $(MYINCLUDEPATH)</pre>
<span class="anchor" id="line-55" style="color:rgb(51,51,51);font-family:Arial;font-size:14px;line-height:26px;"></span><span style="color:rgb(51,51,51);font-family:Arial;font-size:14px;line-height:26px;"></span>
<p class="line874" style="color:rgb(51,51,51);font-family:Arial;font-size:14px;line-height:26px;">
执行qmake<span class="anchor" id="line-56"></span><span class="anchor" id="line-57"></span><span class="anchor" id="line-58"></span><span class="anchor" id="line-59"></span></p>
<pre style="color:rgb(51,51,51);font-size:14px;line-height:26px;font-family:courier, monospace;border:1pt solid rgb(192,192,192);background-color:rgb(240,236,230);"><span class="anchor" id="line-1-5"></span>$ export MYINCLUDEPATH="/home/dbzhang800/include"
<span class="anchor" id="line-2-1"></span>$ qmake test.pro</pre>
<span class="anchor" id="line-60" style="color:rgb(51,51,51);font-family:Arial;font-size:14px;line-height:26px;"></span><span style="color:rgb(51,51,51);font-family:Arial;font-size:14px;line-height:26px;"></span>
<p class="line874" style="color:rgb(51,51,51);font-family:Arial;font-size:14px;line-height:26px;">
生成的makefile:<span class="anchor" id="line-61"></span><span class="anchor" id="line-62"></span><span class="anchor" id="line-63"></span><span class="anchor" id="line-64"></span><span class="anchor" id="line-65"></span></p>
<pre style="color:rgb(51,51,51);font-size:14px;line-height:26px;font-family:courier, monospace;border:1pt solid rgb(192,192,192);background-color:rgb(240,236,230);"><span class="anchor" id="line-1-6"></span>...
<span class="anchor" id="line-2-2"></span>INCPATH = -I/usr/share/qt4/mkspecs/linux-g++ -I. -I/usr/include/qt4/QtCore -I/usr/include/qt4/QtGui -I/usr/include/qt4 -I$(MYINCLUDEPATH) -I.
<span class="anchor" id="line-3-1"></span>...</pre>
<span class="anchor" id="line-66" style="color:rgb(51,51,51);font-family:Arial;font-size:14px;line-height:26px;"></span><span class="anchor" id="line-67" style="color:rgb(51,51,51);font-family:Arial;font-size:14px;line-height:26px;"></span><span style="color:rgb(51,51,51);font-family:Arial;font-size:14px;line-height:26px;"></span>
<p class="line874" style="color:rgb(51,51,51);font-family:Arial;font-size:14px;line-height:26px;">
为了对比,可以将单$符号,改成$$再试试看看,运行命令,结果:
...
INCPATH = -I/usr/share/qt4/mkspecs/linux-g++ -I. -I/usr/include/qt4/QtCore -I/usr/include/qt4/QtGui -I/usr/include/qt4 -I/home/dbzhang800/include -I.
...

$$[varName]</h3> <span class="anchor" id="line-75" style="color:rgb(51,51,51);font-family:Arial;font-size:14px;line-height:26px;"></span><span style="color:rgb(51,51,51);font-family:Arial;font-size:14px;line-height:26px;"></span> <p class="line874" style="color:rgb(51,51,51);font-family:Arial;font-size:14px;line-height:26px;"> Qt配置选项的值?何解??<span class="anchor" id="line-76"></span><span class="anchor" id="line-77"></span></p> <ul style="color:rgb(51,51,51);font-family:Arial;font-size:14px;line-height:26px;"><li>配置选项值有哪些?<span class="anchor" id="line-78"></span></li></ul><p class="line867" style="color:rgb(51,51,51);font-family:Arial;font-size:14px;line-height:26px;"> <span class="anchor" id="line-79"></span><span class="anchor" id="line-80"></span><span class="anchor" id="line-81"></span><span class="anchor" id="line-82"></span><span class="anchor" id="line-83"></span><span class="anchor" id="line-84"></span><span class="anchor" id="line-85"></span><span class="anchor" id="line-86"></span><span class="anchor" id="line-87"></span></p> <pre style="color:rgb(51,51,51);font-size:14px;line-height:26px;font-family:courier, monospace;border:1pt solid rgb(192,192,192);background-color:rgb(240,236,230);"><span class="anchor" id="line-1-8"></span>debao@ubuntu:~/ttt/qmake-t1$ qmake -query <span class="anchor" id="line-2-4"></span>QT_INSTALL_PREFIX:/usr <span class="anchor" id="line-3-3"></span>QT_INSTALL_DATA:/usr/share/qt4 <span class="anchor" id="line-4-1"></span>QT_INSTALL_DOCS:/usr/share/qt4/doc <span class="anchor" id="line-5"></span>QT_INSTALL_HEADERS:/usr/include/qt4 <span class="anchor" id="line-6"></span>QT_INSTALL_LIBS:/usr/lib <span class="anchor" id="line-7"></span>QT_INSTALL_BINS:/usr/bin <span class="anchor" id="line-8"></span>...</pre> <span class="anchor" id="line-88" style="color:rgb(51,51,51);font-family:Arial;font-size:14px;line-height:26px;"></span><span style="color:rgb(51,51,51);font-family:Arial;font-size:14px;line-height:26px;"></span> <ul style="color:rgb(51,51,51);font-family:Arial;font-size:14px;line-height:26px;"><li>有什么用呢?比如,我们编译一个动态库,想将dll放置到Qt的bin目录下(供其它程序使用):<span class="anchor" id="line-89"></span></li></ul><p class="line867" style="color:rgb(51,51,51);font-family:Arial;font-size:14px;line-height:26px;"> <span class="anchor" id="line-90"></span><span class="anchor" id="line-91"></span><span class="anchor" id="line-92"></span><span class="anchor" id="line-93"></span><span class="anchor" id="line-94"></span></p> <pre style="color:rgb(51,51,51);font-size:14px;line-height:26px;font-family:courier, monospace;border:1pt solid rgb(192,192,192);background-color:rgb(240,236,230);"><span class="anchor" id="line-1-9"></span>win32:{ <span class="anchor" id="line-2-5"></span> DLLDESTDIR = $$[QT_INSTALL_BINS] <span class="anchor" id="line-3-4"></span> QMAKE_DISTCLEAN += $$[QT_INSTALL_BINS]\\dbzhang800.dll <span class="anchor" id="line-4-2"></span>}</pre> <span class="anchor" id="line-95" style="color:rgb(51,51,51);font-family:Arial;font-size:14px;line-height:26px;"></span><span style="color:rgb(51,51,51);font-family:Arial;font-size:14px;line-height:26px;"></span> <ul style="color:rgb(51,51,51);font-family:Arial;font-size:14px;line-height:26px;"><li>除了这些还有其他值么?恩,你可以自己设置一些值,比如<span class="anchor" id="line-96"></span></li></ul><p class="line867" style="color:rgb(51,51,51);font-family:Arial;font-size:14px;line-height:26px;"> <span class="anchor" id="line-97"></span><span class="anchor" id="line-98"></span></p> <pre style="color:rgb(51,51,51);font-size:14px;line-height:26px;font-family:courier, monospace;border:1pt solid rgb(192,192,192);background-color:rgb(240,236,230);"><span class="anchor" id="line-1-10"></span>$ qmake -set dbzhang 800</pre> <span class="anchor" id="line-99" style="color:rgb(51,51,51);font-family:Arial;font-size:14px;line-height:26px;"></span><span style="color:rgb(51,51,51);font-family:Arial;font-size:14px;line-height:26px;"></span> <p class="line874" style="color:rgb(51,51,51);font-family:Arial;font-size:14px;line-height:26px;"> 然后就可以在pro文件内用 $$[dbzhang] 了

注:在Qt5下,有 qmake -unset dbzhang 可以取消设置,在Qt4下没有 unset!

注:设置值是通过QSettings保存的。你应该知道保存在何处了,呵呵

QSettings(QSettings::UserScope, "Trolltech", "QMake");

晕死,4个这东西竟然写了这么长。只好本文标题中加个(一),慢慢写二三四了。

参考


QT中PRO文件写法的详细介绍

标签: Qt
  506人阅读  评论(0)  收藏  举报
  分类:

1. 注释
从“#”开始,到这一行结束。

2.模板变量告诉qmake为这个应用程序生成哪种makefile。下面是可供使用的选择:
TEMPLATE = app
A> app -建立一个应用程序的makefile。这是默认值,所以如果模板没有被指定,这个将被使用。
B> lib - 建立一个库的makefile。
C> vcapp - 建立一个应用程序的VisualStudio项目文件。
D> vclib - 建立一个库的VisualStudio项目文件。
E> subdirs -这是一个特殊的模板,它可以创建一个能够进入特定目录并且为一个项目文件生成makefile并且为它调用make的makefile。


#指定生成的 应用程序放置的目录
DESTDIR += ../bin

#指定 生成的应用程序名
TARGET = pksystem

# 配置信息
CONFIG用来告诉qmake关于应用程序的配置信息。

    CONFIG+= qt warn_on release

在这里使用“+=”,是因为我们添加我们的配置选项到任何一个已经存在中。这样做比使用“=”那样替换已经指定的所有选项是更安全的。

debug:编译有调试信息的可执行文件或则库

release:编译不具有调试信息可执行文件或者库(如果同时指定debug release时,只有debug有效)

warn_off:关闭大量警告,默认是打开的

qt:指应用程序使用Qt

dll:动态编译库

staticlib:静态编译库

plugin:编译一个插件

console:应用程序需要写控制台

当我们写CONFIG变量时,可以使用

如:CONFIG = qt release warn_off

或者CONFIG = qt

      CONFIG += release

      CONFIG += warn_off

当想要移除某个设置时:CONFIG -= warn_off


#指定uic命令将 .ui文件转化成ui_*.h文件的存放的目录
UI_DIR += forms

#指定rcc命令将 .qrc文件转换成qrc_*.h文件的存放目录
RCC_DIR += ../tmp

#指定moc命令将 含Q_OBJECT的头文件转换成标准.h文件的存放目录
MOC_DIR += ../tmp

#指定 目标文件(obj)的存放目录
OBJECTS_DIR += ../tmp

#程序 编译时依赖的相关路径
DEPENDPATH += . forms include qrc sources

#头文件包含路径
INCLUDEPATH += .

#qmake时产生的信息 ,[
(PATH)读取环境变量PATH]
#message(
(PATH))
<p></p>
<p style="line-height:28px;color:rgb(102,102,102);font-family:'Hiragino Sans GB W3', 'Hiragino Sans GB', Arial, Helvetica, simsun, u5b8bu4f53;font-size:16px;">
<span style="font-family:Verdana;"><span style="line-height:21px;color:rgb(0,0,255);">#源文件编码方式</span><br><span style="line-height:21px;color:rgb(255,0,0);">CODECFORSRC<span style="line-height:28px;">&nbsp;</span></span>= GBK</span></p>
<p style="line-height:28px;color:rgb(102,102,102);font-family:'Hiragino Sans GB W3', 'Hiragino Sans GB', Arial, Helvetica, simsun, u5b8bu4f53;font-size:16px;">
<span style="font-family:Verdana;"><span style="line-height:21px;color:rgb(0,0,255);">#工程中包含的头文件</span><br><span style="line-height:21px;color:rgb(255,0,0);">HEADERS</span>&nbsp;+= include/painter.h<br></span><span style="font-family:Verdana;"><span style="line-height:21px;color:rgb(0,0,255);">#工程中包含的.ui设计文件<br style="line-height:28px;"></span><span style="line-height:21px;color:rgb(255,0,0);">FORMS</span>&nbsp;+= forms/painter.ui<br></span><span style="font-family:Verdana;"><span style="line-height:21px;color:rgb(0,0,255);">#工程中包含的源文件<br style="line-height:28px;"></span><span style="line-height:21px;color:rgb(255,0,0);">SOURCES</span>&nbsp;+= sources/main.cpp sources/painter.cpp<br><span style="line-height:21px;color:rgb(0,0,255);">#工程中包含的资源文件</span><br><span style="line-height:21px;color:rgb(255,0,0);">RESOURCES</span>&nbsp;+= qrc/painter.qrc</span></p>
<p style="line-height:28px;color:rgb(102,102,102);font-family:'Hiragino Sans GB W3', 'Hiragino Sans GB', Arial, Helvetica, simsun, u5b8bu4f53;font-size:16px;">
<span style="font-family:Verdana;"><span style="line-height:21px;color:rgb(255,0,0);">LIBS</span>&nbsp;+= -L folderPath&nbsp;&nbsp;//<span style="line-height:21px;color:rgb(0,0,255);">引入的lib文件</span>的路径&nbsp;&nbsp;-L:引入路径</span></p>
<p style="line-height:28px;color:rgb(102,102,102);font-family:'Hiragino Sans GB W3', 'Hiragino Sans GB', Arial, Helvetica, simsun, u5b8bu4f53;font-size:16px;">
Release:LIBS += -L folderPath // release 版引入的lib文件路径</p>
<p style="line-height:28px;color:rgb(102,102,102);font-family:'Hiragino Sans GB W3', 'Hiragino Sans GB', Arial, Helvetica, simsun, u5b8bu4f53;font-size:16px;">
Debug:LIBS += -L folderPath // Debug 版引入的lib 文件路径</p>
<p style="line-height:28px;color:rgb(102,102,102);font-family:'Hiragino Sans GB W3', 'Hiragino Sans GB', Arial, Helvetica, simsun, u5b8bu4f53;font-size:16px;">
<span style="font-family:Verdana;"><span style="line-height:21px;color:rgb(255,0,0);">DEFINES</span>&nbsp;+= XX_XX_XXX&nbsp;&nbsp;//<span style="line-height:21px;color:rgb(0,0,255);">定义编译选项</span>,在.h文件中就可以使用:#ifdefine xx_xx_xxx</span></p>
<p style="line-height:28px;color:rgb(102,102,102);font-family:'Hiragino Sans GB W3', 'Hiragino Sans GB', Arial, Helvetica, simsun, u5b8bu4f53;font-size:16px;">
<span style="font-family:Verdana;"><span style="line-height:21px;color:rgb(255,0,0);">RC_FILE</span>&nbsp;= xxx.icns</span></p>
<p style="line-height:28px;color:rgb(102,102,102);font-family:'Hiragino Sans GB W3', 'Hiragino Sans GB', Arial, Helvetica, simsun, u5b8bu4f53;font-size:16px;">
7. 平台相关性处理<br>
我们在这里需要做的是根据qmake所运行的平台来使用相应的作用域来进行处理。为Windows平台添加的依赖平台的文件的简单的作用域看起来就像这样:</p>
<p style="line-height:28px;color:rgb(102,102,102);font-family:'Hiragino Sans GB W3', 'Hiragino Sans GB', Arial, Helvetica, simsun, u5b8bu4f53;font-size:16px;">
win32 {<br>
SOURCES += hello_win.cpp<br>
}<br>
====================================================================================================================<br>
当你已经创建好你的项目文件,生成Makefile就很容易了,你所要做的就是先到你所生成的项目文件那里然后输入:</p>
<p style="line-height:28px;color:rgb(102,102,102);font-family:'Hiragino Sans GB W3', 'Hiragino Sans GB', Arial, Helvetica, simsun, u5b8bu4f53;font-size:16px;">
Makefile可以像这样由“.pro”文件生成:</p>
<p style="line-height:28px;color:rgb(102,102,102);font-family:'Hiragino Sans GB W3', 'Hiragino Sans GB', Arial, Helvetica, simsun, u5b8bu4f53;font-size:16px;">
&nbsp;&nbsp;&nbsp;&nbsp;qmake -oMakefile hello.pro</p>
<p style="line-height:28px;color:rgb(102,102,102);font-family:'Hiragino Sans GB W3', 'Hiragino Sans GB', Arial, Helvetica, simsun, u5b8bu4f53;font-size:16px;">
对于VisualStudio的用户,qmake也可以生成“.dsp”文件,例如:</p>
<p style="line-height:28px;color:rgb(102,102,102);font-family:'Hiragino Sans GB W3', 'Hiragino Sans GB', Arial, Helvetica, simsun, u5b8bu4f53;font-size:16px;">
&nbsp;&nbsp;&nbsp;&nbsp;qmake -tvcapp -o hello.dsp hello.pro</p>
<p style="line-height:28px;color:rgb(102,102,102);font-family:'Hiragino Sans GB W3', 'Hiragino Sans GB', Arial, Helvetica, simsun, u5b8bu4f53;font-size:16px;">
++++++++++++++++++++++++一个PRO文件实例++++++++++++++++++++++++++++++++++++++++</p>
<p style="line-height:28px;color:rgb(102,102,102);font-family:'Hiragino Sans GB W3', 'Hiragino Sans GB', Arial, Helvetica, simsun, u5b8bu4f53;font-size:16px;">
<span style="line-height:21px;color:rgb(0,204,255);"><span style="font-family:Verdana;line-height:28px;">TEMPLATE&nbsp;= app&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;#模块配置<br>
LANGUAGE&nbsp;= C++&nbsp;&nbsp;&nbsp;#C++语言</span></span></p>
<p style="line-height:28px;color:rgb(102,102,102);font-family:'Hiragino Sans GB W3', 'Hiragino Sans GB', Arial, Helvetica, simsun, u5b8bu4f53;font-size:16px;">
<span style="line-height:21px;color:rgb(0,204,255);"><span style="font-family:Verdana;line-height:28px;">CONFIG&nbsp;+= qt warn_on debug release</span></span></p>
<p style="line-height:28px;color:rgb(102,102,102);font-family:'Hiragino Sans GB W3', 'Hiragino Sans GB', Arial, Helvetica, simsun, u5b8bu4f53;font-size:16px;">
<span style="line-height:21px;color:rgb(0,204,255);"><span style="font-family:Verdana;line-height:28px;">#引入的lib文件,用于引入动态链接库<br>
LIBS&nbsp;+= qaxcontainer.lib</span></span></p>
<p style="line-height:28px;color:rgb(102,102,102);font-family:'Hiragino Sans GB W3', 'Hiragino Sans GB', Arial, Helvetica, simsun, u5b8bu4f53;font-size:16px;">
<span style="line-height:21px;color:rgb(0,204,255);"><span style="font-family:Verdana;line-height:28px;">#头文件包含路径<br>
INCLUDEPATH&nbsp;+= ..\..\qtcompnent\qtchklisten\inc ..\..\qtcompnent\qtclearfile\inc ../../validator\inc\validerrcode ../../qtcompnent/qtdir/inc ../inc ../../utillib/inc/xmlapi ../../utillib/inc/util ../../xercesc ../../qtcompnent/qteditor/inc ../../qtcompnent/qtfunreview/inc
 ../../qtcompnent/qttable/inc ../../qtcompnent/qtversion/inc ../../qtcompnent/qtini/inc ../../icdtool/icdservices/inc ../../icdtool/dataset/inc ../../icdtool/doi/inc ../../icdtool/reportcontrol/inc ../../icdtool/GSEconctrol/inc ../../icdtool/inputs/inc ../../icdtool/SMVconctrol/inc
 ../../icdtool/logcontrol/inc ../../scdpreview/inc/scdpreviewtoollib ../../scdpreview/form ../../icdtool/sclcontrol/inc ../../icdtool/log/inc ../../icdtool/settingcontrol/inc ../../qtcompnent\qteditor\inc ../../qtcompnent\qttreeview\inc ../../qtcompnent\qttabwidget\inc
 ../../communication/inc ../../qtcompnent/qtabout/inc ../iedmanage/inc ../ldmanage/inc ../foriecrun/inc ../../qtcompnent\validset\inc</span></span></p>
<p style="line-height:28px;color:rgb(102,102,102);font-family:'Hiragino Sans GB W3', 'Hiragino Sans GB', Arial, Helvetica, simsun, u5b8bu4f53;font-size:16px;">
<span style="line-height:21px;color:rgb(0,204,255);"><span style="font-family:Verdana;line-height:28px;">#工程中包含的头文件<br>
HEADERS&nbsp;+= ../inc/exportstable.h \<br>
&nbsp;../inc/maintabwidget.h \<br>
&nbsp;../inc/outputtab.h \<br>
&nbsp;../inc/strutil.h \<br>
&nbsp;../inc/treeeditview.h \<br>
&nbsp;../inc/MainForm.h \<br>
&nbsp;../inc/recenfileini.h \<br>
&nbsp;../inc/ExportCIDFunction.h</span></span></p>
<p style="line-height:28px;color:rgb(102,102,102);font-family:'Hiragino Sans GB W3', 'Hiragino Sans GB', Arial, Helvetica, simsun, u5b8bu4f53;font-size:16px;">
<span style="line-height:21px;color:rgb(0,204,255);"><span style="font-family:Verdana;line-height:28px;">#工程中包含的源文件<br>
SOURCES&nbsp;+= ../src/main.cpp \<br>
&nbsp;../src/exportstable.cpp \<br>
&nbsp;../src/maintabwidget.cpp \<br>
&nbsp;../src/outputtab.cpp \<br>
&nbsp;../src/treeeditview.cpp \<br>
&nbsp;../src/MainForm.cpp \<br>
&nbsp;../src/recenfileini.cpp \<br>
&nbsp;../src/ExportCIDFunction.cpp</span></span></p>
<p style="line-height:28px;color:rgb(102,102,102);font-family:'Hiragino Sans GB W3', 'Hiragino Sans GB', Arial, Helvetica, simsun, u5b8bu4f53;font-size:16px;">
<span style="line-height:21px;color:rgb(0,204,255);"><span style="font-family:Verdana;line-height:28px;">#工程中包含的.ui设计文件<br>
FORMS&nbsp;= ../form/scdmainform.ui \<br>
&nbsp;../form/exportiedform.ui \<br>
&nbsp;../form/Exportsedform.ui \<br>
&nbsp;../form/Importsedform.ui \<br>
&nbsp;../form/formiminputs.ui</span></span></p>
<p style="line-height:28px;color:rgb(102,102,102);font-family:'Hiragino Sans GB W3', 'Hiragino Sans GB', Arial, Helvetica, simsun, u5b8bu4f53;font-size:16px;">
<span style="line-height:21px;color:rgb(0,204,255);"><span style="font-family:Verdana;line-height:28px;">#图像文件</span></span></p>
<p style="line-height:28px;color:rgb(102,102,102);font-family:'Hiragino Sans GB W3', 'Hiragino Sans GB', Arial, Helvetica, simsun, u5b8bu4f53;font-size:16px;">
<span style="line-height:21px;color:rgb(0,204,255);"><span style="font-family:Verdana;line-height:28px;">IMAGES&nbsp;= images/substation.png \<br>
&nbsp;images/communication.png \<br>
&nbsp;images/autocom.png \<br>
&nbsp;images/reportcfg.png \<br>
&nbsp;images/comcfg.png \<br>
&nbsp;images/filetrans.png \<br>
&nbsp;images/review.png \<br>
&nbsp;images/setting.png</span></span></p>
<p style="line-height:28px;color:rgb(102,102,102);font-family:'Hiragino Sans GB W3', 'Hiragino Sans GB', Arial, Helvetica, simsun, u5b8bu4f53;font-size:16px;">
<span style="line-height:21px;color:rgb(0,204,255);"><span style="font-family:Verdana;line-height:28px;">#工程中包含的资源文件<br>
RESOURCES&nbsp;&nbsp;&nbsp;= Scintilla.qrc</span></span></p>
<p style="line-height:28px;color:rgb(102,102,102);font-family:'Hiragino Sans GB W3', 'Hiragino Sans GB', Arial, Helvetica, simsun, u5b8bu4f53;font-size:16px;">
<span style="line-height:21px;color:rgb(0,204,255);"><span style="font-family:Verdana;line-height:28px;">#CONFIG -= release<br>
CONFIG -= debug</span></span></p>
<p style="line-height:28px;color:rgb(102,102,102);font-family:'Hiragino Sans GB W3', 'Hiragino Sans GB', Arial, Helvetica, simsun, u5b8bu4f53;font-size:16px;">
<br><span style="line-height:21px;color:rgb(0,204,255);"><span style="font-family:Verdana;line-height:28px;">RC_FILE = scdtool.rc</span></span></p>
<p style="line-height:28px;color:rgb(102,102,102);font-family:'Hiragino Sans GB W3', 'Hiragino Sans GB', Arial, Helvetica, simsun, u5b8bu4f53;font-size:16px;">
<span style="line-height:21px;color:rgb(0,204,255);"><span style="font-family:Verdana;line-height:28px;">&nbsp;<br>
BINLIB = ../../bin ../../xercesc/lib</span></span></p>
<p style="line-height:28px;color:rgb(102,102,102);font-family:'Hiragino Sans GB W3', 'Hiragino Sans GB', Arial, Helvetica, simsun, u5b8bu4f53;font-size:16px;">
<span style="line-height:21px;color:rgb(0,204,255);"><span style="font-family:Verdana;line-height:28px;">UI_HEADERS_DIR = ../inc&nbsp;&nbsp;# .ui文件转会为**.h&nbsp;&nbsp;&nbsp;存放的目录<br>
UI_SOURCES_DIR = ../src&nbsp;&nbsp;# .ui文件转会为**.cpp 存放的目录<br>
QMAKE_LIBDIR =
(PATH))<p></p><p style="line-height:28px;color:rgb(102,102,102);font-family:'Hiragino Sans GB W3', 'Hiragino Sans GB', Arial, Helvetica, simsun, u5b8bu4f53;font-size:16px;"><span style="font-family:Verdana;"><span style="line-height:21px;color:rgb(0,0,255);">#源文件编码方式</span><br><span style="line-height:21px;color:rgb(255,0,0);">CODECFORSRC<span style="line-height:28px;">&nbsp;</span></span>= GBK</span></p><p style="line-height:28px;color:rgb(102,102,102);font-family:'Hiragino Sans GB W3', 'Hiragino Sans GB', Arial, Helvetica, simsun, u5b8bu4f53;font-size:16px;"><span style="font-family:Verdana;"><span style="line-height:21px;color:rgb(0,0,255);">#工程中包含的头文件</span><br><span style="line-height:21px;color:rgb(255,0,0);">HEADERS</span>&nbsp;+= include/painter.h<br></span><span style="font-family:Verdana;"><span style="line-height:21px;color:rgb(0,0,255);">#工程中包含的.ui设计文件<br style="line-height:28px;"></span><span style="line-height:21px;color:rgb(255,0,0);">FORMS</span>&nbsp;+= forms/painter.ui<br></span><span style="font-family:Verdana;"><span style="line-height:21px;color:rgb(0,0,255);">#工程中包含的源文件<br style="line-height:28px;"></span><span style="line-height:21px;color:rgb(255,0,0);">SOURCES</span>&nbsp;+= sources/main.cpp sources/painter.cpp<br><span style="line-height:21px;color:rgb(0,0,255);">#工程中包含的资源文件</span><br><span style="line-height:21px;color:rgb(255,0,0);">RESOURCES</span>&nbsp;+= qrc/painter.qrc</span></p><p style="line-height:28px;color:rgb(102,102,102);font-family:'Hiragino Sans GB W3', 'Hiragino Sans GB', Arial, Helvetica, simsun, u5b8bu4f53;font-size:16px;"><span style="font-family:Verdana;"><span style="line-height:21px;color:rgb(255,0,0);">LIBS</span>&nbsp;+= -L folderPath&nbsp;&nbsp;//<span style="line-height:21px;color:rgb(0,0,255);">引入的lib文件</span>的路径&nbsp;&nbsp;-L:引入路径</span></p><p style="line-height:28px;color:rgb(102,102,102);font-family:'Hiragino Sans GB W3', 'Hiragino Sans GB', Arial, Helvetica, simsun, u5b8bu4f53;font-size:16px;">Release:LIBS += -L folderPath // release 版引入的lib文件路径</p><p style="line-height:28px;color:rgb(102,102,102);font-family:'Hiragino Sans GB W3', 'Hiragino Sans GB', Arial, Helvetica, simsun, u5b8bu4f53;font-size:16px;">Debug:LIBS += -L folderPath // Debug 版引入的lib 文件路径</p><p style="line-height:28px;color:rgb(102,102,102);font-family:'Hiragino Sans GB W3', 'Hiragino Sans GB', Arial, Helvetica, simsun, u5b8bu4f53;font-size:16px;"><span style="font-family:Verdana;"><span style="line-height:21px;color:rgb(255,0,0);">DEFINES</span>&nbsp;+= XX_XX_XXX&nbsp;&nbsp;//<span style="line-height:21px;color:rgb(0,0,255);">定义编译选项</span>,在.h文件中就可以使用:#ifdefine xx_xx_xxx</span></p><p style="line-height:28px;color:rgb(102,102,102);font-family:'Hiragino Sans GB W3', 'Hiragino Sans GB', Arial, Helvetica, simsun, u5b8bu4f53;font-size:16px;"><span style="font-family:Verdana;"><span style="line-height:21px;color:rgb(255,0,0);">RC_FILE</span>&nbsp;= xxx.icns</span></p><p style="line-height:28px;color:rgb(102,102,102);font-family:'Hiragino Sans GB W3', 'Hiragino Sans GB', Arial, Helvetica, simsun, u5b8bu4f53;font-size:16px;">7. 平台相关性处理<br>我们在这里需要做的是根据qmake所运行的平台来使用相应的作用域来进行处理。为Windows平台添加的依赖平台的文件的简单的作用域看起来就像这样:</p><p style="line-height:28px;color:rgb(102,102,102);font-family:'Hiragino Sans GB W3', 'Hiragino Sans GB', Arial, Helvetica, simsun, u5b8bu4f53;font-size:16px;">win32 {<br>SOURCES += hello_win.cpp<br>}<br>====================================================================================================================<br>当你已经创建好你的项目文件,生成Makefile就很容易了,你所要做的就是先到你所生成的项目文件那里然后输入:</p><p style="line-height:28px;color:rgb(102,102,102);font-family:'Hiragino Sans GB W3', 'Hiragino Sans GB', Arial, Helvetica, simsun, u5b8bu4f53;font-size:16px;">Makefile可以像这样由“.pro”文件生成:</p><p style="line-height:28px;color:rgb(102,102,102);font-family:'Hiragino Sans GB W3', 'Hiragino Sans GB', Arial, Helvetica, simsun, u5b8bu4f53;font-size:16px;">&nbsp;&nbsp;&nbsp;&nbsp;qmake -oMakefile hello.pro</p><p style="line-height:28px;color:rgb(102,102,102);font-family:'Hiragino Sans GB W3', 'Hiragino Sans GB', Arial, Helvetica, simsun, u5b8bu4f53;font-size:16px;">对于VisualStudio的用户,qmake也可以生成“.dsp”文件,例如:</p><p style="line-height:28px;color:rgb(102,102,102);font-family:'Hiragino Sans GB W3', 'Hiragino Sans GB', Arial, Helvetica, simsun, u5b8bu4f53;font-size:16px;">&nbsp;&nbsp;&nbsp;&nbsp;qmake -tvcapp -o hello.dsp hello.pro</p><p style="line-height:28px;color:rgb(102,102,102);font-family:'Hiragino Sans GB W3', 'Hiragino Sans GB', Arial, Helvetica, simsun, u5b8bu4f53;font-size:16px;">++++++++++++++++++++++++一个PRO文件实例++++++++++++++++++++++++++++++++++++++++</p><p style="line-height:28px;color:rgb(102,102,102);font-family:'Hiragino Sans GB W3', 'Hiragino Sans GB', Arial, Helvetica, simsun, u5b8bu4f53;font-size:16px;"><span style="line-height:21px;color:rgb(0,204,255);"><span style="font-family:Verdana;line-height:28px;">TEMPLATE&nbsp;= app&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;#模块配置<br>LANGUAGE&nbsp;= C++&nbsp;&nbsp;&nbsp;#C++语言</span></span></p><p style="line-height:28px;color:rgb(102,102,102);font-family:'Hiragino Sans GB W3', 'Hiragino Sans GB', Arial, Helvetica, simsun, u5b8bu4f53;font-size:16px;"><span style="line-height:21px;color:rgb(0,204,255);"><span style="font-family:Verdana;line-height:28px;">CONFIG&nbsp;+= qt warn_on debug release</span></span></p><p style="line-height:28px;color:rgb(102,102,102);font-family:'Hiragino Sans GB W3', 'Hiragino Sans GB', Arial, Helvetica, simsun, u5b8bu4f53;font-size:16px;"><span style="line-height:21px;color:rgb(0,204,255);"><span style="font-family:Verdana;line-height:28px;">#引入的lib文件,用于引入动态链接库<br>LIBS&nbsp;+= qaxcontainer.lib</span></span></p><p style="line-height:28px;color:rgb(102,102,102);font-family:'Hiragino Sans GB W3', 'Hiragino Sans GB', Arial, Helvetica, simsun, u5b8bu4f53;font-size:16px;"><span style="line-height:21px;color:rgb(0,204,255);"><span style="font-family:Verdana;line-height:28px;">#头文件包含路径<br>INCLUDEPATH&nbsp;+= ..\..\qtcompnent\qtchklisten\inc ..\..\qtcompnent\qtclearfile\inc ../../validator\inc\validerrcode ../../qtcompnent/qtdir/inc ../inc ../../utillib/inc/xmlapi ../../utillib/inc/util ../../xercesc ../../qtcompnent/qteditor/inc ../../qtcompnent/qtfunreview/inc ../../qtcompnent/qttable/inc ../../qtcompnent/qtversion/inc ../../qtcompnent/qtini/inc ../../icdtool/icdservices/inc ../../icdtool/dataset/inc ../../icdtool/doi/inc ../../icdtool/reportcontrol/inc ../../icdtool/GSEconctrol/inc ../../icdtool/inputs/inc ../../icdtool/SMVconctrol/inc ../../icdtool/logcontrol/inc ../../scdpreview/inc/scdpreviewtoollib ../../scdpreview/form ../../icdtool/sclcontrol/inc ../../icdtool/log/inc ../../icdtool/settingcontrol/inc ../../qtcompnent\qteditor\inc ../../qtcompnent\qttreeview\inc ../../qtcompnent\qttabwidget\inc ../../communication/inc ../../qtcompnent/qtabout/inc ../iedmanage/inc ../ldmanage/inc ../foriecrun/inc ../../qtcompnent\validset\inc</span></span></p><p style="line-height:28px;color:rgb(102,102,102);font-family:'Hiragino Sans GB W3', 'Hiragino Sans GB', Arial, Helvetica, simsun, u5b8bu4f53;font-size:16px;"><span style="line-height:21px;color:rgb(0,204,255);"><span style="font-family:Verdana;line-height:28px;">#工程中包含的头文件<br>HEADERS&nbsp;+= ../inc/exportstable.h \<br>&nbsp;../inc/maintabwidget.h \<br>&nbsp;../inc/outputtab.h \<br>&nbsp;../inc/strutil.h \<br>&nbsp;../inc/treeeditview.h \<br>&nbsp;../inc/MainForm.h \<br>&nbsp;../inc/recenfileini.h \<br>&nbsp;../inc/ExportCIDFunction.h</span></span></p><p style="line-height:28px;color:rgb(102,102,102);font-family:'Hiragino Sans GB W3', 'Hiragino Sans GB', Arial, Helvetica, simsun, u5b8bu4f53;font-size:16px;"><span style="line-height:21px;color:rgb(0,204,255);"><span style="font-family:Verdana;line-height:28px;">#工程中包含的源文件<br>SOURCES&nbsp;+= ../src/main.cpp \<br>&nbsp;../src/exportstable.cpp \<br>&nbsp;../src/maintabwidget.cpp \<br>&nbsp;../src/outputtab.cpp \<br>&nbsp;../src/treeeditview.cpp \<br>&nbsp;../src/MainForm.cpp \<br>&nbsp;../src/recenfileini.cpp \<br>&nbsp;../src/ExportCIDFunction.cpp</span></span></p><p style="line-height:28px;color:rgb(102,102,102);font-family:'Hiragino Sans GB W3', 'Hiragino Sans GB', Arial, Helvetica, simsun, u5b8bu4f53;font-size:16px;"><span style="line-height:21px;color:rgb(0,204,255);"><span style="font-family:Verdana;line-height:28px;">#工程中包含的.ui设计文件<br>FORMS&nbsp;= ../form/scdmainform.ui \<br>&nbsp;../form/exportiedform.ui \<br>&nbsp;../form/Exportsedform.ui \<br>&nbsp;../form/Importsedform.ui \<br>&nbsp;../form/formiminputs.ui</span></span></p><p style="line-height:28px;color:rgb(102,102,102);font-family:'Hiragino Sans GB W3', 'Hiragino Sans GB', Arial, Helvetica, simsun, u5b8bu4f53;font-size:16px;"><span style="line-height:21px;color:rgb(0,204,255);"><span style="font-family:Verdana;line-height:28px;">#图像文件</span></span></p><p style="line-height:28px;color:rgb(102,102,102);font-family:'Hiragino Sans GB W3', 'Hiragino Sans GB', Arial, Helvetica, simsun, u5b8bu4f53;font-size:16px;"><span style="line-height:21px;color:rgb(0,204,255);"><span style="font-family:Verdana;line-height:28px;">IMAGES&nbsp;= images/substation.png \<br>&nbsp;images/communication.png \<br>&nbsp;images/autocom.png \<br>&nbsp;images/reportcfg.png \<br>&nbsp;images/comcfg.png \<br>&nbsp;images/filetrans.png \<br>&nbsp;images/review.png \<br>&nbsp;images/setting.png</span></span></p><p style="line-height:28px;color:rgb(102,102,102);font-family:'Hiragino Sans GB W3', 'Hiragino Sans GB', Arial, Helvetica, simsun, u5b8bu4f53;font-size:16px;"><span style="line-height:21px;color:rgb(0,204,255);"><span style="font-family:Verdana;line-height:28px;">#工程中包含的资源文件<br>RESOURCES&nbsp;&nbsp;&nbsp;= Scintilla.qrc</span></span></p><p style="line-height:28px;color:rgb(102,102,102);font-family:'Hiragino Sans GB W3', 'Hiragino Sans GB', Arial, Helvetica, simsun, u5b8bu4f53;font-size:16px;"><span style="line-height:21px;color:rgb(0,204,255);"><span style="font-family:Verdana;line-height:28px;">#CONFIG -= release<br>CONFIG -= debug</span></span></p><p style="line-height:28px;color:rgb(102,102,102);font-family:'Hiragino Sans GB W3', 'Hiragino Sans GB', Arial, Helvetica, simsun, u5b8bu4f53;font-size:16px;"><br><span style="line-height:21px;color:rgb(0,204,255);"><span style="font-family:Verdana;line-height:28px;">RC_FILE = scdtool.rc</span></span></p><p style="line-height:28px;color:rgb(102,102,102);font-family:'Hiragino Sans GB W3', 'Hiragino Sans GB', Arial, Helvetica, simsun, u5b8bu4f53;font-size:16px;"><span style="line-height:21px;color:rgb(0,204,255);"><span style="font-family:Verdana;line-height:28px;">&nbsp;<br>BINLIB = ../../bin ../../xercesc/lib</span></span></p><p style="line-height:28px;color:rgb(102,102,102);font-family:'Hiragino Sans GB W3', 'Hiragino Sans GB', Arial, Helvetica, simsun, u5b8bu4f53;font-size:16px;"><span style="line-height:21px;color:rgb(0,204,255);"><span style="font-family:Verdana;line-height:28px;">UI_HEADERS_DIR = ../inc&nbsp;&nbsp;# .ui文件转会为**.h&nbsp;&nbsp;&nbsp;存放的目录<br>UI_SOURCES_DIR = ../src&nbsp;&nbsp;# .ui文件转会为**.cpp 存放的目录<br>QMAKE_LIBDIR =
{BINLIB}

release {
TARGET = scdtool       #指定生成的应用程序名
OBJECTS_DIR = ../../obj/scdtool/release #指定目标文件(obj)的存放目录
}
debug {
TARGET = scdtool_d     #指定生成的应用程序名
OBJECTS_DIR = ../../obj/scdtool/debug #指定目标文件(obj)的存放目录
}

MOC_DIR = $${OBJECTS_DIR}
DESTDIR = ../../bin    #指定生成的应用程序放置的目录

 ==============================================================================

1.简介:
  qmake是Trolltech公司创建的用来为不同的平台和编译器书写Makefile的工具。是qt工具包的一部分.在Unixstdio.h>
  int main(int argc, char** argv)
  {
  printf(“Hello, world!\n”);
  return 0;
  }
  创建qmake需要的项目文件(hello.pro),
  SOURCES = hello.cpp
  CONFIG += qt warn_on release
  Makefile可以像这样由”.pro”文件生成:
  qmake -o Makefile hello.pro
  现在你的目录下已经产生了一个 Makefile 文件,输入”make” 指令就可以开始编译 hello.c 成执行文件,执行 ./hello 和 world 打声招呼吧!打开这个Makefile文件看看,是不是很专业啊!
  
  4.高级操作技巧
  当然,在实际使用过程中,我们的工程不可能象这个程序这样简单的,它可能有多个目录,多个头文件,多个源文件,需要链接器它不同的链接库等等情况。别急,让我和你慢慢道来。这些都是非常容易用qmake来实现的。我们从一个更加复杂的项目文件为例和你详细的讲诉qmake的高级技巧:
  项目文件示例:
  SOURCES += myqt.cpp
  SOURCES += main.cpp
  HEADERS += myqt.h
  FORMS += xsimform.ui
  TEMPLATE = lib
  CONFIG += debug warn_on qt thread x11 plugin
  TARGET = ../bin/panel_qt
  INCLUDEPATH = ../../../../xsim ../../../../xsim/IMdkit
  DEFINES = BDB_VERSION4 OS_LINUX
  从这个文件可以知道,SOURCES变量指向项目中的源文件,当项目中有多个源文件时,我们需对项目中的每一个源文件都这样做,直到结束:

 


  SOURCES += hello.cpp
  SOURCES += main.cpp
  当然,如果你喜欢使用像Make一样风格的语法,你也可以写成这样,一行写一个源文件,并用反斜线结尾,然后再起新的一行:
  SOURCES = hello.cpp main.cpp
  HEADERS变量指向项目中的头文件,多个头文件的时候,和多个源文件的解决方法一致。
  FORMS变量指向项目中使用到的窗体文件(qtdesign设计的.ui文件),qmake也注意了Qt的特殊需求,可以自动的包含moc和uic的连编规则。没有的话或者非qt程序可以不写。
  TEMPLATE变量告诉qmake为这个应用程序生成哪种makefile。下面是可供使用的选择:
  app - 建立一个应用程序的makefile。这是默认值,所以如果模板没有被指定,这个将被使用。
  lib - 建立一个链接库的makefile。
  vcapp - 建立一个应用程序的Visual Studio项目文件。
  vclib - 建立一个库的Visual Studio项目文件。
  subdirs - 这是一个特殊的模板,它可以创建一个能够进入特定目录并且为一个项目文件生成makefile并且为它调用make的mkefile。
  CONFIG变量变量指定了编译器所要使用的选项和所需要被连接的库。配置变量中可以添加任何东西,但只有下面这些选项可以被qmake识别。

 


  下面这些选项控制着使用哪些编译器标志:
  release - 应用程序将以release模式连编。如果”debug”被指定,它将被忽略。
  debug - 应用程序将以debug模式连编。
  warn_on - 编译器会输出尽可能多的警告信息。如果”warn_off”被指定,它将被忽略。
  warn_off - 编译器会输出尽可能少的警告信息。
  下面这些选项定义了所要连编的库/应用程序的类型:
  qt - 应用程序是一个Qt应用程序,并且Qt库将会被连接。
  thread - 应用程序是一个多线程应用程序。
  x11 - 应用程序是一个X11应用程序或库。
  windows - 只用于”app”模板:应用程序是一个Windows下的窗口应用程序。
  console - 只用于”app”模板:应用程序是一个Windows下的控制台应用程序。
  dll - 只用于”lib”模板:库是一个共享库(dll)。
  staticlib - 只用于”lib”模板:库是一个静态库。
  plugin - 只用于”lib”模板:库是一个插件,这将会使dll选项生效。
  TARGET变量指定生成的二进制代码的路径和文件名,如果建立的是一个链接库的话,它会在文件名前面自动加上”lib”和在最后自动加上”.so”.
  我们在使用过程中可能会使用到另外的一些函数库,链接库等。函数库的头文件指定使用INCLUDEPATH变量,其它链接库的指定可以通过LIBS 变量来指定,例LIBS += -lmath -L/usr/local/lib
  DEFINES变量的指定就如同make的-D选项一样。
  
  结束语
  Autoconf 和 Automake 功能十分强大,但对于普通用户来说,太过复杂。qmake方便、简单、快捷,是一个轻量级的makefile生成工具,虽然它是qt工具包的一部分,但它也完全可以用来进行其它程序makefile文件的生成,对于大多数人来说,它已经是非常的够用了。你也可以从qt提供的许多现存的源程序中找到相关的.pro项目文件,它们是学习qmake 更多技巧的最佳范例。


http://blog.csdn.NET/adriano119/archive/2010/09/11/5878169.aspx




  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

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

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

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值