91视频专区

《普法栏目剧单行道二》在线观看高清 - 百度网盘无删...

但他同时批评称,这是一场“人为制造的危机”,本来在几个月前是可以得到避免的。

2024年12月03日,颐和园将中国园林艺术发挥到极致,展现深厚的中国传统文化影响。颐和园展现古人浪漫情怀,山水、花木等元素相互辉映,构成诗意画面。

《普法栏目剧单行道二》在线观看高清 - 百度网盘无删...

101

买三 东方证券股份有限公司杭州龙井路证券营业部 1699.53 0.00他的父亲,一位严肃的官员,坚信儿子能够成就一番伟业。

CMakegoujianMakefileshendujiexi:congdicengyuanlidaofuzaxiangmu2023-06-10 21:24·linuxjishuzhanyi、CMakegoujianhoudexiangmujiegoujiexi(Analysis of the Project Structure After CMake Build)1.1 CMakegoujianhoudemulujiegou(Directory Structure After CMake Build)CMakegoujianwanchenghou,huizaixiangmudegenmuluxiashengchengyigemingweibuilddemulu。zhegemulushiCMakegoujianguochengzhongsuoyouzhongjianwenjianhezuizhongshengchengdemubiaowenjiandecunfangdi。xiamianwomenjiangxiangxijiexizhegemuludejiegou。shouxian,womenlaikanyixiabuildmuludeyijizimulu:CMakeFiles:zhegemuluzhongcunfangdeshiCMakezaigoujianguochengzhongshengchengdelinshiwenjian,baokuobianyiqijianchadejieguo、Findmokuai(Find Modules)chazhaodejieguodeng。zhexiewenjianzhuyaoyongyuCMakezishendexuqiu,yibanqingkuangxia,womenbuxuyaoguanzhuzhegemuludeneirong。Testing:ruguonidexiangmuzhongbaohanliaoCTestceshi,namezhegemulujianghuibeishengcheng。tabaohanliaosuoyouCTestceshidejieguo。bin:zhegemuluzhongbaohanliaosuoyoudekezhixingwenjian(Executable Files)。ruguonideCMakexiangmuzhongbaohanliaoduogekezhixingwenjian,nametamenduhuibeifangzaizhegemuluzhong。lib:zhegemuluzhongbaohanliaosuoyoudekuwenjian(Library Files)。wulunshijingtaiku(Static Libraries)huanshidongtaiku(Dynamic Libraries),duhuibeifangzaizhegemuluzhong。jiexialai,womenzaishenrudaoCMakeFilesmuluzhong,kanyixiatadeerjizimulu:project.dir:zhegemuluzhongbaohanliaoxiangmugoujianguochengzhongdelinshiwenjian,ru.owenjianhe.dwenjian。zhexiewenjianshibianyiqizaibianyiyuandaimashishengchengde。CMakeOutput.log:zhegewenjianjiluliaoCMakezaipeizhiguochengzhongdeshuchuxinxi,baokuobianyiqijianchadejieguo、Findmokuaichazhaodejieguodeng。CMakeError.log:zhegewenjianjiluliaoCMakezaipeizhiguochengzhongyudaodecuowuxinxi。yishangjiushiCMakegoujianhoudemulujiegoudejibenqingkuang。zaishijidexiangmuzhong,kenenghuigenjuxiangmudejutixuqiu,shengchenggengduodezimuluhewenjian。danshi,zhexiejibendemuluhewenjianshinizairenheyigeshiyongCMakegoujiandexiangmuzhongdunengkandaode。1.2 goujianshengchengdewenjianleixingjiqizuoyong(Types of Files Generated by the Build and Their Functions)CMakegoujianguochengzhonghuishengchengduozhongleixingdewenjian,meizhongwenjianduyouqitedingdezuoyong。xiamianwomenjiangxiangxijiexizhexiewenjiandeleixinghezuoyong。CMakeFilesmulu:zhegemuluzhongcunfangdeshiCMakezaigoujianguochengzhongshengchengdelinshiwenjian,baokuobianyiqijianchadejieguo、Findmokuai(Find Modules)chazhaodejieguodeng。zhexiewenjianzhuyaoyongyuCMakezishendexuqiu,yibanqingkuangxia,womenbuxuyaoguanzhuzhegemuludeneirong。project.dirmulu:zhegemuluzhongbaohanliaoxiangmugoujianguochengzhongdelinshiwenjian,ru.owenjianhe.dwenjian。zhexiewenjianshibianyiqizaibianyiyuandaimashishengchengde。CMakeOutput.logwenjian:zhegewenjianjiluliaoCMakezaipeizhiguochengzhongdeshuchuxinxi,baokuobianyiqijianchadejieguo、Findmokuaichazhaodejieguodeng。CMakeError.logwenjian:zhegewenjianjiluliaoCMakezaipeizhiguochengzhongyudaodecuowuxinxi。Testingmulu:ruguonidexiangmuzhongbaohanliaoCTestceshi,namezhegemulujianghuibeishengcheng。tabaohanliaosuoyouCTestceshidejieguo。binmulu:zhegemuluzhongbaohanliaosuoyoudekezhixingwenjian(Executable Files)。ruguonideCMakexiangmuzhongbaohanliaoduogekezhixingwenjian,nametamenduhuibeifangzaizhegemuluzhong。libmulu:zhegemuluzhongbaohanliaosuoyoudekuwenjian(Library Files)。wulunshijingtaiku(Static Libraries)huanshidongtaiku(Dynamic Libraries),duhuibeifangzaizhegemuluzhong。yishangjiushiCMakegoujianguochengzhongshengchengdezhuyaowenjianleixingjiqizuoyong。lijiezhexiewenjiandezuoyong,keyibangzhuwomengenghaodilijieCMakedegoujianguocheng。1.3 CMakeLists.txtyushengchengdeMakefiledeguanxi(The Relationship Between CMakeLists.txt and the Generated Makefile)zaiCMakegoujianxitongzhong,CMakeLists.txtwenjianheshengchengdeMakefilewenjianzhijiancunzaizhuomiqiedeguanxi。xiamianwomenjiangxiangxijiexizhezhongguanxi。CMakeLists.txtshiCMakegoujianxitongdehexinwenjian,tadingyiliaoxiangmudegoujianguizeheyilaiguanxi。zaizhixingCMakeminglingshi,CMakehuiduquCMakeLists.txtwenjian,jiexiqizhongdegoujianguizeheyilaiguanxi,ranhoushengchengxiangyingdeMakefilewenjian。MakefilewenjianshiyouCMakegenjuCMakeLists.txtwenjianshengchengde,tashiMakegoujiangongjukeyizhijieduqudegoujianjiaoben。Makefilewenjianzhongbaohanliaojutidebianyiminglinghelianjiemingling,yijiyuanwenjianhemubiaowenjianzhijiandeyilaiguanxi。zaiyigeCMakexiangmuzhong,tongchanghuiyouduogeCMakeLists.txtwenjian,meigemuluxiadukeyiyouyigeCMakeLists.txtwenjian。zhexieCMakeLists.txtwenjianzhongdingyidegoujianguizeheyilaiguanxi,huibeiCMakehebingdaoyiqi,shengchengyigehuoduogeMakefilewenjian。ruguoyigeCMakexiangmuzhongzhiyouyigeCMakeLists.txtwenjian,nameCMakehuishengchengyigeMakefilewenjian。ruguoyigeCMakexiangmuzhongyouduogeCMakeLists.txtwenjian,nameCMakehuizaimeigeCMakeLists.txtwenjiansuozaidemuluxiashengchengyigeMakefilewenjian。zhexieMakefilewenjianzhong,dingcengmuluxiadeMakefilewenjianshizhuMakefilewenjian,tahuidiaoyongqitamuluxiadeMakefilewenjian。zongdelaishuo,CMakeLists.txtwenjianheshengchengdeMakefilewenjianzhijiandeguanxishi:CMakeLists.txtwenjiandingyiliaoxiangmudegoujianguizeheyilaiguanxi,CMakegenjuCMakeLists.txtwenjianshengchengMakefilewenjian,ranhouMakegenjuMakefilewenjianzhixingjutidegoujianrenwu。xiangguanshipintuijiancongchengxubianyidaozhangwo cmake xiangmugoujiangongju2023jiuyexingqingyipiancandan,ruhenadaozijilixiangdeoffer?2023nianzuixinjishutupu,c++houduande8gejishuweidu,zhulinikuaisuchengweidaniuxuyaoC/C++ Linuxfuwuqijiagoushixuexiziliaojiaqun812855908huoqu(ziliaobaokuoC/C++,Linux,golangjishu,Nginx,ZeroMQ,MySQL,Redis,fastdfs,MongoDB,ZK,liumeiti,CDN,P2P,K8S,Docker,TCP/IP,xiecheng,DPDK,ffmpegdeng),mianfeifenxianger、shenrulijieCMakeshengchengdeMakefile2.1 MakefiledejibenjiegouheyuanliMakefileshiGNU makegongjudepeizhiwenjian,tadingyiliaoyizuguizelaizhidingnaxiewenjianxuyaobeigengxin,yijiruhegengxinzhexiewenjian。zaiC++xiangmuzhong,Makefiletongchangyongyubianyiyuandaimabingshengchengkezhixingwenjian。Makefiledejibenjiegoubaokuosangebufen:mubiao(Target)、yilai(Dependencies)hemingling(Commands)。mubiao(Target):zheshixuyaoshengchengdewenjianming。takeyishiyigeduixiangwenjian(Object File),yekeyishiyigekezhixingwenjian(Executable File)。yilai(Dependencies):zhexieshimubiaowenjianxuyaodeyuanwenjian。ruguorenheyigeyilaiwenjianbimubiaowenjiangengxin,namemubiaowenjianjiuxuyaobeizhongxinshengcheng。mingling(Commands):zhexieshishengchengmubiaowenjiansuoxuyaozhixingdeshellmingling。zhexieminglingbixuyiTabzifukaishi。xiamianshiyigejiandandeMakefileshili:target: dependencies commandszaiCMakezhong,CMakeLists.txtwenjianzhongdezhilinghuibeizhuanhuanweiMakefilezhongdemubiao、yilaihemingling。liru,add_executablezhilinghuishengchengyigemubiao,target_link_librarieszhilinghuishengchengyilai,ershijidebianyihelianjieminglingzeyouCMakezidongshengcheng。lijieMakefiledejibenjiegouheyuanli,duiyushenrulijieCMakeshengchengdeMakefileyouzhuozhongyaodezuoyong。zaixiayijiezhong,womenjiangjinyibutantaoduogeCMakeLists.txtshengchengdeMakefiledejiexi。2.2 duogeCMakeLists.txtshengchengdeMakefilejiexizaidaxingdeC++xiangmuzhong,tongchanghuiyouduogeCMakeLists.txtwenjian,meigemuluxiaduyouyige。zhezhongjiegouyouzhuyubaochixiangmudemokuaihua,shidemeigebufenkeyidulidibeigoujianheceshi。dangyunxingCMakeminglingshi,tahuishouxianchazhaogenmuluxiadeCMakeLists.txtwenjian,ranhoudiguidichulimeigezimuluzhongdeCMakeLists.txtwenjian。meigeCMakeLists.txtwenjianduhuishengchengyigeduiyingdeMakefile。zaizhegeguochengzhong,CMakehuichuliCMakeLists.txtwenjianzhongdezhiling,ruadd_executable、add_library、target_link_librariesdeng,bingjiangzhexiezhilingzhuanhuanweiMakefilezhongdemubiao、yilaihemingling。liru,ruguowomenyouruxiademulujiegou:project/├── CMakeLists.txt├── main.cpp└── module/ ├── CMakeLists.txt └── module.cppzaigenmuludeCMakeLists.txtwenjianzhong,womenkenenghuiyouruxiadezhiling:add_executable(main main.cpp)add_subdirectory(module)target_link_libraries(main module)zaimodulemuludeCMakeLists.txtwenjianzhong,womenkenenghuiyouruxiadezhiling:add_library(module module.cpp)zaizhegelizizhong,CMakehuishengchenglianggeMakefile,yigezaiprojectmulu,yigezaiproject/modulemulu。zaiprojectmuludeMakefilezhong,huiyouyigemingweimaindemubiao,tayilaiyumain.cpphemodulemuludeMakefilezhongshengchengdeku。zaiproject/modulemuludeMakefilezhong,huiyouyigemingweimoduledemubiao,tayilaiyumodule.cpp。tongguozhezhongfangshi,CMakeshidemeigezimulukeyidulidibeigoujian,tongshiyebaozhengliaozhenggexiangmudegoujianshunxu。2.3 CMakeyuMakefilededuiyingguanxiCMakeshiyigekuapingtaidegoujianxitong,tadezhuyaorenwushigenjuyonghudexuqiushengchengshidangdeMakefilewenjian。CMaketongguoduquCMakeLists.txtwenjianlailiaojieyonghudexuqiu,ranhoushengchengduiyingdeMakefilewenjian。zaiCMakeyuMakefilezhijian,cunzaiyizhongmingquededuiyingguanxi。CMakeLists.txtwenjianzhongdemeiyitiaozhiling,duhuizaishengchengdeMakefilewenjianzhongyouyigeduiyingdebiaoxian。xiamianwomenlaikanyixiechangjiandeCMakezhiling,yijitamenzaiMakefilezhongdeduiyingguanxi:add_executable:zhegeCMakezhilingyongyudingyiyigekezhixingwenjiandemubiao。zaishengchengdeMakefilezhong,zhegemubiaohuibeidingyiweiyigeguize,guizedemubiaoshikezhixingwenjian,yilaixiangshiyuanwenjian,minglingshibianyimingling。add_library:zhegeCMakezhilingyongyudingyiyigekuwenjiandemubiao。zaishengchengdeMakefilezhong,zhegemubiaoyehuibeidingyiweiyigeguize,guizedemubiaoshikuwenjian,yilaixiangshiyuanwenjian,minglingshibianyimingling。target_link_libraries:zhegeCMakezhilingyongyudingyimubiaodelianjieku。zaishengchengdeMakefilezhong,zhegezhilinghuiyingxiangdaolianjiemingling,lianjieminglinghuibaohanduiyingdekuwenjian。add_subdirectory:zhegeCMakezhilingyongyutianjiazimulu。zaishengchengdeMakefilezhong,zhegezhilinghuidaozhishengchengyigexindeMakefilewenjianzaiduiyingdezimuluzhong。tongguolijieCMakeyuMakefilededuiyingguanxi,womenkeyigenghaodilijieCMakedegongzuoyuanli,yijiruhebianxieyouxiaodeCMakeLists.txtwenjian。zaixiayizhangjiezhong,womenjiangjinyibutantaoCMakegoujianguochengdedicengyuanli。san、CMakegoujianguochengdedicengyuanli(Underlying Principles of the CMake Build Process)3.1 CMakegoujianguochengdejibenliucheng(Basic Flow of the CMake Build Process)CMakedegoujianguochengkeyifenweisangezhuyaobuzhou:peizhi(Configuration)、shengcheng(Generation)hegoujian(Build)。xiamianwomenjiangxiangxijieximeigebuzhou。1、peizhi(Configuration)peizhijieduanshiCMakejiexiCMakeLists.txtwenjiandeguocheng。zaizhegejieduan,CMakehuiduquCMakeLists.txtwenjian,bingzhixingqizhongdemingling。zhexieminglingzhuyaoyongyujianchaxitonghuanjing(lirubianyiqi、kudeng),shezhigoujianxuanxiang,yijidingyigoujianmubiao(liruku、kezhixingwenjiandeng)。CMakeLists.txtwenjianshiCMakedehexin,tadingyiliaoxiangmudegoujianguizeheyilaiguanxi。meigemulu(baokuozimulu)zhongdukeyiyouyigeCMakeLists.txtwenjian。zaipeizhijieduan,CMakehuicongdingcengmuludeCMakeLists.txtwenjiankaishi,diguidichulimeigezimuluzhongdeCMakeLists.txtwenjian。2、shengcheng(Generation)shengchengjieduanshiCMakegenjupeizhijieduandejieguo,shengchengshijidegoujianwenjiandeguocheng。zhexiegoujianwenjiantongchangshiMakefilewenjian,danyekeyishiqitaleixingdegoujianwenjian,liruNinjagoujianwenjian,huozheVisual Studioxiangmuwenjian,zhequjueyunixuanzedegoujiangongju。zaishengchengjieduan,CMakehuijiangCMakeLists.txtwenjianzhongdingyidegoujianguizeheyilaiguanxi,zhuanhuanweigoujiangongjukeyilijiedexingshi。liru,ruguonixuanzedegoujiangongjushiMake,CMakehuishengchengMakefilewenjian。meigemulu(baokuozimulu)zhongduhuishengchengyigeMakefilewenjian。3、goujian(Build)goujianjieduanshishiyonggoujiangongju(liruMake、NinjahuoVisual Studio)genjushengchengdegoujianwenjian,bianyiyuandaimabinglianjieshengchengmubiaowenjiandeguocheng。zaigoujianjieduan,goujiangongjuhuiduqushengchengdegoujianwenjian,anzhaoqizhongdingyideguizeheyilaiguanxi,zhixingshijidebianyihelianjiecaozuo。goujiangongjuhuizidongchuliyilaiguanxi,quebaozaibianyihelianjieyigemubiaowenjianzhiqian,qisuoyouyilaidemubiaowenjianduyijingbeizhengquedibianyihelianjie。yishangjiushiCMakegoujianguochengdejibenliucheng。zailijieliaozhegeliuchengzhihou,womenjiukeyigengshenruditantaoCMakeruheshengchengMakefile,yijiCMakegoujianguochengzhongdeguanjianbuzhouliao。3.2 CMakeruheshengchengMakefile(How CMake Generates Makefile)CMakeshengchengMakefiledeguochengshizaiqishengchengjieduanwanchengde。zhegeguochengzhuyaoshejidaoCMakedehexinzujian——shengchengqi(Generator)。xiamianwomenjiangxiangxijiexizhegeguocheng。1、xuanzeshengchengqi(Selecting a Generator)zaiCMakedeshengchengjieduankaishishi,shouxianxuyaoxuanzeyigeshengchengqi。shengchengqishiCMakedeyigehexinzujian,tafuzejiangCMakeLists.txtwenjianzhongdegoujianguizeheyilaiguanxi,zhuanhuanweitedinggoujiangongjukeyilijiedexingshi。CMakezhichiduozhongshengchengqi,keyishengchengMakefilewenjian,yekeyishengchengNinjagoujianwenjian,huozheVisual Studioxiangmuwenjiandeng。xuanzeshengchengqidefangshitongchangshizaiyunxingCMakeminglingshi,tongguo-Gxuanxiangzhiding。liru,ruguonixiangshengchengUnixfenggedeMakefilewenjian,keyishiyong"Unix Makefiles"shengchengqi,minglingruxia:cmake -G "Unix Makefiles"ruguomeiyouzhidingshengchengqi,CMakehuixuanzeyigemorendeshengchengqi,zhegemorendeshengchengqitongchangshigenjunidexitonghuanjingzidongxuanzede。2、shengchengMakefilexuanzehaoshengchengqizhihou,CMakejiuhuikaishishengchengMakefilewenjian。zaizhegeguochengzhong,CMakehuibianlixiangmuzhongdemeigemulu(baokuozimulu),duimeigemuluzhongdeCMakeLists.txtwenjianjinxingchuli。duiyumeigeCMakeLists.txtwenjian,CMakehuijiexiqizhongdemingling,genjuzhexieminglingdingyidegoujianguizeheyilaiguanxi,shengchengduiyingdeMakefilewenjian。meigeCMakeLists.txtwenjianduhuishengchengyigeMakefilewenjian,zhegeMakefilewenjianzhongbaohanliaobianyihelianjiegaimuluzhongdemubiaowenjiansuoxuyaodeguizehemingling。zaishengchengMakefilewenjianshi,CMakehuizidongchulimubiaowenjianzhijiandeyilaiguanxi。ruguoyigemubiaowenjianyilaiyuqitamubiaowenjian,CMakehuizaishengchengdeMakefilewenjianzhong,weizhegemubiaowenjiantianjiaxiangyingdeyilaiguize。yishangjiushiCMakeruheshengchengMakefiledeguocheng。lijieliaozhegeguocheng,womenjiukeyigenghaodilijieCMakegoujianguochengzhongdeguanjianbuzhou,yijiCMakeyuMakefilezhijiandeguanxiliao。3.3 CMakegoujianguochengzhongdeguanjianbuzhou(Key Steps in the CMake Build Process)CMakegoujianguochengzhongdeguanjianbuzhouzhuyaobaokuoyixiajigefangmian:1、jiexiCMakeLists.txtwenjian(Parsing CMakeLists.txt Files)zheshiCMakegoujianguochengdediyibu,yeshizuiguanjiandeyibu。CMakeLists.txtwenjianshiCMakedehexin,tadingyiliaoxiangmudegoujianguizeheyilaiguanxi。CMakexuyaojiexizhegewenjian,yihuoqugoujianxiangmusuoxudesuoyouxinxi。2、jianchaxitonghuanjing(Checking System Environment)zaiCMakeLists.txtwenjianzhong,tongchanghuibaohanyixiejianchaxitonghuanjingdemingling,lirujianchabianyiqi、kudeng。zhexieminglingzaiCMakegoujianguochengzhonghuibeizhixing,yiquebaoxitonghuanjingmanzuxiangmudegoujianxuqiu。3、shengchenggoujianwenjian(Generating Build Files)CMakedezhuyaorenwushishengchenggoujianwenjian,zhexiegoujianwenjiantongchangshiMakefilewenjian,danyekeyishiqitaleixingdegoujianwenjian,liruNinjagoujianwenjian,huozheVisual Studioxiangmuwenjian,zhequjueyunixuanzedegoujiangongju。shengchenggoujianwenjiandeguochengshiCMakegoujianguochengzhongdeyigeguanjianbuzhou。4、zhixinggoujianmingling(Executing Build Commands)zaishengchengliaogoujianwenjianzhihou,jiukeyikaishizhixinggoujianminglingliao。zhexiegoujianminglingtongchangshiyougoujiangongju(liruMake、NinjahuoVisual Studio)zhixingde。goujiangongjuhuigenjugoujianwenjianzhongdingyideguizehemingling,bianyiyuandaimabinglianjieshengchengmubiaowenjian。yishangjiushiCMakegoujianguochengzhongdeguanjianbuzhou。lijieliaozhexiebuzhou,womenjiukeyigenghaodilijieCMakedegongzuoyuanli,yijiruheshiyongCMakejinxingxiangmugoujianliao。si、CMakezaifuzaxiangmuzhongdeyingyong(Application of CMake in Complex Projects)4.1 fuzaxiangmuzhongdeCMakegoujiancelue(CMake Build Strategy in Complex Projects)zaifuzadexiangmuzhong,CMakedegoujianceluexuyaogengjiajingxihezhouquan。womenxuyaokaolvdaoxiangmudemokuaihua,yilaiguanxi,yijikenengcunzaidepingtaichayi。yixiashiyixiezaifuzaxiangmuzhongshiyongCMakedeceluehejianyi。4.1.1 mokuaihuadeCMakeLists.txt(Modularized CMakeLists.txt)zaidaxingxiangmuzhong,womentongchanghuikandaoxiangmubeihuafenweiduogemokuaihuozixiangmu,meigemokuaiduyouzijideyuandaimaheyilai。zhezhongqingkuangxia,womenkeyiweimeigemokuaichuangjianyigeCMakeLists.txtwenjian,zheyangkeyishigoujianguochenggengjiaqingxi,yefangbianwomenguanlimeigemokuaidegoujianguize。liru,womenkeyizaimeigemokuaidemuluxiachuangjianyigeCMakeLists.txtwenjian,ranhouzaixiangmudedingjimuluxiadeCMakeLists.txtwenjianzhongshiyongadd_subdirectory()minglinglaitianjiazhexiemokuai。4.1.2 guanliyilaiguanxi(Managing Dependencies)zaifuzadexiangmuzhong,butongdemokuaikenenghuiyougezhongyilaiguanxi。CMaketigongliaoyixieminglinglaibangzhuwomenguanlizhexieyilaiguanxi,lirutarget_link_libraries()minglingkeyiyonglaizhidingyigemubiaoxuyaolianjiedeku。zaichuliyilaiguanxishi,womenxuyaozhuyideyigezhongyaoyuanzeshi:jinliangrangyilaiguanximingquehezhiguan。zheyiweizhuo,ruguoyigemokuaiAyilaiyumokuaiB,namezaimokuaiAdeCMakeLists.txtwenjianzhong,womenyinggaimingquedizhichuzhegeyilaiguanxi。4.1.3 chulipingtaichayi(Handling Platform Differences)zaikuapingtaidexiangmuzhong,womenkenengxuyaochulibutongpingtaidechayi。CMaketigongliaoyixiebianliangheminglinglaibangzhuwomenchulizhexiechayi,liruCMAKE_SYSTEM_NAMEbianliangkeyiyonglaijiancedangqiandecaozuoxitong,if()minglingkeyiyonglaigenjubutongdetiaojianzhixingbutongdemingling。zaichulipingtaichayishi,womenyinggaijinliangbimianyingbianmatedingpingtaidexinxi。xiangfan,womenyinggaijinkenengdishiyongCMaketigongdebianlianghemingling,zheyangkeyishiwomendeCMakeLists.txtwenjiangengjiatongyonghekeweihu。yishangjiushizaifuzaxiangmuzhongshiyongCMakedeyixieceluehejianyi。zaishijiyingyongzhong,womenhuanxuyaogenjuxiangmudejutiqingkuanghexuqiulaidiaozhengheyouhuawomendeCMakegoujiancelue。4.1.4 shiyongxiandaiCMakemingling(Using Modern CMake Commands)xiandaideCMakebanbentigongliaoyixiexindeminglinghetexing,zhexieminglinghetexingkeyishiwomendeCMakeLists.txtwenjiangengjiajianjieheyiyulijie。liru,target_include_directories()minglingkeyiyonglaizhidingyigemubiaodetouwenjiansousuolujing,zhebishiyongjiudeinclude_directories()minglinggengjialinghuohezhiguan。zaishiyongxiandaiCMakeminglingshi,womenxuyaozhuyideyigezhongyaoyuanzeshi:jinliangshiyongmubiaoshuxing(target properties)erbushiquanjubianliang(global variables)。zheshiyinweimubiaoshuxingkeyishiwomendeCMakeLists.txtwenjiangengjiamokuaihua,yegengrongyilijieheweihu。4.1.5 liyongCMakedejiaobengongneng(Leveraging CMake’s Scripting Capabilities)CMakebujinshiyigegoujiangongju,tayeshiyizhongjiaobenyuyan。womenkeyiliyongCMakedejiaobengongnenglaishixianyixiefuzadegoujianluoji,liru,womenkeyishiyongif()、foreach()dengminglinglaibianxiexunhuanhetiaojianyuju。zaishiyongCMakedejiaobengongnengshi,womenxuyaozhuyideyigezhongyaoyuanzeshi:jinliangbimianguodufuzadejiaobenluoji。guodufuzadejiaobenluojikenenghuishiwomendeCMakeLists.txtwenjiannanyilijieheweihu。xiangfan,womenyinggaijinkenengdishiyongCMaketigongdeminglinghetexing,zheyangkeyishiwomendeCMakeLists.txtwenjiangengjiajianjieheyiyulijie。yishangjiushizaifuzaxiangmuzhongshiyongCMakedeyixieceluehejianyi。zaishijiyingyongzhong,womenhuanxuyaogenjuxiangmudejutiqingkuanghexuqiulaidiaozhengheyouhuawomendeCMakegoujiancelue。4.2 duogeCMakeLists.txtzaifuzaxiangmuzhongdeguanli(Management of Multiple CMakeLists.txt in Complex Projects)zaidaxingdefuzaxiangmuzhong,womentongchanghuiyouduogeCMakeLists.txtwenjian,meigezimuluxiadukenengyouyige。zhexieCMakeLists.txtwenjiangongtongdingyiliaozhenggexiangmudegoujianguize。guanlizhexieCMakeLists.txtwenjianshiyigezhongyaoderenwu,yixiashiyixieceluehejianyi。4.2.1 mokuaihuaguanli(Modular Management)meigeCMakeLists.txtwenjianyinggaizhifuzeguanliqisuozaimuluxiadeyuandaimaheyilai。zheyangkeyishimeigeCMakeLists.txtwenjiandeneirongbaochijianjie,yefangbianwomenlijieheweihumeigemokuaidegoujianguize。4.2.2 tongyidegoujianguize(Unified Build Rules)jinguanmeigeCMakeLists.txtwenjianduyouqizijidegoujianguize,danwomenyinggaijinliangshizhexiegoujianguizebaochiyizhi。zheyangkeyishiwomendegoujianguochenggengjiakeyuce,yefangbianwomenguanliheweihuwomendegoujianguize。4.2.3 liyongCMakedebaoguanligongneng(Leveraging CMake’s Package Management Features)CMaketigongliaoyixieminglinghetexinglaibangzhuwomenguanlixiangmudeyilai,lirufind_package()minglingkeyiyonglaichazhaohejiazaiwaibuku。womenyinggaijinliangliyongzhexieminglinghetexing,zheyangkeyishiwomendeCMakeLists.txtwenjiangengjiajianjie,yekeyibimianyixiechangjiandeyilaiwenti。4.2.4 bimianyingbianmalujing(Avoid Hard-Coded Paths)zaiCMakeLists.txtwenjianzhong,womenyinggaijinliangbimianyingbianmalujing。yingbianmadelujingkenenghuishiwomendegoujianguochengyilaiyutedingdemulujiegou,zhehuijiangdiwomendegoujianguizedekeyizhixing。xiangfan,womenyinggaijinkenengdishiyongCMaketigongdebianliangheminglinglaizhidinglujing,zheyangkeyishiwomendeCMakeLists.txtwenjiangengjiatongyonghekeweihu。yishangjiushizaifuzaxiangmuzhongguanliduogeCMakeLists.txtwenjiandeyixieceluehejianyi。zaishijiyingyongzhong,womenhuanxuyaogenjuxiangmudejutiqingkuanghexuqiulaidiaozhengheyouhuawomendeguanlicelue。4.3 CMakezaidaxingxiangmuzhongdezuijiashijian(Best Practices of CMake in Large Projects)zaidaxingxiangmuzhongshiyongCMake,womenxuyaozunxunyixiezuijiashijian,yiquebaogoujianguochengdegaoxiao、wendinghekeweihu。yixiashiyixiezaidaxingxiangmuzhongshiyongCMakedezuijiashijian。4.3.1 shiyongzuixinbanbendeCMake(Use the Latest Version of CMake)jinkenengshiyongzuixinbanbendeCMake。xinbanbendeCMaketongchanghuibaohanyixiexindetexinghegaijin,zhexietexinghegaijinkenenghuishiwomendegoujianguochenggengjiagaoxiaohewending。ciwai,xinbanbendeCMakeyekenenghuixiufuyixiejiubanbenzhongdewentihequexian。4.3.2 bimianzaiCMakeLists.txtwenjianzhongxiugaibianyiqibiaozhi(Avoid Modifying Compiler Flags in CMakeLists.txt Files)zaiCMakeLists.txtwenjianzhongzhijiexiugaibianyiqibiaozhikenenghuidaozhiyixiewenti。liru,zhekenenghuifugaiyonghuzaiminglingxingzhongzhidingdebianyiqibiaozhi,huozhedaozhizaibutongpingtaishangdegoujianxingweibuyizhi。xiangfan,womenyinggaishiyongCMaketigongdeminglinghetexinglaiguanlibianyiqibiaozhi,lirutarget_compile_options()mingling。4.3.3 shiyongCMakedeceshigongneng(Use CMake’s Testing Features)CMaketigongliaoyixieminglinghetexinglaibangzhuwomenguanliheyunxingceshi,liruenable_testing()minglingheadd_test()mingling。womenyinggaijinliangliyongzhexieminglinghetexing,zheyangkeyishiwomendeceshiguochenggengjiazidonghuahekekong。4.3.4 shiyongCMakedeanzhuanggongneng(Use CMake’s Installation Features)CMaketigongliaoyixieminglinghetexinglaibangzhuwomenguanlixiangmudeanzhuangguocheng,liruinstall()mingling。womenyinggaijinliangliyongzhexieminglinghetexing,zheyangkeyishiwomendeanzhuangguochenggengjiazidonghuahekekong。yishangjiushizaidaxingxiangmuzhongshiyongCMakedeyixiezuijiashijian。zaishijiyingyongzhong,womenhuanxuyaogenjuxiangmudejutiqingkuanghexuqiulaidiaozhengheyouhuawomendegoujianguocheng。wu、CMakeshengchengdeMakefilexiangjie5.1 CMakeruhefanyishengchengMakefilezaishenrulijieCMakeruhefanyishengchengMakefilezhiqian,womenshouxianlaikanyixiaCMakeyuMakefiledeguanxi。ruxiatusuoshi,CMaketongguojiexiCMakeLists.txtwenjian,shengchengduiyingdeMakefile,ranhouzhixingMakefilejinxingbianyilianjie,zuihoushengchengkezhixingwenjian。CMakedezhuyaogongzuojiushijiexiCMakeLists.txtwenjian,bingjiangqifanyichengMakefile。CMakeLists.txtwenjianshiCMakedehexin,tadingyiliaoxiangmudegoujianguize,baokuoxiangmudemulujiegou、xuyaobianyideyuanwenjian、yilaiguanxi、bianyicanshudengxinxi。CMaketongguoduquCMakeLists.txtwenjian,lijiezhexiegoujianguize,ranhoushengchengduiyingdeMakefile。zaishengchengMakefiledeguochengzhong,CMakehuijinxingyixiliedefanyicaozuo。zhexiecaozuozhuyaobaokuo:jiexiCMakeLists.txtwenjian:CMakeshouxianhuiduquCMakeLists.txtwenjian,jiexiqizhongdeminglinghecanshu,lijiexiangmudegoujianguize。shengchengMakefile:genjujiexidedaodegoujianguize,CMakehuishengchengduiyingdeMakefile。zhegeMakefilebaohanliaosuoyoudebianyilianjiemingling,yijiyuanwenjianhemubiaowenjianzhijiandeyilaiguanxi。chuliyilaiguanxi:zaishengchengMakefiledeguochengzhong,CMakehuichuliyuanwenjianzhijiandeyilaiguanxi。ruguoyigeyuanwenjianyilaiyulingyigeyuanwenjian,namezaiMakefilezhong,zhegeyuanwenjiandebianyiminglingjiuhuiyilaiyulingyigeyuanwenjiandebianyimingling。shezhibianyicanshu:CMakehuanhuishezhiMakefilezhongdebianyicanshu,baokuobianyiqixuanxiang、lianjieqixuanxiangdeng。zhexiecanshuhuiyingxiangdaobianyilianjiedeguocheng。yishangjiushiCMakeruhefanyishengchengMakefiledejibenguocheng。zaihouxudexiaojiezhong,womenjiangshenrutantaoMakefiledexiangxijiegouheyuanli,yijiruhezaiCMakezhongshiyongwaibuMakefiledenggaojihuati。5.2 MakefiledexiangxijiexiMakefileshiyoumakegongjuzhixingdeyizhongjiaobenwenjian,tamiaoshuliaoyizumubiao(target)yijigoujianzhexiemubiaosuoxudeguize(rule)。zaiCMakeshengchengdeMakefilezhong,meiyigemubiaotongchangduiyingyigehuoduogeyuanwenjian,erguizezemiaoshuliaoruhecongzhexieyuanwenjianshengchengmubiao。yixiashiyigejiandandeMakefileshili:all: hellohello: main.o function.o g++ main.o function.o -o hellomain.o: main.cpp g++ -c main.cppfunction.o: function.cpp g++ -c function.cppclean: rm *.o hellozaizhegeshilizhong,all、hello、main.o、function.ohecleandushimubiao,ermeigemubiaohoumiandeneirongzeshigoujiangaimubiaodeguize。liru,hellomubiaodeguizeshig++ main.o function.o -o hello,zhetiaoguizegaosumakegongjuruhecongmain.ohefunction.ozhelianggeyuanwenjianshengchenghellozhegemubiao。zaiCMakeshengchengdeMakefilezhong,zhexieguizehuigengjiafuza,yinweitamenxuyaochulixiangmuzhongdeyilaiguanxi、bianyicanshudengwenti。danshi,jibendejiegouheyuanlishixiangtongde:meigemubiaoduyouyizuguize,zhexieguizemiaoshuliaoruhecongyuanwenjianshengchengmubiao。5.3 CMakeruhefanyishengchengMakefiledangrankeyi,rangwomengengshenruditantaoyixieCMakeminglingheshengchengdeMakefilezhijiandeguanxi。add_executable:zhegeminglingzaiCMakezhongyongyudingyiyigemubiaokezhixingwenjian。liru,add_executable(hello main.cpp)huidingyiyigemingweihellodemubiao,zhegemubiaoyoumain.cppzhegeyuanwenjianshengcheng。zaishengchengdeMakefilezhong,zhegeminglinghuibeifanyichengyigebianyimingling,ru$(CXX) $(CXXFLAGS) -o hello main.cpp。zhetiaominglinggaosumakegongjushiyongC++bianyiqi(( C X X ) )hebianyixuanxiang( (CXX))hebianyixuanxiang((CXX))hebianyixuanxiang((CXXFLAGS))laibianyimain.cpp,bingjiangshuchuwenjianmingmingweihello。add_library:zhegeminglingzaiCMakezhongyongyudingyiyigemubiaokuwenjian。liru,add_library(mylib mylib.cpp)huidingyiyigemingweimylibdemubiao,zhegemubiaoyoumylib.cppzhegeyuanwenjianshengcheng。zaishengchengdeMakefilezhong,zhegeminglinghuibeifanyichengyigekushengchengmingling,ru$(AR) $(ARFLAGS) mylib mylib.cpp。zhetiaominglinggaosumakegongjushiyongkushengchengqi(( A R ) )hekushengchengxuanxiang( (AR))hekushengchengxuanxiang((AR))hekushengchengxuanxiang((ARFLAGS))laishengchengmylibzhegeku。target_link_libraries:zhegeminglingzaiCMakezhongyongyudingyimubiaodelianjieku。liru,target_link_libraries(hello mylib)huigaosuCMake,hellozhegemubiaoxuyaolianjiemylibzhegeku。zaishengchengdeMakefilezhong,zhegeminglinghuibeifanyichengyigelianjiemingling,ru$(CXX) $(LDFLAGS) -o hello main.cpp -lmylib。zhetiaominglinggaosumakegongjuzailianjiehelloshi,xuyaolianjiemylibzhegeku。yishangjiushiCMakeminglingheshengchengdeMakefilezhijiandeyixiejibenguanxi。zaishijidexiangmuzhong,zhexieguanxikenenghuigengfuza,yinweiCMakeheMakefiledushifeichangqiangdadegongju,tamentigongliaoxuduogaojigongnenglaichulixiangmuzhongdegezhongwenti。danshi,lijiezhexiejibenguanxishilijieCMakeheMakefiledeguanjian。5.4 CMakeshengchengdeMakefilezhongdechangjianwentijijiejuefanganzaishiyongCMakeshengchengMakefiledeguochengzhong,kenenghuiyudaoyixiechangjiandewenti。zhexiewentikenengshejidaoMakefiledeshengcheng、zhixing、yijiyilaiguanxidechulidengfangmian。xiamianwomenjiangxiangxijieshaozhexiewenti,yijixiangyingdejiejuefangan。Makefileshengchengshibai:zheshiyigebijiaochangjiandewenti,tongchangshiyouyuCMakeLists.txtwenjianzhongdecuowudaozhide。jiejuezhegewentidefangfashijianchaCMakeLists.txtwenjian,quebaoqizhongdeminglinghecanshudushizhengquede。Makefilezhixingcuowu:zhegewentitongchangshiyouyuMakefilezhongdeminglingcuowudaozhide。jiejuezhegewentidefangfashijianchaMakefile,quebaoqizhongdebianyilianjieminglingdushizhengquede。yilaiguanxichulicuowu:zhegewentitongchangshiyouyuCMakechuliyuanwenjianzhijiandeyilaiguanxishichucuodaozhide。jiejuezhegewentidefangfashijianchaCMakeLists.txtwenjian,quebaoqizhongdeyilaiguanxidushizhengquede。yishangjiushizaishiyongCMakeshengchengMakefileshikenengyudaodeyixiechangjianwenti,yijixiangyingdejiejuefangan。zaishijishiyongzhong,kenenghuanhuiyudaoqitadewenti,zheshihouxuyaogenjujutidecuowuxinxi,jinxingxiangyingdepaichahejiejue。liu、CMakeyuwaibuMakefiledejiaohu(Interaction Between CMake and External Makefile)6.1 ruhezaiCMakezhongshiyongwaibuMakefile(How to Use External Makefile in CMake)zaiCMakezhongshiyongwaibuMakefile,womenkeyishiyongadd_custom_commandheadd_custom_targetzhelianggemingling。zhelianggeminglingkeyiyonglaizhixingyixiezidingyidegoujianguize,biruyunxingyigejiaoben,chuangjianyigewenjian,huozheyunxingyigeMakefile。6.1.1 add_custom_commandadd_custom_commandminglingyongyudingyiruheshengchengyigewenjian。zhegeminglingyouhenduocanshu,danshizuichangyongdeshiOUTPUT,COMMANDheDEPENDS。OUTPUTcanshuyongyuzhidingshengchengdewenjian。COMMANDcanshuyongyuzhidingshengchengwenjiandemingling,keyishirenheshellmingling。DEPENDScanshuyongyuzhidingshengchengwenjiansuoyilaidewenjian。liru,womenkeyishiyongyixiaminglinglaiyunxingyigewaibuMakefile:add_custom_command( OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/generated_file COMMAND make -C ${CMAKE_CURRENT_SOURCE_DIR}/external_project DEPENDS ${CMAKE_CURRENT_SOURCE_DIR}/external_project/Makefile)zhegeminglingbiaoshi,ruguogenerated_filebucunzai,huozheexternal_project/Makefileyourenhegaidong,namejiuhuizhixingmake -C external_projectminglinglaishengchenggenerated_file。6.1.2 add_custom_targetraner,add_custom_commandzhiyouzaiqishuchuwenjianbeiqitamubiaoshiyongshi,caihuibeizhixing。ruguowomenxiangyaozaimeicigoujianshiduzhixingmougemingling,namewomenxuyaoshiyongadd_custom_targetmingling。add_custom_targetminglingyongyudingyiyigezidingyidemubiao。zhegemubiaobuhuishengchengrenhewenjian,yebuhuizaigoujianshizidongbeizhixing。womenxuyaoshoudongzhixingzhegemubiao,huozhejiangtatianjiaweiqitamubiaodeyilai。liru,womenkeyishiyongyixiaminglinglaidingyiyigeyunxingwaibuMakefiledemubiao:add_custom_target( run_external_makefile COMMAND make -C ${CMAKE_CURRENT_SOURCE_DIR}/external_project)zhegeminglingdingyiliaoyigemingweirun_external_makefiledemubiao。womenkeyishiyongmake run_external_makefileminglinglaishoudongzhixingzhegemubiao。ruguowomenxiangyaozaimeicigoujianshiduzhixingzhegemubiao,namewomenkeyijiangtatianjiaweiqitamubiaodeyilai。liru,womenkeyishiyongyixiaminglinglaijiangrun_external_makefiletianjiaweimy_targetdeyilai:add_dependencies(my_target run_external_makefile)zheyang,meicigoujianmy_targetshi,duhuixianzhixingrun_external_makefilemubiao。yishangjiushiruhezaiCMakezhongshiyongwaibuMakefiledejibenfangfa。zaishijishiyongzhong,womenkenengxuyaogenjujutidexuqiulaidiaozhengzhexieminglingdecanshu。6.1.3 add_custom_commanddeqitacanshuchuliaoOUTPUT,COMMANDheDEPENDScanshuwai,add_custom_commandminglinghuanyouyixieqitadecanshu,keyiyonglaikongzhiminglingdexingwei。WORKING_DIRECTORYcanshuyongyuzhidingminglingdegongzuomulu。ruguobuzhidingzhegecanshu,nameminglingdegongzuomulujiushidangqiandegoujianmulu。COMMENTcanshuyongyuzhidingyigezhushi,zhegezhushihuizaiminglingzhixingshixianshizaikongzhitaishang。VERBATIMcanshuyongyukongzhiminglingdecanshushifouxuyaozhuanyi。ruguoshezhiweiTRUE,nameminglingdecanshujiuhuibeizhuanyi,zheyangjiukeyianquandichulibaohanteshuzifudecanshu。liru,womenkeyishiyongyixiaminglinglaiyunxingyigewaibuMakefile,bingxianshiyigezhushi:add_custom_command( OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/generated_file COMMAND make -C ${CMAKE_CURRENT_SOURCE_DIR}/external_project DEPENDS ${CMAKE_CURRENT_SOURCE_DIR}/external_project/Makefile WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR} COMMENT "Running external Makefile" VERBATIM)zhegeminglingbiaoshi,ruguogenerated_filebucunzai,huozheexternal_project/Makefileyourenhegaidong,namejiuhuizai${CMAKE_CURRENT_BINARY_DIR}muluxiazhixingmake -C external_projectminglinglaishengchenggenerated_file,bingxianshi"Running external Makefile"dezhushi。yishangjiushizaiCMakezhongshiyongwaibuMakefiledejibenfangfa。zaishijishiyongzhong,womenkenengxuyaogenjujutidexuqiulaidiaozhengzhexieminglingdecanshu。6.2 waibuMakefileruheyingxiangCMakeshengchengdeMakefile(How External Makefile Affects Makefile Generated by CMake)zaiCMakezhong,womenkeyitongguoadd_custom_commandhuoadd_custom_targetminglinglaicharuwaibuMakefile,congeryingxiangCMakeshengchengdeMakefile。xiamianshizhegeguochengdeshiyitu:bianjitianjiatupianzhushi,buchaoguo 140 zi(kexuan)zaizhegeguochengzhong,CMakeshouxianjiexiCMakeLists.txtwenjian,shengchengCMakeCache.txtwenjian。ranhou,CMakegenjuCMakeCache.txtwenjianshengchengMakefile。zaishengchengMakefiledeguochengzhong,CMakehuizhixingadd_custom_commandhuoadd_custom_targetmingling,charuwaibuMakefile。charuwaibuMakefiledezhuyaomudeshiweiliaozengjiayixiezidingyidegoujianguize。liru,womenkenengxuyaozaigoujianguochengzhongzhixingyixieteshudemingling,huozheshengchengyixieteshudewenjian。tongguocharuwaibuMakefile,womenkeyizaiCMakedegoujianguochengzhongzhixingzhexiezidingyidegoujianguize。raner,charuwaibuMakefileyekenenghuidailaiyixiewenti。liru,ruguowaibuMakefilezhongdegoujianguizeyuCMakeshengchengdegoujianguizechongtu,namekenenghuidaozhigoujianshibai。yinci,zaicharuwaibuMakefileshi,womenxuyaoquebaowaibuMakefilezhongdegoujianguizeyuCMakeshengchengdegoujianguizeshijianrongde。zaishijishiyongzhong,womenkenengxuyaogenjujutidexuqiulaidiaozhengcharuwaibuMakefiledefangshi。liru,womenkeyitongguoxiugaiadd_custom_commandhuoadd_custom_targetminglingdecanshu,laikongzhiwaibuMakefiledecharuweizhi,huozhekongzhiwaibuMakefiledezhixingfangshi。6.3 gaojijiqiao:ziyoukongzhiCMakeshengchengguize(Advanced Techniques: Freely Control CMake Generation Rules)CMaketigongliaoyixiliedemingling,keyiyonglaiziyoukongzhishengchengguize。zhexieminglingkeyiyonglaidingyizidingyidemubiao,tianjiayilaiguanxi,shezhibianyixuanxiang,dengdeng。xiamianwomenjiangjieshaoyixiegaojidejiqiao,keyibangzhunigenghaodikongzhiCMakedeshengchengguize。6.3.1 zidingyimubiao(Custom Targets)zaiCMakezhong,womenkeyishiyongadd_custom_targetminglinglaidingyiyigezidingyidemubiao。zhegemubiaobuhuishengchengrenhewenjian,yebuhuizaigoujianshizidongbeizhixing。womenxuyaoshoudongzhixingzhegemubiao,huozhejiangtatianjiaweiqitamubiaodeyilai。liru,womenkeyishiyongyixiaminglinglaidingyiyigeyunxingwaibuMakefiledemubiao:add_custom_target( run_external_makefile COMMAND make -C ${CMAKE_CURRENT_SOURCE_DIR}/external_project)zhegeminglingdingyiliaoyigemingweirun_external_makefiledemubiao。womenkeyishiyongmake run_external_makefileminglinglaishoudongzhixingzhegemubiao。6.3.2 tianjiayilaiguanxi(Adding Dependencies)zaiCMakezhong,womenkeyishiyongadd_dependenciesminglinglaitianjiamubiaozhijiandeyilaiguanxi。zhegeminglingjieshoulianggehuogengduodecanshu,diyigecanshushimubiao,houmiandecanshushitasuoyilaidemubiao。liru,womenkeyishiyongyixiaminglinglaijiangrun_external_makefiletianjiaweimy_targetdeyilai:add_dependencies(my_target run_external_makefile)zheyang,meicigoujianmy_targetshi,duhuixianzhixingrun_external_makefilemubiao。6.3.3 shezhibianyixuanxiang(Setting Compilation Options)zaiCMakezhong,womenkeyishiyongtarget_compile_optionsminglinglaishezhimubiaodebianyixuanxiang。zhegeminglingjieshoulianggecanshu,diyigecanshushimubiao,diergecanshushibianyixuanxiang。liru,womenkeyishiyongyixiaminglinglaiweimy_targetshezhibianyixuanxiang:target_compile_options(my_target PRIVATE -Wall -Wextra)zhegeminglinghuiweimy_targettianjia-Wallhe-Wextrazhelianggebianyixuanxiang。yishangjiushizaiCMakezhongziyoukongzhishengchengguizedeyixiegaojijiqiao。zaishijishiyongzhong,womenkenengxuyaogenjujutidexuqiulaidiaozhengzhexieminglingdecanshu。zai7yue11rimuniheishanghaidianzizhanshang,zhixunchuangxinkejiyouxiangongsizhanchuliaojiyu19nm 2D SLC NANDshancundequanxinliangchanchanpin,dailailiaocunchuxingyezaierweishancunxinpianlingyudezuixintupo。

