How to setup CMake in a fresh project (custom board) to add/reference the MCUXpresso SDK properly

取消
显示结果 
显示  仅  | 搜索替代 
您的意思是: 

How to setup CMake in a fresh project (custom board) to add/reference the MCUXpresso SDK properly

365 次查看
tomdeboerio
Contributor I

Hello NXP Community !

I am trying to setup a new repository to compile code on the MCXN947. The goal is to have a single repository that will support multiple board variants of the MCXN947 (called in my project "dcm", dcm1212" and "mcxn947-eval"). The last one (mcxn947-eval) is based on the FDR board for the MCXN947, with a daughter board attached to it. It is the only one that currently compiles, so do not worry about the others if you are looking into the issue. 

In my current folder structure, I would like to have (see attached project):

- app folder for my application layer

- ecu folder that abstract the different board variants to the application (one sub folder gets compiled depending on the variant picked via CMake Preset)

- modules folder for some of my library submodule, including a generic HAL layer to abstract the sdk for the application

- mcuxpresso-sdk folder to contain my sdk

 

For the SDK folder, I used the Github mcuxsdk-manifests and customized the yml to only pull the MCXN serie and the component I was interested in. For anybody looking at the project attached, a simple "west update" inside the mcuxpresso-sdk folder should pull what I need.

I now seem to have a hard time figuring out how to setup my CMake system to allow everything to compile nicely together. Most of my project use the CMake library concept to add each subfolder cleanly and nicely. However, I wasn't able to do that with the SDK.

For now, the best solution I have is to manually add the SDK .c files I needs inside my ecu\sources\mcxn947-eval\board CMakeLists. It is honnestly a huge pain and doesn't work fully (for example, initializing the FlexComm in peripherals.c creates a hardware fault). I looked at a couple post in the NXP Community, but none of them seemed to work for me. I always ended up with some compilation or configuration issues when implementing them.

 

Note: Since the final production variant (dcm and dcm1212) will run on a custom board, I am trying to get away from get-go from the "board-defined" settings. This is why the mcxn947-eval do not use the frdm board settings in the SDK at the moment.

标签 (1)
0 项奖励
回复
4 回复数

300 次查看
Harry_Zhang
NXP Employee
NXP Employee

Hi @tomdeboerio 

I think you can use this structure.

repo/

├─ app/ # application layer (board-agnostic)
├─ ecu/
│ ├─ dcm/
│ ├─ dcm1212/
│ └─ mcxn947-eval/ # custom variant based on FRDM

├─ modules/
│ └─ hal_generic/

└─ mcuxpresso-sdk/ # pulled via west

The SDK CMake system already knows which files belong to each component. You should not list these manually.

BR

Harry

0 项奖励
回复

227 次查看
tomdeboerio
Contributor I

Thanks Harry.

 

I agree this is the best structure for my project. My issue is that I am not sure how to create a CMake in the root of my project that would properly add and compile both the application/ecu/modules folders, as well as the sdk folder.

For the ony I wrote manually, I can simply compile them by doing a CMake "add_subdirectory", where each subfolder will contain their own CMake to create CMake libraries. I then link them together in the root CMake with "traget_link_libraries". I put an example of both those CMake as I have them right now (simplified a little bit so we don't worry about the different build target).

What I am missing from it is how to add the SDK to this overall build system and make sure my ecu folder has access to it.

 

0 项奖励
回复

16 次查看
Harry_Zhang
NXP Employee
NXP Employee

Hi @tomdeboerio 

I just tested it.

The structure is 

Harry_Zhang_0-1765438042376.pngHarry_Zhang_1-1765438058379.pngHarry_Zhang_2-1765438077914.png

BR

Harry

 

0 项奖励
回复

29 次查看
Harry_Zhang
NXP Employee
NXP Employee

Hi @tomdeboerio 

We have implemented a drag-drop feature to make it easier for users to add sources to the project. It is currently available as an experimental feature that must be enabled by the user in the extension settings. This allows the user to simply drop sources into the project and the project's CMakeLists.txt file will automatically update.

To enable the feature:

  1. Open the extension settings
  2. Check Enable Add Files to Project
  3. Restart your workspace

Harry_Zhang_0-1765419423926.png

For the hardware fault, check that there are no conflicts in the clocks, pin_mux, etc.

 

Last to enable custom boards (outside of the mcuxsdk repository) please follow the steps in https://mcuxpresso.nxp.com/mcuxsdk/latest/html/develop/sdk/custom_board_development.html#enable-a-cu...

BR

Harry

0 项奖励
回复
%3CLINGO-SUB%20id%3D%22lingo-sub-2248671%22%20slang%3D%22en-US%22%20mode%3D%22CREATE%22%3E%E5%A6%82%E4%BD%95%E5%9C%A8%E5%85%A8%E6%96%B0%E9%A1%B9%E7%9B%AE%EF%BC%88%E8%87%AA%E5%AE%9A%E4%B9%89%E6%9D%BF%EF%BC%89%E4%B8%AD%E8%AE%BE%E7%BD%AE%20CMake%20%E4%BB%A5%E6%AD%A3%E7%A1%AE%E6%B7%BB%E5%8A%A0%2F%E5%8F%82%E8%80%83%20MCUXpresso%20SDK%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-2248671%22%20slang%3D%22en-US%22%20mode%3D%22CREATE%22%3E%3CP%3E%E4%BD%A0%E5%A5%BD%EF%BC%8C%E6%81%A9%E6%99%BA%E6%B5%A6%E7%A4%BE%E5%8C%BA%EF%BC%81%3C%2FP%3E%3CP%3E%E6%88%91%E6%AD%A3%E5%9C%A8%E5%B0%9D%E8%AF%95%E5%BB%BA%E7%AB%8B%E4%B8%80%E4%B8%AA%E6%96%B0%E7%9A%84%E8%B5%84%E6%BA%90%E5%BA%93%EF%BC%8C%E4%BB%A5%E4%BE%BF%E5%9C%A8%20MCXN947%20%E4%B8%8A%E7%BC%96%E8%AF%91%E4%BB%A3%E7%A0%81%E3%80%82%E7%9B%AE%E6%A0%87%E6%98%AF%E5%BB%BA%E7%AB%8B%E4%B8%80%E4%B8%AA%E6%94%AF%E6%8C%81%20MCXN947%20%E7%9A%84%E5%A4%9A%E4%B8%AA%E6%9D%BF%E5%8F%98%E4%BD%93%E7%9A%84%E5%8D%95%E4%B8%80%E5%AD%98%E5%82%A8%E5%BA%93%EF%BC%88%E5%9C%A8%E6%88%91%E7%9A%84%E9%A1%B9%E7%9B%AE%E4%B8%AD%E8%A2%AB%E7%A7%B0%E4%B8%BA%20%22%20dcm%20%22%E3%80%81dcm1212%20%22%20%E5%92%8C%20%22%20mcxn947-eval%20%22%EF%BC%89%E3%80%82%E6%9C%80%E5%90%8E%E4%B8%80%E4%B8%AA%EF%BC%88mcxn947-eval%EF%BC%89%E4%BB%A5%20MCXN947%20%E7%9A%84%20FDR%20%E6%9D%BF%E4%B8%BA%E5%9F%BA%E7%A1%80%EF%BC%8C%E4%B8%8A%E9%9D%A2%E9%99%84%E6%9C%89%E5%AD%90%E6%9D%BF%E3%80%82%E7%9B%AE%E5%89%8D%E5%8F%AA%E6%9C%89%E5%AE%83%E8%83%BD%E7%BC%96%E8%AF%91%EF%BC%8C%E6%89%80%E4%BB%A5%E5%A6%82%E6%9E%9C%E6%82%A8%E6%AD%A3%E5%9C%A8%E7%A0%94%E7%A9%B6%E8%BF%99%E4%B8%AA%E9%97%AE%E9%A2%98%EF%BC%8C%E4%B8%8D%E7%94%A8%E6%8B%85%E5%BF%83%E5%85%B6%E4%BB%96%E7%9A%84%E3%80%82%20%3C%2FP%3E%3CP%3E%E5%9C%A8%E6%88%91%E5%BD%93%E5%89%8D%E7%9A%84%E6%96%87%E4%BB%B6%E5%A4%B9%E7%BB%93%E6%9E%84%E4%B8%AD%EF%BC%8C%E6%88%91%E5%B8%8C%E6%9C%9B%E6%9C%89%EF%BC%88%E8%A7%81%E6%89%80%E9%99%84%E9%A1%B9%E7%9B%AE%EF%BC%89%EF%BC%9A%3C%2FP%3E%3CP%3E-%E6%88%91%E7%9A%84%3CSTRONG%3E%E5%BA%94%E7%94%A8%E7%A8%8B%E5%BA%8F%3C%2FSTRONG%3E%E5%B1%82%E7%9A%84%E5%BA%94%E7%94%A8%E7%A8%8B%E5%BA%8F%E6%96%87%E4%BB%B6%E5%A4%B9%3C%2FP%3E%3CP%3E-%3CSTRONG%3Eecu%3C%2FSTRONG%3E%20%E6%96%87%E4%BB%B6%E5%A4%B9%EF%BC%8C%E7%94%A8%E4%BA%8E%E5%B0%86%E4%B8%8D%E5%90%8C%E7%9A%84%E6%9D%BF%E5%8F%98%E4%BD%93%E6%8A%BD%E8%B1%A1%E5%88%B0%E5%BA%94%E7%94%A8%E7%A8%8B%E5%BA%8F%E4%B8%AD%EF%BC%88%E6%A0%B9%E6%8D%AE%E9%80%9A%E8%BF%87%20CMake%20%E9%A2%84%E8%AE%BE%E9%80%89%E6%8B%A9%E7%9A%84%E5%8F%98%E4%BD%93%E7%BC%96%E8%AF%91%E4%B8%80%E4%B8%AA%E5%AD%90%E6%96%87%E4%BB%B6%E5%A4%B9%EF%BC%89%3C%2FP%3E%3CP%3E-%E6%88%91%E7%9A%84%E9%83%A8%E5%88%86%E5%BA%93%E5%AD%90%3CSTRONG%3E%E6%A8%A1%E5%9D%97%3C%2FSTRONG%3E%E7%9A%84%E6%A8%A1%E5%9D%97%E6%96%87%E4%BB%B6%E5%A4%B9%EF%BC%8C%E5%8C%85%E6%8B%AC%E7%94%A8%E4%BA%8E%E6%8A%BD%E8%B1%A1%E5%BA%94%E7%94%A8%E7%A8%8B%E5%BA%8F%20sdk%20%E7%9A%84%E9%80%9A%E7%94%A8%20HAL%20%E5%B1%82%3C%2FP%3E%3CP%3E-%3CSTRONG%3Emcuxpresso-sdk%20%3C%2FSTRONG%3E%E6%96%87%E4%BB%B6%E5%A4%B9%E5%8C%85%E5%90%AB%E6%88%91%E7%9A%84%20sdk%3C%2FP%3E%3CBR%20%2F%3E%3CP%3E%E5%AF%B9%E4%BA%8E%20SDK%20%E6%96%87%E4%BB%B6%E5%A4%B9%EF%BC%8C%E6%88%91%E4%BD%BF%E7%94%A8%E4%BA%86%20Github%20%3CA%20href%3D%22https%3A%2F%2Fgithub.com%2Fnxp-mcuxpresso%2Fmcuxsdk-manifests%22%20target%3D%22_self%22%20rel%3D%22nofollow%20noopener%20noreferrer%22%3Emcuxsdk-manifests%3C%2FA%3E%20%E5%B9%B6%E5%AF%B9%20yml%20%E8%BF%9B%E8%A1%8C%E4%BA%86%E8%87%AA%E5%AE%9A%E4%B9%89%EF%BC%8C%E4%BD%BF%E5%85%B6%E4%BB%85%E6%8F%90%E5%8F%96%20MCXN%20%E7%B3%BB%E5%88%97%E5%92%8C%E6%88%91%E6%84%9F%E5%85%B4%E8%B6%A3%E7%9A%84%E5%85%83%E5%99%A8%E4%BB%B6%E3%80%82%E5%AF%B9%E4%BA%8E%E6%9F%A5%E7%9C%8B%E6%89%80%E9%99%84%E9%A1%B9%E7%9B%AE%E7%9A%84%E4%BB%BB%E4%BD%95%E4%BA%BA%E6%9D%A5%E8%AF%B4%EF%BC%8C%E5%9C%A8%20mcuxpresso-sdk%20%E6%96%87%E4%BB%B6%E5%A4%B9%E5%86%85%E8%BF%9B%E8%A1%8C%E7%AE%80%E5%8D%95%E7%9A%84%22west%20update%22%20%E5%B0%B1%E8%83%BD%E5%BE%97%E5%88%B0%E6%88%91%E9%9C%80%E8%A6%81%E7%9A%84%E4%B8%9C%E8%A5%BF%E3%80%82%3C%2FP%3E%3CP%3E%E6%88%91%E7%8E%B0%E5%9C%A8%E4%BC%BC%E4%B9%8E%E5%BE%88%E9%9A%BE%E5%BC%84%E6%98%8E%E7%99%BD%E5%A6%82%E4%BD%95%E8%AE%BE%E7%BD%AE%20CMake%20%E7%B3%BB%E7%BB%9F%EF%BC%8C%E8%AE%A9%E6%89%80%E6%9C%89%E5%86%85%E5%AE%B9%E9%83%BD%E8%83%BD%E5%BE%88%E5%A5%BD%E5%9C%B0%E7%BC%96%E8%AF%91%E5%9C%A8%E4%B8%80%E8%B5%B7%E3%80%82%E6%88%91%E7%9A%84%E5%A4%A7%E5%A4%9A%E6%95%B0%E9%A1%B9%E7%9B%AE%E9%83%BD%E4%BD%BF%E7%94%A8%20CMake%20%E5%BA%93%E7%9A%84%E6%A6%82%E5%BF%B5%EF%BC%8C%E4%BB%A5%E5%B9%B2%E5%87%80%E3%80%81%E6%BC%82%E4%BA%AE%E7%9A%84%E6%96%B9%E5%BC%8F%E6%B7%BB%E5%8A%A0%E6%AF%8F%E4%B8%AA%E5%AD%90%E6%96%87%E4%BB%B6%E5%A4%B9%E3%80%82%E4%BD%86%E6%98%AF%EF%BC%8C%E6%88%91%E6%97%A0%E6%B3%95%E4%BD%BF%E7%94%A8%20SDK%20%E5%81%9A%E5%88%B0%E8%BF%99%E4%B8%80%E7%82%B9%E3%80%82%3C%2FP%3E%3CP%3E%E7%9B%AE%E5%89%8D%EF%BC%8C%E6%88%91%E7%9A%84%E6%9C%80%E4%BD%B3%E8%A7%A3%E5%86%B3%E6%96%B9%E6%A1%88%E6%98%AF%E6%89%8B%E5%8A%A8%E6%B7%BB%E5%8A%A0%20SDK%20.c%E6%88%91%E9%9C%80%E8%A6%81%E5%9C%A8%20ecu%5C%20sources%5C%20mcxn947-eval%5C%20%E6%9D%BF%20CMakeLists%20%E9%87%8C%E9%9D%A2%E7%9A%84%E6%96%87%E4%BB%B6%E3%80%82%E8%80%81%E5%AE%9E%E8%AF%B4%EF%BC%8C%E8%BF%99%E6%A0%B7%E5%81%9A%E9%9D%9E%E5%B8%B8%E9%BA%BB%E7%83%A6%EF%BC%8C%E8%80%8C%E4%B8%94%E4%B8%8D%E8%83%BD%E5%AE%8C%E5%85%A8%E5%A5%8F%E6%95%88%EF%BC%88%E4%BE%8B%E5%A6%82%EF%BC%8C%E5%9C%A8%20peripherals.c%20%E4%B8%AD%E5%88%9D%E5%A7%8B%E5%8C%96%20FlexComm%E7%A1%AC%E4%BB%B6%E6%95%85%E9%9A%9C%EF%BC%89%E3%80%82%E6%88%91%E7%9C%8B%E4%BA%86%E6%81%A9%E6%99%BA%E6%B5%A6%E7%A4%BE%E5%8C%BA%E7%9A%84%E4%B8%80%E4%BA%9B%E5%B8%96%E5%AD%90%EF%BC%8C%E4%BD%86%E4%BC%BC%E4%B9%8E%E9%83%BD%E4%B8%8D%E9%80%82%E5%90%88%E6%88%91%E3%80%82%E6%88%91%E5%9C%A8%E4%BD%BF%E7%94%A8%E5%AE%83%E4%BB%AC%E6%97%B6%E6%80%BB%E6%98%AF%E4%BC%9A%E9%81%87%E5%88%B0%E4%B8%80%E4%BA%9B%E7%BC%96%E8%AF%91%E6%88%96%E9%85%8D%E7%BD%AE%E9%97%AE%E9%A2%98%E3%80%82%3C%2FP%3E%3CBR%20%2F%3E%3CP%3E%E6%B3%A8%E6%84%8F%EF%BC%9A%E7%94%B1%E4%BA%8E%E6%9C%80%E7%BB%88%E7%9A%84%E7%94%9F%E4%BA%A7%E7%89%88%E6%9C%AC%EF%BC%88dcm%20%E5%92%8C%20dcm1212%EF%BC%89%E5%B0%86%E5%9C%A8%E8%87%AA%E5%AE%9A%E4%B9%89%E6%9D%BF%E4%B8%8A%E8%BF%90%E8%A1%8C%EF%BC%8C%E6%89%80%E4%BB%A5%E6%88%91%E6%AD%A3%E5%9C%A8%E5%B0%9D%E8%AF%95%E6%91%86%E8%84%B1%20%22%20%E6%9D%BF%E5%AE%9A%E4%B9%89%E7%9A%84%20%22%20%E8%AE%BE%E7%BD%AE%E3%80%82%E8%BF%99%E5%B0%B1%E6%98%AF%E4%B8%BA%E4%BB%80%E4%B9%88%20mcxn947-eval%20%E7%9B%AE%E5%89%8D%E4%B8%8D%E4%BD%BF%E7%94%A8%20SDK%20%E4%B8%AD%E7%9A%84%20frdm%20%E6%9D%BF%E8%AE%BE%E7%BD%AE%E7%9A%84%E5%8E%9F%E5%9B%A0%E3%80%82%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-LABS%20id%3D%22lingo-labs-2248671%22%20slang%3D%22en-US%22%20mode%3D%22CREATE%22%3E%3CLINGO-LABEL%3EMCX%20N%3C%2FLINGO-LABEL%3E%3C%2FLINGO-LABS%3E%3CLINGO-SUB%20id%3D%22lingo-sub-2249938%22%20slang%3D%22en-US%22%20mode%3D%22CREATE%22%20translate%3D%22no%22%3ERe%3A%20How%20to%20setup%20CMake%20in%20a%20fresh%20project%20(custom%20board)%20to%20add%2Freference%20the%20MCUXpresso%20SDK%20properl%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-2249938%22%20slang%3D%22en-US%22%20mode%3D%22CREATE%22%3E%3CP%3E%E4%BD%A0%E5%A5%BD%3CA%20href%3D%22https%3A%2F%2Fcommunity.nxp.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F256105%22%20target%3D%22_blank%22%3E%40%E6%B1%A4%E5%A7%86-%E5%BE%B7%E5%8D%9A%E5%9F%83%E9%87%8C%E5%A5%A5%3C%2FA%3E%3C%2FP%3E%0A%3CP%3E%E6%88%91%E8%AE%A4%E4%B8%BA%E4%BD%A0%E5%8F%AF%E4%BB%A5%E4%BD%BF%E7%94%A8%E8%BF%99%E7%A7%8D%E7%BB%93%E6%9E%84%E3%80%82%3C%2FP%3E%0A%3CP%3Erepo%2F%20%3CBR%20%2F%3E%20%E2%94%82%20%3CBR%20%2F%3E%20%E2%94%9C%E2%94%80%20app%2F%20%23%20%E5%BA%94%E7%94%A8%E5%B1%82%EF%BC%88%E4%B8%8E%E4%B8%BB%E6%9D%BF%E6%97%A0%E5%85%B3%EF%BC%89%E2%94%9C%E2%94%80%20ecu%2F%20%E2%94%82%20%E2%94%9C%E2%94%80%20dcm%2F%20%E2%94%82%20%3CBR%20%2F%3E%20%E2%94%9C%E2%94%80%20dcm1212%2F%20%E2%94%82%20%E2%94%94%E2%94%80%20mcxn947-eval%2F%20%23%20%E5%9F%BA%E4%BA%8E%20FRDM%20%E7%9A%84%E8%87%AA%E5%AE%9A%E4%B9%89%E5%8F%98%E4%BD%93%20%3CBR%20%2F%3E%20%3CBR%20%2F%3E%20%E2%94%82%20%E2%94%9C%E2%94%80%20%E6%A8%A1%E5%9D%97%2F%20%E2%94%82%20%E2%94%94%E2%94%80%20hal_generic%2F%20%3CBR%20%2F%3E%20%E2%94%82%20%E2%94%82%20mcuxpresso-sdk%2F%20%23%20%E4%BB%8E%E8%A5%BF%E9%83%A8%E6%8B%89%E5%87%BA%20%3CBR%20%2F%3E%20%3CBR%20%2F%3E%20%3CBR%20%2F%3E%20%3CBR%20%2F%3E%20%3CBR%20%2F%3E%3C%2FP%3E%0A%3CP%3ESDK%20CMake%20%E7%B3%BB%E7%BB%9F%E5%B7%B2%E7%BB%8F%E7%9F%A5%E9%81%93%E5%93%AA%E4%BA%9B%E6%96%87%E4%BB%B6%E5%B1%9E%E4%BA%8E%E6%AF%8F%E4%B8%AA%E5%85%83%E5%99%A8%E4%BB%B6%E3%80%82%E6%82%A8%E4%B8%8D%E5%BA%94%E6%89%8B%E5%8A%A8%E5%88%97%E5%87%BA%E8%BF%99%E4%BA%9B%E5%86%85%E5%AE%B9%E3%80%82%3C%2FP%3E%0A%3CP%3EBR%3C%2FP%3E%0A%3CP%3E%E5%93%88%E5%88%A9%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-2252351%22%20slang%3D%22en-US%22%20mode%3D%22CREATE%22%20translate%3D%22no%22%3ERe%3A%20How%20to%20setup%20CMake%20in%20a%20fresh%20project%20(custom%20board)%20to%20add%2Freference%20the%20MCUXpresso%20SDK%20properl%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-2252351%22%20slang%3D%22en-US%22%20mode%3D%22CREATE%22%3E%3CP%3E%E8%B0%A2%E8%B0%A2%E4%BD%A0%EF%BC%8C%E5%93%88%E9%87%8C%E3%80%82%3C%2FP%3E%3CBR%20%2F%3E%3CP%3E%E6%88%91%E5%90%8C%E6%84%8F%E8%BF%99%E6%98%AF%E6%9C%80%E9%80%82%E5%90%88%E6%88%91%E7%9A%84%E9%A1%B9%E7%9B%AE%E7%9A%84%E7%BB%93%E6%9E%84%E3%80%82%E6%88%91%E7%9A%84%E9%97%AE%E9%A2%98%E6%98%AF%E4%B8%8D%E7%9F%A5%E9%81%93%E5%A6%82%E4%BD%95%E5%9C%A8%E9%A1%B9%E7%9B%AE%E6%A0%B9%E7%9B%AE%E5%BD%95%E4%B8%8B%E5%88%9B%E5%BB%BA%20CMake%EF%BC%8C%E4%BB%A5%E6%AD%A3%E7%A1%AE%E6%B7%BB%E5%8A%A0%E5%92%8C%E7%BC%96%E8%AF%91%20application%2Fecu%2Fmodules%20%E6%96%87%E4%BB%B6%E5%A4%B9%E5%92%8C%20sdk%20%E6%96%87%E4%BB%B6%E5%A4%B9%E3%80%82%3C%2FP%3E%3CP%3E%E5%AF%B9%E4%BA%8E%E6%88%91%E6%89%8B%E5%8A%A8%E7%BC%96%E5%86%99%E7%9A%84%20ony%EF%BC%8C%E6%88%91%E5%8F%AA%E9%9C%80%E9%80%9A%E8%BF%87%20CMake%22add_subdirectory%22%20%E8%BF%9B%E8%A1%8C%E7%BC%96%E8%AF%91%EF%BC%8C%E5%85%B6%E4%B8%AD%E6%AF%8F%E4%B8%AA%E5%AD%90%E6%96%87%E4%BB%B6%E5%A4%B9%E9%83%BD%E5%B0%86%E5%8C%85%E5%90%AB%E5%90%84%E8%87%AA%E7%9A%84%20CMake%EF%BC%8C%E4%BB%A5%E5%88%9B%E5%BB%BA%20CMake%20%E5%BA%93%E3%80%82%E7%84%B6%E5%90%8E%EF%BC%8C%E6%88%91%E9%80%9A%E8%BF%87%22traget_link_libraries%22%20%E5%9C%A8%20CMake%20%E6%A0%B9%E7%9B%AE%E5%BD%95%E4%B8%AD%E5%B0%86%E5%AE%83%E4%BB%AC%E9%93%BE%E6%8E%A5%E5%9C%A8%E4%B8%80%E8%B5%B7%E3%80%82%E6%88%91%E4%B8%BE%E4%BA%86%E8%BF%99%E4%B8%A4%E4%B8%AA%20CMake%20%E7%9A%84%E4%BE%8B%E5%AD%90%EF%BC%8C%E5%B0%B1%E5%83%8F%E6%88%91%E7%8E%B0%E5%9C%A8%E4%B8%80%E6%A0%B7%EF%BC%88%E7%A8%8D%E5%BE%AE%E7%AE%80%E5%8C%96%E4%BA%86%E4%B8%80%E7%82%B9%EF%BC%8C%E8%BF%99%E6%A0%B7%E6%88%91%E4%BB%AC%E5%B0%B1%E4%B8%8D%E7%94%A8%E6%8B%85%E5%BF%83%E4%B8%8D%E5%90%8C%E7%9A%84%E7%89%88%E6%9C%AC%E7%9B%AE%E6%A0%87%E4%BA%86%EF%BC%89%E3%80%82%3C%2FP%3E%3CP%3E%E6%88%91%E7%BC%BA%E5%B0%91%E7%9A%84%E6%98%AF%E5%A6%82%E4%BD%95%E5%B0%86SDK%E6%B7%BB%E5%8A%A0%E5%88%B0%E8%BF%99%E4%B8%AA%E6%95%B4%E4%BD%93%E7%89%88%E6%9C%AC%E7%B3%BB%E7%BB%9F%E4%B8%AD%EF%BC%8C%E5%B9%B6%E7%A1%AE%E4%BF%9D%E6%88%91%E7%9A%84ecu%E6%96%87%E4%BB%B6%E5%A4%B9%E5%8F%AF%E4%BB%A5%E8%AE%BF%E9%97%AE%E5%AE%83%E3%80%82%3C%2FP%3E%3CBR%20%2F%3E%3C%2FLINGO-BODY%3E