Commit Graph

1356 Commits

Author SHA1 Message Date
Ed Maste
fc2e2c950d src.conf: add WITH_TOOLCHAIN description
It is not used by the in-tree default configuration, but adding it
allows downstream projects with different defaults to make use of
Cirrus-CI (as the makeman test added in 85e8c2a034 requires that
there are no missing option descriptions).

Reviewed by:	imp
Sponsored by:	The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D39936
2023-05-03 11:41:58 -04:00
Ed Maste
0b4568e36f src.opts.mk: Decouple MK_INCLUDES from MK_TOOLCHAIN
Prior to 590461a4b8 installation of include files was controlled
directly by ${MK_TOOLCHAIN}.  590461a4b8 added an INCLUDES knob
defaulting to YES.  Setting WITHOUT_TOOLCHAIN forced it off to retain
existing behaviour.

Decouple them now, as there are reasonable use cases for installing
libraries and include files without a compiler or other tool chain
components.

Reviewed by:	imp, jrtc27
Sponsored by:	The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D39918
2023-05-01 20:33:08 -04:00
Alex Richardson
b347c22846 cross-build: Add common compatibility headers after OS-specific ones
The current order is rather counter-intuitive and it appears to work fine
if we swap the order.

Pull Request:	https://github.com/freebsd/freebsd-src/pull/725
Reviewed by:	imp
2023-04-28 16:10:25 -07:00
John Baldwin
77d2a2d065 depend-cleanup.sh: Handle kqueue1() becoming a wrapper around kqueuex().
For a brief period kqueue1() was a system call and stale dependencies
cause it to not be re-built.
2023-04-24 14:05:18 -07:00
Simon J. Gerraty
644d346d99 We do not need readpassphrase from openssh
When building tar for linux, just disable HAVE_READPASSPHRASE
in config_freebsd.h and libarchive will provide for readpassphrase
Otherwise the two conflict.
2023-04-24 13:50:18 -07:00
Simon J. Gerraty
976ba7f02a Enable building tar for non-FreeBSD host
For DIRDEPS_BUILD we need Makefile.depend.options to
force libegacy to be built on older FreeBSD and non-FreeBSD hosts.

Add readpassphrase to libegacy to avoid the need for libbsd on Linux

src.opts.mk disable TESTS for host if MK_host_egacy is yes

Reviewed by:	imp
Sponsored by:	Juniper Networks, Inc.
Differential Revision:	https://reviews.freebsd.org/D39766
2023-04-24 10:20:17 -07:00
Simon J. Gerraty
baf2dc6476 Set UPDATE_DEPDFILE=NO for showconfig
Exporting UPDATE_DEPDFILE=NO from makeman didn't work,
back to setting it in local.meta.sys.env.mk
2023-04-23 13:43:45 -07:00
Colin Percival
df53ae0fdd Remove portsnap(8)
Rather than having a tool in the FreeBSD base system for obtaining
the FreeBSD ports tree, users are encouraged to `pkg install git`
and then `git clone https://git.FreeBSD.org/ports.git /usr/ports`.

The portsnap servers will continue operating until FreeBSD 13 reaches
its End-of-Life, and portsnap is available from the ports tree as
ports-mgmt/portsnap.

Requested by:	portmgr
Relnotes:	yes
Differential Revision:	https://reviews.freebsd.org/D39563
X-MFC:		no
2023-04-22 18:12:37 -07:00
Simon J. Gerraty
16161b4839 makeman export UPDATE_DEPENFILE=no
Just to be clear we do not need any updates.
2023-04-22 14:57:24 -07:00
Simon J. Gerraty
db98bc2c0d Allow tools/build to work for DIRDEPS_BUILD
We want to be able to build some host tools for non-FreeBSD hosts
without building more than we need.  The DIRDEPS_BUILD lets us
do that.

We use the pseudo MACHINE "host" when building
for the host - deal with that when setting _host_arch.