2024-07-08 06:42·上(Shang)观(Guan)新(Xin)闻(Wen)

“yihaogongcheng”zailuodi,zhijiLS7chengshangqixinnengyuanzhuanxingshengjitisuzhizuoyuanchuang2023-02-17 14:27·jingjiguanchabaozuoweishangqijituande“yihaogongcheng”,zhijiqichezidanshengyilaijiubeishouxingyeguanzhu。riqian,zaishoukuanchanpinzhijiL7jiaofujinbannianduohou,zhijiqichexunsudachuliao“dierzhangpai”——zhijiLS7。2yue10ri,zhijiLS7zhengshishangshi,xinchedingweizhinengchundianzhongdaxinghaohuaSUV,gongtuichu6kuanchexing,dianchibaoyou77/90/100kWhsanzhongguige,shoujiaqujianwei30.98~45.98wanyuan。jujieshao,zhijiLS7dabufenbanbenyuji3yuefenshixianjiaofu。qizhong,77kWhbiaozhunxuhangPurechunxianghouqubanchexingjiangyujinnianxiabanniankaiqiyuding,bingyunianneikaiqijiaofu。zhijiqichechengliyu2020nian12yue,youshangqijituan、zhangjianggaokehealibabajituangongtongdazao,chuangshilunrongziguimoda100yiyuan,shishangqijituande“yihaogongcheng”,chengzaizhuojituanjizhigaigechuangxin、pinpaixiangshangtuweidezhongren。erzhijiLS7zuowei“yihaogongcheng”deshoukuanSUVchexingbeijiyuhouwang。“zaizhongguodezhonggaoduanhaohuadiandongSUV/jiaocheshichang,zhuliujiagequjianwei35wandao39wanyuan。L7bangzhuzhijiqichezhanwenliaogaoduanpinpaiduilie,erLS7jiangtongguogenggaodejiazhibiquzhengqugengduoshichangfene。”zhijiqichelianxiCEOliutaozaijieshoumeiticaifangshibiaoshi。tongshi,zhijiLS7yejiangchengweishangqijituanxiangxinnengyuanqichezhuanxingdeguanjianchanpin。genjuciqianpiludexinxi,shangqijituan2023nianxinnengyuanqichexiaoliangmubiaowei150wanliang,dao2025nianshangqixinnengyuanchezaizhengtixiaoliangzhongdezhanbixudadao40%,jisannianneishixianfanfan。qizhong“yihaogongcheng”zhijiqichewuyijiangchongdanglingjunjiaose。danzhidezhuyideshi,dangqianguoneixinnengyuanqicheshichangjingzhengriqujilie,yifangmianrujuzheyuelaiyueduo,lingyifangmianzaitesiladebuduanjiangjiaxia,guoneixinnengyuan“jiagezhan”xiaoyanzaiqi,youqishizaizhijiLS7suochude30wanjishichang,gengshiqujin“honghai”。zaizhezhongqingkuangxia,zhijiLS7jiangruhetuchuzhongwei?jishuchuangxincheng“shashouzuo”dangqian,shangqijituanchuyucongchuantongcheqixianggaokejikejiqiyezhuanxingdezhongyaoshiqi,erbaohanliaozhuduo“heikeji”dezhijiLS7shizeshishangqijituanchuangxinchengguodezaiciluodi,yeshijituankuaisuzhuanxingdezhijietixian。zhideliuyideshi,zhijiLS7suodazaideqianyankejibingfeidangqianxuduocheqirezhongde“duiliao”,erjiyuduihailiangyonghudediaoyanyuyanpan,wajuechutamenzuizhenshizuihexindexuqiuhou,youzhenduixingjinxingdechexingdazao。tongshi,zhijigongchengtuanduihuanchaijieliaoshiduokuanhexinjingpinheremenchexing,yanjiuliaosuoyouzhuliuhaohuaSUVchexing,yiqiuzhijiLS7nenggoushixiankejihexingnengdelingxian,zhenzhengmanzuyonghuxuqiu。congchexingdingweikan,zhijiLS7shangshihou,huojiangyutesilaModel Ydechangxuhangban,yijigaoxingnengban、xiaopengG9、weilaiEC7dengchexingzhankaijingzheng。erxiangduiyujingpin,zhijiLS7xiangduijingpinyousandahexinliangdian,fenbieshidashiye、lingzhonglizuoyi、quanmingxingdipanjiakong。jutilaikan,jiyuzhijiduiSUVdeshichangdiaoyanjieguoxianshi,70%yishangdeyonghujiangdashiyezuoweishouxuanliyou,yihuodegenghaodezhangkongganheanquangan。yinci,zhijiqichedazaoliaoIMAXjijiashishiye,zhijijiangqichengwei “Star Fall xingpubingganqianzuoding ” ——fengdangbolijihuyanshendaoliao B zhushangfangdeweizhi,geijiashiyuanxingchengliaotongjizuidade106duzongxiangshiye。gaijufubolicaiyongliaoguochanC919dafeijitongzhongqianzhangongyihetezhongzhizaoshebeiyitiyazhichengxingde,anquanxingnenggaodaguobiaojinsibei。lingwai,weihuiying85%zhonggaoduanSUVyonghuduikongjiandeqiangliexuqiu,zhijiLS7lvxianyingyongliaosandazhinenghuachuangxinjishu,kaichuangxingdazaoanyonghuchangjingxuqiulinghuobianhuadekongjianbuju,qizhongzuidadeliangdianshihoupaiyoucetigongliao " lingzhonglifuganzuoyi "。jujieshao,zaiqidonglingzhonglimoshihou,qianpaifujiazuoyinenggouwanquanzhedie,bingtongguo SUV shishangzuichangdediandonghuagui(1955mm),wanquanshounadaoyibanshiqianpaishoutaoxiangdexiafang。lingzhonglizuoyizekeyichongfenzhankai,shengqijiaotuo,xingcheng 121 ° detangzijiajiao,yigengdadezhichengmianji,rangquanshendepingjunyalizhijinwei 0.27 N/cm2,dailai " lingzhongli " detiyan。erzaizuinengtixiancheliangxingnengdedipanfangmian,zhijiLS7dazailiaozhijiqichequanxinfabudezhonggaonie6xidanjinggaoya100kWhgaonengdianchi,keshixianchongdian26fenzhongxuhang400gonglidechongdiansudu,bingshixianchaogaodedantinengliangmiduhetongjizuigaozhengbaonengliangmidu。ciwaiLS7dazaidedingzhibanheibiaolvmeihejinzhipuyoulengdianji,caiyongEVDshiliangsiqujishu,liangqu/siquqiehuanshijianjinwei 300ms。eTACbianyuanniujukongzhijishukeshixianhaomiaojibiedefanghuakongzhixiangying,xiangjiaoyuchuantongTCSkuailiao3beiyishang。zaidangqianzhinengdiandongchezui“juan”dezhinenghuafangmian,zhijiLS7yepoyouchengyi。yingjianfangmian,xinchedazailiaoyingweidaOrinXchaogaosuanlizhijiaxinpian、shuangjiguangleida、gaotong8155zhicangSoCxinpian、qianzhaoyitaiwangchuanshusudu、AMOLED 2Kjiqingjiaohupingdeng。ruanjianfangmian,zetuichuliaoxinyidaiquanyuronghezhinenghechuangxinjiaohudeIM OS 2.0。zhijiafangmian,zhijiNOAyizaiquanguogechengshiluxushangxian,jiyugaojingditudeNOAyejihuazainiandiqiankaishigongce, qugaojingdituhuadechengquNOAkaifa2023niandiwancheng。chucizhiwai,zhijiLS7huandazailiaogengduoyeneidexianjindejishuhepeizhi,ruqifengdangbolishouciyingyongliao “sancengduyinjishu”,nengrangziwaixiangejuelvdadao 99.99%,qiedazailiaoguoneishoukuanliangchanyingyongdebanfufangxiangpandeng,zhexiejunchengweizhijiLS7yingduijingzhengdeduyou“liqi”。sharu“juesaiquan”congxingyezhengtikan,suizhuoxinnengyuanqicheshichangkuaisufazhan,xinzaocheqiyeyijingduguoqianqishichangjiaoyujieduan,qiebansuixinnengyuanqichebutiezai2023nianzhengshituichu,xinnengyuanqicheshichangkaishijinruzhenzhengpingshilishuohuadejuesaijieduan。zaizhegeguochengzhong,zhiyoujubeidutejingzhenglideqiyecainengcunhuoxialai。qizhong,zhijiqicheshijiaobeikanhaodexinzaochepinpaizhiyi。zhezhuyaodeyiyuqibeikaoshangqi、alibabadengdagudong,youzhuojiaoqiangdezijinhejishuzhichi。gengweiguanjiandeshi,zaishangqijituandexietongxia,zhijiqichejiangzaigongyinglianjichengbenfangmianqudejiaodayoushi,shiqichanpingengjuxingjiabi。yicicishangshidezhijiLS7weili,zaizhuduoxingye“heikeji”jiachideqingkuangxia,xincheqishoujiadingzailiao30wanyuan,zaiqipinpaichuyufazhanjieduan,yanfachengbennanyibeitanbaodeqingkuangxia,gaidingjiabeirenweichengyimanman。erliutaozaicaifangzhongtancheng,jiyushangqizaichengbenfangmiandefuneng,zhijiqicheshouyiliangduo。“youshangqijituandefuneng,womennenggouyizuishihedechengben,nadaozuihaodedongxi。biruzaidipan、jixiesuzhi、pingtaifangmian,shangqijituanqixiayou‘yinxingguanjun’huayuqiche;neishifangmian,shangqiyouquanqiuzuidadeqichezuoyixingyelongtouqiyeyanfeng;zaichedengshang,huayushijueshizuishanchangzuogaoduanchedengdegongsi。tamenzuihaodejishu,zuididechengbenyidinghuigeidaowomen,zhedushiwomendeyoushi。”liutaobiaoshi。tongyangjiyushangqijituandefuneng,zhijiduigongyingliandewendingxingyepojuxinxin。2022nianqichexingyejingliliaoyanzhongdexinpianduanque,erliutaodiqishizudibiaoshi,xiangduiyuqitaxinzaocheqiye,zhijizaizhefangmiandeyalihuibijiaoxiao。“yourenwen,jiexialaichongjixiaoliangzhijidegongyinglianshifouyouyali,xinpianhuibuhuirengranshipingjing?wojuedehenyouxinxin。yinweizhiyaoshangqimaidedaoxinpian,jiujueduibuhuiquezhijide。”liutaoshuo。ercongshichangdefankuikan,zhijiqichechanpinjiaofuhouyijingzhanxianchuyidingdeshichangshili,qishoukuanchezhijiL7zaikaiqijiaofuhou,zaibudao45tiandeshijianneixiaoliangpoqiantai,chengweiguonei35wanyuanyishanghaohuachundiandongchexingleijijiaofuliangpoqianzuikuaichexing,bingzai2022nian9yuezuoshengaoduanjiaochexiaoliangbangdan。jiexialai,suizhuogengjuxingjiabidezhijiLS7shangshi,zhijiqichedeshichangbiaoxianyouwangjixutisheng。juxi,2yue10rishangshishi,zhijiLS7zongdingdantupo12000tai。liutaobiaoshi,2023nianzhijiqichexiwangdacheng 4.5 wanliangdexiaoliang。qudaofangmian,zhijiqicheyejiangjiakuaijincheng。shujuxianshi,jiezhi2022niandi,zhijiqichegongyou120jiatiyanzhongxinhejiaofuzhongxin。zuoweiduibi,weilaiguoneiyongyou394jiamendian;xiaopengmendianchaoguo270jia;lixiangmendianshuliangdadao296jia。zhijibiaoshi,jiexialaijiangjiakuaiqudaobujubufa,jinnianniandidemubiaoshidadao240jia,6yue30rizhiqiandadao180dao190jia,daliangerxianchengshijianghuibeifugai。congjituancengmiankan,duiyudangqianchuzaixinnengyuanzhuanxingdeshangqilaishuo,zhijiLS7deshangshiwuyiweiqipinpaixiangshangqipaohoudejiasuzhuruliaoyizhen“qiangxinji”。jiexialai,“yihaogongcheng”huanjiangchixufali,jinnianxiabannian,zhijijiangtuichuyikuanzhongxingpiandadeSUV;2024nianshangbannian,zhijijiangtuichuzhongxingjiaoche。zibencengmian,zhijiqicheyuqunian8yuewanchengAlunrongzi,shoulunrongzihoushichangguzhijin300yiyuan。zhejiuxuyaojiachangzhangwozhengquedeshengchangguilv,cainengbimianyinwaijiedepianjian,yingxiangzanmenduihaizidepanduan。

