Deal with optional HAVE_GCC.
This commit is contained in:
parent
f4f2339ab8
commit
c14f2d4ef8
4
external/gpl3/Makefile
vendored
4
external/gpl3/Makefile
vendored
@ -1,4 +1,4 @@
|
||||
# $NetBSD: Makefile,v 1.6 2011/10/31 08:14:44 mrg Exp $
|
||||
# $NetBSD: Makefile,v 1.7 2012/08/10 16:05:26 joerg Exp $
|
||||
|
||||
.include <bsd.own.mk>
|
||||
|
||||
@ -6,11 +6,13 @@
|
||||
SUBDIR+= binutils
|
||||
.endif
|
||||
|
||||
.if ${MKGCC} != "no"
|
||||
.if ${HAVE_GCC} == 45
|
||||
.if ${MKGCCCMDS} != "no"
|
||||
SUBDIR+= gcc
|
||||
.endif
|
||||
.endif
|
||||
.endif
|
||||
|
||||
.if ${MKGDB} != "no"
|
||||
.if ${HAVE_GDB} == "7"
|
||||
|
4
external/historical/nawk/bin/Makefile
vendored
4
external/historical/nawk/bin/Makefile
vendored
@ -1,4 +1,4 @@
|
||||
# $NetBSD: Makefile,v 1.8 2011/08/16 10:45:37 christos Exp $
|
||||
# $NetBSD: Makefile,v 1.9 2012/08/10 16:05:26 joerg Exp $
|
||||
|
||||
WARNS?= 4
|
||||
CWARNFLAGS.clang+= -Wno-self-assign
|
||||
@ -17,9 +17,7 @@ LDADD+= -lm
|
||||
DPADD+= ${LIBM}
|
||||
.endif
|
||||
YHEADER= yes
|
||||
.if defined(HAVE_GCC) || defined(HAVE_PCC)
|
||||
COPTS+= -Wno-pointer-sign
|
||||
.endif
|
||||
COPTS.run.c += -Wno-format-nonliteral
|
||||
COPTS.tran.c += -Wno-format-nonliteral
|
||||
|
||||
|
4
external/lgpl3/gmp/lib/libgmp/Makefile
vendored
4
external/lgpl3/gmp/lib/libgmp/Makefile
vendored
@ -1,4 +1,4 @@
|
||||
# $NetBSD: Makefile,v 1.12 2011/09/21 02:06:42 mrg Exp $
|
||||
# $NetBSD: Makefile,v 1.13 2012/08/10 16:05:26 joerg Exp $
|
||||
|
||||
.include <bsd.init.mk>
|
||||
|
||||
@ -191,8 +191,6 @@ CLEANFILES+= ${DPSRCS} gen-fac_ui gen-fib gen-bases gen-psqr gen-trialdivtab
|
||||
|
||||
# Don't warn about functions which cannot be stack smash protected as
|
||||
# there are a lot of them.
|
||||
.if defined(HAVE_GCC) || defined(HAVE_PCC)
|
||||
COPTS += -Wno-stack-protector
|
||||
.endif
|
||||
|
||||
CWARNFLAGS.clang+= -Wno-unused-value -Wno-tautological-compare
|
||||
|
@ -1,4 +1,4 @@
|
||||
# $NetBSD: Makefile.kern.inc,v 1.157 2012/07/27 05:40:51 matt Exp $
|
||||
# $NetBSD: Makefile.kern.inc,v 1.158 2012/08/10 16:05:26 joerg Exp $
|
||||
#
|
||||
# This file contains common `MI' targets and definitions and it is included
|
||||
# at the bottom of each `MD' ${MACHINE}/conf/Makefile.${MACHINE}.
|
||||
@ -70,7 +70,6 @@ CWARNFLAGS+= -Wold-style-definition
|
||||
CWARNFLAGS+= -Wswitch -Wshadow
|
||||
CWARNFLAGS+= -Wcast-qual -Wwrite-strings
|
||||
CWARNFLAGS+= -Wno-unreachable-code
|
||||
. if defined(HAVE_GCC) || defined(HAVE_PCC)
|
||||
CWARNFLAGS+= -Wno-pointer-sign -Wno-attributes
|
||||
. if ${MACHINE} == "i386" || ${MACHINE_ARCH} == "x86_64" || \
|
||||
${MACHINE_ARCH} == "sparc64" || ${MACHINE} == "prep"
|
||||
@ -79,7 +78,6 @@ CWARNFLAGS+= -Wextra -Wno-unused-parameter
|
||||
. if ${MACHINE} == "i386" || ${MACHINE_ARCH} == "x86_64"
|
||||
CWARNFLAGS+= -Wold-style-definition
|
||||
. endif
|
||||
. endif
|
||||
# Add -Wno-sign-compare. -Wsign-compare is included in -Wall as of GCC 3.3,
|
||||
# but our sources aren't up for it yet.
|
||||
CWARNFLAGS+= -Wno-sign-compare
|
||||
@ -96,7 +94,7 @@ CFLAGS+= ${DEBUG} ${COPTS}
|
||||
AFLAGS+= -D_LOCORE -Wa,--fatal-warnings
|
||||
|
||||
# XXX
|
||||
.if defined(HAVE_GCC)
|
||||
.if defined(HAVE_GCC) || defined(HAVE_LLVM)
|
||||
CFLAGS+= -fno-strict-aliasing
|
||||
CFLAGS+= -fno-common
|
||||
.endif
|
||||
@ -566,11 +564,9 @@ VARSTACK=kern/uipc_socket.c miscfs/genfs/genfs_vnops.c \
|
||||
uvm/uvm_pager.c dev/ic/aic7xxx.c dev/ic/aic79xx.c arch/xen/i386/gdt.c \
|
||||
dev/ofw/ofw_subr.c
|
||||
|
||||
.if defined(HAVE_GCC) || defined(HAVE_PCC)
|
||||
.for __varstack in ${VARSTACK}
|
||||
COPTS.${__varstack:T} += -Wno-stack-protector
|
||||
.endfor
|
||||
.endif
|
||||
|
||||
AFLAGS+= ${AOPTS.${.IMPSRC:T}}
|
||||
CFLAGS+= ${COPTS.${.IMPSRC:T}} ${CPUFLAGS.${.IMPSRC:T}}
|
||||
|
@ -1,4 +1,4 @@
|
||||
# $NetBSD: Makefile.inc,v 1.40 2005/12/20 19:35:26 christos Exp $
|
||||
# $NetBSD: Makefile.inc,v 1.41 2012/08/10 16:05:27 joerg Exp $
|
||||
#
|
||||
# Configuration variables (default values are below):
|
||||
#
|
||||
@ -47,6 +47,8 @@ KERNMAKE= \
|
||||
KERNCPPFLAGS=${CPPFLAGS:S@^-I.@-I${KERNDOTDIR}@g:Q} \
|
||||
KERNMISCCPPFLAGS=${KERNMISCCPPFLAGS:Q} \
|
||||
LINTFLAGS=${KERNLINTFLAGS:Q} \
|
||||
LIBKERN_ARCH=${LIBKERN_ARCH:Q} \
|
||||
COMMON_MACHINE_ARCH=${COMMON_MACHINE_ARCH:Q} \
|
||||
${KERNMISCMAKEFLAGS}
|
||||
|
||||
${KERNLIB}: .NOTMAIN .MAKE __always_make_kernlib
|
||||
|
@ -1,4 +1,4 @@
|
||||
# $NetBSD: Makefile,v 1.77 2012/01/16 18:44:13 christos Exp $
|
||||
# $NetBSD: Makefile,v 1.78 2012/08/10 16:05:27 joerg Exp $
|
||||
|
||||
LIB= sa
|
||||
NOPIC= # defined
|
||||
@ -91,9 +91,7 @@ lib${LIB}.o:: ${OBJS}
|
||||
@rm -f lib${LIB}.o
|
||||
@${LD} -r -o lib${LIB}.o `lorder ${OBJS} | tsort`
|
||||
|
||||
.if defined(HAVE_GCC) || defined(HAVE_PCC)
|
||||
CPPFLAGS+= -Wno-pointer-sign
|
||||
.endif
|
||||
|
||||
.if defined(HAVE_GCC) && ${HAVE_GCC} >= 45 && ${MACHINE_ARCH} == "vax"
|
||||
COPTS.bootp.c+= -O0
|
||||
|
@ -1,4 +1,4 @@
|
||||
# $NetBSD: Makefile.rump,v 1.62 2012/08/05 15:37:39 pooka Exp $
|
||||
# $NetBSD: Makefile.rump,v 1.63 2012/08/10 16:05:27 joerg Exp $
|
||||
#
|
||||
|
||||
WARNS?= 3 # XXX: src/sys won't compile with -Wsign-compare yet
|
||||
@ -16,7 +16,7 @@ CPPFLAGS+= -D_RUMP_NATIVE_ABI
|
||||
.endif
|
||||
|
||||
CFLAGS+= -ffreestanding -fno-strict-aliasing
|
||||
.if defined(HAVE_GCC) && ${HAVE_GCC} >= 3
|
||||
.if (defined(HAVE_GCC) && ${HAVE_GCC} >= 3) || defined(HAVE_LLVM)
|
||||
CFLAGS+= -Wsign-compare
|
||||
CFLAGS+= -Wno-pointer-sign -Wno-attributes
|
||||
CFLAGS+= -std=gnu99
|
||||
|
Loading…
Reference in New Issue
Block a user