Commit Graph

4285 Commits

Author SHA1 Message Date
Enji Cooper
076777cc29 MFhead@r325199 2017-10-31 02:46:36 +00:00
Bryan Drewery
177d707c0c makeman: Ensure MK_AUTO_OBJ is disabled in some lookups.
Sponsored by:	Dell EMC Isilon
2017-10-31 02:18:06 +00:00
Bryan Drewery
ea825d0274 DIRDEPS_BUILD: Update dependencies.
Sponsored by:	Dell EMC Isilon
2017-10-31 00:07:04 +00:00
Bryan Drewery
9a0c5c4c85 Fix native-xtools installion after r325082 and r325000 to be to /nxb-bin.
- r325082 split native-xtools-install out of native-xtools.
- r325000 incorrectly changed the installation path from /nxb-bin to /.

Discussed with:	imp at D12782
2017-10-30 18:54:27 +00:00
Enji Cooper
3c5ab8c1cc MFhead@r325119 2017-10-30 05:52:26 +00:00
Warner Losh
36f1c58dc5 Fix parallel build issues and add MK_ZFS=no case
To ensure that I don't break the MK_ZFS=no case (currently working),
add that to the build, at least for i386 and amd64. Also, out of an
abundance of caution, clean single threaded, and then build in a
separate make. Otherwise, I hit a race where we build before objdir
has been created, which breaks at the moment.

Sponsored by: Netflix
2017-10-30 03:12:34 +00:00
Eitan Adler
a2aef24aa3 Update several more URLs
- Primarily http -> https
- Primarily FreeBSD project URLs
2017-10-29 08:17:03 +00:00
Enji Cooper
5ff880dc0f MFhead@r325004 2017-10-26 03:34:17 +00:00
Bryan Drewery
e0dd694935 native-xtools: Override proper NXBDESTDIR.
The new native-xtools uses 'make toolchain' so overriding DESTDIR
as a make argument may interfere with WORLDTMP handling.
The target also does a 'mkdir -p ${NXBDESTDIR}/usr', so we should
be modifying that rather than DESTDIR.

Note this causes the native-xtools binaries to be installed in
NANO_WORLDDIR/usr NANO_WORLDDIR/bin rather than NANO_WORLDDIR/nxb-bin/usr
and NANO_WORLDDIR/nxb-bin/bin.  This was the case before this change
as well.

MFC after:	2 weeks
Reviewed by:	imp
Differential Revision:	https://reviews.freebsd.org/D12782
2017-10-25 21:46:33 +00:00
Warner Losh
9bd6ac8da0 Do a chdir to SRCTOP/sys/boot before starting the run. This lets one
run this script from anywhere, but makes it only work on sys/boot.

Sponsored by: Netflix
2017-10-25 15:27:48 +00:00
Enji Cooper
dd467c8ac1 MFhead@r324884 2017-10-22 23:40:49 +00:00
Warner Losh
c02a64d8be Create a shell script to build sys/boot on all the architectures.
One could run this from any directory, but it's designed to do
regression testing on sys/boot (it only tests on a subset of
architectures since all of them would take a lot longer and not help).
This will also ensure that future commits to sys/boot compile
everywhere.

Sponsored by: Netflix
2017-10-22 22:52:23 +00:00
Enji Cooper
d769de5a12 Add more draft text to WITH_COVERAGE 2017-10-22 07:20:11 +00:00
Enji Cooper
0a8f81bc28 MFhead@r324837
While here, diff reduce some of the changes in sys/boot by moving
MK_COVERAGE=no to sys/boot/Makefile.inc .
2017-10-21 23:40:52 +00:00
Brad Davis
1ff30c6af0 Teach beinstall to use and prefer svnlite, with a fallback to svn.
Approved by:	will
2017-10-18 15:48:26 +00:00
Baptiste Daroussin
578ec783ff Do not try to remove diff.7 optionaly has it is always removed
since GNU diff(1) has been replaced with BSD diff(1)
2017-10-11 14:41:11 +00:00
Ed Maste
00d78afd17 OptionalObsoleteFiles: remove diff from MK_GNU_DIFF=no block
diff (and man page) are not from GNU, as of r317209, and should not be
deleted if WITHOUT_GNU_DIFF is set. (WITHOUT_GNU_DIFF still controls
whether diff3 is built.)

