Migration from CW10.3 to KDS 3.0

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

Migration from CW10.3 to KDS 3.0

跳至解决方案
1,418 次查看
w2vy
Contributor V

I am moving a K60 project from CW10.3 w/MQX to KDS and stumbled upon a problem that I am sure there is a simple answer to.

(yet google searches don't reveal it to me...)

 

In CW10 (and many earlier versions of CW) there is an option for a "prefix" file which is a file that gets included before the target file being complied.

It is used to setup the pre-processor environment.

 

In CW10 this is what it looks like

 

32275_32275.pngCW10.3_prefix.png

 

How can I do that in KDS?

 

Tom

标签 (1)
标记 (2)
0 项奖励
回复
1 解答
1,213 次查看
BlackNight
NXP Employee
NXP Employee

Hi Tom,

see Preprocessor Options - Using the GNU Compiler Collection (GCC)

-include file
Process file as if #include "file" appeared as the first line of the primary source file. However, the first directory searched for file is the preprocessor's working directory instead of the directory containing the main source file. If not found there, it is searched for in the remainder of the #include "..." search chain as normal. 

If multiple -include options are given, the files are included in the order they appear on the command line. 

I hope this helps,

Erich

在原帖中查看解决方案

0 项奖励
回复
3 回复数
1,214 次查看
BlackNight
NXP Employee
NXP Employee

Hi Tom,

see Preprocessor Options - Using the GNU Compiler Collection (GCC)

-include file
Process file as if #include "file" appeared as the first line of the primary source file. However, the first directory searched for file is the preprocessor's working directory instead of the directory containing the main source file. If not found there, it is searched for in the remainder of the #include "..." search chain as normal. 

If multiple -include options are given, the files are included in the order they appear on the command line. 

I hope this helps,

Erich

0 项奖励
回复
1,213 次查看
w2vy
Contributor V

Yes I found that at mcuonline... Thanks was coming back to update...

One thing that was surprising is that I tried using a variable and while I could use the KSDK path variables, I could not use my own defined variable that was in the same table under Properties->Resource->Path Variables

I may need to make a simple example to demonstrate this

tom

0 项奖励
回复
1,213 次查看
trytohelp
NXP Employee
NXP Employee

Hi Tom,

Don't know if this can help you but you can have a look the the doc:

    Importing MCU V10.6 projects (sample, using PE and MQX) under KDS

Have a great day,
Pascal
Freescale Technical Support
-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

0 项奖励
回复