当前位置:网站首页>Cmake qmake simple knowledge
Cmake qmake simple knowledge
2022-04-23 03:36:00 【Crispy eggplant strips】
CMake(Cross platform Make) It is an open source cross platform automatic construction tool , It can generate all kinds of... Across platforms makefile perhaps project file , Support the use of various compilation tools to generate executable programs or link libraries .
CMake Don't compile the program yourself , It's equivalent to using your own build script CMakeLists.txt, Call various compilation toolsets to generate executable programs or link libraries .
Generally used to compile programs makefile The files are complicated , It's more troublesome to write by yourself , And the use of CMake , You can write relatively simple CMakeLists.txt , from CMake according to CMakeLists.txt Automatic generation makefile, And then you can use it make Generate executable programs or link libraries .
qmake by QT Project building tools , Can generate cross platform .pro Project documents , It can generate corresponding files according to different operating systems and compiling tools Makefile, Used to build executable programs or link libraries .
Qt Use .pro Document management project ;
VC++ Then use .vcproj As a project file .
Integrated development environments are usually based on project documents (.pro/.vcproj) Manage and build projects .
Makefile
That is, generate script , Although you can call the compiler directly, such as g++ compiler , But if there are more code files in the project , Which code files have been updated and need to be recompiled , Which code has not been changed and does not need to be recompiled, etc , It's troublesome to rely on the programmer's own memory , What other code needs to be preprocessed or linked to which library files , These are complicated processes . In order to standardize the compilation and generation process of the program , Generated a standardized generation script , Namely Makefile, generator make According to the standard Makefile Automatically generate target program or library files .
To put it simply , Is to define Makefile , Let programmers just focus on how to write code , And all the dirty work in the process of generating the program is handed over to make Program .
Now? Makefile There are usually tools to automatically generate , Such as qmake Tools , This greatly reduces the burden on programmers .
Makefile
That is, generate script , Although you can call the compiler directly, such as g++ compiler , But if there are more code files in the project , Which code files have been updated and need to be recompiled , Which code has not been changed and does not need to be recompiled, etc , It's troublesome to rely on the programmer's own memory , What other code needs to be preprocessed or linked to which library files , These are complicated processes . In order to standardize the compilation and generation process of the program , Generated a standardized generation script , Namely Makefile, generator make According to the standard Makefile Automatically generate target program or library files . To put it simply , Is to define Makefile , Let programmers just focus on how to write code , And all the dirty work in the process of generating the program is handed over to make Program .
Now? Makefile There are usually tools to automatically generate , Such as qmake Tools , This greatly reduces the burden on programmers .
Linux/Unix The extension of static library in the system is generally .a, The dynamic library extension is generally .so .Windows In the system VC The static library extension used by the compiler is generally .lib, The dynamic library extension is generally .dll .
windeployqt yes Qt Provided Windows Platform packaging tool , It can find StuInfoFile.exe All dynamic link libraries required for executable files , And copy them to the current folder .
版权声明
本文为[Crispy eggplant strips]所创,转载请带上原文链接,感谢
https://yzsam.com/2022/04/202204220602451602.html
边栏推荐
- Unity games and related interview questions
- L3-011 direct attack Huanglong (30 points)
- vscode删除卸载残余
- Talent Plan 学习营初体验:交流+坚持 开源协作课程学习的不二路径
- Unity knowledge points (ugui)
- 標識符、關鍵字、數據類型
- AWS from entry to actual combat: creating accounts
- MySQL zip installation tutorial
- Test questions (2)
- Super easy to use asynchronous export function of Excel
猜你喜欢
Section 2 map and structure in Chapter 6
QT dynamic translation of Chinese and English languages
Visual programming -- how to customize the mouse cursor
Codeforces Round #784 (Div. 4)題解 (第一次AK cf (XD
The art of concurrent programming (3): an in-depth understanding of the principle of synchronized
Common net HP UNIX system FTP server listfiles returns null solution.
2022 团体程序设计天梯赛 模拟赛 L2-4 哲哲打游戏 (25 分)
Design and implementation of redis (2): how to handle expired keys
Supersocket is Use in net5 - startup
Punch in: 4.22 C language chapter - (1) first knowledge of C language - (11) pointer
随机推荐
If statement format flow
AWS from entry to actual combat: creating accounts
2022 团体程序设计天梯赛 模拟赛 L2-1 盲盒包装流水线 (25 分)
String input problem
The fourth operation
Problem a: face recognition
The art of concurrent programming (3): an in-depth understanding of the principle of synchronized
Unity knowledge points (ugui 2)
SQL learning record
批量下載文件----壓縮後再下載
Wechat applet cloud database value assignment to array error
Using swagger in. Net5
Database - MySQL -- Navicat import SQL error 1067 - invalid default value for 'paydate‘
Activity supports multi window display
"Visual programming" test paper
POI create and export Excel based on data
51 single chip microcomputer: D / a digital to analog conversion experiment
Leetcode punch in diary day 01
L3-011 直捣黄龙 (30 分)
The art of concurrent programming (5): the use of reentrantlock