Page MenuHomeFreeBSD

Disable C standards under C99 from kernel build
AcceptedPublic

Authored by minsoochoo0122_proton.me on Feb 28 2024, 11:45 PM.
Referenced Files
Unknown Object (File)
Sun, May 19, 5:56 AM
Unknown Object (File)
Wed, May 15, 10:16 AM
Unknown Object (File)
Sat, May 11, 2:54 PM
Unknown Object (File)
Sat, May 11, 8:05 AM
Unknown Object (File)
Sat, May 11, 3:57 AM
Unknown Object (File)
Mon, May 6, 10:50 PM
Unknown Object (File)
Sun, Apr 28, 5:44 PM
Unknown Object (File)
Sun, Apr 28, 2:46 AM

Details

Reviewers
emaste
imp
Group Reviewers
Contributor Reviews (src)
Summary

Separated from D43254

Test Plan
make buildworld
make buildkernel

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Passed
Unit
No Test Coverage
Build Status
Buildable 56337
Build 53225: arc lint + arc unit

Event Timeline

This revision is now accepted and ready to land.Feb 29 2024, 6:08 PM

Thanks for splitting this out.

sys/conf/kern.mk
285

Oh wait a sec.... This changes c99 too...

Is c99 now an alias on all supported compilers? I'm pretty sure it is, but wanted to double check.

at least current versions of clang/gcc12 do... with gcc 12's reaction -std=c98 being the best:
gcc12: error: unrecognized command-line option '-std=c98'; did you mean '-std=c18'?

sys/conf/kern.mk
285

I think gcc12+ and llvm15+ are the relevant (if not supported) compilers and they support c99

sys/conf/kern.mk
285

gcc supports c99 since gcc 4.5 with -std=c99 (https://gcc.gnu.org/c99status.html)
clang had c99 option since its early releases (https://clang.llvm.org/c_status.html)