“前(蚕颈补苍)瞻(窜丑补苍)布(叠耻)局(闯耻)下(齿颈补)一(驰颈)代(顿补颈)互(贬耻)联(尝颈补苍)网(奥补苍驳)等(顿别苍驳)前(蚕颈补苍)沿(驰补苍)领(尝颈苍驳)域(驰耻),全(蚕耻补苍)面(惭颈补苍)推(罢耻颈)进(闯颈苍)6骋技(闯颈)术(厂丑耻)研(驰补苍)发(贵补),营(驰颈苍驳)造(窜补辞)良(尝颈补苍驳)好(贬补辞)发(贵补)展(窜丑补苍)环(贬耻补苍)境(闯颈苍驳),引(驰颈苍)导(顿补辞)支(窜丑颈)持(颁丑颈)企(蚕颈)业(驰别)加(闯颈补)大(顿补)研(驰补苍)发(贵补)投(罢辞耻)入(搁耻),加(闯颈补)快(碍耻补颈)人(搁别苍)工(骋辞苍驳)智(窜丑颈)能(狈别苍驳)、区(蚕耻)块(碍耻补颈)链(尝颈补苍)、云(驰耻苍)计(闯颈)算(厂耻补苍)、网(奥补苍驳)络(尝耻辞)安(础苍)全(蚕耻补苍)等(顿别苍驳)新(齿颈苍)型(齿颈苍驳)数(厂丑耻)字(窜颈)产(颁丑补苍)业(驰别)发(贵补)展(窜丑补苍)。”工(骋辞苍驳)信(齿颈苍)部(叠耻)部(叠耻)长(颁丑补苍驳)金(闯颈苍)壮(窜丑耻补苍驳)龙(尝辞苍驳)4日(搁颈)表(叠颈补辞)示(厂丑颈)。