Sponsored by:	The FreeBSD Foundation
2017-10-11 14:34:06 +00:00
Enji Cooper
50896984cd MFhead@r324482 2017-10-10 06:26:12 +00:00
Jeremie Le Hen
e415aa2846 Remove rcmds.
If they are still needed, you can find them in the net/bsdrcmds port.

This was proposed June, 20th and approved by various committers [1].
They have been marked as deprecated on CURRENT in r320644 [2] on July, 4th.
Both stable/11 and release/11.1 contain the deprecation notice (thanks to
allanjude@).

Note that ruptime(1)/rwho(1)/rwhod(8) were initially thought to be part of
rcmds but this was a mistake and those are therefore NOT removed.

[1] https://lists.freebsd.org/pipermail/freebsd-arch/2017-June/018239.html
[2] https://svnweb.freebsd.org/base?view=revision&revision=320644

Reviewed by:	bapt, brooks
Differential Revision:	https://reviews.freebsd.org/D12573
2017-10-06 08:43:14 +00:00
Enji Cooper
d2549a448d MFhead@r324075 2017-09-28 05:20:37 +00:00
Gleb Smirnoff
119bdf3b3a Fix regression from r323855. The EXIT trap now isn't cleared, so upon
exit it tried to unmount already unmounted partition, resulting in failure.
2017-09-26 21:54:19 +00:00
Enji Cooper
1207267e5c MFhead@r323974 2017-09-24 19:48:46 +00:00
Warner Losh
7d608e53e6 Fix packages with interactive post install scripts.
Tell pkg(8) we're running non-interactively so packages that with
interactive post install scripts don't hang.

Submitted by: Guido van Rooij
2017-09-24 14:22:36 +00:00
Enji Cooper
e5d34ca9fd MFhead@r320180 2017-09-23 18:37:37 +00:00
Warner Losh
07f2d905e6 Always create usr/local/etc -> /etc/local symlink
/usr/local/etc gets created and populated by packages. However, if no
packages are installed when setup_nanobsd is run, this symlink won't
get created, causing problems if packages are installed later (say on
first boot). Therefore, always create the symlink and etc/local. It
does no harm and may help.

Inspired by crochet issue #183 (consuingly says NanoBSD, means crochet)
Sponsored by: Netflix
2017-09-21 23:10:56 +00:00
Nick Hibma
657db16fce Remove an 'unused' function.
This function was only set in legacy.sh and only at the very end after
the disk image had been successfully created. The only difference will be
that the message 'Error encountered. Please check...' will not appear if
nanobsd.sh exits with an error after the disk image has been created.
2017-09-21 10:13:48 +00:00
Nick Hibma
7c1e70c8f9 Fix up style for consistency. 2017-09-21 09:27:44 +00:00
Nick Hibma
b391b675f7 Speling mistakes. 2017-09-21 09:22:41 +00:00
Enji Cooper
8fcbcc2d74 MFhead@r323635 2017-09-16 03:54:20 +00:00
Ed Maste
4154e70ea8 Update OptionalObsoleteFiles.inc with NTP docs
The list of files for MK_NTP was incomplete.

PR:		218193
Submitted by:	brnrd
MFC after:	1 week
2017-09-15 00:54:37 +00:00
Gordon Tetlow
4572fb3faf Deorbit catman. The tradeoff of disk for performance has long since tipped
in favor of just rendering the manpage instead of relying on pre-formatted
catpages. Note, this does not impede the ability to use existing catpages,
it just removes the utility to generate them.

Reviewed by:	imp, allanjude
Approved by:	emaste (mentor)
Differential Revision:	https://reviews.freebsd.org/D12317
2017-09-13 16:35:16 +00:00
Enji Cooper
5be4ad9e80 MFhead@r323343 2017-09-09 05:42:23 +00:00
Nick Hibma
1f7000f77a Bugfix: Don't treat NANO_IMAGES as a direcotory.
This was probably accidentally broken in r295377 .

