Commit graph

1471 commits

Author SHA1 Message Date
Warner Losh 758d02fb30 checkstyle9: Relax sob line requirement 2024-05-04 07:56:36 -06:00
Brooks Davis b25ceb97ed Revert "Make WITHOUT_UNDEFINED_VERSION the default"
This is causing failures on gcc13 CI builds so those need to be fixed
or worked around.

This reverts commit 4510f2ca91.
2024-05-02 22:55:08 +01:00
Brooks Davis 4510f2ca91 Make WITHOUT_UNDEFINED_VERSION the default
Link with --no-undefined-version by default.  Will detect and prevent
the accidental removal of symbols from versioned libraries.

Reviewed by:	arichardson, kib, dim, emaste
Differential Revision:	https://reviews.freebsd.org/D44216
2024-05-02 18:13:39 +01:00
Ed Maste b07689d1f2 beinstall: retire mergemaster support
Mergemaster has been deprecated for some time, and will be retired.

Reviewed by:	kevans
Sponsored by:	The FreeBSD Foundation
Differential Revision:	https://reviews.freebsd.org/D41799
2024-05-01 19:02:00 -04:00
Mateusz Piotrowski 42255af64a checkstyle9: Allow a space between "*" and _*restrict
Before the change, we would get errors like this:

    ERROR: "foo * bar" should be "foo *bar"
    #369: FILE: foobar.c:369:
    +barbaz(char * __restrict s,

Reviewed by:		des, imp
Sponsored by:		Klara, Inc.
Differential Revision:	https://reviews.freebsd.org/D44911
2024-04-25 11:51:25 +02:00
Warner Losh ea6f2d7797 checkstyle9.pl: Warn if there's no SOB line
If there's no Signed-off-by: line, complain.

Sponsored by:		Netflix
2024-04-23 14:04:08 -06:00
John Baldwin ee3187f6fa Remove the MK_NVME build option
The drivers and utilities are now built and installed unconditionally.

Reviewed by:	imp, emaste
Sponsored by:	Chelsio Communications
Differential Revision:	https://reviews.freebsd.org/D44843
2024-04-23 11:47:44 -07:00
Ed Maste 91d35fb663 Remove WITHOUT_CAPSICUM build support
Capsicum is non-optional as of c24c117b96 ("Remove
WITHOUT_{CAPSICUM,CASPER} options").

`#ifndef WITHOUT_CAPSICUM` is left in the source for the benefit of
downstream consumers, but is never defined in FreeBSD.

Reviewed by:	oshogbo
Sponsored by:	The FreeBSD Foundation
Differential Revision:	https://reviews.freebsd.org/D42077
2024-04-23 08:26:28 -04:00
Cy Schubert f7f570eb97 tools: Remove stray "then"
Fixes:		26a09db3ad
2024-04-18 08:10:14 -07:00
Brooks Davis 26a09db3ad Fix incremental build with WITH_NVME newly enabled
rescue.mk doesn't get updated when options change so nvme_util.o is now
missing on architectures were NVME was previously marked BROKEN.

Reviewed by:	imp
Fixes:		2fda3ab0ac WITH_NVME: Remove from broken.
Differential Revision:	https://reviews.freebsd.org/D44826
2024-04-18 14:58:17 +01:00
Mark Johnston 11c79f9e35 arm64: Connect bhyve and libvmmapi to the build
Reviewed by:	corvink, andrew, jhb, emaste
MFC after:	2 weeks
Sponsored by:	Innovate UK
Differential Revision:	https://reviews.freebsd.org/D41742
2024-04-10 11:17:56 -04:00
Dimitry Andric cb14a3fe51 Merge llvm-project main llvmorg-18-init-15692-g007ed0dccd6a
This updates llvm, clang, compiler-rt, libc++, libunwind, lld, lldb and
openmp to llvm-project main llvmorg-18-init-15692-g007ed0dccd6a.

PR:		276104
MFC after:	1 month
2024-04-06 22:13:06 +02:00
Dimitry Andric 5f757f3ff9 Merge llvm-project main llvmorg-18-init-15088-gd14ee76181fb
This updates llvm, clang, compiler-rt, libc++, libunwind, lld, lldb and
openmp to llvm-project main llvmorg-18-init-15088-gd14ee76181fb.

PR:		276104
MFC after:	1 month
2024-04-06 22:11:55 +02:00
Olivier Cochard a927571469 OptionalObsoleteFiles: add missed cuda wrappers include files
Files introduced since clang 17.0.2.

Approved by:	dim
Sponsored by:	Netflix
Differential Revision:	https://reviews.freebsd.org/D44597
2024-04-02 22:59:28 +02:00
Dag-Erling Smørgrav 125c4560bc usr.bin: Make lorder conditional on MK_TOOLCHAIN.
MFC after:	1 week
Reviewed by:	allanjude, markj
Differential Revision:	https://reviews.freebsd.org/D44558
2024-04-01 15:18:35 +02:00
Brooks Davis d9108adbc0 lib{c,sys}: really fix incremental builds
Reported by:	andrew
Fixes:		a650ec0e55 lib{c,sys}: fix incremental builds
2024-03-18 18:52:42 +00:00
Baptiste Daroussin a42d6f7601 nuageinit: add basic support for cloudinit.
this is a very early script to support cloudinit, it does not intend to
be a full featured cloudinit client, but will support a good enough
subset to be viable in most case.

It support nocloud and openstack config-2 config drive mode (iso9660 or
msdosfs)

The following features are currently supported:
- adding users (including a default user named 'freebsd' with password
  'freebsd'
- adding groups
- adding ssh keys
- static ipv4, static ipv6, dynamic ipv4

With this one is able to use the 'bring your own image feature" out of
box.

It is expected that the script grows the support of other clouds
supporting cloud-init, contributions are welcomed.

It is designed to be only run once via the firstboot mecanism.

Sponsored by:	OVHCloud
MFC After:	3 weeks
Differential Revision:	https://reviews.freebsd.org/D44141
2024-03-15 09:22:16 +01:00
Brooks Davis a650ec0e55 lib{c,sys}: fix incremental builds
I removed lib/libsys/{aarch64,arm,riscv}/syscall.S in favor of an
idential generated version.  We need to clean out the .ddepend files to
ensure the generated version is actually generated.

The guard here is technically too strict, but should be fine in practice
and I've verified both the breakage and fix on an armv7 build.

Reported by:	imp
Fixes:		e6ffc7669a Remove pointless MD syscall(2)
Fixes:		0ee0ae2373 Remove pointless MD syscall(2)
Fixes:		7b3836c281 Remove pointless MD syscall(2)
2024-03-08 19:14:24 +00:00
Brooks Davis 2956f5885c Add an UNDEFINED_VERSION option
When enabled (current default) link with --undefined-version to allow
symbol maps to contain symbols not defined by libraries.  When disabled,
link with --no-undefined-version to disallow these bugs.

WITHOUT_UNDEFINED_VERSION is currently broken.  Once it is fixed it
should be made the default and this option should likely be removed.

Reviewed by:	dim, emaste
Differential Revision:	https://reviews.freebsd.org/D44169
2024-03-01 23:22:11 +00:00
Warner Losh 63e9c97664 loader: Add new option WITH_LOADER_BIOS_TEXTONLY
This option will omit all the graphics support, the teken terminal
library, video mode support, etc and support a simple, basic, text-only
video console for the x86 BIOS boot loader. It uses the FreeBSD 12
version of vidconsole.c. It defaults to NO.

Sponsored by:		Netflix
Differential Revision:	https://reviews.freebsd.org/D43912
2024-02-17 23:29:07 -07:00
Dimitry Andric 73ff7384e0 Optionally create full debuginfo for llvm-related executables
Commit de6feefdb7 limited the amount of debuginfo generated for clang
and other llvm-related executables. This was done to save disk space and
memory during building, but it makes debugging any of these executables
much harder.

Add a new src.conf(5) setting, WITH_LLVM_FULL_DEBUGINFO, to generate
full debuginfo instead. This is off by default, but could for example be
enabled for release builds or snapshots, so llvm executables are easier
to debug.

Reviewed by:	emaste
MFC after:	1 week
Differential Revision: https://reviews.freebsd.org/D43839
2024-02-17 00:15:32 +01:00
Warner Losh 22d12caad6 checkstyle9.pl: Differentiate errors and warnings
Use ::error and ::warning as appropriate to give better meaning to the
messages.

Sponsored by:		Netflix
2024-02-02 00:24:32 -07:00
Warner Losh ac9abe93e8 checkstyle9.pl: Another correction to github workflow
Remove extra space...

Sponsored by:		Netflix
2024-02-01 23:27:37 -07:00
Warner Losh c2f5306c64 checkstyle9.pl: Correct github output
Change the : between file and line to a ,. This should fix this...

Sponsored by:		Netflix
2024-02-01 23:15:13 -07:00
Warner Losh 0949b237bb checkstyle9.pl: Add --github to output for github workflows
If you add "::error file=foo/bar.c:line=123:" before the error message,
it will appear inline.

Sponsored by:		Netflix
2024-02-01 22:50:19 -07:00
Gregory Neil Shapiro 1b6a5580c1 New sendmail 8.18.1 cf file 2024-02-01 00:13:58 +00:00
Jessica Clarke b771d5705f tools/build/make.py: Avoid Python 3.7+ subprocess.run capture_output
This is just a convenient alias for setting stdout and stderr to PIPE,
so substitute it for that to be compatible with Python 3.6.

Fixes:	69cfdc81ea ("tools/build/make.py: Keep bootstrapped bmake binary up-to-date")
2024-01-31 19:45:59 +00:00
Jessica Clarke edec803c5b tools/build/make.py: Add missing comma to fix tinderbox and worlds
The missing comma meant this was interpreted as a single target called
"tinderboxworlds", and so neither tinderbox nor worlds were recognised
as being MI targets (i.e. still required TARGET(_ARCH) to be given).

Fixes:	5157b451c6 ("tools/build/make.py: Grow the list of MI targets")
2024-01-20 22:07:48 +00:00
Warner Losh 57623b3b74 checkstyle9.pl: Soften the single line braces requirement
We inherited the error for single line statements needing braces from
the original script. Style(9) allow that, and could be read to encourage
that, but does not require that.

Sponsored by:		Netflix
2024-01-15 17:57:28 -07:00
Kyle Evans 5d1ecf0b61 build: only inspect the first word of toolchain tools
CC/CXX/CPP/LD may all have arguments supplied in various circumstances,
which break the logic here.  We only need to determine which of these
tools we're expecting to invoke from PATH, which just requires
examination of the first word.  Limit our scope to exactly that.

Patch suggested by:	jrtc27
Reviewed by:		imp, jrtc27
Differential Revision:	https://reviews.freebsd.org/D43372
2024-01-08 22:22:25 -06:00
Warner Losh 4748db6ffd checkstyle9.pl: Don't use $root if not defined
$root is only defined when given on the command line. Don't try to use
its value when it's not defined.

Sponsored by:		Netflix
2024-01-07 09:51:49 -07:00
Warner Losh 1e81724578 checkstyle9: Remove irrelevant stuff from qemu
Remove some qemu project specific things we don't care about

o Remove python interpreter check
o Remove linux header check
o Remove trace file specail treatment
o Add $FreeBSD$ tag additions
o Remove some experiemntal code we won't need
o Remove commented out initializer code that we don't explicitly have a
  rule for.

Sponsored by:		Netflix
2024-01-07 09:51:49 -07:00
Warner Losh 2c5dcc5447 make_check: Deobit fmake support
We don't need make_check to work in a fmake world anymore (nor have we
in the past decade). Just remove it here.

Note in passing it's been 10 years since we've added a new test here and
maybe we're past the need for this part of the build (or need to revamp
it to include all the features added to bmake since 2016 that the build
system silently depends on).

Sponsored by:		Netflix
Reviewed by: brooks
Pull Request: https://github.com/freebsd/freebsd-src/pull/980
2024-01-03 12:14:17 -07:00
Warner Losh 259e6fefc0 test-includes: Add -ansi to the compile line to catch problems
We support C89 files, but compile everything in the tree with C99 or
newer. By compiling these -ansi, that will force C89 which doesn't
understand inline. All our header files must use __inline instead of
inline when they define inline functions.

Sponsored by:		Netflix
Reviewed by:		emaste
Differential Revision:	https://reviews.freebsd.org/D43235
2023-12-31 23:14:08 -07:00
John Baldwin e7300a8f63 OptionalObsoleteFiles.inc: Add libnss_tacplus_p.a as an old profiled library
Noticed this was still present after upgrading a 12.x stable host to
14.0 stable.
2023-12-28 14:20:54 -08:00
Tijl Coosemans 272b4b764b devd: Don't install autofs.conf with WITHOUT_AUTOFS 2023-12-22 15:27:50 +01:00
Jessica Clarke ff7c12c1f1 Make kldxref a bootstrap tool and use unconditionally
Now that kldxref is a generic cross tool and can be built on non-FreeBSD
we can bootstrap it during the build and thus remove the condition for
whether it exists. We also need to make sure to add it to the METALOG
for -DNO_ROOT builds.

Reviewed by:	brooks, imp
Differential Revision:	https://reviews.freebsd.org/D43051
2023-12-13 21:43:10 +00:00
Jessica Clarke 881ec81372 tools/build: Provide sys/linker_set.h when cross-building
This is needed for kldxref, which will shortly become a bootstrap tool.
Linux can use the same one as FreeBSD (provided the cross-building
sys/cdefs.h is augmented appropriately), whilst macOS needs its own
Mach-O-specific implementation.

Reviewed by:	brooks
Differential Revision:	https://reviews.freebsd.org/D43049
2023-12-13 21:43:09 +00:00
Dimitry Andric 06c3fb2749 Merge llvm-project main llvmorg-17-init-19304-gd0b54bb50e51
This updates llvm, clang, compiler-rt, libc++, libunwind, lld, lldb and
openmp to llvm-project main llvmorg-17-init-19304-gd0b54bb50e51, the
last commit before the upstream release/17.x branch was created.

PR:		273753
MFC after:	1 month
2023-12-08 18:34:50 +01:00
Warner Losh 6bfca4dcab tools: Automated cleanup of cdefs and other formatting
Apply the following automated changes to try to eliminate
no-longer-needed sys/cdefs.h includes as well as now-empty
blank lines in a row.

Remove /^#if.*\n#endif.*\n#include\s+<sys/cdefs.h>.*\n/
Remove /\n+#include\s+<sys/cdefs.h>.*\n+#if.*\n#endif.*\n+/
Remove /\n+#if.*\n#endif.*\n+/
Remove /^#if.*\n#endif.*\n/
Remove /\n+#include\s+<sys/cdefs.h>\n#include\s+<sys/types.h>/
Remove /\n+#include\s+<sys/cdefs.h>\n#include\s+<sys/param.h>/
Remove /\n+#include\s+<sys/cdefs.h>\n#include\s+<sys/capsicum.h>/

Sponsored by:		Netflix
2023-11-26 22:24:01 -07:00
Brooks Davis 4cd0f014a1 OptionalObsoleteFiles.inc: document block order
Options should be in sort(1) order by primary option (usually, but not
always, first in the if statement).

Reviewed by:	emaste, imp, netchild
Pull Request:	https://github.com/freebsd/freebsd-src/pull/896
2023-11-14 16:50:52 +00:00
Brooks Davis c90d0600ee Sort MK_NETLINK option
Reviewed by:	emaste, imp, netchild
Pull Request:	https://github.com/freebsd/freebsd-src/pull/896
2023-11-14 16:50:01 +00:00
Brooks Davis 2b3bf27da4 Sort MK_GNU_DIFF option
Reviewed by:	emaste, imp, netchild
Pull Request:	https://github.com/freebsd/freebsd-src/pull/896
2023-11-14 16:49:59 +00:00
Brooks Davis fb173fc89e Combine and sort MK_LLVM_COV
These used to be grouped with MK_GCOV option or the like.

Reviewed by:	emaste, imp, netchild
Pull Request:	https://github.com/freebsd/freebsd-src/pull/896
2023-11-14 16:49:55 +00:00
Brooks Davis 16743f0e0b Sort MK_EFI and MK_FTP options
Reviewed by:	emaste, imp, netchild
Pull Request:	https://github.com/freebsd/freebsd-src/pull/896
2023-11-14 16:49:53 +00:00
Brooks Davis a62cefbb5c Sort MK_DTRACE and MK_ZFS options
Presumably these were under MK_CDDL at some point, but these days
src.opts.mk takes care of setting them to "no" when MK_CDDL is.

Reviewed by:	emaste, imp, netchild
Pull Request:	https://github.com/freebsd/freebsd-src/pull/896
2023-11-14 16:49:50 +00:00
Brooks Davis e70ad278f4 Sort MK_HYPERV option
Reviewed by:	emaste, imp, netchild
Pull Request:	https://github.com/freebsd/freebsd-src/pull/896
2023-11-14 16:49:47 +00:00
Brooks Davis 4ca5df8039 Sort MK_BSD_CPIO before MK_BSDINSTALL
Using sort(1) order makes verification of the sort easier.

Reviewed by:	emaste, imp, netchild
Pull Request:	https://github.com/freebsd/freebsd-src/pull/896
2023-11-14 16:49:41 +00:00
Brooks Davis ec4c2adb50 Retire LLD_IS_LD option
The option was added to parallel the CLANG_IS_CC which was removed in
commit 20a66ab4bf.

Reviewed by:	imp, dim, emaste
Differential Revision:	https://reviews.freebsd.org/D42575
2023-11-13 21:34:14 +00:00
Warner Losh 2d8fabef75 ino64: Fix incremental builds
These files were removed, so we need to fix up depends for WITHOUT_CLEAN
builds (the default). Metamode builds aren't affected.

Sponsored by:		Netflix
Feedback from:		emaste
Tested by:		Pierre Pronchery
Differential Revision:	https://reviews.freebsd.org/D42433
2023-11-02 12:07:59 -06:00