开发者

View Linux module source file after preprocessed

开发者 https://www.devze.com 2023-02-27 02:32 出处:网络
When compiling with gcc we can view preprocessed source files with option -E. How can we apply this to the Makefile of kernel modules (external compile). The source files contain a lot of #ifdef #else

When compiling with gcc we can view preprocessed source files with option -E. How can we apply this to the Makefile of kernel modules (external compile). The source files contain a lot of #ifdef #else #endif, is there a way to quick check which parts of code 开发者_开发问答are actually included in the compiled file. Any suggestions are appreciated. Thanks in advanced.


Add CFLAGS=-E to your make invocation.

0

精彩评论

暂无评论...
验证码 换一张
取 消