style.Makefile(5):

Use WARNS?= instead of WARNS=

For this to work properly for all part is the subdirectories
the WARNS assignments in Makefile.inc0 are moved to the correspondning
Makefile.inc.

Approved by:	obrien (binutils maintainer)
Tested by:	make universe
This commit is contained in:
johan 2004-02-24 19:23:33 +00:00
parent b646484505
commit d5866454e3
19 changed files with 25 additions and 22 deletions

View File

@ -1,4 +1,11 @@
#
# $FreeBSD$
#
.if (${TARGET_ARCH} == "alpha")
WARNS?= 2
.else
WARNS?= 3
.endif
.include "../Makefile.inc"

View File

@ -17,11 +17,6 @@ RELTOP:= ..
RELSRC= ${RELTOP}/../../../contrib/binutils
SRCDIR= ${.CURDIR}/${RELSRC}
.if (${TARGET_ARCH} == "alpha")
WARNS= 2
.else
WARNS= 3
.endif
CFLAGS+= -D_GNU_SOURCE
CFLAGS+= -I.
.if exists(${.CURDIR}/${TARGET_ARCH})

View File

@ -6,7 +6,7 @@
PROG= addr2line
SRCS= addr2line.c
WARNS= 2
WARNS?= 2
CFLAGS+= -I${.CURDIR}/${RELTOP}/libbinutils
CFLAGS+= -I${SRCDIR}/binutils
DPADD= ${RELTOP}/libbinutils/libbinutils.a

View File

@ -1,4 +1,6 @@
# $FreeBSD$
WARNS?= 2
# BINDIR
.include "${.CURDIR}/../../Makefile.inc"

View File

@ -15,7 +15,6 @@ SRCS+= app.c as.c atof-generic.c atof-ieee.c bignum-copy.c \
subsegs.c symbols.c write.c depend.c ehopt.c
# DEO: why not used?
#SRCS+= itbl-ops.c
WARNS= 2
CFLAGS+= -I${SRCDIR}/gas -I${SRCDIR}/gas/config -I${SRCDIR} -I${.CURDIR}/..
CFLAGS+= -DVERSION=\"${VERSION:C/[ ]?${VERSION_DATE}[ ]?//g}\"
CFLAGS+= -DBFD_VERSION_STRING=\"${VERSION}\"

View File

@ -2,7 +2,7 @@
.include "${.CURDIR}/../Makefile.inc0"
WARNS= 0
WARNS?= 0
.if ${TARGET_ARCH} != "ia64"
NOMAN= true

View File

@ -6,7 +6,7 @@
PROG= gasp
SRCS+= gasp+%FIXED.c macro.c sb.c hash.c
WARNS= 2
WARNS?= 2
CFLAGS+= -DBFD_ASSEMBLER
CFLAGS+= -I${.CURDIR}/../as/${TARGET_ARCH}-freebsd -I${.CURDIR}/../as
CFLAGS+= -I${.CURDIR}

View File

@ -50,7 +50,7 @@ SRCS= init.c ${XSRCS} nm.h tm.h xm.h gdbversion.c xregex.h
.include "${.CURDIR}/Makefile.${TARGET_ARCH}"
WARNS= 0
WARNS?= 0
.if ${TARGET_ARCH} != ${MACHINE_ARCH}
CFLAGS+= -DCROSS_COMPILE=1
.endif

View File

@ -10,7 +10,7 @@ SRCS+= ldcref.c ldctor.c ldemul.c ldemul-list.h ldexp.c ldfile.c \
ldgram.y ldlang.c ldlex.l ldmain.c ldmisc.c \
ldver.c ldwrite.c lexsup.c mri.c
WARNS= 1
WARNS?= 1
CFLAGS+= -DSCRIPTDIR=\"${TOOLS_PREFIX}/usr/libdata\"
CFLAGS+= -DBFD_VERSION_STRING=\"${VERSION}\"
CFLAGS+= -I${SRCDIR}/ld -I${SRCDIR}/bfd

View File