Reviewed by:	jrtc27
Sponsored by:	Juniper Networks, Inc.
Differential Revision:	https://reviews.freebsd.org/D39751
2023-04-22 12:25:54 -07:00
Brooks Davis
0ef8e98fda Add WITH_NETLINK_SUPPORT description
Reviewed by:	melifaro
Differential Revision:	https://reviews.freebsd.org/D39676
2023-04-20 22:34:21 +01:00
Ed Maste
a9d0665bbb src.conf.5: Expand WITH_LLVM_BINUTILS description
List the specific tools that are controlled by WITH_LLVM_BINUTILS, and
mention the tools that are always or never taken from LLVM.  Tools come
from one of three sources (LLVM, ELF Tool Chain, bespoke base system)
and it is useful to be explicit.

Reviewed by:	markj
Sponsored by:	The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D39428
2023-04-05 13:05:15 -04:00
John Baldwin
a827077e01 Add libcap_netdb.so.1 to the list of libcasper helper libraries.
Reported by:	Yuri <yuri@aetern.org>
Fixes:		7d8e1e8dd9 libcasper: Move helper libraries from /lib/casper to /lib.
2023-03-30 14:54:48 -07:00
Mark Johnston
0ec03c0b10 cross-build: Add secure_getenv() for MacOS cross builds
Reviewed by:	arichardson
Fixes:		68ca8363c7 ("libc: Use secure_getenv(3) where appropriate")
Differential Revision:	https://reviews.freebsd.org/D39295
2023-03-30 00:54:13 -04:00
John Baldwin
7d8e1e8dd9 libcasper: Move helper libraries from /lib/casper to /lib.
These libraries are linked to directly by applications rather than
opened at runtime via dlopen().

Discussed with:	oshogbo
Reviewed by:	markj, emaste
Differential Revision:	https://reviews.freebsd.org/D39245
2023-03-29 15:04:28 -07:00
John Baldwin
c476ca181a OptionalObsoleteFiles.inc: Remove MIPS-specific hwpmc manpages.
These are unconditionally removed in ObsoleteFiles.inc.
2023-03-29 10:40:59 -07:00
John Baldwin
ac6b2b4344 build: glibc on Linux defines explicit_bzero in <string.h>.
Don't install strings.h on such systems.  The local prototype doesn't
match the native Linux one when built as C++ breaking the build of
config(8) as a bootstrap tool on some Linux systems.  If the missing
prototype becomes a problem in the future,
tools/build/cross-build/include/linux/strings.h can be patched to add
it.

Reviewed by:	imp, emaste
Obtained from:	CheriBSD
Sponsored by:	DARPA
Differential Revision:	https://reviews.freebsd.org/D39289
2023-03-27 14:27:16 -07:00
Alexander V. Chernikov
64dfea8651 netlink: add NETLINK/NETLINK_SUPPORT userland options.
Make userland tools such as netstat, route, arp and ndp use
 either netlink or rtsock interfaces based on the NETLINK_SUPPORT
 options.
Both NETLINK and NETLINK_SUPPORT options are turned on by default.

Reviewed By: eugen
Differential Revision: https://reviews.freebsd.org/D39148
2023-03-26 08:59:58 +00:00
Warner Losh
3a3c924273 checkstyle9.pl: Perl script to check if a change is approximately style(9)
This code is adapted from the QEMU checkpatch.pl script. It can check
either a patch, a file or a git branch. It tries to warn about things
that I believe might be style(9) violations. It's experimental, since I
heavily hacked on the qemu version to get it to not complain (much)
about iconic code in the tree. At the moment, it's use should be
considered expermental. It will likely miss violations, and complain
about code that's perfectly fine.  It's offered as an experiment
and to make it easier for contributors to submit patches.
2023-03-25 11:06:13 -06:00
John Baldwin
1ad3cafcd3 Remove /usr/lib/dtrace/ipfw.d for WITHOUT_DTRACE.
Reviewed by:	brooks
Sponsored by:	DARPA
Differential Revision:	https://reviews.freebsd.org/D39099
2023-03-21 19:06:40 -07:00
Jessica Clarke
9e914c7af1 Add new DISK_IMAGE_TOOLS_BOOTSTRAP option
This will build etdump, makefs and mkimg as bootstrap tools to allow
easily creating disk images. Note that etdump is bootstrapped due to its
use in the release scripts for building ISO images.

