Copyright (c) 1999-2023 The NetBSD Foundation, Inc.
All rights reserved.
This code is derived from software contributed to The NetBSD Foundation
by Luke Mewburn.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions
are met:
1. Redistributions of source code must retain the above copyright
notice, this list of conditions and the following disclaimer.
2. Redistributions in binary form must reproduce the above copyright
notice, this list of conditions and the following disclaimer in the
documentation and/or other materials provided with the distribution.
THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS
``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS
BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
POSSIBILITY OF SUCH DAMAGE.
.Dd June 1, 2022 .Dt MK.CONF 5 .Os turn off hyphenation
. .Sh NAME .Nm mk.conf .Nd make configuration file . .Sh DESCRIPTION The .Nm file overrides various parameters used during the build of the system.
p Listed below are the .Nm variables that may be set, the values to which each may be set, a brief description of what each variable does, and a reference to relevant manual pages. . .Ss NetBSD System variables .
p .Em Default : .. .DFLT .Dq no .. .DFLT Unset. .. .DFLT .Dq yes ..
p Forced to .Dq no if .Sy \\$* is defined, usually in the Makefile before any .Xr make 1 .Cm .include directives. ..
p
Forced to
.Dq no
if
.Sy \\$* .
..
Can be set to
.Dq yes
or
.Dq no .
..
.
l -tag -width 15n .
These entries are sorted alphabetically
.
t Sy BSDOBJDIR The real path to the object directory tree for the
.Nx
source tree.
.DFLT
.Dq Pa /usr/obj
.
t Sy BSDSRCDIR The real path to the
.Nx
source tree, if
.Sy NETBSDSRCDIR
isn't defined.
.DFLT
.Dq Pa /usr/src
.
t Sy BUILD If defined,
.Sq "make install"
checks that the targets in the source directories are up-to-date and
re-makes them if they are out of date, instead of blindly trying to install
out of date or non-existent targets.
.DFLTu
.
t Sy BUILDID Identifier for the build.
The identifier will be appended to
object directory names, and can be consulted in the
.Xr make 1
configuration file in order to set additional build parameters,
such as compiler flags.
.DFLTu
.
t Sy COPTS Extra options for the C compiler.
Should be appended to (e.g.,
.Sy COPTS+=-g ) ,
rather than explicitly set.
Note that
.Sy CPUFLAGS ,
not
.Sy COPTS ,
should be used for
compiler flags that select CPU-related options.
Also note that
.Sy CFLAGS
should never be set in
.Nm .
.
t Sy CPUFLAGS Additional flags passed to the compiler/assembler to select
CPU instruction set options, CPU tuning options, etc.
Such options should not be specified in
.Sy COPTS ,
because some parts of the build process need to override
CPU-related compiler options.
.
t Sy DESTDIR Directory to contain the built
.Nx
system.
If set, special options are passed to the compilation tools to
prevent their default use of the host system's
.Sy /usr/include , /usr/lib ,
and so forth.
This pathname should
.Em not
end with a slash
q / character (for installation into the system's root directory, set .Sy DESTDIR to an empty string). The directory must reside on a file system which supports long file names and hard links.
p .Em Note : .Sy build.sh will provide a default of .Dq Pa destdir . Ns Sy MACHINE (in the top-level .Sy .OBJDIR ) unless run in .Sq expert mode .DFLT Empty string if .Sy USETOOLS=yes ; unset otherwise. . t Sy EXTSRCSRCDIR Obsolete. . t Sy KERNEL_DIR Pq No experimental .YorN Indicates if a top-level directory .Sy /netbsd/ is created. If .Dq yes , the directory will contain a kernel file
a /netbsd/kernel and a corresponding modules directory
a /netbsd/modules/ . System bootstrap procedures will be modified to search for the kernel and modules in the
a /netbsd/ directory. This is intended to simplify system upgrade and rollback procedures by keeping the kernel and its associated modules together in one place.
p If .Dq no , the kernel file will be stored in
a /netbsd and the modules will be stored within the
a /stand/${ARCH}/ directory hierarchy.
p The .Sy KERNEL_DIR option is a work-in-progress, and is highly experimental. It is also subject to change without notice. .DFLTn t Sy MAKEVERBOSE Level of verbosity of status messages. Supported values: l -tag -width 2n t 0 No descriptive messages or commands executed by .Xr make 1 are shown. t 1 Brief messages are shown describing what is being done, but the actual commands executed by .Xr make 1 are not displayed. t 2 Descriptive messages are shown as above (prefixed with a .Sq # ) , and ordinary commands performed by .Xr make 1 are displayed. t 3 In addition to the above, all commands performed by .Xr make 1 are displayed, even if they would ordinarily have been hidden through use of the .Dq @ prefix in the relevant makefile. t 4 In addition to the above, commands executed by .Xr make 1 are traced through use of the .Xr sh 1 .Dq Fl x flag. .El .DFLT 2 . t Sy MKAMDGPUFIRMWARE .YorN Indicates whether to install the
a /libdata/firmware/amdgpu directory, which is necessary for the .Xr amdgpu 4 AMD RADEON GPU video driver. .DFLTy on .Sy i386 and .Sy x86_64 ; .Dq no on other platforms. . t Sy MKARGON2 .YorN Indicates whether the Argon2 hash is enabled in libcrypt. .DFLTy . t Sy MKARZERO .YorN Indicates whether .Xr ar 1 should zero the timestamp, uid, and gid in the archive for reproducible builds. .DFLT The value of .Sy MKREPRO (if defined), otherwise .Dq no . . t Sy MKATF .YorN Indicates whether the Automated Testing Framework (ATF) will be built and installed. This also controls whether the .Nx test suite will be built and installed, as the tests rely on ATF and cannot be built without it. .NOVAR MKCXX=no .DFLTy . t Sy MKBFD Obsolete, use .Sy MKBINUTILS . . t Sy MKBINUTILS .YorN Indicates whether any of the binutils tools or libraries will be built and installed. That is, the libraries .Sy libbfd , .Sy libiberty , or any of the things that depend upon them, e.g. .Xr as 1 , .Xr ld 1 , .Xr dbsym 8 , or .Xr mdsetimage 8 . .NOVAR TOOLCHAIN_MISSING!=no .DFLTy . t Sy MKBSDGREP .YorN Determines which implementation of .Xr grep 1 will be built and installed. If .Dq yes , use the BSD implementation. If .Dq no , use the GNU implementation. .DFLTn . t Sy MKBSDTAR .YorN Determines which implementation of .Xr cpio 1 and .Xr tar 1 will be built and installed. If .Dq yes , use the .Sy libarchive Ns - Ns based implementations. If .Dq no , use the .Xr pax 1 based implementations. .DFLTy . t Sy MKCATPAGES .YorN Indicates whether preformatted plaintext manual pages will be created and installed. .NOVAR MKMAN=no No or Sy MKSHARE=no .DFLTn . t Sy MKCLEANSRC .YorN Indicates whether .Sq "make clean" and .Sq "make cleandir" will delete file names in .Sy CLEANFILES or .Sy CLEANDIRFILES from both the object directory, .Sy .OBJDIR , and the source directory, .Sy .SRCDIR .
p If .Dq yes , then these file names will be deleted relative to both .Sy .OBJDIR and .Sy .CURDIR . If .Dq no , then the deletion will be performed relative to .Sy .OBJDIR only. .DFLTy . t Sy MKCLEANVERIFY .YorN Controls whether .Sq "make clean" and .Sq "make cleandir" will verify that files have been deleted. If .Dq yes , then file deletions will be verified using .Xr ls 1 . If .Dq no , then file deletions will not be verified. .DFLTy . t Sy MKCOMPAT .YorN Indicates whether support for multiple ABIs is to be built and installed. .NODEF NOCOMPAT .DFLTy on .Sy aarch64 (without gcc), .Sy mips64 , .Sy powerpc64 , .Sy riscv64 , .Sy sparc64 , and .Sy x86_64 ; .Dq no on other platforms. . t Sy MKCOMPATMODULES .YorN Indicates whether the compat kernel modules will be built and installed. .NOVAR MKCOMPAT=no .DFLTy on .Sy evbppc-powerpc and .Sy mips64 ; .Dq no on other platforms. . t Sy MKCOMPATTESTS .YorN Indicates whether the .Nx test suite for
a src/compat will be built and installed. .NOVAR MKCOMPAT=no .DFLTn . t Sy MKCOMPATX11 .YorN Indicates whether the X11 libraries will be built and installed. .NOVAR MKCOMPAT=no .DFLTn . t Sy MKCOMPLEX .YorN Indicates whether the .Lb libm is compiled with support for n complex.h . .DFLTy . t Sy MKCRYPTO Obsolete. . t Sy MKCTF .YorN Indicates whether CTF tools are to be built and installed. If .Dq yes , the tools will be used to generate and manipulate CTF data of ELF binaries during build. .NODEF NOCTF
p This is disabled internally for standalone programs in
a /usr/mdec . .DFLTy on .Sy aarch64 , .Sy amd64 , and .Sy i386 ; .Dq no on other platforms. . t Sy MKCVS .YorN Indicates whether .Xr cvs 1 will be built and installed. .DFLTy . t Sy MKCXX .YorN Indicates whether C++ support is enabled.
p If .Dq no , C++ compilers and software will not be built, and acts as .Sy MKATF=no MKGCCCMDS=no MKGDB=no MKGROFF=no MKKYUA=no . .DFLTy . t Sy MKDEBUG .YorN Indicates whether separate debugging symbols should be installed into .Sy DESTDIR Ns Pa /usr/libdata/debug . .NODEF NODEBUG .DFLTn . t Sy MKDEBUGKERNEL .YorN Indicates whether debugging symbols will be built for kernels by default; pretend as if .Em makeoptions DEBUG="-g" is specified in kernel configuration files. This will also put the debug kernel in the kernel sets. See .Xr options 4 for details. .DFLTn . t Sy MKDEBUGLIB .YorN Indicates whether debug libraries .Sy ( lib*_g.a ) will be built and installed. Debug libraries are compiled with .Dq Li -g -DDEBUG . .NODEF NODEBUGLIB .DFLTn . t Sy MKDEBUGTOOLS .YorN Indicates whether debug information .Sy ( lib*_g.a ) will be included in the build toolchain. .DFLTn . t Sy MKDEPINCLUDES .YorN Indicates whether to add .Cm .include statements in the
a .depend files instead of inlining the contents of the
a *.d files. This is useful when stale dependencies are present, to list the exact files that need refreshing, but it is possibly slower than inlining. .DFLTn . t Sy MKDOC .YorN Indicates whether system documentation destined for .Sy DESTDIR Ns Pa /usr/share/doc will be installed. .NODEF NODOC .NOVAR MKSHARE=no .DFLTy . t Sy MKDTB Indicates whether the devicetree blobs will be built and installed. .DFLTy on .Sy aarch64 , .Sy armv6 , .Sy armv7 , .Sy riscv32 , and .Sy riscv64 ; .Dq no on other platforms. . t Sy MKDTC .YorN Indicates whether the Device Tree Compiler (dtc) will be built and installed. .DFLTy . t Sy MKDTRACE .YorN Indicates whether the kernel modules, utilities, and libraries for .Xr dtrace 1 support are to be built and installed. .DFLTy on .Sy aarch64 , .Sy amd64 , and .Sy i386 ; .Dq no on other platforms. . t Sy MKDYNAMICROOT .YorN Indicates whether all programs should be dynamically linked, and to install shared libraries required by
a /bin and
a /sbin and the shared linker .Xr ld.elf_so 1 into
a /lib . If .Dq no , link programs in
a /bin and
a /sbin statically. .DFLTn on .Sy ia64 ; .Dq yes on other platforms. . t Sy MKEXTSRC Obsolete. . t Sy MKFIRMWARE .YorN Indicates whether to install the
a /libdata/firmware directory, which is necessary for various drivers, including: .Xr athn 4 , .Xr bcm43xx 4 , .Xr bwfm 4 , .Xr ipw 4 , .Xr iwi 4 , .Xr iwm 4 , .Xr iwn 4 , .Xr otus 4 , .Xr ral 4 , .Xr rtwn 4 , .Xr rum 4 , .Xr run 4 , .Xr urtwn 4 , .Xr wpi 4 , .Xr zyd 4 , and the Tegra 124 SoC. .DFLTy on .Sy amd64 , .Sy cobalt , .Sy evbarm , .Sy evbmips , .Sy evbppc , .Sy hpcarm , .Sy hppa , .Sy i386 , .Sy mac68k , .Sy macppc , .Sy sandpoint , and .Sy sparc64 ; .Dq no on other platforms. . t Sy MKGCC .YorN Indicates whether .Xr gcc 1 or any related libraries
q Sy libg2c , libgcc , libobjc , libstdc++ will be built and installed. .NOVAR TOOLCHAIN_MISSING!=no No or Sy EXTERNAL_TOOLCHAIN No is defined .DFLTy . t Sy MKGCCCMDS .YorN Indicates whether .Xr gcc 1 will be built and installed. If .Dq no , then .Sy MKGCC controls if the GCC libraries will be built and installed. .NOVAR MKCXX=no .DFLTn on .Sy m68000 ; .Dq yes on other platforms. . t Sy MKGDB .YorN Indicates whether .Xr gdb 1 will be built and installed. .NOVAR MKCXX=no No or Sy TOOLCHAIN_MISSING!=no .DFLTn on .Sy ia64 and .Sy or1k ; .Dq yes on other platforms. . t Sy MKGROFF .YorN Indicates whether .Xr groff 1 will be built, installed, and used to format some of the PostScript and PDF documentation. .NOVAR MKCXX=no .DFLTy . t Sy MKGROFFHTMLDOC .YorN Indicates whether to use .Xr groff 1 to generate HTML for miscellaneous articles which sometimes requires software not in the base installation. Does not affect the generation of HTML man pages. .DFLTn . t Sy MKHESIOD .YorN Indicates whether the Hesiod infrastructure (libraries and support programs) will be built and installed. .DFLTy . t Sy MKHOSTOBJ .YorN If .Dq yes , then for programs intended to be run on the compile host, the name, release, and architecture of the host operating system will be suffixed to the name of the object directory created by .Dq make obj . (This allows multiple host systems to compile .Nx for a single target.) If .Dq no , then programs built to be run on the compile host will use the same object directory names as programs built to be run on the target. .DFLTn . t Sy MKHTML .YorN Indicates whether the HTML manual pages are created and installed. .NODEF NOHTML .NOVAR MKMAN=no No or Sy MKSHARE=no .DFLTy . t Sy MKIEEEFP .YorN Indicates whether code for IEEE754/IEC60559 conformance will be built and installed. Has no effect on most platforms. .DFLTy . t Sy MKINET6 .YorN Indicates whether INET6 (IPv6) infrastructure (libraries and support programs) will be built and installed. .DFLTy . t Sy MKINFO .YorN Indicates whether GNU Info files, used for the documentation for most of the compilation tools, will be built and installed. .NODEF NOINFO .NOVAR MKSHARE=no .DFLTy . t Sy MKIPFILTER .YorN Indicates whether the .Xr ipf 4 programs, headers, and other components will be built and installed. .DFLTy . t Sy MKISCSI .YorN Indicates whether the iSCSI library and applications are built and installed. .DFLTn on .Sy m68000 ; .Dq yes on other platforms. . t Sy MKKDEBUG Deprecated, use .Sy MKDEBUGKERNEL . . t Sy MKKERBEROS .YorN Indicates whether the Kerberos v5 infrastructure (libraries and support programs) will be built and installed. Caution: the default .Xr pam 8 configuration requires that Kerberos be present even if not used. Do not install a userland without Kerberos without also either updating the .Xr pam.conf 5 files or disabling PAM via .Sy MKPAM . Otherwise all logins will fail. .DFLTy . t Sy MKKERBEROS4 Obsolete. . t Sy MKKMOD .YorN Indicates whether kernel modules will be built and installed. .DFLTn on .Sy or1k ; .Dq yes on other platforms. . t Sy MKKYUA .YorN Indicates whether Kyua (the testing infrastructure used by .Nx ) will be built and installed. .NOVAR MKCXX=no
p .Em Note : This does not control the installation of the tests themselves. The tests rely on the ATF libraries and therefore their build is controlled by the .Sy MKATF variable. .DFLTn until the import of Kyua is done and validated. . t Sy MKLDAP .YorN Indicates whether the Lightweight Directory Access Protocol (LDAP) infrastructure (libraries and support programs) will be built and installed. .DFLTy . t Sy MKLIBCSANITIZER .YorN Indicates whether to use the sanitizer for libc, using the sanitizer defined by .Sy USE_LIBCSANITIZER . .NODEF NOLIBCSANITIZER .DFLTn . t Sy MKLIBCXX .YorN Indicates if libc++ will be built and installed (usually for .Xr clang++ 1 ) . .DFLTy if .Sy MKLLVM=yes ; .Dq no otherwise. . t Sy MKLIBSTDCXX .YorN Indicates if libstdc++ will be built and installed (usually for .Xr g++ 1 ) . .DFLTy . t Sy MKLINKLIB .YorN Indicates whether all of the shared library infrastructure will be built and installed. If .Dq no , prevents: installation of the .Sy *.a libraries, installation of the .Sy *_pic.a libraries on PIC systems, building of .Sy *.a libraries on PIC systems, or installation of .Sy .so symlinks on ELF systems. .NODEF NOLINKLIB
p If .Dq no , acts as .Sy MKLINT=no MKPICINSTALL=no MKPROFILE=no . .DFLTy . t Sy MKLINT .YorN Indicates whether .Xr lint 1 will be run against portions of the .Nx source code during the build, and whether lint libraries will be installed into .Sy DESTDIR Ns Pa /usr/libdata/lint . .NODEF NOLINT .NOVAR MKLINKLIB=no .DFLTn . t Sy MKLLD Obsolete. . t Sy MKLLDB Obsolete. . t Sy MKLLVM .YorN Indicates whether .Xr clang 1 is installed as a host tool and target compiler.
p If .Dq yes , acts as .Sy MKLIBCXX=yes .
p .Em Note : Use of .Xr clang 1 as the system compiler is controlled by .Sy HAVE_LLVM . .DFLTn . t Sy MKLLVMRT .YorN Indicates whether to build the LLVM PIC libraries necessary for the various Mesa backend and the native JIT of the target architecture, if supported. (Radeon R300 and newer, LLVMPIPE for most.) .DFLT If .Sy MKX11=yes and .Sy HAVE_MESA_VER>=19 , .Dq yes on .Sy aarch64 , .Sy amd64 , and .Sy i386 ; .Dq no otherwise. . t Sy MKLVM .YorN If not .Dq no , build and install the logical volume manager. .DFLTy . t Sy MKMAKEMANDB .YorN Indicates if the whatis tools .Xr ( apropos 1 , .Xr whatis 1 , .Xr getNAME 8 , .Xr makemandb 8 , and .Xr makewhatis 8 ) , should be built, installed, and used to create and install the
a whatis.db . .DFLTy . t Sy MKMAN .YorN Indicates whether manual pages will be installed. .NODEF NOMAN .NOVAR MKSHARE=no
p If .Dq no , acts as .Sy MKCATPAGES=no MKHTML=no . .DFLTy . t Sy MKMANDOC .YorN Indicates whether .Xr mandoc 1 will be built and installed, and used to create and install catman and HTML pages.
p If .Dq no , use .Xr groff 1 instead of .Xr mandoc 1 . .NODEF NOMANDOC No or Sy NOMANDOC . Ns Ar target No (for a given target Ar target )
p Only used if .Sy MKMAN=yes . .DFLTy . t Sy MKMANZ .YorN Indicates whether manual pages should be compressed with .Xr gzip 1 at installation time.
p Only used if .Sy MKMAN=yes . .DFLTn . t Sy MKMCLINKER Obsolete. . t Sy MKMDNS .YorN Indicates whether the mDNS (Multicast DNS) infrastructure (libraries and support programs) will be built and installed. .DFLTy . t Sy MKNLS .YorN Indicates whether Native Language System (NLS) locale zone files will be built and installed. .NODEF NONLS .NOVAR MKSHARE=no .DFLTy . t Sy MKNOUVEAUFIRMWARE .YorN Indicates whether to install the
a /libdata/firmware/nouveau directory, which is necessary for the .Xr nouveau 4 NVIDIA video driver. .DFLTy on .Sy aarch64 , .Sy i386 , and .Sy x86_64 , .Dq no on other platforms. . t Sy MKNPF .YorN Indicates whether the NPF packet filter is to be built and installed. .DFLTy . t Sy MKNSD .YorN Indicates whether the Name Server Daemon (NSD) is to be built and installed. .DFLTn . t Sy MKOBJ .YorN Indicates whether object directories will be created when running .Dq make obj . If .Dq no , then all built files will be located inside the regular source tree. .NODEF NOOBJ
p If .Dq no , acts as .Sy MKOBJDIRS=no . .DFLTy . t Sy MKOBJDIRS .YorN Indicates whether object directories will be created automatically (via a .Dq make obj pass) at the start of a build. .NOVAR MKOBJ=no .DFLTn . t Sy MKPAM .YorN Indicates whether the .Xr pam 8 framework (libraries and support files) will be built and installed. The pre-PAM code is not supported and may be removed in the future. .DFLTy . t Sy MKPCC .YorN Indicates whether .Xr pcc 1 or any related libraries
q Sy libpcc , libpccsoftfloat will be built and installed. .DFLTn . t Sy MKPERFUSE Obsolete. . t Sy MKPF .YorN Indicates whether the .Xr pf 4 programs, headers, and LKM will be built and installed. .DFLTy . t Sy MKPIC .YorN Indicates whether shared objects and libraries will be created and installed. If .Dq no , the entire built system will be statically linked. .NODEF NOPIC
p If .Dq no , acts as .Sy MKPICLIB=no . .DFLTn on .Sy m68000 ; .Dq yes on other platforms. . t Sy MKPICINSTALL .YorN Indicates whether the .Xr ar 1 format libraries .Sy ( lib*_pic.a ) , used to generate shared libraries, are installed. .NODEF NOPICINSTALL .NOVAR MKLINKLIB=no .DFLTn . t Sy MKPICLIB .YorN Indicates whether the .Xr ar 1 format libraries .Sy ( lib*_pic.a ) , used to generate shared libraries. .NOVAR MKPIC=no .DFLTn on .Sy vax ; .Dq yes on other platforms. . t Sy MKPIE Indicates whether Position Independent Executables (PIE) will be built and installed. .NODEF NOPIE .NOVAR COVERITY_TOP_CONFIG No is defined
p This is disabled internally for standalone programs in
a /usr/mdec . .DFLTy on .Sy aarch64 , .Sy arm , .Sy i386 , .Sy m68k , .Sy mips , .Sy sh3 , .Sy sparc64 , and .Sy x86_64 ; .Dq no on other platforms. . t Sy MKPIGZGZIP .YorN If .Dq no , the .Xr pigz 1 utility is not installed as .Xr gzip 1 . .DFLTn . t Sy MKPOSTFIX .YorN Indicates whether Postfix will be built and installed. .DFLTy . t Sy MKPROFILE .YorN Indicates whether profiled libraries .Sy ( lib*_p.a ) will be built and installed. .NODEF NOPROFILE .NOVAR MKLINKLIB=no .DFLTn on .Sy or1k , .Sy riscv32 , and .Sy riscv64 (due to toolchain problems with profiled code); .Dq yes on other platforms. . t Sy MKRADEONFIRMWARE .YorN Indicates whether to install the
a /libdata/firmware/radeon directory, which is necessary for the .Xr radeon 4 AMD RADEON GPU video driver. .DFLTy on .Sy aarch64 , .Sy i386 , and .Sy x86_64 , .Dq no on other platforms. . t Sy MKRELRO Indicates whether to enable support for Relocation Read-Only (RELRO). Supported values: l -tag -width partial t partial Set the non-PLT GOT to read-only. t full Set the non-PLT GOT to read-only and also force immediate symbol binding, unless .Sy NOFULLRELRO is defined and not .Dq no (usually in the Makefile before any .Xr make 1 .Cm .include directives). t no Disable RELRO. .El .NODEF NORELRO .DFLT .Dq partial on .Sy aarch64 , .Sy i386 , and .Sy x86_64 ; .Dq no on other platforms. . t Sy MKREPRO .YorN Indicates whether builds are to be reproducible. If .Dq yes , two builds from the same source tree will produce the same build results.
p Used as the default for .Sy MKARZERO . .DFLTn . t Sy MKRUMP .YorN Indicates whether the .Xr rump 3 headers, libraries, and programs are to be installed. .NOVAR COVERITY_TOP_CONFIG No is defined .DFLTy . t Sy MKSANITIZER .YorN Indicates whether to use the sanitizer to compile userland programs, using the sanitizer defined by .Sy USE_SANITIZER . .NODEF NOSANITIZER .DFLTn . t Sy MKSHARE .YorN Indicates whether files destined to reside in .Sy DESTDIR Ns Pa /usr/share will be built and installed. .NODEF NOSHARE
p If .Dq no , acts as .Sy MKCATPAGES=no MKDOC=no MKINFO=no MKHTML=no MKMAN=no MKNLS=no . .DFLTy . t Sy MKSKEY .YorN Indicates whether the S/key infrastructure (libraries and support programs) will be built and installed. .DFLTy . t Sy MKSLJIT .YorN Indicates whether to enable support for sljit (stack-less platform-independent Just in Time (JIT) compiler) private library and tests. .DFLTy on .Sy i386 , .Sy sparc , and .Sy x86_64 ; .Dq no on other platforms. . t Sy MKSOFTFLOAT .YorN Indicates whether the compiler generates output containing library calls for floating point and possibly soft-float library support.
p Forced to .Dq yes on .Sy arm without .Sq hf , .Sy coldfire , .Sy emips , .Sy or1k , and .Sy sh3 . .DFLTy on .Sy mips64 ; .Dq no on other platforms. . t Sy MKSTATICLIB .YorN Indicates whether the normal static libraries .Sy ( lib*_g.a ) will be built and installed. .NODEF NOSTATICLIB .DFLTy . t Sy MKSTATICPIE .YorN Indicates whether support for static PIE binaries will be built and installed. .DFLTy on .Sy i386 and .Sy x86_64 ; .Dq no on other platforms. . t Sy MKSTRIPIDENT .YorN Indicates whether RCS IDs, for use with .Xr ident 1 , should be stripped from program binaries and shared libraries. .DFLTn . t Sy MKSTRIPSYM .YorN Indicates whether all local symbols should be stripped from shared libraries. If .Dq yes , strip all local symbols from shared libraries; the effect is equivalent to the .Fl x option of .Xr ld 1 . If .Dq no , strip only temporary local symbols; the effect is equivalent to the .Fl X option of .Xr ld 1 . Keeping non-temporary local symbols such as static function names is useful on using DTrace for userland libraries and getting a backtrace from a rump kernel loading shared libraries. .DFLTy . t Sy MKTEGRAFIRMWARE .YorN Indicates whether to install the
a /libdata/firmware/nvidia directory, which is necessary for the NVIDIA Tegra XHCI driver. .DFLTy on .Sy evbarm ; .Dq no on other platforms. . t Sy MKTOOLSDEBUG Deprecated, use .Sy MKDEBUGTOOLS . . t Sy MKTPM .YorN Indicates whether to install the Trusted Platform Module (TPM) infrastructure. .DFLTn . t Sy MKUNBOUND .YorN Indicates whether the .Xr unbound 8 DNS resolver will be built and installed. .DFLTy . t Sy MKUNPRIVED .YorN Indicates whether an unprivileged install will occur. The user, group, permissions, and file flags, will not be set on the installed item; instead the information will be appended to a file called
a METALOG in .Sy DESTDIR . The contents of
a METALOG is used during the generation of the distribution tar files to ensure that the appropriate file ownership is stored. .DFLTn . t Sy MKUPDATE .YorN Indicates whether all install operations intended to write to .Sy DESTDIR will compare file timestamps before installing, and skip the install phase if the destination files are up-to-date. This also has implications on full builds (see next subsection). .DFLTn . t Sy MKX11 .YorN Indicates whether X11 will be built and installed (by descending into
a src/external/mit/xorg ) . .DFLTn . t Sy MKX11FONTS .YorN If .Dq no , do not build and install the X fonts.
p Only used if .Sy MKX11=yes . .DFLTy . t Sy MKX11MOTIF .YorN If .Dq yes , build the native Xorg libGLw with Motif stubs. Requires that Motif can be found via .Sy X11MOTIFPATH . .DFLTn . t Sy MKXORG_SERVER .YorN Indicates whether the .Xr Xorg 7 X server and drivers will be built and installed. .DFLTy on .Sy alpha , .Sy amd64 , .Sy amiga , .Sy bebox , .Sy cats , .Sy dreamcast , .Sy ews4800mips , .Sy evbarm , .Sy evbmips , .Sy evbppc , .Sy hp300 , .Sy hpcarm , .Sy hpcmips , .Sy hpcsh , .Sy hppa , .Sy i386 , .Sy ibmnws , .Sy iyonix , .Sy luna68k , .Sy mac68k , .Sy macppc , .Sy netwinder , .Sy newsmips , .Sy pmax , .Sy prep , .Sy ofppc , .Sy sgimips , .Sy shark , .Sy sparc , .Sy sparc64 , .Sy vax , and .Sy zaurus ; .Dq no on other platforms. . t Sy MKYP .YorN Indicates whether the YP (NIS) infrastructure (libraries and support programs) will be built and installed. .DFLTy . t Sy MKZFS .YorN Indicates whether the ZFS kernel module and the utilities and libraries used to manage the ZFS system are to be built and installed. .DFLTy on .Sy aarch64 , .Sy amd64 , and .Sy sparc64 ; .Dq no on other platforms. . t Sy NETBSDSRCDIR The path to the top level of the .Nx sources. If .Xr make 1 is run from within the .Nx source tree, the default is the top level of that tree (as determined by the presence of
a build.sh and
a tools/ ) , otherwise .Sy BSDSRCDIR will be used. . t Sy NETBSD_OFFICIAL_RELEASE .YorN Indicates whether the build creates an official .Nx release which is going to be available from .Lk ftp.NetBSD.org and/or .Lk cdn.NetBSD.org locations. This variable modifies a few default paths in the installer and also creates different links in the install documentation. The auto-build cluster uses this variable to distinguish .Sq daily builds from real releases. .DFLTu
q Dq no . . t Sy OBJMACHINE If defined, creates objdirs of the form
a obj . Ns Sy MACHINE , where .Sy MACHINE is the current architecture (as per .Sq "uname -m" ) . . t Sy RELEASEDIR If set, specifies the directory to which a .Xr release 7 layout will be written at the end of a .Dq make release .
p .Em Note : .Sy build.sh will provide a default of .Dq Pa releasedir (in the top-level .Sy .OBJDIR ) unless run in .Sq expert mode. .DFLTu . t Sy SHAREDSTRINGS Obsolete. . t Sy TOOLDIR Directory to hold the host tools, once built. This directory should be unique to a given host system and .Nx source tree. (However, multiple targets may share the same .Sy TOOLDIR ; the target-dependent files have unique names.) If unset, a default based on the .Xr uname 1 information of the host platform will be created in the .Sy .OBJDIR of
a src . .DFLTu . t Sy USETOOLS Indicates whether the tools specified by .Sy TOOLDIR should be used as part of a build in progress. Must be set to .Dq yes if cross-compiling. Supported values: l -tag -width never t yes Use the tools from .Sy TOOLDIR . t no Do not use the tools from .Sy TOOLDIR , but refuse to build native compilation tool components that are version-specific for that tool. t never Do not use the tools from .Sy TOOLDIR , even when building native tool components. This is similar to the traditional .Nx build method, but does .Em not verify that the compilation tools in use are up-to-date enough in order to build the tree successfully. This may cause build or runtime problems when building the whole .Nx source tree. .El .DFLT .Dq yes if building all or part of a whole .Nx source tree (detected automatically); .Dq no otherwise (to preserve traditional semantics of the .Aq bsd.*.mk .Xr make 1 include files). . t Sy USE_COMBINE Obsolete. . t Sy USE_FORT .YorN Indicates whether the so-called .Dq FORTIFY_SOURCE .Xr security 7 extensions are enabled; see .Xr ssp 3 for details. This imposes some performance penalty. .NODEF NOFORT .DFLTn . t Sy USE_HESIOD .YorN Indicates whether Hesiod support is enabled in the various applications that support it. .NOVAR MKHESIOD=no .DFLTy . t Sy USE_INET6 .YorN Indicates whether INET6 (IPv6) support is enabled in the various applications that support it. .NOVAR MKINET6=no .DFLTy . t Sy USE_JEMALLOC .YorN Indicates whether the .Em jemalloc allocator
q which is designed for improved performance with threaded applications is used instead of the .Em phkmalloc allocator
q that was the default until Nx 5.0 . .DFLTy . t Sy USE_KERBEROS .YorN Indicates whether Kerberos v5 support is enabled in the various applications that support it. .NOVAR MKKERBEROS=no .DFLTy . t Sy USE_LDAP .YorN Indicates whether LDAP support is enabled in the various applications that support it. .NOVAR MKLDAP=no .DFLTy . t Sy USE_LIBCSANITIZER Selects the sanitizer in libc to compile userland programs and libraries. Supported values: l -tag -width undefined t undefined Enables the micro-UBSan in the user mode (uUBSan) undefined behaviour sanitizer, with .Li -fsanitize=no-vptr as that sanitizer is not supported. .El
p The value of .Sy USE_LIBCSANITIZER is passed to the C and C++ compilers as the argument to .Li -fsanitize= . Additional sanitizer arguments can be passed through .Sy LIBCSANITIZERFLAGS .
p Disabled if .Sy MKLIBCSANITIZER=no . .DFLT .Dq undefined . . t Sy USE_PAM .YorN Indicates whether .Xr pam 8 support is enabled in the various applications that support it. .NOVAR MKPAM=no .DFLTy . t Sy USE_PIGZGZIP .YorN Indicates whether .Xr pigz 1 is used instead of .Xr gzip 1 for multi-threaded gzip compression of the distribution tar sets. .DFLTn . t Sy USE_SANITIZER Selects the sanitizer to compile userland programs and libraries. Supported (one or more, comma-separated) values: l -tag -width safe-stack t address A memory error detector. t cfi A control flow detector. t dataflow A general data flow analysis. t leak A memory leak detector. t memory An uninitialized memory read detector. t safe-stack Protect against stack-based corruption. t scudo The Scudo Hardened Allocator. t thread A data race detector. t undefined An undefined behavior detector. .El
p The value of .Sy USE_SANITIZER is passed to the C and C++ compilers as the argument to .Li -fsanitize= . Additional sanitizer arguments can be passed through .Sy SANITIZERFLAGS .
p The list of supported features and their valid combinations depends on the compiler version and target CPU architecture.
p Disabled if .Sy MKSANITIZER=no . .DFLT .Dq address . . t Sy USE_SKEY .YorN Indicates whether S/key support is enabled in the various applications that support it. .NOVAR MKSKEY=no
p .Em Note : This is mutually exclusive to .Sy USE_PAM!=no . .DFLTn . t Sy USE_SSP .YorN Indicates whether GCC stack-smashing protection (SSP) support, which detects stack overflows and aborts the program, is enabled. This imposes some performance penalty.
p This is disabled internally for standalone programs in
a /usr/mdec . .NODEF NOSSP .NOVAR COVERITY_TOP_CONFIG No is defined .DFLTn on .Sy alpha , .Sy hppa , .Sy ia64 , and .Sy mips ; .Dq yes on other platforms. . t Sy USE_XZ_SETS .YorN Indicates whether the distribution tar files are to be compressed with .Xr xz 1 instead of .Xr gzip 1 or .Xr pigz 1 . .NOVAR USE_PIGZGZIP=yes .DFLTy on .Sy aarch64 , .Sy amd64 , and .Sy sparc64 , .Dq no on other platforms. . t Sy USE_YP .YorN Indicates whether YP (NIS) support is enabled in the various applications that support it. .NOVAR MKYP=no .DFLTy . t Sy X11MOTIFPATH Path of the Motif installation to use if .Sy MKX11MOTIF=yes . .DFLT .Dq Pa /usr/pkg . .El . .Ss pkgsrc system variables . Please see the pkgsrc guide at .Lk http://www.netbsd.org/Documentation/pkgsrc/ or
a pkgsrc/doc/pkgsrc.txt for more variables used internally by the package system and
a ${PKGSRCDIR}/mk/defaults/mk.conf for package-specific examples. . .Sh FILES l -tag -width /etc/mk.conf . t Pa /etc/mk.conf This file. . t Pa ${PKGSRCDIR}/mk/defaults/mk.conf Examples for settings regarding the pkgsrc collection. .El . .Sh SEE ALSO .Xr apropos 1 , .Xr ar 1 , .Xr as 1 , .Xr clang 1 , .Xr clang++ 1 , .Xr cpio 1 , .Xr cvs 1 , .Xr dtrace 1 , .Xr g++ 1 , .Xr gcc 1 , .Xr gdb 1 , .Xr groff 1 , .Xr gzip 1 , .Xr ident 1 , .Xr ld 1 , .Xr ld.elf_so 1 , .Xr lint 1 , .Xr ls 1 , .Xr make 1 , .Xr mandoc 1 , .Xr pax 1 , .Xr pcc 1 , .Xr pigz 1 , .Xr sh 1 , .Xr tar 1 , .Xr uname 1 , .Xr whatis 1 , .Xr xz 1 , .Xr rump 3 , .Xr ssp 3 , .Xr amdgpu 4 , .Xr athn 4 , .Xr bcm43xx 4 , .Xr bwfm 4 , .Xr ipf 4 , .Xr ipw 4 , .Xr iwi 4 , .Xr iwm 4 , .Xr iwn 4 , .Xr nouveau 4 , .Xr options 4 , .Xr otus 4 , .Xr pf 4 , .Xr radeon 4 , .Xr ral 4 , .Xr rtwn 4 , .Xr rum 4 , .Xr run 4 , .Xr urtwn 4 , .Xr wpi 4 , .Xr zyd 4 , .Xr pam.conf 5 , .Xr release 7 , .Xr security 7 , .Xr Xorg 7 , .Xr dbsym 8 , .Xr getNAME 8 , .Xr makemandb 8 , .Xr makewhatis 8 , .Xr mdsetimage 8 , .Xr pam 8 , .Xr unbound 8 ,
a /usr/share/mk/bsd.README ,
a pkgsrc/doc/pkgsrc.txt , .Lk http://www.netbsd.org/Documentation/pkgsrc/ .Sh HISTORY The .Nm file appeared in .Nx 1.2 .