o2 icon indicating copy to clipboard operation
o2 copied to clipboard

allow injection of additional CFLAGS

Open umlaeute opened this issue 3 years ago • 2 comments

it seems that the CMakeFile sets the build flags https://github.com/rbdannenberg/o2/blob/151b1c6b9536fac333e647a13a6cef3b547fa814/CMakeLists.txt#L361 in a way, that does not allow the user to inject additional build flags.

would it be possible to use something like this instead:

set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -std=c11 -mcx16")

?

umlaeute avatar Aug 16 '22 15:08 umlaeute

Yes, I made the change. As far as I can tell, with the change, you can set CMAKE_C_FLAGS in the cache to "extra" flags and get "-std=c11 -mcx16" added automatically.

rbdannenberg avatar Oct 08 '22 14:10 rbdannenberg

As far as I can tell, [..]

yes, this was my intention.

Yes, I made the change

i don't see it in current master: https://github.com/rbdannenberg/o2/blob/e83488f166bb5d58ba672217dd0c2a3cf3031874/CMakeLists.txt#L362

am i missing something?

umlaeute avatar Oct 10 '22 06:10 umlaeute