@ -10,10 +10,10 @@ SRCS+= archive.c archive64.c archures.c bfd.c binary.c cache.c \
hash.c ihex.c init.c libbfd.c linker.c merge.c opncls.c reloc.c \
section.c srec.c stab-syms.c stabs.c syms.c targets.c tekhex.c \
targmatch.h dwarf1.c dwarf2.c config.h
WARNS?=0
.if (${TARGET_ARCH} == "alpha" || ${TARGET_ARCH} == "ia64" || ${TARGET_ARCH} == "sparc64")
WARNS= 2
WARNS?= 2
.endif
WARNS=0
CFLAGS+= -I${SRCDIR}/bfd
CFLAGS+= -DBFD_VERSION=\"${VERSION_DATE}\" -DBFD_VERSION_DATE=${VERSION_DATE}
CFLAGS+= -DBFD_VERSION_STRING=\"${VERSION}\"

View File

@ -8,7 +8,7 @@ LIB= binutils
SRCS+= arlex.l arparse.y arsup.c bucomm.c debug.c filemode.c \
ieee.c rdcoff.c rddbg.c rename.c stabs.c unwind-ia64.c \
wrstabs.c version.c binemul.c budemang.c emul_vanilla.c
WARNS= 0
WARNS?= 0
.if ${TARGET_ARCH} == "amd64"
BINUTILS_ARCH=x86_64
.else

View File

@ -10,7 +10,7 @@ SRCS= argv.c choose-temp.c concat.c cp-demangle.c cplus-dem.c \
hex.c floatformat.c hashtab.c lbasename.c make-temp-file.c \
objalloc.c obstack.c safe-ctype.c xatexit.c xexit.c xmalloc.c \
xstrdup.c xstrerror.c
WARNS= 1
WARNS?= 1
CFLAGS+= -DHAVE_CONFIG_H
INTERNALLIB= true

View File

@ -6,7 +6,7 @@
PROG= nm
SRCS= nm.c
WARNS= 2
WARNS?= 2
CFLAGS+= -I${.CURDIR}/${RELTOP}/libbinutils
CFLAGS+= -I${SRCDIR}/bfd
CFLAGS+= -I${SRCDIR}/binutils

View File

@ -6,7 +6,7 @@
PROG= objcopy
SRCS= objcopy.c not-strip.c
WARNS= 2
WARNS?= 2
CFLAGS+= -I${.CURDIR}/${RELTOP}/libbinutils
CFLAGS+= -I${SRCDIR}/binutils
DPADD= ${RELTOP}/libbinutils/libbinutils.a

View File

@ -6,7 +6,7 @@
PROG= objdump
SRCS= objdump.c prdbg.c
WARNS= 2
WARNS?= 2
CFLAGS+= -I${.CURDIR}/${RELTOP}/libbinutils
CFLAGS+= -I${SRCDIR}/binutils
CFLAGS+= -DBFD_VERSION_STRING=\"${VERSION}\"

View File

@ -9,7 +9,7 @@ BINDIR=/usr/bin
PROG= readelf
SRCS= ${PROG}.c
WARNS= 0
WARNS?= 0
CFLAGS+= -I${.CURDIR}/${RELTOP}/libbinutils -I${SRCDIR}/binutils
DPADD= ${RELTOP}/libbinutils/libbinutils.a

View File

@ -6,7 +6,7 @@
PROG= size
SRCS= size.c
WARNS= 2
WARNS?= 2
CFLAGS+= -I${.CURDIR}/${RELTOP}/libbinutils
CFLAGS+= -I${SRCDIR}/binutils
DPADD= ${RELTOP}/libbinutils/libbinutils.a

View File

@ -6,7 +6,7 @@
PROG= strings
SRCS= strings.c
WARNS= 2
WARNS?= 2
CFLAGS+= -I${.CURDIR}/${RELTOP}/libbinutils
CFLAGS+= -I${SRCDIR}/binutils
DPADD= ${RELTOP}/libbinutils/libbinutils.a

View File

@ -6,7 +6,7 @@
PROG= strip
SRCS= objcopy.c is-strip.c
WARNS= 2
WARNS?= 2
CFLAGS+= -I${.CURDIR}/${RELTOP}/libbinutils
CFLAGS+= -I${SRCDIR}/binutils
DPADD= ${RELTOP}/libbinutils/libbinutils.a