Redo a change in rev 1.160 with more proper way:

> Don't make linker warnings fatal on linking static libs since
> there is no proper way to avoid "FOO is a patented algorithm" warnings.

Ok'ed by christos@ and dogcow@ on tech-toolchain, and
tested build.sh build for sun2, news68k, alpha and newsmips.
This commit is contained in:
tsutsui 2008-04-22 12:47:59 +00:00
parent 8668268571
commit c81a918994

View File

@ -1,4 +1,4 @@
# $NetBSD: bsd.sys.mk,v 1.161 2008/04/15 00:08:05 tsutsui Exp $
# $NetBSD: bsd.sys.mk,v 1.162 2008/04/22 12:47:59 tsutsui Exp $
#
# Build definitions used for NetBSD source tree builds.
@ -17,8 +17,13 @@ CFLAGS+= -Wall -Wstrict-prototypes -Wmissing-prototypes -Wpointer-arith
# we wanted, and now we don't get anymore.
CFLAGS+= -Wno-sign-compare -Wno-traditional
# Set linker warnings to be fatal
# XXX no proper way to avoid "FOO is a patented algorithm" warnings
# XXX on linking static libs
.if (!defined(MKPIC) || ${MKPIC} != "no") && \
(!defined(LDSTATIC) || ${LDSTATIC} != "-static")
LDFLAGS+= -Wl,--fatal-warnings
.endif
.endif
.if ${WARNS} > 1
CFLAGS+= -Wreturn-type -Wswitch -Wshadow
.endif