Commit Graph

16 Commits

Author SHA1 Message Date
mrg de11d87641 introduce some common variables for use in GCC warning disables:
GCC_NO_FORMAT_TRUNCATION    -Wno-format-truncation (GCC 7/8)
GCC_NO_STRINGOP_TRUNCATION  -Wno-stringop-truncation (GCC 8)
GCC_NO_STRINGOP_OVERFLOW    -Wno-stringop-overflow (GCC 8)
GCC_NO_CAST_FUNCTION_TYPE   -Wno-cast-function-type (GCC 8)

use these to turn off warnings for most GCC-8 complaints.  many
of these are false positives, most of the real bugs are already
commited, or are yet to come.


we plan to introduce versions of (some?) of these that use the
"-Wno-error=" form, which still displays the warnings but does
not make it an error, and all of the above will be re-considered
as either being "fix me" (warning still displayed) or "warning
is wrong."
2019-10-13 07:28:04 +00:00
lukem d877c4c3c0 Enable WARNS=4 by default, except for:
cpuctl  dumplfs  hprop  ipf  iprop-log  kadmin  kcm  kdc  kdigest
	kimpersonate  kstash  ktutil  makefs  ndbootd  ntp  pppd  quot
	racoon  racoonctl  rtadvd  sntp  sup  tcpdchk  tcpdmatch  tcpdump
	traceroute  traceroute6  user  veriexecgen  wsmoused  zic
(Mostly third-party applications)
2009-04-22 15:23:01 +00:00
tls 4147a3c54a Add new Makefile knob, USE_FORT, which extends USE_SSP by turning on the
FORTIFY_SOURCE feature of libssp, thus checking the size of arguments to
various string and memory copy and set functions (as well as a few system
calls and other miscellany) where known at function entry.  RedHat has
evidently built all "core system packages" with this option for some time.

This option should be used at the top of Makefiles (or Makefile.inc where
this is used for subdirectories) but after any setting of LIB.

This is only useful for userland code, and cannot be used in libc or in
any code which includes the libc internals, because it overrides certain
libc functions with macros.  Some effort has been made to make USE_FORT=yes
work correctly for a full-system build by having the bsd.sys.mk logic
disable the feature where it should not be used (libc, libssp iteself,
the kernel) but no attempt has been made to build the entire system with
USE_FORT and doing so will doubtless expose numerous bugs and misfeatures.

Adjust the system build so that all programs and libraries that are setuid,
directly handle network data (including serial comm data), perform
authentication, or appear likely to have (or have a history of having)
data-driven bugs (e.g. file(1)) are built with USE_FORT=yes by default,
with the exception of libc, which cannot use USE_FORT and thus uses
only USE_SSP by default.  Tested on i386 with no ill results; USE_FORT=no
per-directory or in a system build will disable if desired.
2007-05-28 12:06:17 +00:00
christos f17eeccada Fixes from Liam J. Foy to use poll, and proper signals. (from OpenBSD)
While there, ansify, and fix const abuse.
2005-06-24 13:22:09 +00:00
lukem 17d72c8a6b use NETBSDSRCDIR as appropriate 2002-09-18 03:54:26 +00:00
christos b166b5b47b use utmpx. 2002-08-02 02:38:15 +00:00
thorpej bcd4659148 Use pidfile(3). 1999-06-06 03:27:35 +00:00
lukem 149f1867d1 rcsid fascism 1997-10-18 04:36:50 +00:00
cgd dd7fbd1461 doesn't need libkvm any more 1997-03-08 22:21:55 +00:00
cgd d8806814a6 specify man pages the new way. 1994-12-22 11:32:57 +00:00
andrew b55bc39b4e rwhod wasn't too happy after the off_t change - its lseek() to check the
boottime was broken.  Replaced this code with kvm_nlist()/kvm_read() to be
more efficient.
1994-04-06 03:01:46 +00:00
cgd ecd53521f1 no longer need lib hackery 1994-01-28 05:13:28 +00:00
cgd 8970fe6df6 hack to make getloadavg() link properly 1994-01-28 00:58:41 +00:00
mycroft 3731815919 Add RCS identifiers. 1993-07-30 20:50:20 +00:00
mrg c78c6a22ab 4.4BSD-Lite2 1993-06-06 20:58:02 +00:00
cgd e541169ce2 after 0.2.2 "stable" patches applied 1993-03-21 18:04:42 +00:00