1786aa69aSBen Smithurst.\" Copyright (c) 2000 2786aa69aSBen Smithurst.\" Mike W. Meyer 3786aa69aSBen Smithurst.\" 4786aa69aSBen Smithurst.\" Redistribution and use in source and binary forms, with or without 5786aa69aSBen Smithurst.\" modification, are permitted provided that the following conditions 6786aa69aSBen Smithurst.\" are met: 7786aa69aSBen Smithurst.\" 1. Redistributions of source code must retain the above copyright 8786aa69aSBen Smithurst.\" notice, this list of conditions and the following disclaimer. 9786aa69aSBen Smithurst.\" 2. Redistributions in binary form must reproduce the above copyright 10786aa69aSBen Smithurst.\" notice, this list of conditions and the following disclaimer in the 11786aa69aSBen Smithurst.\" documentation and/or other materials provided with the distribution. 12786aa69aSBen Smithurst.\" 13786aa69aSBen Smithurst.\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND 14786aa69aSBen Smithurst.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 15786aa69aSBen Smithurst.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 16786aa69aSBen Smithurst.\" ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR BE LIABLE 17786aa69aSBen Smithurst.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 18786aa69aSBen Smithurst.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 19786aa69aSBen Smithurst.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 20786aa69aSBen Smithurst.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 21786aa69aSBen Smithurst.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 22786aa69aSBen Smithurst.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 23786aa69aSBen Smithurst.\" SUCH DAMAGE. 24786aa69aSBen Smithurst.\" 25786aa69aSBen Smithurst.\" $FreeBSD$ 26786aa69aSBen Smithurst.\" 274b2cc4d1SKyle Evans.Dd August 16, 2018 28786aa69aSBen Smithurst.Dt BUILD 7 293d45e180SRuslan Ermilov.Os 30786aa69aSBen Smithurst.Sh NAME 31786aa69aSBen Smithurst.Nm build 32eb083802SRuslan Ermilov.Nd information on how to build the system 33786aa69aSBen Smithurst.Sh DESCRIPTION 347b710ab2SJoseph KoshyThe sources for the 35d003b779SRuslan Ermilov.Fx 367b710ab2SJoseph Koshysystem and its applications are contained in three different directories, 37786aa69aSBen Smithurstnormally 38786aa69aSBen Smithurst.Pa /usr/src , 39786aa69aSBen Smithurst.Pa /usr/doc , 40786aa69aSBen Smithurstand 41786aa69aSBen Smithurst.Pa /usr/ports . 4250a994c9SWarren BlockThese directories may be initially empty or non-existent until updated with 43d335e7a1SGavin Atkinson.Xr svn 1 4450a994c9SWarren Blockor 45c046b2a9SAlexander Leidinger.Xr svnlite 1 46c046b2a9SAlexander Leidingeror 47d732418bSWarren Block.Xr portsnap 8 . 487b710ab2SJoseph KoshyDirectory 49786aa69aSBen Smithurst.Pa /usr/src 50786aa69aSBen Smithurstcontains the 51786aa69aSBen Smithurst.Dq "base system" 52786aa69aSBen Smithurstsources, which is loosely defined as the things required to rebuild 53786aa69aSBen Smithurstthe system to a useful state. 547b710ab2SJoseph KoshyDirectory 55786aa69aSBen Smithurst.Pa /usr/doc 56786aa69aSBen Smithurstcontains the source for the system documentation, excluding the manual 57786aa69aSBen Smithurstpages. 587b710ab2SJoseph KoshyDirectory 59786aa69aSBen Smithurst.Pa /usr/ports 607b710ab2SJoseph Koshycontains a tree that provides a consistent interface for building and 61786aa69aSBen Smithurstinstalling third party applications. 627b710ab2SJoseph KoshyFor more information about the ports build process, see 637b710ab2SJoseph Koshy.Xr ports 7 . 64786aa69aSBen Smithurst.Pp 65786aa69aSBen SmithurstThe 66786aa69aSBen Smithurst.Xr make 1 67786aa69aSBen Smithurstcommand is used in each of these directories to build and install the 681caae057SRuslan Ermilovthings in that directory. 691caae057SRuslan ErmilovIssuing the 701caae057SRuslan Ermilov.Xr make 1 711caae057SRuslan Ermilovcommand in any directory or 72786aa69aSBen Smithurstsubdirectory of those directories has the same effect as issuing the 731caae057SRuslan Ermilovsame command in all subdirectories of that directory. 741caae057SRuslan ErmilovWith no target specified, the things in that directory are just built. 757b710ab2SJoseph Koshy.Pp 767b710ab2SJoseph KoshyA source tree is allowed to be read-only. 777b710ab2SJoseph KoshyAs described in 787b710ab2SJoseph Koshy.Xr make 1 , 797b710ab2SJoseph Koshyobjects are usually built in a separate object directory hierarchy 807b710ab2SJoseph Koshyspecified by the environment variable 817b710ab2SJoseph Koshy.Va MAKEOBJDIRPREFIX , 827b710ab2SJoseph Koshyor under 837b710ab2SJoseph Koshy.Pa /usr/obj 847b710ab2SJoseph Koshyif variable 857b710ab2SJoseph Koshy.Va MAKEOBJDIRPREFIX 867b710ab2SJoseph Koshyis not set. 87dfa09989SBryan DreweryThe canonical object directory is described in the documentation for the 887b710ab2SJoseph Koshy.Cm buildworld 897b710ab2SJoseph Koshytarget below. 907b710ab2SJoseph Koshy.Pp 917b710ab2SJoseph KoshyThe build may be controlled by defining 927b710ab2SJoseph Koshy.Xr make 1 937b710ab2SJoseph Koshyvariables described in the 947b710ab2SJoseph Koshy.Sx ENVIRONMENT 957b710ab2SJoseph Koshysection below, and by the variables documented in 967b710ab2SJoseph Koshy.Xr make.conf 5 . 977b710ab2SJoseph Koshy.Pp 987b710ab2SJoseph KoshyThe following list provides the names and actions for the targets 997b710ab2SJoseph Koshysupported by the build system: 1007b710ab2SJoseph Koshy.Bl -tag -width ".Cm cleandepend" 101aae63957SBryan Drewery.It Cm analyze 102aae63957SBryan DreweryRun Clang static analyzer against all objects and present output on stdout. 10371b7fa12SEnji Cooper.It Cm check 10471b7fa12SEnji CooperRun tests for a given subdirectory. 10571b7fa12SEnji CooperThe default directory used is 10671b7fa12SEnji Cooper.Pa ${.OBJDIR} , 10771b7fa12SEnji Cooperbut the check directory can be changed with 10871b7fa12SEnji Cooper.Pa ${CHECKDIR} . 10971b7fa12SEnji Cooper.It Cm checkworld 11071b7fa12SEnji CooperRun the 11171b7fa12SEnji Cooper.Fx 11271b7fa12SEnji Coopertest suite on installed world. 1131caae057SRuslan Ermilov.It Cm clean 1147b710ab2SJoseph KoshyRemove any files created during the build process. 1157b710ab2SJoseph Koshy.It Cm cleandepend 116497e8091SBryan DreweryRemove the 117497e8091SBryan Drewery.Pa ${.OBJDIR}/${DEPENDFILE}* 118497e8091SBryan Dreweryfiles generated by prior 119497e8091SBryan Drewery.Dq Li "make" 120497e8091SBryan Dreweryand 1217b710ab2SJoseph Koshy.Dq Li "make depend" 122497e8091SBryan Drewerysteps. 1237b710ab2SJoseph Koshy.It Cm cleandir 1247b710ab2SJoseph KoshyRemove the canonical object directory if it exists, or perform 1257b710ab2SJoseph Koshyactions equivalent to 1267b710ab2SJoseph Koshy.Dq Li "make clean cleandepend" 1277b710ab2SJoseph Koshyif it does not. 1287b710ab2SJoseph KoshyThis target will also remove an 1297b710ab2SJoseph Koshy.Pa obj 1307b710ab2SJoseph Koshylink in 1317b710ab2SJoseph Koshy.Pa ${.CURDIR} 1327b710ab2SJoseph Koshyif that exists. 1337b710ab2SJoseph Koshy.Pp 1347b710ab2SJoseph KoshyIt is advisable to run 1357b710ab2SJoseph Koshy.Dq Li "make cleandir" 1367b710ab2SJoseph Koshytwice: the first invocation will remove the canonical object directory 1377b710ab2SJoseph Koshyand the second one will clean up 1387b710ab2SJoseph Koshy.Pa ${.CURDIR} . 1397b710ab2SJoseph Koshy.It Cm depend 1407b710ab2SJoseph KoshyGenerate a list of build dependencies in file 1417b710ab2SJoseph Koshy.Pa ${.OBJDIR}/${DEPENDFILE} . 142497e8091SBryan DreweryPer-object dependencies are generated at build time and stored in 143497e8091SBryan Drewery.Pa ${.OBJDIR}/${DEPENDFILE}.${OBJ} . 1441caae057SRuslan Ermilov.It Cm install 1457b710ab2SJoseph KoshyInstall the results of the build to the appropriate location in the 1467b710ab2SJoseph Koshyinstallation directory hierarchy specified in variable 1477b710ab2SJoseph Koshy.Va DESTDIR . 1487b710ab2SJoseph Koshy.It Cm obj 1497b710ab2SJoseph KoshyCreate the canonical object directory associated with the current 1507b710ab2SJoseph Koshydirectory. 1517b710ab2SJoseph Koshy.It Cm objlink 1527b710ab2SJoseph KoshyCreate a symbolic link to the canonical object directory in 1537b710ab2SJoseph Koshy.Pa ${.CURDIR} . 1547b710ab2SJoseph Koshy.It Cm tags 1557b710ab2SJoseph KoshyGenerate a tags file using the program specified in the 1567b710ab2SJoseph Koshy.Xr make 1 1577b710ab2SJoseph Koshyvariable 1587b710ab2SJoseph Koshy.Va CTAGS . 1597b710ab2SJoseph KoshyThe build system supports 1607b710ab2SJoseph Koshy.Xr ctags 1 1617b710ab2SJoseph Koshyand 1627b710ab2SJoseph Koshy.Nm "GNU Global" . 1637b710ab2SJoseph Koshy.El 1647b710ab2SJoseph Koshy.Pp 1657b710ab2SJoseph KoshyThe other supported targets under directory 1667b710ab2SJoseph Koshy.Pa /usr/src 1677b710ab2SJoseph Koshyare: 1687b710ab2SJoseph Koshy.Bl -tag -width ".Cm distributeworld" 1697b710ab2SJoseph Koshy.It Cm buildenv 1707b710ab2SJoseph KoshySpawn an interactive shell with environment variables set up for 1717b710ab2SJoseph Koshycross-building the system. 1727b710ab2SJoseph KoshyThe target architecture needs to be specified with 1737b710ab2SJoseph Koshy.Xr make 1 1747b710ab2SJoseph Koshyvariables 1757b710ab2SJoseph Koshy.Va TARGET_ARCH 1767b710ab2SJoseph Koshyand 1777b710ab2SJoseph Koshy.Va TARGET . 1787b710ab2SJoseph Koshy.Pp 1797b710ab2SJoseph KoshyThis target is only useful after a complete cross-toolchain including 1807b710ab2SJoseph Koshythe compiler, linker, assembler, headers and libraries has been 1817b710ab2SJoseph Koshybuilt; see the 1827b710ab2SJoseph Koshy.Cm toolchain 1837b710ab2SJoseph Koshytarget below. 1847b710ab2SJoseph Koshy.It Cm buildworld 1857b710ab2SJoseph KoshyBuild everything but the kernel, configure files in 1867b710ab2SJoseph Koshy.Pa etc , 1877b710ab2SJoseph Koshyand 1887b710ab2SJoseph Koshy.Pa release . 189d90f12e3SWarren BlockThe object directory can be changed from the default 190d90f12e3SWarren Block.Pa /usr/obj 191d90f12e3SWarren Blockby setting the 192d90f12e3SWarren Block.Pa MAKEOBJDIRPREFIX 193d90f12e3SWarren Block.Xr make 1 194d90f12e3SWarren Blockvariable. 195dfa09989SBryan DreweryThe actual build location prefix used 196dfa09989SBryan Drewerydepends on the 197dfa09989SBryan Drewery.Va WITH_UNIFIED_OBJDIR 198dfa09989SBryan Dreweryoption from 199dfa09989SBryan Drewery.Xr src.conf 5 . 200dfa09989SBryan DreweryIf enabled it is 201dfa09989SBryan Drewery.Pa ${MAKEOBJDIRPREFIX}${.CURDIR}/${TARGET}.${TARGET_ARCH} 202dfa09989SBryan Dreweryfor all builds. 203dfa09989SBryan DreweryIf disabled it is 2047b710ab2SJoseph Koshy.Pa ${MAKEOBJDIRPREFIX}${.CURDIR} 2057b710ab2SJoseph Koshyfor native builds, and 206dfa09989SBryan Drewery.Pa ${MAKEOBJDIRPREFIX}/${TARGET}.${TARGET_ARCH}${.CURDIR} 2077b710ab2SJoseph Koshyfor cross builds and native builds with variable 2087b710ab2SJoseph Koshy.Va CROSS_BUILD_TESTING 2097b710ab2SJoseph Koshyset. 2107b710ab2SJoseph Koshy.It Cm cleanworld 2117b710ab2SJoseph KoshyAttempt to clean up targets built by a preceding 212c10062b9SBryan Drewery.Cm buildworld , 213c10062b9SBryan Dreweryor similar step built from this source directory. 214c10062b9SBryan Drewery.It Cm cleanuniverse 215c10062b9SBryan DreweryWhen 216c10062b9SBryan Drewery.Va WITH_UNIFIED_OBJDIR 217c10062b9SBryan Dreweryis enabled, attempt to clean up targets built by a preceding 218c10062b9SBryan Drewery.Cm buildworld , 219c10062b9SBryan Drewery.Cm universe , 220c10062b9SBryan Dreweryor similar step, for any architecture built from this source directory. 2217b710ab2SJoseph Koshy.It Cm distributeworld 2227b710ab2SJoseph KoshyDistribute everything compiled by a preceding 2237b710ab2SJoseph Koshy.Cm buildworld 2247b710ab2SJoseph Koshystep. 2257b710ab2SJoseph KoshyFiles are placed in the directory hierarchy specified by 2267b710ab2SJoseph Koshy.Xr make 1 2277b710ab2SJoseph Koshyvariable 2287b710ab2SJoseph Koshy.Va DISTDIR . 2297b710ab2SJoseph KoshyThis target is used while building a release; see 2307b710ab2SJoseph Koshy.Xr release 7 . 2317441e255SBryan Drewery.It Cm native-xtools 2327441e255SBryan DreweryThis target builds a cross-toolchain for the given 2337441e255SBryan Drewery.Sy TARGET 2347441e255SBryan Dreweryand 2357441e255SBryan Drewery.Sy TARGET_ARCH , 2367441e255SBryan Dreweryas well as a select list of static userland tools for the host system. 2377441e255SBryan DreweryThis is intended to be used in a jail where QEMU is used to improve 2387441e255SBryan Dreweryperformance by avoiding emulating binaries that do not need to be emulated. 2397441e255SBryan Drewery.Sy TARGET 2407441e255SBryan Dreweryand 2417441e255SBryan Drewery.Sy TARGET_ARCH 2427441e255SBryan Dreweryshould be defined. 2435bd47cc5SBryan Drewery.It Cm native-xtools-install 2445bd47cc5SBryan DreweryInstalls the results to 2455bd47cc5SBryan Drewery.Pa ${DESTDIR}/${NXTP} 2465bd47cc5SBryan Drewerywhere 2475bd47cc5SBryan Drewery.Va NXTP 2485bd47cc5SBryan Drewerydefaults to 2495bd47cc5SBryan Drewery.Pa nxb-bin . 2505bd47cc5SBryan Drewery.Sy TARGET 2515bd47cc5SBryan Dreweryand 2525bd47cc5SBryan Drewery.Sy TARGET_ARCH 2535bd47cc5SBryan Drewerymust be defined. 254e8423d00SNathan Whitehorn.It Cm packageworld 255e8423d00SNathan WhitehornArchive the results of 256e8423d00SNathan Whitehorn.Cm distributeworld , 257e8423d00SNathan Whitehornplacing the results in 258e8423d00SNathan Whitehorn.Va DISTDIR . 259e8423d00SNathan WhitehornThis target is used while building a release; see 260e8423d00SNathan Whitehorn.Xr release 7 . 2617b710ab2SJoseph Koshy.It Cm installworld 2627b710ab2SJoseph KoshyInstall everything built by a preceding 2637b710ab2SJoseph Koshy.Cm buildworld 2647b710ab2SJoseph Koshystep into the directory hierarchy pointed to by 2657b710ab2SJoseph Koshy.Xr make 1 2667b710ab2SJoseph Koshyvariable 2677b710ab2SJoseph Koshy.Va DESTDIR . 268a3aed80dSRuslan Ermilov.Pp 26904876cf3SRuslan ErmilovIf installing onto an NFS file system and running 2708ed6451eSRuslan Ermilov.Xr make 1 2718ed6451eSRuslan Ermilovwith the 27204876cf3SRuslan Ermilov.Fl j 27304876cf3SRuslan Ermilovoption, make sure that 274a3aed80dSRuslan Ermilov.Xr rpc.lockd 8 275a3aed80dSRuslan Ermilovis running on both client and server. 276a3aed80dSRuslan ErmilovSee 277a3aed80dSRuslan Ermilov.Xr rc.conf 5 278a3aed80dSRuslan Ermilovon how to make it start at boot time. 2797b710ab2SJoseph Koshy.It Cm toolchain 2807b710ab2SJoseph KoshyCreate the build toolchain needed to build the rest of the system. 2817b710ab2SJoseph KoshyFor cross-architecture builds, this step creates a cross-toolchain. 2827b710ab2SJoseph Koshy.It Cm universe 2834e889921SJohn BaldwinFor each architecture, 2844e889921SJohn Baldwinexecute a 2857b710ab2SJoseph Koshy.Cm buildworld 2864e889921SJohn Baldwinfollowed by a 2877b710ab2SJoseph Koshy.Cm buildkernel 2884e889921SJohn Baldwinfor all kernels for that architecture, 2894e889921SJohn Baldwinincluding 2904e889921SJohn Baldwin.Pa LINT . 2917b710ab2SJoseph KoshyThis command takes a long time. 2921caae057SRuslan Ermilov.It Cm update 2937b710ab2SJoseph KoshyGet updated sources as configured in 29408b91343SYaroslav Tykhiy.Xr make.conf 5 . 295f1d16bd8SBjoern A. Zeeb.It Cm targets 296f1d16bd8SBjoern A. ZeebPrint a list of supported 297f1d16bd8SBjoern A. Zeeb.Va TARGET 298f1d16bd8SBjoern A. Zeeb/ 299f1d16bd8SBjoern A. Zeeb.Va TARGET_ARCH 300f1d16bd8SBjoern A. Zeebpairs for world and kernel targets. 301eee8163bSBjoern A. Zeeb.It Cm tinderbox 302eee8163bSBjoern A. ZeebExecute the same targets as 303eee8163bSBjoern A. Zeeb.Cm universe . 304eee8163bSBjoern A. ZeebIn addition print a summary of all failed targets at the end and 305eee8163bSBjoern A. Zeebexit with an error if there were any. 3064e889921SJohn Baldwin.It Cm toolchains 3074e889921SJohn BaldwinCreate a build toolchain for each architecture supported by the build system. 308b135fb6eSBryan Drewery.It Cm xdev 309b135fb6eSBryan DreweryBuilds and installs a cross-toolchain and sysroot for the given 310b135fb6eSBryan Drewery.Sy TARGET 311b135fb6eSBryan Dreweryand 312b135fb6eSBryan Drewery.Sy TARGET_ARCH . 313b135fb6eSBryan DreweryThe sysroot contains target library and headers. 314b135fb6eSBryan DreweryThe target is an alias for 315b135fb6eSBryan Drewery.Cm xdev-build 316b135fb6eSBryan Dreweryand 317b135fb6eSBryan Drewery.Cm xdev-install . 318b135fb6eSBryan DreweryThe location of the files installed can be controlled with 319b135fb6eSBryan Drewery.Va DESTDIR . 320b135fb6eSBryan DreweryThe target location in 321b135fb6eSBryan Drewery.Va DESTDIR 322b135fb6eSBryan Dreweryis 323b135fb6eSBryan Drewery.Pa ${DESTDIR}/${XDTP} 324b135fb6eSBryan Drewerywhere 325b135fb6eSBryan Drewery.Va XDTP 326b135fb6eSBryan Drewerydefaults to 327b135fb6eSBryan Drewery.Pa /usr/${XDDIR} 328b135fb6eSBryan Dreweryand 329b135fb6eSBryan Drewery.Va XDDIR 330b135fb6eSBryan Drewerydefaults to 331b135fb6eSBryan Drewery.Pa ${TARGET_ARCH}-freebsd . 332b135fb6eSBryan Drewery.It Cm xdev-build 333b135fb6eSBryan DreweryBuilds for the 334b135fb6eSBryan Drewery.Cm xdev 335b135fb6eSBryan Drewerytarget. 336b135fb6eSBryan Drewery.It Cm xdev-install 337b135fb6eSBryan DreweryInstalls the files for the 338b135fb6eSBryan Drewery.Cm xdev 339b135fb6eSBryan Drewerytarget. 340b135fb6eSBryan Drewery.It Cm xdev-links 341b135fb6eSBryan DreweryInstalls autoconf-style symlinks to 342b135fb6eSBryan Drewery.Pa ${DESTDIR}/usr/bin 343b135fb6eSBryan Drewerypointing into the xdev toolchain in 344b135fb6eSBryan Drewery.Pa ${DESTDIR}/${XDTP} . 345786aa69aSBen Smithurst.El 346786aa69aSBen Smithurst.Pp 3477b710ab2SJoseph KoshyKernel specific build targets in 348786aa69aSBen Smithurst.Pa /usr/src 3497b710ab2SJoseph Koshyare: 350e8423d00SNathan Whitehorn.Bl -tag -width ".Cm distributekernel" 3511caae057SRuslan Ermilov.It Cm buildkernel 3521caae057SRuslan ErmilovRebuild the kernel and the kernel modules. 353d90f12e3SWarren BlockThe object directory can be changed from the default 354d90f12e3SWarren Block.Pa /usr/obj 355d90f12e3SWarren Blockby setting the 356d90f12e3SWarren Block.Pa MAKEOBJDIRPREFIX 357d90f12e3SWarren Block.Xr make 1 358d90f12e3SWarren Blockvariable. 3591caae057SRuslan Ermilov.It Cm installkernel 3607b710ab2SJoseph KoshyInstall the kernel and the kernel modules to directory 3617b710ab2SJoseph Koshy.Pa ${DESTDIR}/boot/kernel , 3627b710ab2SJoseph Koshyrenaming any pre-existing directory with this name to 3637b710ab2SJoseph Koshy.Pa kernel.old 3647b710ab2SJoseph Koshyif it contained the currently running kernel. 3657b710ab2SJoseph KoshyThe target directory under 3667b710ab2SJoseph Koshy.Pa ${DESTDIR} 3677b710ab2SJoseph Koshymay be modified using the 3687b710ab2SJoseph Koshy.Va INSTKERNNAME 3697b710ab2SJoseph Koshyand 3707b710ab2SJoseph Koshy.Va KODIR 3717b710ab2SJoseph Koshy.Xr make 1 3727b710ab2SJoseph Koshyvariables. 373e8423d00SNathan Whitehorn.It Cm distributekernel 374e8423d00SNathan WhitehornInstall the kernel to the directory 375e8423d00SNathan Whitehorn.Pa ${DISTDIR}/kernel/boot/kernel . 376e8423d00SNathan WhitehornThis target is used while building a release; see 377e8423d00SNathan Whitehorn.Xr release 7 . 378e8423d00SNathan Whitehorn.It Cm packagekernel 379e8423d00SNathan WhitehornArchive the results of 380e8423d00SNathan Whitehorn.Cm distributekernel , 381e8423d00SNathan Whitehornplacing the results in 382e8423d00SNathan Whitehorn.Va DISTDIR . 383e8423d00SNathan WhitehornThis target is used while building a release; see 384e8423d00SNathan Whitehorn.Xr release 7 . 385389e98a7STom Rhodes.It Cm kernel 386389e98a7STom RhodesEquivalent to 387389e98a7STom Rhodes.Cm buildkernel 388389e98a7STom Rhodesfollowed by 389389e98a7STom Rhodes.Cm installkernel 3907b710ab2SJoseph Koshy.It Cm kernel-toolchain 3917b710ab2SJoseph KoshyRebuild the tools needed for kernel compilation. 3927b710ab2SJoseph KoshyUse this if you did not do a 3937b710ab2SJoseph Koshy.Cm buildworld 3947b710ab2SJoseph Koshyfirst. 3957b710ab2SJoseph Koshy.It Cm reinstallkernel 3967b710ab2SJoseph KoshyReinstall the kernel and the kernel modules, overwriting the contents 3977b710ab2SJoseph Koshyof the target directory. 3987b710ab2SJoseph KoshyAs with the 3997b710ab2SJoseph Koshy.Cm installkernel 4007b710ab2SJoseph Koshytarget, the target directory can be specified using the 4017b710ab2SJoseph Koshy.Xr make 1 4027b710ab2SJoseph Koshyvariable 4037b710ab2SJoseph Koshy.Va INSTKERNNAME . 4047b710ab2SJoseph Koshy.El 4057b710ab2SJoseph Koshy.Pp 4067b710ab2SJoseph KoshyConvenience targets for cleaning up the install destination directory 4077b710ab2SJoseph Koshydenoted by variable 4087b710ab2SJoseph Koshy.Va DESTDIR 4097b710ab2SJoseph Koshyinclude: 4107b710ab2SJoseph Koshy.Bl -tag -width ".Cm delete-old-libs" 4117b710ab2SJoseph Koshy.It Cm check-old 412abfabbeaSMike PritchardPrint a list of old files and directories in the system. 413e2a36081SAlexander Leidinger.It Cm delete-old 414e2a36081SAlexander LeidingerDelete obsolete base system files and directories interactively. 41578ad5421SRuslan ErmilovWhen 41678ad5421SRuslan Ermilov.Li -DBATCH_DELETE_OLD_FILES 4177b710ab2SJoseph Koshyis specified at the command line, the delete operation will be 4187b710ab2SJoseph Koshynon-interactive. 419c8ef0ed5SRuslan ErmilovThe variables 4207b710ab2SJoseph Koshy.Va DESTDIR , 4217b710ab2SJoseph Koshy.Va TARGET_ARCH 422c8ef0ed5SRuslan Ermilovand 423c8ef0ed5SRuslan Ermilov.Va TARGET 424c8ef0ed5SRuslan Ermilovshould be set as with 425c8ef0ed5SRuslan Ermilov.Dq Li "make installworld" . 426e2a36081SAlexander Leidinger.It Cm delete-old-libs 427e2a36081SAlexander LeidingerDelete obsolete base system libraries interactively. 428d90f12e3SWarren BlockThis target should only be used if no third party software uses these 4297b710ab2SJoseph Koshylibraries. 43078ad5421SRuslan ErmilovWhen 43178ad5421SRuslan Ermilov.Li -DBATCH_DELETE_OLD_FILES 4327b710ab2SJoseph Koshyis specified at the command line, the delete operation will be 4337b710ab2SJoseph Koshynon-interactive. 434c8ef0ed5SRuslan ErmilovThe variables 4357b710ab2SJoseph Koshy.Va DESTDIR , 4367b710ab2SJoseph Koshy.Va TARGET_ARCH 437c8ef0ed5SRuslan Ermilovand 438c8ef0ed5SRuslan Ermilov.Va TARGET 439c8ef0ed5SRuslan Ermilovshould be set as with 440c8ef0ed5SRuslan Ermilov.Dq Li "make installworld" . 441786aa69aSBen Smithurst.El 442b82e53e2SMurray Stokely.Sh ENVIRONMENT 4437b710ab2SJoseph KoshyVariables that influence all builds include: 4447b710ab2SJoseph Koshy.Bl -tag -width ".Va MAKEOBJDIRPREFIX" 445fea87c03SGiorgos Keramidas.It Va DEBUG_FLAGS 446fea87c03SGiorgos KeramidasDefines a set of debugging flags that will be used to build all userland 447fea87c03SGiorgos Keramidasbinaries under 448fea87c03SGiorgos Keramidas.Pa /usr/src . 449fea87c03SGiorgos KeramidasWhen 450fea87c03SGiorgos Keramidas.Va DEBUG_FLAGS 451fea87c03SGiorgos Keramidasis defined, the 452fea87c03SGiorgos Keramidas.Cm install 453fea87c03SGiorgos Keramidasand 454fea87c03SGiorgos Keramidas.Cm installworld 455fea87c03SGiorgos Keramidastargets install binaries from the current 456fea87c03SGiorgos Keramidas.Va MAKEOBJDIRPREFIX 457fea87c03SGiorgos Keramidaswithout stripping, 458fea87c03SGiorgos Keramidasso that debugging information is retained in the installed binaries. 4597b710ab2SJoseph Koshy.It Va DESTDIR 4607b710ab2SJoseph KoshyThe directory hierarchy prefix where built objects will be installed. 4617b710ab2SJoseph KoshyIf not set, 4627b710ab2SJoseph Koshy.Va DESTDIR 4637b710ab2SJoseph Koshydefaults to the empty string. 4647b710ab2SJoseph Koshy.It Va MAKEOBJDIRPREFIX 4657b710ab2SJoseph KoshyDefines the prefix for directory names in the tree of built objects. 4667b710ab2SJoseph KoshyDefaults to 4677b710ab2SJoseph Koshy.Pa /usr/obj 4687b710ab2SJoseph Koshyif not defined. 469dfa09989SBryan DreweryThis variable should only be set in the environment or 470dfa09989SBryan Drewery.Pa /etc/src-env.conf 471dfa09989SBryan Dreweryand not via 4727b710ab2SJoseph Koshy.Pa /etc/make.conf 473dfa09989SBryan Dreweryor 474dfa09989SBryan Drewery.Pa /etc/src.conf 4757b710ab2SJoseph Koshyor the command line. 4767b710ab2SJoseph Koshy.It Va NO_WERROR 4777b710ab2SJoseph KoshyIf defined, compiler warnings will not cause the build to halt, 4787b710ab2SJoseph Koshyeven if the makefile says otherwise. 47921edb039SAlexander Leidinger.It Va WITH_CTF 48021edb039SAlexander LeidingerIf defined, the build process will run the DTrace CTF conversion 48121edb039SAlexander Leidingertools on built objects. 4827b710ab2SJoseph Koshy.El 4837b710ab2SJoseph Koshy.Pp 4847b710ab2SJoseph KoshyAdditionally, builds in 4857b710ab2SJoseph Koshy.Pa /usr/src 4867b710ab2SJoseph Koshyare influenced by the following 4877b710ab2SJoseph Koshy.Xr make 1 4887b710ab2SJoseph Koshyvariables: 4897b710ab2SJoseph Koshy.Bl -tag -width ".Va SUBDIR_OVERRIDE" 490e6cdeeddSWarner Losh.It Va KERNCONF 491e6cdeeddSWarner LoshOverrides which kernel to build and install for the various kernel 492e6cdeeddSWarner Loshmake targets. 493e6cdeeddSWarner LoshIt defaults to 494e6cdeeddSWarner Losh.Cm GENERIC . 4954b2cc4d1SKyle Evans.It Va KERNCONFDIR 4964b2cc4d1SKyle EvansOverrides the directory in which 4974b2cc4d1SKyle Evans.Va KERNCONF 4984b2cc4d1SKyle Evansand any files included by 4994b2cc4d1SKyle Evans.Va KERNCONF 5004b2cc4d1SKyle Evansshould be found. 5014b2cc4d1SKyle EvansDefaults to 5024b2cc4d1SKyle Evans.Pa sys/${ARCH}/conf . 503e6cdeeddSWarner Losh.It Va KERNFAST 504e6cdeeddSWarner LoshIf set, the build target 505e6cdeeddSWarner Losh.Cm buildkernel 506e6cdeeddSWarner Loshdefaults to setting 507e6cdeeddSWarner Losh.Va NO_KERNELCLEAN , 5086d50d5e4SWarner Losh.Va NO_KERNELCONFIG , 509e6cdeeddSWarner Loshand 5106d50d5e4SWarner Losh.Va NO_KERNELOBJ . 511e6cdeeddSWarner LoshWhen set to a value other than 512e6cdeeddSWarner Losh.Cm 1 513e6cdeeddSWarner Loshthen 514e6cdeeddSWarner Losh.Va KERNCONF 515e6cdeeddSWarner Loshis set to the value of 516e6cdeeddSWarner Losh.Va KERNFAST . 5177b710ab2SJoseph Koshy.It Va LOCAL_DIRS 518ca6a54ceSBryan DreweryIf set, this variable supplies a list of additional directories relative to 519ca6a54ceSBryan Drewerythe root of the source tree to build as part of the 520ca6a54ceSBryan Drewery.Cm everything 521ca6a54ceSBryan Drewerytarget. 522e93e5bb0SIan LeporeThe directories are built in parallel with each other, 523e93e5bb0SIan Leporeand with the base system directories. 524e93e5bb0SIan LeporeInsert a 525e93e5bb0SIan Lepore.Va .WAIT 526e93e5bb0SIan Leporedirective at the beginning of the 527e93e5bb0SIan Lepore.Va LOCAL_DIRS 528e93e5bb0SIan Leporelist to ensure all base system directories are built first. 529e93e5bb0SIan Lepore.Va .WAIT 530e93e5bb0SIan Leporemay also be used as needed elsewhere within the list. 531a0e6a013SBryan Drewery.It Va LOCAL_ITOOLS 532a0e6a013SBryan DreweryIf set, this variable supplies a list of additional tools that are used by the 533a0e6a013SBryan Drewery.Cm installworld 534a0e6a013SBryan Dreweryand 535a0e6a013SBryan Drewery.Cm distributeworld 536a0e6a013SBryan Drewerytargets. 537ca6a54ceSBryan Drewery.It Va LOCAL_LIB_DIRS 538ca6a54ceSBryan DreweryIf set, this variable supplies a list of additional directories relative to 539ca6a54ceSBryan Drewerythe root of the source tree to build as part of the 540ca6a54ceSBryan Drewery.Cm libraries 541ca6a54ceSBryan Drewerytarget. 542e93e5bb0SIan LeporeThe directories are built in parallel with each other, 543e93e5bb0SIan Leporeand with the base system libraries. 544e93e5bb0SIan LeporeInsert a 545e93e5bb0SIan Lepore.Va .WAIT 546e93e5bb0SIan Leporedirective at the beginning of the 547e93e5bb0SIan Lepore.Va LOCAL_DIRS 548e93e5bb0SIan Leporelist to ensure all base system libraries are built first. 549e93e5bb0SIan Lepore.Va .WAIT 550e93e5bb0SIan Leporemay also be used as needed elsewhere within the list. 551ca6a54ceSBryan Drewery.It Va LOCAL_MTREE 552ca6a54ceSBryan DreweryIf set, this variable supplies a list of additional mtrees relative to the 553ca6a54ceSBryan Dreweryroot of the source tree to use as part of the 554ca6a54ceSBryan Drewery.Cm hierarchy 555ca6a54ceSBryan Drewerytarget. 556ca6a54ceSBryan Drewery.It Va LOCAL_TOOL_DIRS 557ca6a54ceSBryan DreweryIf set, this variable supplies a list of additional directories relative to 558ca6a54ceSBryan Drewerythe root of the source tree to build as part of the 559ca6a54ceSBryan Drewery.Cm build-tools 560ca6a54ceSBryan Drewerytarget. 5614143850bSBryan Drewery.It Va LOCAL_XTOOL_DIRS 5624143850bSBryan DreweryIf set, this variable supplies a list of additional directories relative to 5634143850bSBryan Drewerythe root of the source tree to build as part of the 5644143850bSBryan Drewery.Cm cross-tools 5654143850bSBryan Drewerytarget. 566170c2788SGlen Barber.It Va PORTS_MODULES 567170c2788SGlen BarberA list of ports with kernel modules that should be built and installed 568170c2788SGlen Barberas part of the 569170c2788SGlen Barber.Cm buildkernel 570170c2788SGlen Barberand 571170c2788SGlen Barber.Cm installkernel 572170c2788SGlen Barberprocess. 573170c2788SGlen Barber.Bd -literal -offset indent 574170c2788SGlen Barbermake PORTS_MODULES=emulators/kqemu-kmod kernel 575170c2788SGlen Barber.Ed 57642e7be20SEnji Cooper.It Va STRIPBIN 5773547290fSEnji CooperCommand to use at install time when stripping binaries. 5783547290fSEnji CooperBe sure to add any additional tools required to run 57942e7be20SEnji Cooper.Va STRIPBIN 5803547290fSEnji Cooperto the 5813547290fSEnji Cooper.Va LOCAL_ITOOLS 5823547290fSEnji Cooper.Xr make 1 5833547290fSEnji Coopervariable before running the 5843547290fSEnji Cooper.Cm distributeworld 5853547290fSEnji Cooperor 5863547290fSEnji Cooper.Cm installworld 5873547290fSEnji Coopertargets. 5883547290fSEnji CooperSee 5893547290fSEnji Cooper.Xr install 1 5903547290fSEnji Cooperfor more details. 5917b710ab2SJoseph Koshy.It Va SUBDIR_OVERRIDE 5927b710ab2SJoseph KoshyOverride the default list of sub-directories and only build the 5937b710ab2SJoseph Koshysub-directory named in this variable. 5947f1636b7SBryan DreweryIf combined with 5957f1636b7SBryan Drewery.Cm buildworld 5967f1636b7SBryan Drewerythen all libraries and includes, and some of the build tools will still build 5977f1636b7SBryan Dreweryas well. 598c889d480SBryan DrewerySpecifying 599c889d480SBryan Drewery.Cm -DNO_LIBS , 600c889d480SBryan Dreweryand 601c889d480SBryan Drewery.Cm -DWORLDFAST 602c889d480SBryan Drewerywill only build the specified directory as was done historically. 6037f1636b7SBryan DreweryWhen combined with 6047f1636b7SBryan Drewery.Cm buildworld 6057f1636b7SBryan Dreweryit is necesarry to override 6067f1636b7SBryan Drewery.Va LOCAL_LIB_DIRS 6077f1636b7SBryan Drewerywith any custom directories containing libraries. 6087f1636b7SBryan DreweryThis allows building a subset of the system in the same way as 6097f1636b7SBryan Drewery.Cm buildworld 6107f1636b7SBryan Drewerydoes using its sysroot handling. 6117f1636b7SBryan DreweryThis variable can also be useful when debugging failed builds. 6127b710ab2SJoseph Koshy.Bd -literal -offset indent 6137b710ab2SJoseph Koshymake some-target SUBDIR_OVERRIDE=foo/bar 6147b710ab2SJoseph Koshy.Ed 6156f9ac6feSMurray Stokely.It Va TARGET 616b3a43ea3SMurray StokelyThe target hardware platform. 617365a17c0SMurray StokelyThis is analogous to the 6181caae057SRuslan Ermilov.Dq Nm uname Fl m 619b3a43ea3SMurray Stokelyoutput. 620b3a43ea3SMurray StokelyThis is necessary to cross-build some target architectures. 6212f6a7e42SEnji CooperFor example, cross-building for ARM64 machines requires 6222f6a7e42SEnji Cooper.Va TARGET_ARCH Ns = Ns Li aarch64 623b3a43ea3SMurray Stokelyand 6242f6a7e42SEnji Cooper.Va TARGET Ns = Ns Li arm64 . 6257b710ab2SJoseph KoshyIf not set, 6267b710ab2SJoseph Koshy.Va TARGET 627f4721165SEdward Tomasz Napieraladefaults to the current hardware platform, unless 628f4721165SEdward Tomasz Napierala.Va TARGET_ARCH 629f4721165SEdward Tomasz Napieralais also set, in which case it defaults to the appropriate 630f4721165SEdward Tomasz Napieralavalue for that architecture. 6317b710ab2SJoseph Koshy.It Va TARGET_ARCH 6327b710ab2SJoseph KoshyThe target machine processor architecture. 6337b710ab2SJoseph KoshyThis is analogous to the 6347b710ab2SJoseph Koshy.Dq Nm uname Fl p 6357b710ab2SJoseph Koshyoutput. 6367b710ab2SJoseph KoshySet this to cross-build for a different architecture. 6377b710ab2SJoseph KoshyIf not set, 6387b710ab2SJoseph Koshy.Va TARGET_ARCH 639531b260aSWarner Loshdefaults to the current machine architecture, unless 640531b260aSWarner Losh.Va TARGET 641531b260aSWarner Loshis also set, in which case it defaults to the appropriate 642531b260aSWarner Loshvalue for that platform. 643c22c7f86SWarner LoshTypically, one only needs to set 644c22c7f86SWarner Losh.Va TARGET . 6457b710ab2SJoseph Koshy.El 6467b710ab2SJoseph Koshy.Pp 6477b710ab2SJoseph KoshyBuilds under directory 648fd23b461SGiorgos Keramidas.Pa /usr/src 6497d6af40dSGlen Barberare also influenced by defining one or more of the following symbols, 650fd23b461SGiorgos Keramidasusing the 651fd23b461SGiorgos Keramidas.Fl D 652fd23b461SGiorgos Keramidasoption of 653fd23b461SGiorgos Keramidas.Xr make 1 : 654497e8091SBryan Drewery.Bl -tag -width ".Va -DNO_KERNELCONFIG" 655*01012c64SWarner Losh.It Va LOADER_DEFAULT_INTERP 656*01012c64SWarner LoshDefines what interpreter the default loader program will have. 657*01012c64SWarner LoshValid values include 658*01012c64SWarner Losh.Dq 4th , 659*01012c64SWarner Losh.Dq lua , 660*01012c64SWarner Loshand 661*01012c64SWarner Losh.Dq simp . 662*01012c64SWarner LoshThis creates the default link for 663*01012c64SWarner Losh.Pa /boot/loader 664*01012c64SWarner Loshto the loader with that interpreter. 665*01012c64SWarner LoshIt also determines what interpreter is compiled into 666*01012c64SWarner Losh.Pa userboot . 667fd23b461SGiorgos Keramidas.It Va NO_CLEANDIR 668fd23b461SGiorgos KeramidasIf set, the build targets that clean parts of the object tree use the 669fd23b461SGiorgos Keramidasequivalent of 670fd23b461SGiorgos Keramidas.Dq make clean 671fd23b461SGiorgos Keramidasinstead of 672fd23b461SGiorgos Keramidas.Dq make cleandir . 673fd23b461SGiorgos Keramidas.It Va NO_CLEAN 674fd23b461SGiorgos KeramidasIf set, no object tree files are cleaned at all. 675473fda75SBryan DreweryThis is the default when 676473fda75SBryan Drewery.Va WITH_META_MODE 677473fda75SBryan Dreweryis used with 678473fda75SBryan Drewery.Xr filemon 4 679473fda75SBryan Dreweryloaded. 680473fda75SBryan DrewerySee 681473fda75SBryan Drewery.Xr src.conf 5 682473fda75SBryan Dreweryfor more details. 683fd23b461SGiorgos KeramidasSetting 684fd23b461SGiorgos Keramidas.Va NO_CLEAN 685fd23b461SGiorgos Keramidasimplies 686fd23b461SGiorgos Keramidas.Va NO_KERNELCLEAN , 687fd23b461SGiorgos Keramidasso when 688fd23b461SGiorgos Keramidas.Va NO_CLEAN 689fd23b461SGiorgos Keramidasis set no kernel objects are cleaned either. 690fd23b461SGiorgos Keramidas.It Va NO_CTF 691fd23b461SGiorgos KeramidasIf set, the build process does not run the DTrace CTF conversion tools 692fd23b461SGiorgos Keramidason built objects. 693fd23b461SGiorgos Keramidas.It Va NO_SHARE 694fd23b461SGiorgos KeramidasIf set, the build does not descend into the 695fd23b461SGiorgos Keramidas.Pa /usr/src/share 696d90f12e3SWarren Blocksubdirectory (i.e., manual pages, locale data files, timezone data files and 697fd23b461SGiorgos Keramidasother 698fd23b461SGiorgos Keramidas.Pa /usr/src/share 699fd23b461SGiorgos Keramidasfiles will not be rebuild from their sources). 700fd23b461SGiorgos Keramidas.It Va NO_KERNELCLEAN 701fd23b461SGiorgos KeramidasIf set, the build process does not run 702fd23b461SGiorgos Keramidas.Dq make clean 703fd23b461SGiorgos Keramidasas part of the 704fd23b461SGiorgos Keramidas.Cm buildkernel 705fd23b461SGiorgos Keramidastarget. 706fd23b461SGiorgos Keramidas.It Va NO_KERNELCONFIG 707fd23b461SGiorgos KeramidasIf set, the build process does not run 708fd23b461SGiorgos Keramidas.Xr config 8 709fd23b461SGiorgos Keramidasas part of the 710fd23b461SGiorgos Keramidas.Cm buildkernel 711fd23b461SGiorgos Keramidastarget. 7126d50d5e4SWarner Losh.It Va NO_KERNELOBJ 7136d50d5e4SWarner LoshIf set, the build process does not run 7146d50d5e4SWarner Losh.Dq make obj 7156d50d5e4SWarner Loshas part of the 7166d50d5e4SWarner Losh.Cm buildkernel 7176d50d5e4SWarner Loshtarget. 718fd23b461SGiorgos Keramidas.It Va NO_DOCUPDATE 719fd23b461SGiorgos KeramidasIf set, the update process does not update the source of the 720fd23b461SGiorgos Keramidas.Fx 721fd23b461SGiorgos Keramidasdocumentation as part of the 722fd23b461SGiorgos Keramidas.Dq make update 723fd23b461SGiorgos Keramidastarget. 724c596c287SBryan Drewery.It Va NO_LIBS 725c596c287SBryan DreweryIf set, the libraries phase will be skipped. 7262abeba9dSBryan Drewery.It Va NO_OBJWALK 7276d75a7a8SBryan DreweryIf set, no object directories will be created. 7286d75a7a8SBryan DreweryThis should only be used if object directories were created in a 7296d75a7a8SBryan Dreweryprevious build and no new directories are connected. 730fd23b461SGiorgos Keramidas.It Va NO_PORTSUPDATE 731fd23b461SGiorgos KeramidasIf set, the update process does not update the Ports tree as part of the 732fd23b461SGiorgos Keramidas.Dq make update 733fd23b461SGiorgos Keramidastarget. 73469c488cdSRuslan Ermilov.It Va NO_WWWUPDATE 73569c488cdSRuslan ErmilovIf set, the update process does not update the www tree as part of the 73669c488cdSRuslan Ermilov.Dq make update 73769c488cdSRuslan Ermilovtarget. 73816892c77SBryan Drewery.It Va WORLDFAST 73916892c77SBryan DreweryIf set, the build target 74016892c77SBryan Drewery.Cm buildworld 74116892c77SBryan Drewerydefaults to setting 74216892c77SBryan Drewery.Va NO_CLEAN , 7432abeba9dSBryan Drewery.Va NO_OBJWALK , 74416892c77SBryan Dreweryand will skip most bootstrap phases. 74516892c77SBryan DreweryIt will only bootstrap libraries and build all of userland. 74616892c77SBryan DreweryThis option should be used only when it is known that none of the bootstrap 74716892c77SBryan Dreweryneeds changed and that no new directories have been connected to the build. 748fd23b461SGiorgos Keramidas.El 749fd23b461SGiorgos Keramidas.Pp 750fd23b461SGiorgos KeramidasBuilds under directory 7517b710ab2SJoseph Koshy.Pa /usr/doc 7527b710ab2SJoseph Koshyare influenced by the following 7537b710ab2SJoseph Koshy.Xr make 1 7547b710ab2SJoseph Koshyvariables: 7557b710ab2SJoseph Koshy.Bl -tag -width ".Va DOC_LANG" 7567b710ab2SJoseph Koshy.It Va DOC_LANG 7577b710ab2SJoseph KoshyIf set, restricts the documentation build to the language subdirectories 7587b710ab2SJoseph Koshyspecified as its content. 7597b710ab2SJoseph KoshyThe default action is to build documentation for all languages. 760b82e53e2SMurray Stokely.El 7614e889921SJohn Baldwin.Pp 7624e889921SJohn BaldwinBuilds using the 7634e889921SJohn Baldwin.Cm universe 7644e889921SJohn Baldwintarget are influenced by the following 7654e889921SJohn Baldwin.Xr make 1 7664e889921SJohn Baldwinvariables: 7674e889921SJohn Baldwin.Bl -tag -width ".Va MAKE_JUST_KERNELS" 7684e889921SJohn Baldwin.It Va JFLAG 7694e889921SJohn BaldwinPass the value of this variable to each 7704e889921SJohn Baldwin.Xr make 1 7714e889921SJohn Baldwininvocation used to build worlds and kernels. 7724e889921SJohn BaldwinThis can be used to enable multiple jobs within a single architecture's build 7734e889921SJohn Baldwinwhile still building each architecture serially. 7744e889921SJohn Baldwin.It Va MAKE_JUST_KERNELS 7754e889921SJohn BaldwinOnly build kernels for each supported architecture. 7764e889921SJohn Baldwin.It Va MAKE_JUST_WORLDS 7774e889921SJohn BaldwinOnly build worlds for each supported architecture. 7784e889921SJohn Baldwin.It Va UNIVERSE_TARGET 7794e889921SJohn BaldwinExecute the specified 7804e889921SJohn Baldwin.Xr make 1 7814e889921SJohn Baldwintarget for each supported architecture instead of the default action of 7824e889921SJohn Baldwinbuilding a world and one or more kernels. 7834e889921SJohn Baldwin.El 784786aa69aSBen Smithurst.Sh FILES 7850c0eb9beSRuslan Ermilov.Bl -tag -width ".Pa /usr/share/examples/etc/make.conf" -compact 786786aa69aSBen Smithurst.It Pa /usr/doc/Makefile 787786aa69aSBen Smithurst.It Pa /usr/doc/share/mk/doc.project.mk 788786aa69aSBen Smithurst.It Pa /usr/ports/Mk/bsd.port.mk 789786aa69aSBen Smithurst.It Pa /usr/ports/Mk/bsd.sites.mk 7901caae057SRuslan Ermilov.It Pa /usr/share/examples/etc/make.conf 7910c0eb9beSRuslan Ermilov.It Pa /usr/src/Makefile 7920c0eb9beSRuslan Ermilov.It Pa /usr/src/Makefile.inc1 7933136363fSRuslan Ermilov.El 7943faf5fc9SBen Smithurst.Sh EXAMPLES 795be6a4760SRuslan ErmilovFor an 7963faf5fc9SBen Smithurst.Dq approved 7977b710ab2SJoseph Koshymethod of updating your system from the latest sources, please see the 798be6a4760SRuslan Ermilov.Sx COMMON ITEMS 799be6a4760SRuslan Ermilovsection in 800be6a4760SRuslan Ermilov.Pa src/UPDATING . 801b82e53e2SMurray Stokely.Pp 802b82e53e2SMurray StokelyThe following sequence of commands can be used to cross-build the 803f4721165SEdward Tomasz Napieralasystem for the armv6 architecture on an amd64 host: 804b82e53e2SMurray Stokely.Bd -literal -offset indent 805b82e53e2SMurray Stokelycd /usr/src 806f4721165SEdward Tomasz Napieralamake TARGET_ARCH=armv6 buildworld buildkernel 807f4721165SEdward Tomasz Napieralamake TARGET_ARCH=armv6 DESTDIR=/clients/arm64 installworld installkernel 808b82e53e2SMurray Stokely.Ed 809786aa69aSBen Smithurst.Sh SEE ALSO 8107c20a493SBen Smithurst.Xr cc 1 , 811786aa69aSBen Smithurst.Xr install 1 , 812786aa69aSBen Smithurst.Xr make 1 , 81350a994c9SWarren Block.Xr svn 1 , 814c046b2a9SAlexander Leidinger.Xr svnlite 1 , 815786aa69aSBen Smithurst.Xr make.conf 5 , 816157376baSJoseph Koshy.Xr src.conf 5 , 817f4721165SEdward Tomasz Napierala.Xr arch 7 , 818a81996b6SBen Smithurst.Xr ports 7 , 819a54bda91SMurray Stokely.Xr release 7 , 82053837b18SEnji Cooper.Xr tests 7 , 82161001d75STom Rhodes.Xr config 8 , 82247f77d8cSBen Smithurst.Xr mergemaster 8 , 823d732418bSWarren Block.Xr portsnap 8 , 824a81996b6SBen Smithurst.Xr reboot 8 , 82553837b18SEnji Cooper.Xr shutdown 8 826786aa69aSBen Smithurst.Sh AUTHORS 827a63d6c94SBaptiste Daroussin.An Mike W. Meyer Aq Mt mwm@mired.org 828