mirror of
https://github.com/freebsd/freebsd-src
synced 2024-10-15 12:54:27 +00:00
Enable -Wdate-time warning
This produces an "expansion of date or time macro is not reproducible" warning or error upon use of __DATE__ or __TIME__. Provide NO_WDATE_TIME for ports or 3rd party software to opt out. This is a recommit of489d7a8528
, which was reverted (bybaf8cbcd97
) due to ports build failures. PR: 267902 [exp-run] Reviewed by: markj Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D29580
This commit is contained in:
parent
983a18021d
commit
a8f92d247e
|
@ -75,6 +75,9 @@ CWARNFLAGS.clang+= -Wthread-safety
|
|||
CWARNFLAGS+= -Wno-uninitialized
|
||||
.endif # WARNS >=2 && WARNS <= 4
|
||||
CWARNFLAGS+= -Wno-pointer-sign
|
||||
.if !defined(NO_WDATE_TIME)
|
||||
CWARNFLAGS+= -Wdate-time
|
||||
.endif # NO_WDATE_TIME
|
||||
# Clang has more warnings enabled by default, and when using -Wall, so if WARNS
|
||||
# is set to low values, these have to be disabled explicitly.
|
||||
.if ${WARNS} <= 6
|
||||
|
|
Loading…
Reference in a new issue