只听见建业说道:“大伯,您快试试,我看这次来,您这鞋子都磨破了,就给您买了一双。”上面有一万多元,她让我拿着这笔钱去好好做生意,等到挣钱的时候,回来记得给她养老就行。《普法栏目剧单行道二》在线观看高清 - 百度网盘无删...

新能源汽车颜值经济趋热 中国车企解锁潮改新玩法2023-03-05 20:47·中国新闻网中新社柳州3月5日电 题:新能源汽车颜值经济趋热 中国车企解锁潮改新玩法作者 李娇阳3月5日广西柳州市五菱新能源柳州潮创中心(以下简称潮创中心)外广场上展示的十余辆新能源汽车因配色大胆、车身图案个性十足吸引民众驻足楼宇间的空地如同潮改车展现场3月5日广西柳州市五菱新能源柳州潮创中心外广场民众驻足欣赏高颜值的新能源汽车 中新社发 李娇阳 摄潮创中心门店内试驾的顾客络绎不绝潮改顾问带着改装案例合集为车主答疑解惑负一层的车间里数名技术人员在为新能源汽车贴膜、加装设备等该中心于2021年建成为具有潮改需求的消费者提供一站式服务‘潮改’是汽车‘轻改装’与时尚潮流交融的产物车主通过外观改造、内饰升级实现对汽车‘高颜值’和优质驾驶体验的追求潮创中心营销经理徐翔宇从事汽车行业十余年他表示随着新能源汽车销量上涨汽车轻改装通过互联网得到普及新能源汽车潮改市场也在升温25岁的李泰锡计划年内购买一辆新能源汽车这是自己‘挣’来的第一辆汽车除考虑性能也希望在汽车的颜色、配饰等方面体现出个人特质因此有改装的计划她表示在互联网上看到心仪的汽车潮改作品会激发自己对相应车型的购买欲3月5日广西柳州市五菱新能源柳州潮创中心门店内高颜值的新能源汽车吸引民众上车体验 中新社发 李娇阳 摄当下90后逐渐成为消费主力军他们追求个性化表达热衷将汽车改装成果互联网平台新能源汽车潮改风靡车友圈受颜值至上消费观念的影响车主们为新能源汽车注入时尚单品的属性这也让车企看到汽车消费市场的新亮点‘潮改’项目包含车身定制改色、升级汽车音响等内容车主以‘点单’形式参与汽车改装‘门槛’并不高徐翔宇表示对于部分购车者而言新能源汽车是家庭第二辆车能深度参与改装甚至成为其购车目的柳州市是中国新能源汽车之都《中国新能源汽车城柳州范本大数据报告》显示柳州累计乘用车电动化率达31.6%居中国各城市之首在该市众多新能源汽车车主通过轻改装将爱车打造成个人名片成为城市道路上的独特风景线新能源汽车潮改市场的潜力得到显现根据中国公安部统计数据2022年中国新能源汽车保有量达1310万辆同比增长67.13%新注册登记新能源汽车数量从2018年的107万辆到2022年的535万辆呈高速增长态势在此背景下新能源汽车后市场这片消费新蓝海引起众多中国车企的关注为拉近品牌与消费者之间的距离中国车企纷纷加入玩车行列与用户进行共创东风雪铁龙接连开展X-Dream Car潮改季微改玩家 全民凡尔赛等改装活动比亚迪发起eStarpro潮改共创计划展示来自中国各地的汽车潮改作品奇瑞汽车则推出原厂定制的改装套件丰富改装产物与服务与音乐、游戏、体育等领域玩跨界合作与热门IP联动推出联名款让外观独特、可玩性强的潮改车型亮相中国A级车展……车企的加入让汽车潮改不再是车主们的自嗨卷入新能源汽车潮改赛道的中国车企正在解锁新能源汽车营销服务新模式曾经受汽车产物供应链分散、改装技术人才不足等因素影响中国车企在挖掘汽车消费者需求以及让个性化需求落地等方面碰到难题如今互联网和大数据让需求更加清晰车企亦通过整合汽车产物供应链与职业院校联合培养汽车改装行业技术人才调整营销策略等方式加速开发新能源汽车潮改这片消费新蓝海(完)

发布于:鼎湖区
声明:该文观点仅代表作者本人,搜狐号系信息发布平台,搜狐仅提供信息存储空间服务。
意见反馈 合作

Copyright ? 2023 Sohu All Rights Reserved

搜狐公司 版权所有