Submitted by:	Igor Serikov
MFC after:	2 weeks
2017-09-05 21:17:20 +00:00
Enji Cooper
1be4c195db MFhead@r322870 2017-08-25 02:48:31 +00:00
Gleb Smirnoff
a4658c801e Add a test case for a connection on accept queue that is reset before
it is accepted.  In that case accept(2) shall return ECONNABORTED.
Accept filters provide help with easily replicating that case.
2017-08-24 20:52:02 +00:00
Enji Cooper
a451e71162 MFhead@r322675 2017-08-18 21:37:26 +00:00
Ed Maste
63cd05d97a remove debug files in delete-old* when WITHOUT_DEBUG_FILES
Reported by:	brd
Reviewed by:	bdrewery, brd
MFC after:	2 weeks
Sponsored by:	The FreeBSD Foundation
Differential Revision:	https://reviews.freebsd.org/D12044
2017-08-16 17:22:42 +00:00
Enji Cooper
82baa8db5e MFhead@r322515 2017-08-14 19:28:49 +00:00
Enji Cooper
38f8fddf05 Add limited sandbox capability to "make check"
== Rationale ==

r295380 introduced "make check" and consolidated means for running
test code in an attempt to simplify running tests. One could either
install files/libraries/programs and run "make check", or run "make check"
with an explicit CHECKDIR, e.g., `make check CHECKDIR=$(make -V.OBJDIR)``.

One criticism that was received is that "make check" should be run with
the intent of making dev->test->commit easier, which means that the target
audience's workflow should be developers. One developer pattern available
in other opensource projects is to run test code from a developer sandbox,
instead of installing to a system.

== Method ==

This approach is slightly different from the standard approach, in the sense
that it builds and installs into a deterministic directory under .OBJDIR (as I call it,
the "sandbox"), then runs "make check" against that. In the event the test
run is successful, the deterministic directory is removed to save space.

== Approach ==

bsd.lib.mk, bsd.prog.mk:

To support this functionality, a new variable `HAS_TESTS` is being added.

HAS_TESTS enables appropriate behavior with bsd.lib.mk and bsd.prog.mk, as
follows:
- Add "make check" as an available target from the directory.
- Pass down appropriate variables via ${TESTS_ENV}, i.e.,
  ${TESTS_LD_LIBRARY_PATH} and ${TESTS_PATH}.

One should add "HAS_TESTS" to directories containing tests in them, e.g. from
bin/sh/Makefile,

  HAS_TESTS=
  SUBDIR.${MK_TESTS}+= tests

HAS_TESTS doesn't automatically add the tests subdirectory for flexibility
reasons.

bsd.opts.mk, src.opts.mk:
- The knob ${MK_MAKE_CHECK_USE_SANDBOX} has been added, both to explicitly
  direct (internally) when to set a deterministic ${DESTDIR} and to also allow
  users to disable this behavior globally, i.e., via src.conf.
- MK_TESTS has been promoted from src.opts.mk to bsd.opts.mk to leverage
  syntactic sugar for having MK_TESTS be a dependency for
  MK_MAKE_CHECK_USE_SANDBOX, but to also ensure that src.opts.mk isn't required
  to use suite.test.mk (which is a dependency of bsd.test.mk).

suite.test.mk:
- beforecheck behavior (when MK_MAKE_CHECK_USE_SANDBOX is enabled) is modified
  from a no-op to:
-- Build.
-- Run "make hierarchy" on the sandbox dir.
-- Install the tests/files to the sandbox dir.
- aftercheck behavior (when MK_MAKE_CHECK_USE_SANDBOX is enabled) is modified
  from a no-op to:
-- Remove the sandbox dir.

Again, because the dependency order set in bsd.test.mk is
beforecheck -> check -> aftercheck, "make check" will not be run unless
"beforecheck" completes successfully, and "aftercheck" will not be run unless
"beforecheck" and "check" complete successfully.

== Caveats ==

- This target must either be run with MK_INSTALL_AS_USER or as root. Otherwise
  it will fail when running "make install" as the default user/group for many
  makefiles when calling INSTALL is root/wheel.
- This target must be run from a suitable top-level directory. For example,
  running tests from `tests/sys/fs/tmpfs` won't work, but `tests/sys/fs` will,
  because `tests/sys/fs/tmpfs` relies on files installed by `tests/sys/fs`.
- Running MK_INSTALL_AS_USER may introduce determinism issues. However, using
  it could identify deficiences in tests in terms of needing to be run as
  root, which are not properly articulated in the test requirements.
- The doesn't negate the need for running "make installworld" and
  "make checkworld", etc. Again, this just is intended to simplify the
  dev->test->commit workflow.

== Cleanup done ==
- CHECKDIR is removed; one can use "MK_MAKE_CHECK_USE_SANDBOX=no" to enable
  "legacy" (r295380) behavior.

MFC after:	2 months
Relnotes:	yes (CHECKDIR removed; "make check" behavior changed)
Requested by:	jhb
Reviewed by:	arch (silence), testing (silence)
Differential Revision:	D11905
2017-08-14 19:03:05 +00:00
Enji Cooper
083c8ded05 MFhead@r322451 2017-08-13 01:23:13 +00:00
Jeremie Le Hen
ac0ced90e0 rwho/ruptime/rwhod shouldn't be gated by RCMDS.
As peter@ points out in pr/220953:
"rwho, rwhod and ruptime are not part of the remote login suite (rsh, rlogin
etc).

They should *not* be in the rcmds package which is disabled by default.  We
rely on rwho/rwhod/ruptime in the freebsd.org cluster."

This commit is a re-commit of r322029 and r322031 with a better commit log, as
pointed out by ngie@.

This also includes the necesary changes to OptionalObsoleteFiles.inc, as
requested by jhb@.

PR:		220953
Reported by:	peter@, jhb@
Differential Revision:	https://reviews.freebsd.org/D11743
2017-08-08 20:17:07 +00:00
Enji Cooper
d59ead01d8 MFhead@r321970 2017-08-03 05:30:11 +00:00
Andriy Gapon
5d1186a4ed zfsboottest: catch up with r316585 and provide ldi_get_size method
This method is required for querying file / disk sizes which is needed
at least for finding all copies of ZFS VDEV labels.

Reported by:	ngie
MFC after:	1 week
2017-08-01 11:09:18 +00:00
Enji Cooper
6755788d98 Fix up r321849
pager_output should return 0 if no more output needs to be paged; non-zero
otherwise.

MFC after:	1 week
MFC with:	r321849
Reported by:	avg
2017-08-01 06:51:03 +00:00
Enji Cooper
d125609b7a Makefile cleanup
- Standardize on SRCTOP instead of .CURDIR-relative paths
- Use LIBADD instead of a mix of specifying -lgeom via DPADD/LDADD/LDFLAGS.
  Specifying -lgeom via LDFLAGS is an especially unnecessary and odd
  pattern.

MFC after:	1 week
2017-08-01 05:34:04 +00:00
Enji Cooper
7e299eacab Fix the return type for pager_output(..) in bootparttest and zfsboottest
pager_output(..) has always returned int. For some reason (probably the
clang 5.0 update), this mismatch now results in an error with CC=clang.

MFC after:	1 week
2017-08-01 05:29:36 +00:00
Enji Cooper
d96899bad0 Chase r315408 with the fourth parameter being removed from disk_open(..)
This fixes one part of the build.
2017-08-01 05:26:45 +00:00
Enji Cooper
405873f16d Standardize on SRCTOP instead of .CURDIR-relative paths
MFC after:	3 days
2017-08-01 05:23:49 +00:00
Adrian Chadd
495842b117 [wlanwds] allow for a DWDS AP VAP to be not be the first VAP on a NIC.
The wlanwds code was just creating a clone VAP without specifying the MAC
address to use for said clone VAP.  This meant that if an interface
was cloned from an AP interface that wasn't the first created VAP
(which shares the same MAC as the parent physical interface by default)
then the cloned interface would have the wrong MAC and traffic wouldn't work.

Besides chip bugs (ha!) this isn't a requirement.

So, teach wlanwds to:

* look up the link layer address for a given interface (which really should
  be a library interface, and will likely quickly become one);
* use this when creating a cloned interface for a DWDS peer;
* (net80211 already has the infrastructure to do this, it just needed to be
  used);
* add some extra logging to see what MAC addresses, parent interfaces, etc
  are being created.

Whilst here, add a reminder that I should extend this to include monitoring
a specific VAP for DWDS updates rather than just the parent interface.

This is the first step in allowing for multiple DWDS hops, which is a
pre-requisite for adrian's house having wifi in the single upstairs room.

Tested:

* AR9380, DWDS AP + AP mode - with DWDS AP being the second VAP created
  with a different MAC address;
* AR9331 (Carambola2), AP + DWDS STA;
* passing traffic

TODO:

* fix 802.11s so this DWDS stuff is no longer required!
2017-07-31 17:33:57 +00:00
Enji Cooper
0e34ba734c MFhead@r321755 2017-07-31 04:20:21 +00:00