当前位置:网站首页>Solve cmakelist find_ Package cannot find Qt5, ECM cannot be found
Solve cmakelist find_ Package cannot find Qt5, ECM cannot be found
2022-07-05 16:39:00 【Trendy technology research society】
Compiling a cmake When the project is , Need to use ECM, So using vcpkg install ecm, Results the installation was successful , however cmake Still don't recognize ,find_package Report errors , Can't find ecm Location , Obviously ,vcpkg install ecm To packages Under the path , This packages The path is not cmake Find the
Now , We need to be in CMakeList Add path description to the file , That is to use set 了 .
As shown in the figure below ,Qt5 Can directly set, however ECM, I can't find it ECM How to set the path of ,Qt5_DIR We often see , however ECM_DIR But I have never seen , Obviously , Give it a try , no way .
Then I tried to vcpkg in packages In the catalog ecm Installation directory share Copy the directory directly to cmake share Directory ,cmake Successfully found ecm, But that's normal ,cmake Look under your own path , It must be found .
find_package(ECM ${KF5_MIN_VERSION} REQUIRED CONFIG)
set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} ${ECM_MODULE_PATH} )
set(Qt5_DIR "D:\\Qt\\5.15.2\\msvc2019_64\\lib\\cmake\\Qt5")
find_package(Qt5 ${QT_MIN_VERSION} REQUIRED NO_MODULE COMPONENTS Widgets Svg Concurrent)
边栏推荐
猜你喜欢

Spring Festival Limited "forget trouble in the year of the ox" gift bag waiting for you to pick it up~

迁移/home分区

2020-2022两周年创作纪念日

单商户 V4.4,初心未变,实力依旧!

【学术相关】多位博士毕业去了三四流高校,目前惨不忍睹……

Fleet tutorial 09 basic introduction to navigationrail (tutorial includes source code)

Basic introduction to the control of the row component displaying its children in the horizontal array (tutorial includes source code)

Today's sleep quality record 79 points

Data access - entityframework integration

Win11如何给应用换图标?Win11给应用换图标的方法
随机推荐
【 brosser le titre 】 chemise culturelle de l'usine d'oies
新春限定丨“牛年忘烦”礼包等你来领~
10分钟帮你搞定Zabbix监控平台告警推送到钉钉群
[js] skill simplification if empty judgment
Query the latest record in SQL
【漏洞预警】CVE-2022-26134 Confluence 远程代码执行漏洞POC验证与修复过程
CISP-PTE之PHP伪协议总结
"21 days proficient in typescript-3" - install and build a typescript development environment md
[深度学习][原创]让yolov6-0.1.0支持yolov5的txt读取数据集模式
Flet tutorial 12 stack overlapping to build a basic introduction to graphic and text mixing (tutorial includes source code)
漫画:什么是MapReduce?
《21天精通TypeScript-3》-安装搭建TypeScript开发环境.md
树莓派4b安装Pytorch1.11
ES6 drill down - Async functions and symbol types
清晰还原31年前现场,火山引擎超清修复Beyond经典演唱会
Data access - entityframework integration
[brush title] goose factory shirt problem
Practice independent and controllable 3.0 and truly create the open source business of the Chinese people
Data Lake (XIV): spark and iceberg integrated query operation
Basic introduction to the control of the row component displaying its children in the horizontal array (tutorial includes source code)