Building LLVM with a host gcc 13 fails and suggests including <cstdint>
in external/apache2/llvm/dist/llvm/include/llvm/Support/Signals.h .
Instead of this, joerg@ suggested not modifying the llvm vendor branch
but instead working around this in our LLVM build infrastructure.
Original commit message from Roy Marples:
"Derive our primary interface and address by trying to connect to an
address in the TEST-NET-2 network as noted in RFC5737 instead of using
the 1.1.1.1 address. Also, use port 7 (echo) for better style.
Fixes PR bin/46758 thanks to Lloyd Parkes."
pullups needed for netbsd-9, netbsd-10.
this commit doesn't reapply "dumping of the unicast server list
to the DumpStateLog debugging output" enhancement.
It doesn't build anymore, no idea how to rewrite.
Should fix PR 57442. Needs pull-ups for netbsd-9, netbsd-10.
macOS/x86_64 defines boolean_t as 'unsigned int' not 'int',
which causes a build issue with tools/ctfmerge on that host
after my recent fixes for macOS semaphores.
So use the <mach/boolean.h> instead of a local typedef ifdef __APPLE__.
May fix a macOS/x86_64 build issue reported by cjep@.
Builds fine on NetBSD/amd64 or macOS/arm.
Note: this compat stuff is clunky, and based on the commit log,
annoyingly error prone. A newer sync of osnet from upstream /may/
improve a lot of these compat typedef workarounds for solaris types...
dispatch_semaphore_signal() doesn't return an error, just an
indicator of whether a thread was woken or not, so there's
no need to fail on non-zero return.
autoconf relies upon GNU m4 emacs-style regexs, which
don't support intervals so don't escape these.
A fix to usr.bin/m4 -g (GNU m4 emulation) is incoming.
Add local fix to AC_FUNC_ALLOCA() to include <stdlib.h> on BSD:
# elif defined(__NetBSD__) || defined(__FreeBSD__) || defined(__DragonFly__) || defined(__OpenBSD__)
# include <stdlib.h>
This change avoids regen losing this change in tools/compat/configure
that was added in rev 1.75 on 2013-03-05 of tools/compat/configure,
and subsequent commits that keep re-adding these lines back
manually (e.g., rev 1.97 on 2019-06-22 of tools/compat/configure)
XXX: Arguably this could be fixed in a separate way to allow us to
use an unmodified modern autoconf in the future ?
Use dispatch_semaphore_create() if present instead of sem_init().
macOS doesn't actually implement sem_init() (et al)
(even though it provides the prototypes as deprecated).
This was detected by the previous commit to ctfmerge
that added error handling.
Implement ctfmerge's barrier operations in terms of
dispatch(3) APIs such as dispatch_semaphore_create() (et al).
Update tools/compat/configure.ac to find dispatch_semaphore_create().
Fixes ctfmerge on macOS hosts.
Inspired by https://stackoverflow.com/a/27847103.
terminate() if sem_*() returns -1 or pthread_*() returns != 0.
(Set errno from pthread_*() so terminate() prints the strerror message).
Note: Failing on errors instead of ignoring them helps identify
reasons for intermittent failures, such as those on macOS host builds:
ERROR: nbctfmerge: barrier_init: sem_init(bar_sem): Function not implemented
arm is a little more complicated because it has three cases:
- big-endian data, big-endian instructions
- big-endian data, little-endian instructions
- little-endian data, little-endian instructions
Define HOSTPROG_CXX before .include anything that brings in bsd.own.mk.
This ensures that HOST_DBG (etc) gets assigned before HOST_CFLAGS
and HOST_CXXFLAGS is created.
backend: .include <bsd.init.mk> much earlier, as per the other directories.
Fixes backend build when using clang++ as the host compiler (e.g., macOS),
because backend host tools are now built with -O.
Inspired by https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=255760
Note that gcc.old/Makefile.prog may be mis-used because it defines HOSTPROG_CXX
and this Makefile fragment is included after bsd.*.mk in other Makefiles,
but they seem to build ok so leaving it alone for now.
Fixes PR toolchain/57014
Use a more restrictive pattern to extract -j NNN from MAKEFLAGS
into GMAKE_J_ARGS, to avoid false positives when the source directory
has "-j" in the path (e.g "amd64-job-000012" or "src-j9999").
Previously this could pass either -"-j" or "-j BIGNUM" to gmake
and result in "vfork: Resource temporarily unavailable" failures.
PR misc/54456
These had their -h option removed in the ATF 0.19 release, but these
references in the man pages weren't (mostly) removed upstream until
a later commit (that hasn't been released).
* privsep: keep resources open rather than open/close
* dhcp6: OPTION_NTP_SERVER is now preferred over OPTION_SNTP_SERVER
* Misc bug fixes mainly around privsep for many platforms.
* Fix for reading the some BSD routing table entries.
* Fix reading authtokens from config.
Big new release, mainly around better privsep process management
which allows us to detect when they exit unexpectedly.
Function 'leaveblock' was generating "break" label before removing
variables from the closing block. If 'createlabel' created a 'close'
instruction (which it did when matching a goto/break that exited
the scope of an upvalue), that instruction would use the wrong level.
handling an error." (CVE-2022-33099)
Save stack space while handling errors
Because error handling (luaG_errormsg) uses slots from EXTRA_STACK,
and some errors can recur (e.g., string overflow while creating an
error message in 'luaG_runerror', or a C-stack overflow before calling
the message handler), the code should use stack slots with parsimony.
This commit fixes the bug "Lua-stack overflow when C stack overflows
while handling an error".