Commit Graph

14 Commits

Author SHA1 Message Date
Ed Schouten
7e659f9491 Add the Clang specific -Wmissing-variable-declarations to WARNS=6.
This compiler flag enforces that that people either mark variables
static or use an external declarations for the variable, similar to how
-Wmissing-prototypes works for functions.

Due to the fact that Yacc/Lex generate code that cannot trivially be
changed to not warn because of this (lots of yy* variables), add a
NO_WMISSING_VARIABLE_DECLARATIONS that can be used to turn off this
specific compiler warning.

Announced on:	toolchain@
2013-04-19 19:45:00 +00:00
Antoine Brodin
6af2d8427c Add missing DPADD. 2013-01-01 18:25:14 +00:00
Andreas Tobler
6f1a642726 Fix build. 2012-10-21 08:38:55 +00:00
Dimitry Andric
c48f7f6814 Repair breakage after r228697: since m4 now uses pow(3), it needs -lm.
Pointy hat to:	bapt
2011-12-18 23:54:32 +00:00
Baptiste Daroussin
a841e1ebe6 Synchronize with laster version of m4 from OpenBSD and NetBSD
This bring better compatibility with gnum4

Reviewed by:	cognet
Approved by:	cognet
Obtained from:	OpenBSD, NetBSD
2011-11-28 13:32:39 +00:00
Ed Schouten
1e2070ab5b Fix build of m4 with WARNS=6.
Change the parser; rename `exp' to `exponent' not to collide with exp(3).
2011-10-16 08:09:17 +00:00
Ed Schouten
b7946da96b Build usr.bin/ with WARNS=6 by default.
Also add some missing $FreeBSD$ to keep svn happy.
2010-01-02 10:27:05 +00:00
Ruslan Ermilov
254dd1666e Let bsd.prog.mk set SRCS and MAN to their default values. 2005-01-28 16:08:11 +00:00
Juli Mallett
bd2bfb5846 Merge local changes again, against ANSIfied m4(1). 2002-05-01 21:37:29 +00:00
Juli Mallett
82130df48c Use %zu to print a size_t, not %u and definitely not %d.
Remove WARNS?=2, as GCC will usually throw a fit right now, and I'm not going
to mix WARNS and NO_WERROR.

Submitted by:	fenner
2002-04-20 21:37:26 +00:00
Juli Mallett
ccc5b4e6f4 Crank WARNS.
Cast sizeof() to (int), as it's being compared against an int, not a size_t.
If i is changed to a size_t, it means the logic must be slightly changed later
in the flow, where --i is checked to be >= 0.  I am not sure I want to make a
logic change to account for clearing up a warning, when an aesthetic one will
keep from modifying the logic.

Other harmless casts, that I think I've made in the right directions.

Make gpbc() an inline function, rather than an obfuscated macro, make its
scratch space local, rather than global.  The previous macro used a dirty
hack (logical AND in place of a conditional) which would lead GCC to throw
a fit (rightly so) as the logical check, as well as the incrementation of
a variable, were not used for anything.

const'ify a few places where gcc3 yells. xstrdup() some global consts in
places where we xstrdup() when not using consts, but tried to assign them
to non-consts before.

Don't use execv(2) if we don't have the kind of arguments it wants.

Reviewed by:    asmodai obrien tjr
Submitted by:   tjr (a gcc3 build log)
2002-04-20 01:49:10 +00:00
Juli Mallett
acc9d40838 Bring OpenBSD m4(1) off of the OPENBSD vendor branch, and add the -s option,
$FreeBSD$ identifiers, and fix initialisation to stderr to happen in a function
as stderr is not the same in CURRENT as in OpenBSD.

Reviewed by:	obrien
2002-04-19 17:26:21 +00:00
Rodney W. Grimes
7799f52a32 Remove trailing whitespace. 1995-05-30 06:41:30 +00:00
Rodney W. Grimes
9b50d90275 BSD 4.4 Lite Usr.bin Sources 1994-05-27 12:33:43 +00:00