Commit Graph

48 Commits

Author SHA1 Message Date
Simon J. Gerraty
ccfb965433 Add META_MODE support.
Off by default, build behaves normally.
WITH_META_MODE we get auto objdir creation, the ability to
start build from anywhere in the tree.

Still need to add real targets under targets/ to build packages.

Differential Revision:       D2796
Reviewed by: brooks imp
2015-06-13 19:20:56 +00:00
Simon J. Gerraty
44d314f704 dirdeps.mk now sets DEP_RELDIR 2015-06-08 23:35:17 +00:00
Simon J. Gerraty
98e0ffaefb Merge sync of head 2015-05-27 01:19:58 +00:00
Ed Maste
ad746bd1b7 Fix libfifolog dependency on libz
Consumers should not need to encode fifolog's dependency on libz.
Handle it automatically in src.libnames.mk.

Differential Revision:	https://reviews.freebsd.org/D2278
Reviewed by:	bapt
Sponsored by:	The FreeBSD Foundation
2015-04-10 21:24:38 +00:00
Baptiste Daroussin
a7f8c4eb4c Readd Makefile.inc that were used to include upper level Makefile.inc and
set (among other things) the destination where the binary should be installed
2014-11-28 22:03:35 +00:00
Baptiste Daroussin
c6db8143ed Convert usr.sbin to LIBADD
Reduce overlinking
2014-11-25 16:57:27 +00:00
Simon J. Gerraty
488c975a1f Updated/new dependencies 2014-11-19 07:10:38 +00:00
Simon J. Gerraty
9268022b74 Merge from head@274682 2014-11-19 01:07:58 +00:00
Baptiste Daroussin
10b5ed75fb fifolog_writer does not depend on libutil 2014-11-06 13:13:47 +00:00
Baptiste Daroussin
295e858606 fifolog_reader does not depend on libutil 2014-11-06 13:12:12 +00:00
Bryan Drewery
5608fd23c2 Revert r267233 for now. PIE support needs to be reworked.
1. 50+% of NO_PIE use is fixed by adding -fPIC to INTERNALLIB and other
   build-only utility libraries.
2. Another 40% is fixed by generating _pic.a variants of various libraries.
3. Some of the NO_PIE use is a bit absurd as it is disabling PIE (and ASLR)
   where it never would work anyhow, such as csu or loader. This suggests
   there may be better ways of adding support to the tree. Many of these
   cases can be fixed such that -fPIE will work but there is really no
   reason to have it in those cases.
4. Some of the uses are working around hacks done to some Makefiles that are
   really building libraries but have been using bsd.prog.mk because the code
   is cleaner. Had they been using bsd.lib.mk then NO_PIE would not have
   been needed.

We likely do want to enable PIE by default (opt-out) for non-tree consumers
(such as ports). For in-tree though we probably want to only enable PIE
(opt-in) for common attack targets such as remote service daemons and setuid
utilities. This is also a great performance compromise since ASLR is expected
to reduce performance. As such it does not make sense to enable it in all
utilities such as ls(1) that have little benefit to having it enabled.

Reported by:	kib
2014-08-19 15:04:32 +00:00
Simon J. Gerraty
ee7b0571c2 Merge head from 7/28 2014-08-19 06:50:54 +00:00
Bryan Drewery
864c53ead8 In preparation for ASLR [1] support add WITH_PIE to support building with -fPIE.
This is currently an opt-in build flag. Once ASLR support is ready and stable
it should changed to opt-out and be enabled by default along with ASLR.

Each application Makefile uses opt-out to ensure that ASLR will be enabled by
default in new directories when the system is compiled with PIE/ASLR. [2]

Mark known build failures as NO_PIE for now.

The only known runtime failure was rtld.

[1] http://www.bsdcan.org/2014/schedule/events/452.en.html
Submitted by:		Shawn Webb <lattera@gmail.com>
Discussed between:	des@ and Shawn Webb [2]
2014-06-08 17:29:31 +00:00
Simon J. Gerraty
fae50821ae Updated dependencies 2014-05-16 14:09:51 +00:00
Simon J. Gerraty
76b28ad6ab Updated dependencies 2014-05-10 05:16:28 +00:00
Simon J. Gerraty
3b8f084595 Merge head 2014-04-28 07:50:45 +00:00
Warner Losh
3bdf775801 NO_MAN= has been deprecated in favor of MAN= for some time, go ahead
and finish the job. ncurses is now the only Makefile in the tree that
uses it since it wasn't a simple mechanical change, and will be
addressed in a future commit.
2014-04-13 05:21:56 +00:00
Simon J. Gerraty
d1d0158641 Merge from head 2013-09-05 20:18:59 +00:00
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
Simon J. Gerraty
7cf3a1c6b2 Updated dependencies 2013-03-11 17:21:52 +00:00
Simon J. Gerraty
f5f7c05209 Updated dependencies 2013-02-16 01:23:54 +00:00
Simon J. Gerraty
23090366f7 Sync from head 2012-11-04 02:52:03 +00:00
Sergey Kandaurov
b94db03dca mdoc: point to an existing cross reference. 2012-10-02 09:53:50 +00:00
Marcel Moolenaar
7750ad47a9 Sync FreeBSD's bmake branch with Juniper's internal bmake branch.
Requested by: Simon Gerraty <sjg@juniper.net>
2012-08-22 19:25:57 +00:00
Baptiste Daroussin
5e2a209a27 Fix world after byacc import:
- old yacc(1) use to magicially append stdlib.h, while new one don't
- new yacc(1) do declare yyparse by itself, fix redundant declaration of
  'yyparse'