Reviewed by:	emaste, arichardson
Differential Revision:	https://reviews.freebsd.org/D39072
2023-03-15 00:06:53 +00:00
Brooks Davis
3ac71149ba Add WITH_LOADER_VERIEXEC_VECTX description
PR:		270017
Reviewed by:	emaste
Sponsored by:	DARPA
Differential Revision:	https://reviews.freebsd.org/D39002
2023-03-09 21:39:41 +00:00
Brooks Davis
aad600e52e Remove WITH(OUT)_ATM option
With the removal of NgATM it no longer controls anything.

Reviewed by:	manu, emaste
Sponsored by:	DARPA
Differential Revision:	https://reviews.freebsd.org/D38882
2023-03-09 18:09:18 +00:00
Brooks Davis
af0cc0b223 NgATM: Remove netgraph ATM support
Most ATM support was removed prior to FreeBSD 12.  The netgraph support
was kept as it was less intrusive, but it is presumed to be unused.

Reviewed by:	manu
Relnotes:	yes
Sponsored by:	DARPA
Differential Revision:	https://reviews.freebsd.org/D38879
2023-03-09 18:04:02 +00:00
Ed Maste
bd258f88e5 src.conf.5: Use common phrasing in WITHOUT_OFED text
Reported by:	jhb
Sponsored by:	The FreeBSD Foundation
2023-03-08 21:18:37 -05:00
Ed Maste
c581962414 src.conf.5: Add some WITH_/WITHOUT_ option descriptions
Reviewed by:	markj, brooks
Sponsored by:	The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D38961
2023-03-08 18:30:45 -05:00
Brooks Davis
cc36164a77 makeman: replace -\|/ twiddles with dots
It shows progress more clearly, there aren't so many that the output
is excessive, and it's more friendly for things like Cirrus-CI's
logging that print the backspaces as boxes.

Reviewed by:	emaste
Sponsored by:	DARPA
Differential Revision:	https://reviews.freebsd.org/D38990
2023-03-08 21:01:17 +00:00
Brooks Davis
fca7df1b28 makeman: don't insert a $FreeBSD$
There's no need to insert this line which won't be expanded in git.  Not
generating it won't impact MFCs to 12 since the removal won't be MFCd.

Reviewed by:	emaste
Sponsored by:	DARPA
Differential Revision:	https://reviews.freebsd.org/D38989
2023-03-08 21:01:17 +00:00
Brooks Davis
42afe48b1a makeman: fix a whitespace bug
Reviewed by:	emaste
Sponsored by:	DARPA
Differential Revision:	https://reviews.freebsd.org/D38988
2023-03-08 21:01:17 +00:00
Jose Luis Duran
320e7e0003 Revert "Fix cross-build support for Ubuntu 16.04"
This reverts commit d6327ae8c1.

Before version 2.25, glibc's unistd.h would define the POSIX subset of
getopt.h by defining __need_getopt, including getopt.h (which would
disable the header guard) and then undefining it so later including
getopt.h explicitly would define the extensions. However, we wrap
getopt, and so the wrapper's #pragma once breaks that. Thus getopt.h was
included before the real unistd.h to ensure we get all the extensions.

However, with clang 12 that causes problems where we get a function
mismatch (since getopt can throw exceptions). If we include it after
unistd.h, it will get the full definitions since glibc no longer does
the subsetting thing. This will result in matching definitions and fix
clang 12.

