-o0 in CCFLAGS breaking scons debug build on linux #343

Closed
opened 2023-02-03 22:10:02 +00:00 by NQNStudios · 0 comments
NQNStudios commented 2023-02-03 22:10:02 +00:00 (Migrated from github.com)

scons debug=true on Linux isn't working because it adds -g -o0 to the compiler flags. -o0 should be interpreted by g++ and clang as disabling optimization but it's actually being processed as setting the output file to 0. So every file is getting compiled to cboe/0 and of course that's no good.

1bc7524ec2/SConstruct (L50)

Changing the flag here to -O0 (capital O) fixes it for me.

`scons debug=true` on Linux isn't working because it adds `-g -o0` to the compiler flags. `-o0` should be interpreted by g++ and clang as disabling optimization but it's actually being processed as setting the output file to 0. So every file is getting compiled to `cboe/0` and of course that's no good. https://github.com/calref/cboe/blob/1bc7524ec218782ee469b2cb853f570a3f4eedcc/SConstruct#L50 Changing the flag here to `-O0` (capital O) fixes it for me.
Sign in to join this conversation.
No description provided.