Commit graph

25 commits

Author SHA1 Message Date
Warner Losh d0b2dbfa0e Remove $FreeBSD$: one-line sh pattern
Remove /^\s*#[#!]?\s*\$FreeBSD\$.*$\n/
2023-08-16 11:55:03 -06:00
Emmanuel Vadot 26ea904caa pkgbase: Create a FreeBSD-newsyslog package
This allow one to install it without having to install FreeBSD-utilities.
While here put some newsyslog.d file in their own package.

MFC after:	2 weeks
Sponsored by:	Beckhoff Automation GmbH & Co. KG
Differential Revision:	https://reviews.freebsd.org/D33456
2021-12-21 10:17:42 +01:00
Brad Davis 31ef5c6891 Move all the newsyslog related configs to usr.sbin/newsyslog/
This is related to pkgbase and changes these to use CONFS so that these are
tagged as config files.

Approved by:	AllanJude (mentor)
Sponsored by:	Essen Hackathon
Differential Revision:	https://reviews.freebsd.org/D16694
2018-08-12 13:24:53 +00:00
Mark Johnston 28984f2552 Simplify compression code.
- Remove the compression suffix macros and move them directly into the
  compress_type array.
- Remove the hardcoded sizes on the suffix and compression args arrays.
- Simplify the compression args arrays at the expense of a __DECONST
  when calling execv().
- Rewrite do_zipwork.  The COMPRESS_* macros can directly index the
  compress_types array, so the outer loop is not needed. Convert
  fixed-length strings into asprintf or sbuf calls.

Submitted by:	Dan Nelson <dnelson_1901@yahoo.com>
Reviewed by:	gad
MFC after:	2 weeks
Differential Revision:	https://reviews.freebsd.org/D16518
2018-08-08 17:26:51 +00:00
Enji Cooper d511b20a69 Add HAS_TESTS to all Makefiles that are currently using the
`SUBDIR.${MK_TESTS}+= tests` idiom.

This is a follow up to r321912.
2017-08-02 08:50:42 +00:00
Enji Cooper 4b330699f8 Convert traditional ${MK_TESTS} conditional idiom for including test
directories to SUBDIR.${MK_TESTS} idiom

This is being done to pave the way for future work (and homogenity) in
^/projects/make-check-sandbox .

No functional change intended.

MFC after:	1 weeks
2017-08-02 08:35:51 +00:00
Warner Losh c6063d0da8 Use src.opts.mk in preference to bsd.own.mk except where we need stuff
from the latter.
2014-05-06 04:22:01 +00:00
Julio Merino d14afb2adc Migrate tools/regression/{usr.bin/lastcomm,usr.sbin}/ to the new tests layout.
This change was originally going to only migrate the usr.sbin tests but, as
it turns out, the usr.sbin/sa/ tests require files from usr.bin/lastcomm/
so it's better to just also migrate the latter at the same time.  The other
usr.bin tests will be moved separately.

To make these tests work within the test suite, some of them have required
changes to prevent modifying the source directory and instead just rely on
the current directory for file manipulation.
2014-03-16 04:09:22 +00:00
Ed Schouten 71ccf09269 The last big commit: let usr.sbin/ use WARNS=6 by default. 2010-01-02 11:07:44 +00:00
Tom Rhodes 491abe5ac7 Move newsyslog.conf.5 to usr.sbin/newsyslog. There is no real history
other than 'initial revision' thus I did not request a repocopy.

Requested by:   ru, gad
2004-03-12 16:03:26 +00:00
Garance A Drosehn 2f8d7c56da Move the parse8601 and parseDWM routines into a new ptime.c file. The
only code-change is to add a "next_time" parameter to both routines (and
that is not used yet).  A later update will make "next_time" more useful.

MFC after:	20 days
2003-09-12 01:33:37 +00:00
Maxim Sobolev 4ea03b3140 Backout unapproved WARNS level change occasionally slipped into previous
commit.

Big pointy hat to:	sobomax
2002-12-11 01:21:57 +00:00
Maxim Sobolev f2562be03e - Allow comments to be placed at the end of configuration line.
Sponsored by:   Porta Software Ltd
Approved by:    re
MFC after:      2 weeks
2002-12-11 01:19:56 +00:00
Ruslan Ermilov eb6626f52a WARNS= -> WARNS?= 2001-09-21 07:25:53 +00:00
David E. O'Brien 9674b13dcb WARNS-2'ify.
(this included removing the funny "if (unsigned_var < 0)" test)
2001-07-30 15:41:20 +00:00
David E. O'Brien 90e655ea4e Perform a major cleanup of the usr.sbin Makefiles.
These are not perfectly in agreement with each other style-wise, but they
are orders of orders of magnitude more consistent style-wise than before.
2001-07-20 06:20:32 +00:00
Ruslan Ermilov 345e52e742 - Backout botched attempt to introduce MANSECT feature.
- MAN[1-9] -> MAN.
2001-03-26 14:42:20 +00:00
Ruslan Ermilov c73e22c3d4 Set the default manual section for usr.sbin/ to 8. 2001-03-20 18:17:26 +00:00
Peter Wemm 97d92980a9 $Id$ -> $FreeBSD$ 1999-08-28 01:35:59 +00:00
Garrett Wollman 8fba304b43 A slight bit of code and doco cleanup, but mostly:
Add the much-needed and long-desired ability to force the log rotation
to take place on a specific day or time, and document same.  This works
by extending the syntax of the `when' field to allow a restricted
ISO 8601 time specification, and performing the log rotation if newsyslog
is run during the same hour as is specified.
1999-01-22 19:38:39 +00:00
David E. O'Brien 2887f586f0 Remove useless `BINOWN=root' now that it is the default. 1998-09-19 22:42:14 +00:00
Peter Wemm 476602a9d0 Revert $FreeBSD$ to $Id$ 1997-02-22 16:15:28 +00:00
Jordan K. Hubbard 1130b656e5 Make the long-awaited change from $Id$ to $FreeBSD$
This will make a number of things easier in the future, as well as (finally!)
avoiding the Id-smashing problem which has plagued developers for so long.

Boy, I'm glad we're not using sup anymore.  This update would have been
insane otherwise.
1997-01-14 07:20:47 +00:00
Thomas Graichen 9bf204a77e Submitted by: charnier@lirmm.fr (Philippe Charnier)
1) correct MAX_PID according to system definition.
2) replace fprintf(stderr,...)/perror/exit by 4.4 equivalence.
3) make strings enough larger so they can't overflow: MAXHOSTNAMELEN for
   host and MAXPATHLEN for filenames.
4) call execl with correct parameters (compress -> gzip).
1996-01-16 10:32:04 +00:00
Thomas Graichen abf212be33 Obtained from: NetBSD
imported the newsyslog command from NetBSD - it make the "rotation" of
the logfiles much simpler (it is currently done by "hand" in the
/etc/[daily,weekly,monthly] scripts) - now it will be done by invoking
newsyslog every hour which is very customizable via a
/etc/newsyslog.conf file
1996-01-05 09:28:11 +00:00