Lines Matching +full:linux +full:- +full:headers
20 # Also add ufs/ffs/msdosfs/disk headers to allow building makefs as a bootstrap tool
42 _XCODE_ROOT!=xcode-select -p
43 # since macOS 10.14 C headers are no longer installed in /usr but only
46 # Only command line tools installed -> host headers are in the SDKs directory
49 # Full XCode installed -> host headers are below Platforms/MacOSX.platform
54 .error You must install the macOS SDK (try xcode-select --install)
60 # Allow building libc-internal files (also on non-FreeBSD hosts)
61 CFLAGS+= -I${.CURDIR}/libc-bootstrap
62 # Symbol versioning is not required for -legacy (and macOS bootstrap)
65 _WITH_PWCACHEDB!= grep -c pwcache_groupdb ${HOST_INCLUDE_ROOT}/grp.h || true
67 .PATH: ${.CURDIR}/../../contrib/libc-pwcache
68 CFLAGS.pwcache.c+= -I${.CURDIR}/../../contrib/libc-pwcache
72 _WITH_STRSVIS!= grep -c strsvis ${HOST_INCLUDE_ROOT}/vis.h 2>/dev/null || true
74 .PATH: ${.CURDIR}/../../contrib/libc-vis
77 CFLAGS.vis.c+= -I${.CURDIR}/../../contrib/libc-vis -DHAVE_VIS=0 -DHAVE_SVIS=0
78 CFLAGS.unvis.c+= -I${.CURDIR}/../../contrib/libc-vis -DHAVE_VIS=0 -DHAVE_SVIS=0
81 _WITH_REALLOCARRAY!= grep -c reallocarray ${HOST_INCLUDE_ROOT}/stdlib.h || true
93 _WITH_UTIMENS!= grep -c utimensat ${HOST_INCLUDE_ROOT}/sys/stat.h || true
105 _WITH_EXPLICIT_BZERO!= cat ${HOST_INCLUDE_ROOT}/strings.h ${HOST_INCLUDE_ROOT}/string.h | grep -c e…
108 # Adding sys/libkern to .PATH breaks building the cross-build compat library
119 _WITH_FSPACECTL!= grep -c fspacectl ${HOST_INCLUDE_ROOT}/fcntl.h || true
126 _WITH_CAPH_ENTER!= grep -c caph_enter ${HOST_INCLUDE_ROOT}/capsicum_helpers.h || true
127 _WITH_CAPH_RIGHTS_LIMIT!= grep -c caph_rights_limit ${HOST_INCLUDE_ROOT}/capsicum_helpers.h || true
137 # This is especially important on non-FreeBSD systems where the types may
160 # bmake on Linux/mac often prints that instead of amd64
163 # Linux calls arm64, aarch64, across the board
187 # macOS's bitstring lacks FreeBSD-specific additions used by makefs's ZFS code
188 # and Linux doesn't have it at all. Older FreeBSD versions lack recent
194 .PATH: ${.CURDIR}/cross-build
199 # dbopen() behaves differently on Linux and FreeBSD so we ensure that we
200 # bootstrap the FreeBSD db code. The cross-build headers #define dbopen() to
206 # on Linux (and to avoid surprises also compile the FreeBSD code on macOS)
223 .if ${.MAKE.OS} == "Linux"
224 # On Linux, glibc does not provide strmode. It only provides strlcpy
229 _WITH_EXPLICIT_STRLCPY!= cat ${HOST_INCLUDE_ROOT}/strings.h ${HOST_INCLUDE_ROOT}/string.h | grep -c…
233 # On Linux, glibc provides ffs* but not fls*
237 CFLAGS.closefrom.c+= -DSTDC_HEADERS -DHAVE_SYS_DIR_H -DHAVE_DIRENT_H \
238 -DHAVE_DIRFD -DHAVE_SYSCONF
247 # macOS has a standalone cross-build implementation, but Linux can use the same
251 .endif # ${MAKE.OS} == "Linux"
261 # Provide the same arc4random implementation on Linux/macOS
262 CFLAGS.arc4random.c+= -I${SRCTOP}/sys/crypto/chacha20 -D__isthreaded=1
265 # expand_number() is not provided by either Linux or MacOS libutil
268 # Linux libutil also doesn't have fparseln
284 # Headers needed for msdosfs use in makefs
335 INCS+= ${SRCTOP}/crypto/krb5/src/util/verto/verto-module.h
344 SUBDIR= cross-build
347 # To allow bootstrapping makefs on FreeBSD 11 or non-FreeBSD systems:
405 # This is especially important when building on Linux/MacOS where many of the
409 # from the FreeBSD sources during the bootstrap-tools stage.
412 # Linux/MacOS since we only use flags that are supported by all of them.
420 # since e.g. on Linux and MacOS that will be GNU make.
424 _LINK_HOST_TOOL= ln -sfn
430 _COPY_HOST_TOOL= install -p
432 # However, this is not necessary on Linux/macOS. Additionally, copying the host
433 # tools to another directory with cp -p results in freezes on macOS Big Sur for
449 # We also need to symlink any non-absolute toolchain commands. Clang finds its
461 _WRAP_HOST_TOOL= sh -c "printf '\#!/bin/sh\nexec \"\%s\" \"\$$@\"\n' \"\$$0\" > \"\$$1\" && chmod +…
474 host-symlinks:
479 if [ ! -e "$${source_path}" ] ; then \
482 rm -f "${DESTDIR}/bin/${_tool}"; \
488 if [ ! -e "$${source_path}" ] ; then \
491 rm -f "$${target_path}"; \
495 rm -f ${DESTDIR}/usr/libexec/flua
501 if [ ! -e "$${source_path}" ] ; then \
504 rm -f "${DESTDIR}/bin/${_tool}"; \
508 # Create all the directories that are needed during the legacy, bootstrap-tools
509 # and cross-tools stages. We do this here using mkdir since mtree may not exist
510 # yet (this happens if we are crossbuilding from Linux/Mac).
524 mkdir -p ${INSTALLDIR_LIST:S,^,${DESTDIR}/,}
528 # bootstrap-tools phase. We could also overrride BINDIR when building bootstrap
534 @if [ -e ${DESTDIR}/${_dir} ] && [ ! -L ${DESTDIR}/${_dir} ]; then \
535 echo "removing old non-symlink ${DESTDIR}/${_dir}"; \
536 rm -rf "${DESTDIR}/${_dir}"; \
539 ln -sfn bin ${DESTDIR}/sbin
540 ln -sfn ../bin ${DESTDIR}/usr/bin
541 ln -sfn ../bin ${DESTDIR}/usr/sbin
543 mkdir -p "${DESTDIR}/${${_group}DIR}"