Would it be "-D"?

As in, to enable foo:
em++ -D FOO=1
to disable foo
em++ -D FOO=0

?


On Monday, October 5, 2020 at 11:21:11 AM UTC-7, Shawn Riordan wrote:
>
> If I wanted my code to have a custom preprocessor definition, how do I 
> pass that on the emcc commandline?
>
> Lets say I want my C++ code to have something like:
>
> #ifdef FOO
>     printf("foo");
> #endif
>
> how do I set the value of FOO when I run emcc?
>

-- 
You received this message because you are subscribed to the Google Groups 
"emscripten-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/emscripten-discuss/5830eb7e-33b6-4149-8d37-21239e20fe1bo%40googlegroups.com.

Reply via email to