Reviewed by: imp, jrtc27 (OK'd on irc)
Pull Request: https://github.com/freebsd/freebsd-src/pull/668
2023-03-07 16:11:11 -07:00
Herbert J. Skuhra
08e66b7a37 ATM: Remove /usr/include/netnatm when disbled 2023-03-06 21:47:36 +00:00
Emmanuel Vadot
66a175980e Add description for WITH_ATM
Sponsored by:	Beckhoff Automation GmbH & Co. KG
Differential Revision:	https://reviews.freebsd.org/D38845
2023-03-03 08:52:39 +01:00
Ed Maste
c5e54e56e6 tools/build: Hide spurious errors if sys/stat.h does not exist
Reviewed by:	brooks
Sponsored by:	The FreeBSD Foundation
Differential Revision:	https://reviews.freebsd.org/D38757
2023-03-01 19:59:26 -05:00
John Baldwin
3dfd18a769 Remove support for the base/* toolchain ports.
These ports have been removed so these knobs are no longer meaningful.

This reverts commit 608289394f.
This reverts commit 39eb07f172.

Reviewed by:	imp, bapt, emaste
Differential Revision:	https://reviews.freebsd.org/D38562
2023-02-13 13:16:24 -08:00
Kyle Evans
ee3872a714 tools: cleanup stale dependencies from further config(8) C++ification
Sponsored by:	Klara, Inc.
Sponsored by:	NetApp, Inc.
Differential Revision:	https://reviews.freebsd.org/D38276
2023-02-08 23:19:09 -06:00
Dag-Erling Smørgrav
0dfaefa975 depend-cleanup.sh: Simplify the logic, and clean bootstrap tools.
* There's no need to check if the file exists before grepping it; if it does not exist, grep will fail, which is what we want.  Just redirect the error message to /dev/null.
* There's no need to split the .o and .pico cases; the bodies are identical, so combine the conditions.  Use a glob to avoid a false negative if one exists but not the other.
* Also run depend-cleanup.sh on the bootstrap build tree.  This unbreaks the build after 29c5f8bf9a.

Sponsored by:	Klara, Inc.
Sponsored by:	NetApp, Inc.
Reviewed by:	imp, emaste
Differential Revision:	https://reviews.freebsd.org/D38447
2023-02-08 23:59:13 +01:00
Dimitry Andric
50d7464c3f Merge llvm-project release/15.x llvmorg-15.0.7-0-g8dfdcc7b7bf6
This updates llvm, clang, compiler-rt, libc++, libunwind, lld, lldb and
openmp to llvmorg-15.0.7-0-g8dfdcc7b7bf6.

PR:		265425
MFC after:	2 weeks
2023-02-08 20:05:25 +01:00
Dimitry Andric
f3fd488f1e Merge llvm-project release/15.x llvmorg-15.0.6-0-g088f33605d8a
This updates llvm, clang, compiler-rt, libc++, libunwind, lld, lldb and
openmp to llvmorg-15.0.6-0-g088f33605d8a.

PR:		265425
MFC after:	2 weeks
2023-02-08 20:05:19 +01:00
Dimitry Andric
6246ae0b85 Merge llvm-project release/15.x llvmorg-15.0.2-10-gf3c5289e7846
This updates llvm, clang, compiler-rt, libc++, libunwind, lld, lldb and
openmp to llvmorg-15.0.2-10-gf3c5289e7846.

PR:		265425
MFC after:	2 weeks
2023-02-08 20:05:09 +01:00
Dimitry Andric
753f127f3a Merge llvm-project main llvmorg-15-init-16436-g18a6ab5b8d1f
This updates llvm, clang, compiler-rt, libc++, libunwind, lld, lldb and
openmp to llvmorg-15-init-16436-g18a6ab5b8d1f.

PR:		265425
MFC after:	2 weeks
2023-02-08 20:03:59 +01:00
Dimitry Andric
81ad626541 Merge llvm-project main llvmorg-15-init-15358-g53dc0f10787
This updates llvm, clang, compiler-rt, libc++, libunwind, lld, lldb and
openmp to llvmorg-15-init-15358-g53dc0f10787.

PR:		265425
MFC after:	2 weeks
2023-02-08 20:02:26 +01:00
Kyle Evans
4e86369417 tools: cleanup stale dependencies from recent config(8) change
mkmakefile.c moved to mkmakefile.cc, let's preemptively handle it.

Sponsored by:	Klara, Inc.
Sponsored by:	NetApp, Inc.
Differential Revision:	https://reviews.freebsd.org/D38275
2023-02-08 00:09:57 -06:00
Jessica Clarke
b78ae0367f Revert "tools/build: Unbreak bmake bootstrap on Linux"
Now that make.py no longer has the described hack on Linux we can drop
this ugly workaround.

This reverts commit fba998a3d8.
2023-01-29 23:53:04 +00:00
Jessica Clarke
35921bba73 tools/build/make.py: Drop problematic Linux hack for bmake bootstrap
Since e2eeea75eb ("Merge bmake-20201117") missing/sys/cdefs.h has
been present in bmake, and _GNU_SOURCE seems to have been defined by
config.h for much longer than that, possibly for the entire time OS
cross-build support has been in-tree, so these are obsolete. Moreover,
since 79e02149fc ("Fix dtrace tools bootstrap on non-FreeBSD after
OpenZFS import"), HAVE_STRLCAT and HAVE_STRLCPY have been defined by our
cross-build headers in order to placate DTrace tools (which is not the
right way to solve that problem, but motivates fixing this one). Commit
4fde40d9b5 ("Merge/update to bmake-20230126") changed the strlcpy.c in
bmake from including config.h directly to including make.h, which means
it includes string.h and thus sees these bogus definitions, causing it
to not define the strlcpy compat function on Linux even though it needs
to and thus failing to link. Thus, fix this whole mess by removing the
hack we no longer need.
2023-01-29 23:53:04 +00:00
Ed Maste
ac4c695ad6 Retire WITHOUT_CXX option
Several important base system components are written in C++, and the
WITHOUT_CXX option produced a system that was not fully functional.
Just accept this, and remove the option to build without C++ support.

This reverts commit adc3c128c6.

Reviewed by:	brooks, kevans, jhb (earlier)
Sponsored by:	The FreeBSD Foundation
Differential Revision:	https://reviews.freebsd.org/D33108
2023-01-26 21:13:16 -05:00
Dag-Erling Smørgrav
4a158fc030 depend-cleanup.sh: handle zic moving one level up.
MFC after:	1 week
Sponsored by:	Klara, Inc.
Differential Revision: https://reviews.freebsd.org/D38044
2023-01-14 18:17:22 +01:00
Brooks Davis
3b073d2ee5 tools/build: Always bootstrap (sys/)bitstring.h
Older, supported FreeBSD versions lack bit_ntest() so hoist the boostrap
installation out of the OS!=FreeBSD case and always install it.  A more
precise criteria is possible, but would add little value.

This fixes bootstrapping makefs as a build tool on 13.1.

Reviewed by:	jrtc27, emaste
Sponsored by:	DARPA, AFRL
Differential Revision:	https://reviews.freebsd.org/D37951
2023-01-09 19:17:48 +00:00
Joseph Mingrone
a0c50eda29
beinstall.sh: Check correct exit status
When retrieving the timestamp of the last commit using git-show(1), do
not pipe the output to head(1), otherwise the return value in $? will be
for head(1) and not git-show(1).

Approved by:	bapt
Sponsored by:	The FreeBSD Foundation
Differential Revision:	https://reviews.freebsd.org/D37742
2023-01-03 10:27:53 -04:00
Ed Maste
86edb11e74 Always install llvm-objdump as objdump
Instead of providing no /usr/bin/objdump when LLVM_BINUTILS is false.

PR:		267854 [exp-run]
Reviewed by:	dim
MFC after:	2 weeks
Sponsored by:	The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D37445
2022-12-12 10:36:02 -05:00
Philip Paeps
821549a9df OptionalObsoleteFiles.inc: add zoneinfo/America/Ciudad_Juarez
tzdata 2022g and later split America/Ciudad_Juarez from America/Ojinaga.
Ensure this file is removed in builds WITHOUT_ZONEINFO.

MFC after:	1 day
2022-11-30 09:50:26 +08:00