Approved by:	des (mentor)
2012-05-22 16:33:10 +00:00
Poul-Henning Kamp
818bc4157a Another couple of unsigned/ssize_t changes. 2011-03-01 08:52:10 +00:00
Poul-Henning Kamp
2f203e818f Type-change to ssize_t to (app|pl)ease ppc platform. 2011-02-28 14:48:00 +00:00
Poul-Henning Kamp
6e482ac5ad Update fifolog internals to match main version:
Rename ...write_bytes... to ...write_records..., that's what they do.

Move writer .h stuff into writer private .h file.

Change logic in writer to support both fifolog usage in FreeBSD and
Measured usage better, by always using an input buffer.

Various cleanups.
2011-02-28 09:11:46 +00:00
Poul-Henning Kamp
54a3365da2 Don't override the perfectly good default ->zalloc and ->zfree functions. 2011-02-28 08:59:35 +00:00
Poul-Henning Kamp
fb4f617201 Fix a bunch of trivial whitespace mistakes and update the miniobj.h
file before the real work starts.
2011-02-25 09:40:17 +00:00
Poul-Henning Kamp
5d964b5cc9 Use a "push" strategy to get data through libz, rather than a "pull" strategy. 2010-12-07 16:30:52 +00:00
Ulrich Spörlein
768e090da1 Typo fixes
PR:		docs/149314
Submitted by:	olgeni
MFC after:	3 days
2010-08-06 12:38:30 +00:00
Giorgos Keramidas
36dc373119 Fix reading of empty fifolog files. When we don't have anything
to inflate, skip the rest of the fifolog reader code to avoid
hitting the assert about Z_OK a bit further down.

Approved by:	phk
MFC after:	1 week
2010-07-10 11:40:31 +00:00
Poul-Henning Kamp
c6bfb71a6f Do not attempt to render a logrecord with length byte, until we have
decompressed all the bytes required.
2010-05-15 08:57:16 +00:00
Ulrich Spörlein
aa12cea2cc mdoc: order prologue macros consistently by Dd/Dt/Os
Although groff_mdoc(7) gives another impression, this is the ordering
most widely used and also required by mdocml/mandoc.

Reviewed by:	ru
Approved by:	philip, ed (mentors)
2010-04-14 19:08:06 +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
Ed Schouten
10bc3a7f42 ANSIfy almost all applications that use WARNS=6.
I was considering committing all these patches one by one, but as
discussed with brooks@, there is no need to do this. If we ever
need/want to merge these changes back, it is still possible to do this
per application.
2009-12-29 22:53:27 +00:00
Jaakko Heinonen
89834b119e Unify fifolog_writer usage printout with fifolog_create and
fifolog_reader.

Approved by:	trasz (mentor)
2009-11-17 17:38:41 +00:00
Ruslan Ermilov
c022d15e0f Fixed NAME section. 2009-04-04 15:48:09 +00:00
Poul-Henning Kamp
9e7948d849 The last sector in the first segment might just be a sync, increment before
checking validity of segment two.
2009-02-02 14:30:07 +00:00
Poul-Henning Kamp
b183b801b5 Don't overwrite it, if only one sector is written yet.
Discovered by:	"Dewayne Geraghty" <dewayne.geraghty@heuristicsystems.com.au>
2009-02-02 14:29:15 +00:00
Poul-Henning Kamp
ba2b54296f Fix a cornercase during search 2008-12-09 09:25:03 +00:00
Poul-Henning Kamp
22d0b5dc8b Populate usage()
Submitted by:   Jaakko Heinonen <jh@saunalahti.fi>
2008-05-14 23:29:02 +00:00
Ruslan Ermilov
a1e0a00fd2 Clean up makefiles and a manpage.
OK'ed by:	phk
2008-04-10 14:02:00 +00:00
Poul-Henning Kamp
8d2888bc54 Accept empty -T arguments.
Proposed by:	clemens fischer <ino-qc@spotteswoode.de.eu.org>
2008-03-31 13:56:15 +00:00
Poul-Henning Kamp
103c0e21dd Fix two bugs introduced in conversion to FreeBSD source tree:
Off by one error in length calcuation of string records.
Don't attempt to free stack variable.
2008-03-19 10:56:51 +00:00
Poul-Henning Kamp
9371f06305 Remove trailing ';' on macros.
Spotted by:	antoine
2008-03-16 23:00:43 +00:00
Poul-Henning Kamp
662cb04c25 Add the fifolog tools to FreeBSD.
Quoth the man-page:

     Fifologs provide a compact round-robin circular storage for recording
     text and binary information to permanent storage in a bounded and pre-
     dictable fashion, time and space wise.

Not yet connected to the build, but feel free to test & review.
2008-03-09 19:14:36 +00:00