This fixes incremental build of OpenSSH after the recent upgrade.
For example, in secure/lib/libssh, -include ssh_namespace.h is used on
all files. This is not tracked in the .depend file though due to
MKDEP_CFLAGS not including it. The ssh example was broken in r291941
when not using FAST_DEPEND due to the .depend bug. FAST_DEPEND was not
affected by this because it generates dependencies at compile time and
thus sees the -include.
This ugly make syntax could be simpler for bmake by using :tW but
fmake-compatible syntax is used since this needs to be MFC'd all the way
to stable/9.
Also add a temporary hack to workaround existing checkouts building
incrementally with a .depend file not having these headers.
MFC after: 1 week
Sponsored by: EMC / Isilon Storage Division
This was a regression in r290629, which was revealed partly in r294360.
Once 'make depend' has ran it will generate all headers already. Thus
even with FAST_DEPEND lacking proper dependencies before building, it
will not have any missing headers. Once objects are compiled the depend
files will be generated with proper dependencies.
Sponsored by: EMC / Isilon Storage Division
This reworks r289254 and removes ALL_SUBDIR_TARGETS.
Because there is an include guard in this file there is no need for
LOCAL_ or ?= on SUBDIR_TARGETS or STANDALONE_SUBDIR_TARGETS. These can
just be set via src.conf. By the time bsd.subdir.mk is included it will
just append the values to the existing value and work fine. This allows
a consistent way to append to these variables without introducing a
LOCAL_ var for STANDALONE_SUBDIR_TARGETS or renaming the historical
SUBDIR_TARGETS.
Sponsored by: EMC / Isilon Storage Division
If filemon is used then there is no need to generate dependency files during
compilation as the .meta files will achieve the same result.
This is a temporary solution until FAST_DEPEND is default. Once that is
default there will be an option to disable dependency generation entirely
as it is only useful if an incremental build is planned, thus META_MODE+filemon
can enable that option to short-circuit all FAST_DEPEND-related logic.
Sponsored by: EMC / Isilon Storage Division
The .MAKEFLAGS check inside of the .for loop is extremely slow for some
reason. Just moving it out of the loop trimmed -V lookup time from 11
seconds to 1 second in the kernel obj directory.
Sponsored by: EMC / Isilon Storage Division
Allow user-specified warning flag overrides for specific files under
bsd.sys.mk, in the same way kern.mk does.
This will to be used by future commits.
MFC after: 2 weeks
X-MFC-With: r293268
Sponsored by: Multiplay
It is built in libgcc_s.so and libgcc_eh.a to simplify transition.
It is enabled by default on arm64 (where we previously had no other
unwinder) and may be enabled for testing on other platforms by setting
WITH_LLVM_LIBUNWIND in src.conf(5).
Also add compiler-rt's __gcc_personality_v0 implementation for use with
the LLVM unwinder.
Relnotes: Yes
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D4787
This will ensure that the variable was not set as a make override, in
make.conf, src.conf or src-env.conf. It allows setting the value in
src-env.conf when using WITH_AUTO_OBJ since that case properly handles
changing .OBJDIR (except if MAKEOBJDIRPREFIX does not yet exist which is
being discussed to be changed).
This change allows setting a default MAKEOBJDIRPREFIX via local.sys.env.mk.
Sponsored by: EMC / Isilon Storage Division
for libraries that follow the soft float ABI. It's only supported on
armv6 as a transition to the new hard float ABI, so mark as broken
everywhere else.
For determining the compiler version, quote the string to be echo'd,
otherwise the command might fail. This is because clang -v now results
in the following:
FreeBSD clang version 3.8.0 (trunk 256633) (based on LLVM 3.8.0svn)
The second "3.8.8svn)" string tripped up the shell command.
MFC after: 3 days
otherwise the command might fail. This is because clang -v now results
in the following:
FreeBSD clang version 3.8.0 (trunk 256633) (based on LLVM 3.8.0svn)
The second "3.8.8svn)" string tripped up the shell command.
POSIX requires for the c99 compiler.
(In fact, our c99(1) already ignores -lxnet; but our make(1) doesn't set
${CC} correctly, and our cc(1) treats xnet like any other library.)
Reviewed by: kib
LLDB is usable for userland core file and live debugging on amd64, and
for userland core file debugging on arm64. In general it works at least
as well on FreeBSD as our in-tree gdb version, so enable it by default
to allow for broader use and testing.
An LLDB tutorial is available at http://lldb.llvm.org/tutorial.html, and
a table mapping GDB commands to LLDB commands can be found at
http://lldb.llvm.org/lldb-gdb.html .
LLDB also has some level of support for FreeBSD on arm, mips, i386,
and powerpc, but is not yet ready to have them enabled by default.
Reviewed by: gnn
Relnotes: Yes
This is not wrong, but was unexpected. Using <empty>:H results in '.' which
then using the rest of the conversion was added in RELDIR. This was also
causing an empty _DP_DIRDEPS to resolve to SRCTOP for DIRDEPS.
Sponsored by: EMC / Isilon Storage Division
This logic is potentially included multiple times, so overwrite the temporary
variable rather than append to it.
Sponsored by: EMC / Isilon Storage Division
This is because LDADD+=-lFOO is not the same as LDADD+=-lprivateFOO which is
what the private libs in LIBADD are.
Sponsored by: EMC / Isilon Storage Division
system call information such as system call arguments. Initially this
will consist of pulling duplicated code out of truss and kdump though it
may prove useful for other utilities in the future.
This commit moves the shared utrace(2) record parser out of kdump into
the library and updates kdump and truss to use it. One difference from
the previous version is that the library version treats unknown events
that start with the "RTLD" signature as unknown events. This simplifies
the interface and allows the consumer to decide how to handle all
non-recognized events. Instead, this function only generates a string
description for known malloc() and RTLD records.
Reviewed by: bdrewery
Differential Revision: https://reviews.freebsd.org/D4537
These use ld(1), effectively -nostdlib, and don't need any of these
normal dependencies.
kmod builds also define PROG so just checking for KMOD here seems to be
the easiest to handle it.
Sponsored by: EMC / Isilon Storage Division
RISC-V is a new ISA designed to support computer research and education, and
is now become a standard open architecture for industry implementations.
This is a minimal set of changes required to run 'make kernel-toolchain'
using external (GNU) toolchain.
The FreeBSD/RISC-V project home: https://wiki.freebsd.org/riscv.
Reviewed by: andrew, bdrewery, emaste, imp
Sponsored by: DARPA, AFRL
Sponsored by: HEIF5
Differential Revision: https://reviews.freebsd.org/D4445
Older ccache don't work with an empty CCACHE_PATH value. They will error with:
ccache: FATAL: Could not find compiler "cc" in PATH
make: "/mnt/bdrewery/git/onefs/src/share/mk/bsd.compiler.mk" line 134: Unable to determine compiler type for /usr/local/bin/ccache cc. Consider setting COMPILER_TYPE.
Sponsored by: EMC / Isilon Storage Division
STAGE_OBJTOP and STAGE_HOST_OBJTOP.
These will always be overridden in sub-makes when building in-tree, but
are exported for the benefit of hooking in external builds, such as
ports.
Sponsored by: EMC / Isilon Storage Division
- Don't bother looking up REVISION/BRANCH/etc from release/, or the
CPUTYPE check, as these are not used for makeman and wastes time. The also
invokes auto.obj.mk after I reverted auto.obj.mk ignoring -V in r291312.
- Don't modify CC or PATH when WITH_CCACHE_BUILD or WITH_META_MODE is enabled
as it leads to bsd.compiler.mk errors.
Sponsored by: EMC / Isilon Storage Division
Debug data files are now built by default with 'make buildworld' and
installed with 'make installworld'. This facilitates debugging but
requires more disk space both during the build and for the installed
world. Debug files may be disabled by setting WITHOUT_DEBUG_FILES=yes
in src.conf(5).
Reviewed by: bdrewery, eadler, vangyzen
Relnotes: Yes
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D4018
This will save time generating dependency files that we didn't expect
due to cases where SRCS!=OBJS or for building custom targetted objects
in Makefiles that do not end up in the DEPENDOBJS list.
This uses a bmake trick to modify CFLAGS based on ${.TARGET}. A
.PARSEDIR check is done for the sake of MFC safety.
MFC after: 2 weeks
Sponsored by: EMC / Isilon Storage Division