回复: [edk2-devel] Is it possible to inject compiler arguments and library dependencies from the build system?


gaoliming
 

Pedro:

 For the specific platform, you can add the compiler flag into [BuildOptions] in Platform.dsc file, and add NULL|xxxLib.inf into [LibraryClasses] section in Platform.dsc file so that this library is linked to every module.

 

Thanks

Liming

发件人: devel@edk2.groups.io <devel@edk2.groups.io> 代表 Pedro Falcato
发送时间: 202261 5:43
收件人: edk2-devel-groups-io <devel@edk2.groups.io>
主题: [edk2-devel] Is it possible to inject compiler arguments and library dependencies from the build system?

 

Hi all,

 

Following https://edk2.groups.io/g/devel/message/89684, I want to add sanitizer support to upstream EDK2. Doing this in a non-intrusive way would mean that I need to force all modules to depend on the UBSAN/ASAN implementation lib and force them to use a specific compile flag. Is there a way to do this using the current build system?

 

Thanks,

Pedro

Join devel@edk2.groups.io to automatically receive all group messages.