Skip to contentSkip to conversation

Enabling Macro from .bb file

DISCUSSION Ugesh Reddy 2 participants 2 messages May 29, 2018 – Jun 4, 2018 1 message not in the archive

lore
Share & tools
lore

A message that is not in the archive (sent off-list or not yet received): [email protected]

#1 lore raw

Hello,  I have the source code were the part of the code kept inside the #ifdef SOME_MACRO  and what would be the correct place to define SOME_MACRO  this macro?note: This define is specific to the recipe. Regrds,Ugesh

#2 lore raw

You want to pass -DSOME_MACRO to the compiler, so extend CPPFLAGS in your recipe:

CPPFLAGS += "-DSOME_MACRO"

Note that this assumes the build system that the code is using is listening to $CPPFLAGS.

Ross

Quoted 15 lines · Ugesh Reddy

Hello,
I have the source code were the part of the code kept inside the #ifdef
SOME_MACRO and what would be the correct place to define SOME_MACRO this macro?
note: This define is specific to the recipe.

Regrds,
Ugesh

--
_______________________________________________
yocto mailing list
[email protected]
https://lists.yoctoproject.org/listinfo/yocto