4 .\" Redistribution and use in source and binary forms, with or without
5 .\" modification, are permitted provided that the following conditions
7 .\" 1. Redistributions of source code must retain the above copyright
8 .\" notice, this list of conditions and the following disclaimer.
9 .\" 2. Redistributions in binary form must reproduce the above copyright
10 .\" notice, this list of conditions and the following disclaimer in the
11 .\" documentation and/or other materials provided with the distribution.
13 .\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND
14 .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
15 .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
16 .\" ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR BE LIABLE
17 .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
18 .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
19 .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
20 .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
21 .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
22 .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
32 .Nd system build information
36 contains system-wide settings that will apply to every build using
41 This is achieved as follows:
43 processes the system makefile
45 before any other file by default, and
52 uses the standard makefile syntax.
55 should not specify any dependencies to
61 variables that control the actions of other makefiles.
63 The default location of
67 though an alternative location can be specified in the
71 You may need to override the location of
73 if the system-wide settings are not suitable for a particular build.
78 effectively resets all build controls to their defaults.
80 The primary purpose of
82 is to control the compilation of the
84 sources, documentation, and ported applications,
85 which are usually found in
90 As a rule, the system administrator creates
92 when the values of certain control variables need to be changed
95 The system build procedures occur in four broad areas:
96 the world, the kernel, documentation and ports.
99 may be applicable in one, two, or all four of these areas.
100 In addition, control variables can be specified
101 for a particular build via the
108 The following lists provide a name and short description for each
109 variable you can use during the indicated builds.
113 are ignored; the variable being
119 be treated as if it were set.
121 The following list provides a name and short description for variables
122 that are used for all builds, or are used by the
124 for things other than builds.
126 .It Va ALWAYS_CHECK_MAKE
128 Instructs the top-level makefile in the source tree (normally
133 Normally this is only done for the world and buildworld targets to handle
134 upgrades from older versions of
138 Controls the compiler setting when compiling C code.
139 Optimization levels other than
145 is provided as a set of
147 settings suggested by
148 .An "Bruce Evans" Aq bde@FreeBSD.org
149 for developing and testing changes.
150 They can be used, if set, by:
151 .Bd -literal -offset indent
156 Controls which processor should be targeted for generated
158 This controls processor-specific optimizations in
159 certain code (currently only OpenSSL) as well as modifying
164 to contain the appropriate optimization directive to
166 The automatic setting of
170 may be overridden using the
174 variables, respectively.
176 .Pa /usr/share/examples/etc/make.conf
177 for a list of recognized
189 .Dq Li "make update" .
192 Controls the compiler settings when compiling C++ code.
194 is initially set to the value of
208 .Dq Li "make update" .
210 .Pa /usr/share/examples/cvsup/doc-supfile .
213 the default install command.
214 To install only files for which the target differs or does not exist, use
215 .Bd -literal -offset indent
218 Note that some makefiles (including those in
220 may hardcode options for the supplied install command.
223 List any directories that should be entered when doing
229 Controls the shell used internally by
231 to process the command scripts in makefiles.
236 all currently supported.
239 .It Va MTREE_FOLLOWS_SYMLINKS
248 Setting this variable will prevent CPU specific compiler flags
249 from being automatically added to
252 .It Va NO_CPU_COPTFLAGS
254 Setting this variable will prevent CPU specific compiler flags
255 from being automatically added to
260 Set this to not update the doc tree during
261 .Dq Li "make update" .
262 .It Va NO_PORTSUPDATE
264 Set this to not update the ports tree during
265 .Dq Li "make update" .
268 Set this to not update the www tree during
269 .Dq Li "make update" .
275 .Dq Li "make update" .
277 .Pa /usr/share/examples/cvsup/ports-supfile .
285 .Dq Li "make update" .
291 .Dq Li "make update" .
293 .Pa /usr/share/examples/cvsup/standard-supfile .
299 .Dq Li "make update" .
305 .Dq Li "make update" .
311 .Dq Li "make update" .
316 The hostname of the sup server to use when doing
317 .Dq Li "make update" .
323 .Pa src , ports , doc
327 .Dq Li "make update" .
335 .Dq Li "make update" .
341 .Dq Li "make update" .
343 .Pa /usr/share/examples/cvsup/www-supfile .
345 .Ss "BUILDING THE KERNEL"
346 The following list provides a name and short description for variables
347 that are only used doing a kernel build:
351 Controls the amount of time the kernel waits for a console keypress
352 before booting the default kernel.
353 The value is approximately milliseconds.
354 Keypresses are accepted by the BIOS before booting from disk,
355 making it possible to give custom boot parameters even when this is
359 Controls the compiler settings when building the
361 Optimization levels above
362 .Oo Fl O ( O2 , No ...\& ) Oc
363 are not guaranteed to work.
366 Controls which kernel configurations will be
368 .Dq Li "${MAKE} buildkernel"
370 .Dq Li "${MAKE} installkernel" .
372 .Bd -literal -offset indent
373 KERNCONF=MINE DEBUG GENERIC OTHERMACHINE
376 will build the kernels specified by the config files
377 .Pa MINE , DEBUG , GENERIC ,
380 and install the kernel specified by the config file
384 .It Va MODULES_OVERRIDE
386 Set to a list of modules to build instead of all of them.
387 .It Va NO_KERNELCLEAN
389 Set this to skip running
390 .Dq Li "${MAKE} clean"
392 .Dq Li "${MAKE} buildkernel" .
393 .It Va NO_KERNELCONFIG
395 Set this to skip running
398 .Dq Li "${MAKE} buildkernel" .
399 .It Va NO_KERNELDEPEND
401 Set this to skip running
402 .Dq Li "${MAKE} depend"
404 .Dq Li "${MAKE} buildkernel" .
407 Set this to skip running
410 .Dq Li "${MAKE} buildkernel" .
413 Set to not build modules with the kernel.
415 Set this to the list of ports you wish to rebuild every time the kernel
417 .It Va WITHOUT_MODULES
419 Set to a list of modules to exclude from the build.
421 somewhat easier way to exclude modules you are certain you will never
423 .Va MODULES_OVERRIDE .
426 .Va MODULES_OVERRIDE .
428 .Ss "BUILDING THE WORLD"
429 The following list provides a name and short description for variables
430 that are used during the world build:
432 .It Va BOOT_COMCONSOLE_PORT
434 The port address to use for the console if the boot blocks have
435 been configured to use a serial console instead of the keyboard/video card.
436 .It Va BOOT_COMCONSOLE_SPEED
438 The baud rate to use for the console if the boot blocks have
439 been configured to use a serial console instead of the keyboard/video card.
440 .It Va BOOT_PXELDR_ALWAYS_SERIAL
442 Compile in the code into
444 that forces the use of a serial console.
445 This is analogous to the
450 .It Va BOOT_PXELDR_PROBE_KEYBOARD
452 Compile in the code into
454 that probes the keyboard.
455 If no keyboard is found, boot with the dual console configuration.
456 This is analogous to the
461 .It Va ENABLE_SUID_K5SU
463 Set this if you wish to use the ksu utility.
464 Otherwise, it will be
465 installed without the set-user-ID bit set.
466 .It Va ENABLE_SUID_NEWGRP
470 with the set-user-ID bit set.
473 will not be able to change users' groups.
474 .It Va ENABLE_SUID_SSH
478 with the set-user-ID bit turned on.
479 .It Va LOADER_TFTP_SUPPORT
483 loader retrieves the kernel via NFS.
484 Defining this and recompiling
485 .Pa /usr/src/sys/boot
486 will cause it to retrieve the kernel via TFTP.
489 to load a custom BOOTP diskless kernel yet
490 still mount the server's
492 rather than load the server's kernel.
493 .It Va LOADER_FIREWIRE_SUPPORT
495 Defining this and recompiling
496 .Pa /usr/src/sys/boot/i386
501 and allow access over FireWire(IEEE1394) using
503 Currently, only i386 and amd64 are supported.
504 .It Va MALLOC_PRODUCTION
506 Set this to disable assertions and statistics gathering in
508 It also defaults the A and J runtime options to off.
509 Disabled by default on -CURRENT.
510 .It Va MODULES_WITH_WORLD
512 Set to build modules with the system instead of the kernel.
515 Set this to disable cleaning during
516 .Dq Li "make buildworld" .
517 This should not be set unless you know what you are doing.
521 .Dq Li "${MAKE} clean"
523 .Dq Li "${MAKE} cleandir" .
524 .It Va NO_MANCOMPRESS
526 Set to install manual pages uncompressed.
529 Set to not build in the
538 statically linked, this can be bad.
539 If set, every utility that uses
541 will be linked statically.
546 without support for network address translation (NAT).
547 .It Va PPP_NO_NETGRAPH
551 without support for Netgraph.
556 without support for RADIUS.
559 Set to disable the installation of
561 as a set-user-ID root program.
562 .It Va SENDMAIL_ADDITIONAL_MC
566 files which should be built into
569 The value should include the full path to the
573 .Pa /etc/mail/bar.mc .
574 .It Va SENDMAIL_ALIASES
578 files to rebuild when using
579 .Pa /etc/mail/Makefile .
581 .Pa /etc/mail/aliases .
582 .It Va SENDMAIL_CFLAGS
584 Flags to pass to the compile command when building
588 flags can be used to provide SASL support with setting such as:
589 .Bd -literal -offset indent
590 SENDMAIL_CFLAGS=-I/usr/local/include -DSASL
591 SENDMAIL_LDFLAGS=-L/usr/local/lib
592 SENDMAIL_LDADD=-lsasl
594 .It Va SENDMAIL_CF_DIR
596 Override the default location for the
598 configuration files used to build a
603 .It Va SENDMAIL_DPADD
605 Extra dependencies to add when building
607 .It Va SENDMAIL_LDADD
609 Flags to add to the end of the
611 command when building
613 .It Va SENDMAIL_LDFLAGS
617 command when building
619 .It Va SENDMAIL_M4_FLAGS
628 .It Va SENDMAIL_MAP_PERMS
630 Mode to use when generating alias and map database files using
631 .Pa /etc/mail/Makefile .
632 The default value is 0640.
633 .It Va SENDMAIL_MAP_SRC
635 Additional maps to rebuild when using
636 .Pa /etc/mail/Makefile .
646 maps are always rebuilt if they exist.
647 .It Va SENDMAIL_MAP_TYPE
649 Database map type to use when generating map database files using
650 .Pa /etc/mail/Makefile .
651 The default value is hash.
652 The alternative is btree.
657 configuration file to use at install time.
658 The value should include the full path to the
661 .Pa /etc/mail/myconfig.mc .
662 Use with caution as a make install will overwrite any existing
663 .Pa /etc/mail/sendmail.cf .
667 .It Va SENDMAIL_SET_USER_ID
671 as a set-user-ID root binary instead of a set-group-ID binary
673 .Pa /etc/mail/submit.{cf,mc} .
674 Use of this flag is not recommended and the alternative advice in
676 should be followed instead if at all possible.
677 .It Va SENDMAIL_START_SCRIPT
680 .Pa /etc/mail/Makefile
681 to start, stop, and restart
684 .Pa /etc/rc.sendmail .
685 This value should match the
686 .Dq Li mta_start_script
689 .It Va SENDMAIL_SUBMIT_MC
693 configuration file for mail submission
694 to use at install time.
695 The value should include the full path to the
698 .Pa /etc/mail/mysubmit.mc .
699 Use with caution as a make install will overwrite any existing
700 .Pa /etc/mail/submit.cf .
701 .It Va TOP_TABLE_SIZE
704 uses a hash table for the user names.
705 The size of this hash can be tuned to match the number of local users.
706 The table size should be a prime number
707 approximately twice as large as the number of lines in
709 The default number is 20011.
710 .It Va WANT_FORCE_OPTIMIZATION_DOWNGRADE
712 Causes the system compiler to be built such that it forces high optimization
713 levels to a lower one.
716 and above is known to trigger known optimizer bugs at various
718 The value assigned is the highest optimization value used.
720 .Ss "BUILDING DOCUMENTATION"
721 The following list provides a name and short description for variables
722 that are used when building documentation.
723 .Bl -tag -width ".Va PRINTERDEVICE"
726 Where distfiles are kept.
733 The list of languages and encodings to build and install.
736 The default format for system documentation, depends on your
740 for simple printers, or
742 for postscript or graphics printers with a ghostscript
746 .Bl -tag -width ".Pa /usr/share/examples/etc/make.conf" -compact
747 .It Pa /etc/make.conf
748 .It Pa /usr/doc/Makefile
749 .It Pa /usr/ports/Makefile
750 .It Pa /usr/share/examples/etc/make.conf
751 .It Pa /usr/share/mk/sys.mk
752 .It Pa /usr/src/Makefile
753 .It Pa /usr/src/Makefile.inc1
766 file appeared sometime before
770 manual page was written by
771 .An Mike W. Meyer Aq mwm@mired.org .
777 are environment variables and should not be set in
779 but in make's environment.
781 This manual page may occasionally be out of date with respect to
782 the options currently available for use in
785 .Pa /usr/share/examples/etc/make.conf
786 file for the latest options which are available.