Annotation of src/share/mk/bsd.README, Revision 1.134
1.134 ! lukem 1: # $NetBSD: bsd.README,v 1.133 2003/08/02 00:34:25 lukem Exp $
1.24 mikel 2: # @(#)bsd.README 8.2 (Berkeley) 4/2/94
1.1 cgd 3:
4: This is the README file for the new make "include" files for the BSD
5: source tree. The files are installed in /usr/share/mk, and are, by
1.11 jtc 6: convention, named with the suffix ".mk".
1.1 cgd 7:
8: Note, this file is not intended to replace reading through the .mk
9: files for anything tricky.
10:
11: =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
12:
13: RANDOM THINGS WORTH KNOWING:
14:
15: The files are simply C-style #include files, and pretty much behave like
16: you'd expect. The syntax is slightly different in that a single '.' is
17: used instead of the hash mark, i.e. ".include <bsd.prog.mk>".
18:
19: One difference that will save you lots of debugging time is that inclusion
20: of the file is normally done at the *end* of the Makefile. The reason for
21: this is because .mk files often modify variables and behavior based on the
22: values of variables set in the Makefile. To make this work, remember that
23: the FIRST target found is the target that is used, i.e. if the Makefile has:
24:
25: a:
26: echo a
27: a:
28: echo a number two
29:
30: the command "make a" will echo "a". To make things confusing, the SECOND
31: variable assignment is the overriding one, i.e. if the Makefile has:
32:
33: a= foo
34: a= bar
35:
36: b:
37: echo ${a}
38:
39: the command "make b" will echo "bar". This is for compatibility with the
40: way the V7 make behaved.
41:
42: It's fairly difficult to make the BSD .mk files work when you're building
1.75 agc 43: multiple programs in a single directory. It's a lot easier to split up the
1.1 cgd 44: programs than to deal with the problem. Most of the agony comes from making
1.36 ross 45: the "obj" directory stuff work right, not because we switched to a new version
1.1 cgd 46: of make. So, don't get mad at us, figure out a better way to handle multiple
47: architectures so we can quit using the symbolic link stuff. (Imake doesn't
48: count.)
49:
50: The file .depend in the source directory is expected to contain dependencies
51: for the source files. This file is read automatically by make after reading
52: the Makefile.
53:
54: The variable DESTDIR works as before. It's not set anywhere but will change
55: the tree where the file gets installed.
56:
57: The profiled libraries are no longer built in a different directory than
58: the regular libraries. A new suffix, ".po", is used to denote a profiled
1.21 christos 59: object, and ".so" denotes a shared (position-independent) object.
1.97 itojun 60:
61: There are various make variables used during the build. Basic rule for
62: the variable naming scheme is as follows:
63:
1.129 lukem 64: MKxxx Can be set to "no" to disable functionality, or
65: "yes" to enable it.
66: Usually defaults to "yes", although some variables
67: default to "no".
68: Due to make(1) implementation issues, if a temporary
1.134 ! lukem 69: command-line override of a mk.conf or <bsd.own.mk> setting
1.129 lukem 70: is required whilst still honouring a particular
71: Makefile's setting of MKxxx, use
72: env MKxxx=value make
73: instead of
74: make MKxxx=value
1.97 itojun 75:
1.116 lukem 76: NOxxx If defined, disables a feature.
77: Not intended for users.
78: This is to allow Makefiles to disable functionality
79: that they don't support (such as missing man pages).
1.101 lukem 80: NOxxx variables must be defined before <bsd.own.mk>
81: is included.
1.21 christos 82:
1.45 lukem 83: The following variables that control how things are made/installed that
1.47 tv 84: are not set by default. These should not be set by Makefiles; they're for
1.134 ! lukem 85: the user to define in MAKECONF (see <bsd.own.mk>, below) or on the make(1)
1.47 tv 86: command line:
1.21 christos 87:
1.45 lukem 88: BUILD If defined, 'make install' checks that the targets in the
89: source directories are up-to-date and remakes them if they
1.21 christos 90: are out of date, instead of blindly trying to install
1.79 wiz 91: out of date or non-existent targets.
1.21 christos 92:
1.120 lukem 93: MKBFD If "no", don't build libbfd, libiberty, or any of the things
94: that depend on them (binutils/gas/ld, gdb, dbsym, mdsetimage).
95: Default: yes
96:
1.121 lukem 97: MKCATPAGES If "no", don't build or install the catman pages.
98: Default: yes
99:
1.120 lukem 100: MKCRYPTO If "no", no cryptography support will be built into the system,
1.127 lukem 101: and also acts as MKKERBEROS=no MKKERBEROS4=no.
1.120 lukem 102: Default: yes
103:
104: MKCRYPTO_IDEA If not "no", IDEA support will be built into libcrypto_idea.a.
105: Default: no
1.52 simonb 106:
1.120 lukem 107: MKCRYPTO_MDC2 If not "no", MDC2 support will be built into libcrypto_mdc2.a
108: Default: no
1.45 lukem 109:
1.120 lukem 110: MKCRYPTO_RC5 If not "no", RC5 support will be built into libcrypto_rc5.a.
111: Default: no
1.86 thorpej 112:
1.45 lukem 113: MKDOC If "no", don't build or install the documentation.
1.120 lukem 114: Default: yes
1.86 thorpej 115:
1.104 lukem 116: MKDYNAMICROOT If "no", build programs in /bin and /sbin statically,
117: don't install certain libraries in /lib, and don't
118: install the shared linker into /libexec.
1.120 lukem 119: Default: yes
120:
121: MKGCC If "no", don't build gcc or any of the gcc-related
122: libraries (libg2c, libgcc, libobjc, libstdc++).
123: Default: yes
1.104 lukem 124:
1.103 thorpej 125: MKGDB If "no", don't build gdb.
1.120 lukem 126: Default: yes
127:
128: MKHESIOD If "no", disables building of Hesiod infrastructure
129: (libraries and support programs).
130: Default: yes
1.121 lukem 131:
132: MKHOSTOBJ If "yes", for programs intended to be run on the compile host,
133: the name, release, and architecture of the host operating
134: system will be suffixed to the name of the object directory
135: created by "make obj".
136: Default: no
1.86 thorpej 137:
1.120 lukem 138: MKHTML If "no", don't build or install the html man pages.
139: Default: yes
1.92 ross 140:
141: MKIEEEFP If "no", don't add code for IEEE754/IEC60559 conformance.
142: Has no effect on most platforms.
1.120 lukem 143: Default: yes
1.45 lukem 144:
1.47 tv 145: MKINFO If "no", don't build or install Info documentation from
146: Texinfo source files.
1.120 lukem 147: Default: yes
148:
1.126 itojun 149: MKKERBEROS4 If "no", disables building of Kerberos v4
150: infrastructure (libraries and support programs).
151: Default: yes
152:
153: MKKERBEROS If "no", disables building of Kerberos v5
1.120 lukem 154: infrastructure (libraries and support programs).
155: Default: yes
156:
157: MKLINKLIB If "no", act as "MKPICINSTALL=no MKPROFILE=no".
158: Also:
159: - don't install the .a libraries
160: - don't install _pic.a libraries on PIC systems
161: - don't build .a libraries on PIC systems
162: - don't install the .so symlink on ELF systems
163: I.e, only install the shared library (and the .so.major
164: symlink on ELF).
165: Default: yes
1.45 lukem 166:
167: MKLINT If "no", don't build or install the lint libraries.
1.120 lukem 168: Default: yes
1.45 lukem 169:
1.120 lukem 170: MKMAN If "no", don't build or install the man or catman pages,
171: and also acts as "MKCATPAGES=no MKHTML=no"
172: Default: yes
1.45 lukem 173:
1.119 lukem 174: MKMANZ If not "no", compress manual pages at installation time.
1.120 lukem 175: Default: no
1.119 lukem 176:
1.74 itojun 177: MKNLS If "no", don't build or install the NLS files and locale
178: definition files.
1.120 lukem 179: Default: yes
1.45 lukem 180:
1.120 lukem 181: MKOBJ If "no", don't enable the rule which creates objdirs,
182: and also acts as "MKOBJDIRS=no"
183: Default: yes
1.55 sommerfe 184:
185: MKOBJDIRS If "no", don't create objdirs during a "make build".
1.120 lukem 186: Default: no
1.45 lukem 187:
1.120 lukem 188: MKPIC If "no", don't build or install shared libraries, and
189: also acts as "MKPICLIB=no"
1.122 lukem 190: Default: yes, except for ${MACHINE_ARCH} == "sh3"
1.45 lukem 191:
192: MKPICINSTALL If "no", don't install the *_pic.a libraries.
1.120 lukem 193: Default: yes
194:
195: MKPICLIB If "no", don't build *_pic.a libraries, and build the
196: shared object libraries from the .a libraries.
197: A symlink is installed in ${DESTDIR}/usr/lib for the
198: _pic.a library pointing to the .a library.
199: Default: yes
1.45 lukem 200:
201: MKPROFILE If "no", don't build or install the profiling libraries.
1.120 lukem 202: Default: yes
203:
204: MKSHARE If "no", act as "MKCATPAGES=no MKDOC=no MKHTML=no MKINFO=no
205: MKMAN=no MKNLS=no".
206: I.e, don't build catman pages, documentation, Info
207: documentation, man pages, NLS files, ...
208: Default: yes
209:
210: MKSKEY If "no", disables building of S/key authentication
211: infrastructure (libraries and support programs).
212: Default: yes
213:
214: MKSOFTFLOAT If not "no", build with options to enable the compiler to
215: generate output containing library calls for floating
216: point and possibly soft-float library support.
217: Default: no
218:
219: MKUNPRIVED If not "no", don't set the owner/group/mode when installing
220: files or directories, and keep a metadata log of what
221: the owner/group/mode should be. This allows a
222: non-root "make install".
223: Default: no
224:
225: MKUPDATE If not "no", 'make install' only installs targets that are
226: more recently modified in the source directories that their
227: installed counterparts.
228: Default: no
1.45 lukem 229:
1.120 lukem 230: MKYP If "no", disables building of YP (NIS)
231: infrastructure (libraries and support programs).
232: Default: yes
1.1 cgd 233:
1.129 lukem 234: USE_HESIOD If "no", disables building Hesiod support into
1.122 lukem 235: various system utilities/libraries that support it.
1.129 lukem 236: If MKHESIOD is "no", USE_HESIOD will also be
1.122 lukem 237: forced to "no".
238:
1.129 lukem 239: USE_KERBEROS4 If "no", disables building Kerberos v4
1.126 itojun 240: support into various system utilities/libraries that
1.129 lukem 241: support it. If MKKERBEROS4 is "no", USE_KERBEROS4
1.126 itojun 242: will also be forced to "no".
243:
1.129 lukem 244: USE_KERBEROS If "no", disables building Kerberos v4 or v5)
1.122 lukem 245: support into various system utilities/libraries that
1.129 lukem 246: support it. If MKKERBEROS is "no", USE_KERBEROS
1.122 lukem 247: will also be forced to "no".
248:
1.129 lukem 249: USE_SKEY If "no", disables building S/key authentication
1.122 lukem 250: support into various system utilities/libraries that
1.129 lukem 251: support it. If MKSKEY is "no", USE_SKEY will
1.122 lukem 252: also be forced to "no".
253:
1.129 lukem 254: USE_YP If "no", disables building YP (NIS) support into
255: various system utilities/libraries that support it.
256: If MKYP is "no", USE_YP will also be forced to "no".
1.122 lukem 257:
1.118 lukem 258:
259: =-=-=-=-= sys.mk =-=-=-=-=
1.1 cgd 260:
261: The include file <sys.mk> has the default rules for all makes, in the BSD
262: environment or otherwise. You probably don't want to touch this file.
263:
1.118 lukem 264: =-=-=-=-= bsd.own.mk =-=-=-=-=
1.1 cgd 265:
1.17 thorpej 266: The include file <bsd.own.mk> contains source tree configuration parameters,
267: such as the owners, groups, etc. for both manual pages and binaries, and
268: a few global "feature configuration" parameters.
1.1 cgd 269:
270: It has no targets.
271:
1.134 ! lukem 272: To get system-specific configuration parameters, <bsd.own.mk> will try to
1.29 cjs 273: include the file specified by the "MAKECONF" variable. If MAKECONF is not
274: set, or no such file exists, the system make configuration file, /etc/mk.conf
275: is included. These files may define any of the variables described below.
1.17 thorpej 276:
1.134 ! lukem 277: <bsd.own.mk> sets the following variables, if they are not already defined
1.17 thorpej 278: (defaults are in brackets):
1.15 cgd 279:
1.98 lukem 280: NETBSDSRCDIR Top of the NetBSD source tree.
281: If _SRC_TOP_ != "", that will be used as the default,
282: otherwise BSDSRCDIR will be used as the default.
283: Various makefiles within the NetBSD source tree will
284: use this to reference the top level of the source tree.
285:
1.95 lukem 286: _SRC_TOP_ Top of the system source tree, as determined by <bsd.own.mk>
1.98 lukem 287: based on the presence of tools/ and build.sh. This variable
288: is "internal" to <bsd.own.mk>, although its value is only
289: determined once and then propagated to all sub-makes.
1.95 lukem 290:
1.15 cgd 291: BSDSRCDIR The real path to the system sources, so that 'make obj'
1.116 lukem 292: will work correctly. [/usr/src]
1.15 cgd 293:
294: BSDOBJDIR The real path to the system 'obj' tree, so that 'make obj'
1.116 lukem 295: will work correctly. [/usr/obj]
1.15 cgd 296:
1.116 lukem 297: BINGRP Binary group. [wheel]
1.15 cgd 298:
1.116 lukem 299: BINOWN Binary owner. [root]
1.15 cgd 300:
1.116 lukem 301: BINMODE Binary mode. [555]
1.15 cgd 302:
1.116 lukem 303: NONBINMODE Mode for non-executable files. [444]
1.15 cgd 304:
1.116 lukem 305: MANDIR Base path for manual installation. [/usr/share/man/cat]
1.15 cgd 306:
1.116 lukem 307: MANGRP Manual group. [wheel]
1.15 cgd 308:
1.116 lukem 309: MANOWN Manual owner. [root]
1.15 cgd 310:
1.116 lukem 311: MANMODE Manual mode. [${NONBINMODE}]
1.15 cgd 312:
1.21 christos 313: MANINSTALL Manual installation type: maninstall, catinstall, or both
1.76 fair 314:
315: LDSTATIC Control program linking; if set blank, link everything
1.129 lukem 316: dynamically. If set to "-static", link everything statically.
1.76 fair 317: If not set, programs link according to their makefile.
1.21 christos 318:
1.116 lukem 319: LIBDIR Base path for library installation. [/usr/lib]
1.15 cgd 320:
1.116 lukem 321: LINTLIBDIR Base path for lint(1) library installation. [/usr/libdata/lint]
1.15 cgd 322:
1.116 lukem 323: LIBGRP Library group. [${BINGRP}]
1.15 cgd 324:
1.116 lukem 325: LIBOWN Library owner. [${BINOWN}]
1.15 cgd 326:
1.116 lukem 327: LIBMODE Library mode. [${NONBINMODE}]
1.15 cgd 328:
329: DOCDIR Base path for system documentation (e.g. PSD, USD, etc.)
1.116 lukem 330: installation. [/usr/share/doc]
1.62 simonb 331:
332: HTMLDOCDIR Base path for html system documentation installation.
333: [/usr/share/doc/html]
1.15 cgd 334:
1.116 lukem 335: DOCGRP Documentation group. [wheel]
1.15 cgd 336:
1.116 lukem 337: DOCOWN Documentation owner. [root]
1.15 cgd 338:
1.116 lukem 339: DOCMODE Documentation mode. [${NONBINMODE}]
1.15 cgd 340:
1.84 kleink 341: NLSDIR Base path for Native Language Support files installation.
1.15 cgd 342: [/usr/share/nls]
1.1 cgd 343:
1.116 lukem 344: NLSGRP Native Language Support files group. [wheel]
1.1 cgd 345:
1.116 lukem 346: NLSOWN Native Language Support files owner. [root]
1.1 cgd 347:
1.116 lukem 348: NLSMODE Native Language Support files mode. [${NONBINMODE}]
1.1 cgd 349:
1.32 mikel 350: STRIPFLAG The flag passed to the install program to cause the binary
1.1 cgd 351: to be stripped. This is to be used when building your
352: own install script so that the entire system can be made
1.116 lukem 353: stripped/not-stripped using a single knob. [-s]
1.1 cgd 354:
1.2 cgd 355: COPY The flag passed to the install program to cause the binary
356: to be copied rather than moved. This is to be used when
357: building our own install script so that the entire system
358: can either be installed with copies, or with moves using
1.116 lukem 359: a single knob. [-c]
1.15 cgd 360:
1.134 ! lukem 361: Additionally, the following variables may be set by <bsd.own.mk> or in a
1.17 thorpej 362: make configuration file to modify the behaviour of the system build
363: process (default values are in brackets along with comments, if set by
1.134 ! lukem 364: <bsd.own.mk>):
1.33 jonathan 365:
1.116 lukem 366: OBJECT_FMT Object file format. [set to "ELF" on architectures that
1.50 thorpej 367: use ELF -- currently if ${MACHINE_ARCH} is "alpha",
368: "mipsel", "mipseb", "powerpc", "sparc", "sparc64",
1.77 simonb 369: "i386" and some m68k machines, or set to "a.out" on
370: other architectures].
1.33 jonathan 371:
1.103 thorpej 372: TOOLCHAIN_MISSING
373: If "yes", this indicates that the platform being built
374: does not have a working in-tree toolchain. If the
375: MACHINE_ARCH in question falls into this category, the
376: variable is conditionally assigned the value "yes".
377: Otherwise, the variable is unconditionally assigned the
378: value "no".
379:
380: If TOOLCHAIN_MISSING is "yes", the variables MKBFD, MKGCC,
381: and MKGDB are unconditionally assigned the value "no".
382:
383: EXTERNAL_TOOLCHAIN
384: This variable is not directly set by <bsd.own.mk>, but
385: including <bsd.own.mk> is the canonical way to gain
386: access to this variable. The variable should be defined
387: either in the user's environment or in the user's mk.conf
388: file. If defined, this variable indicates the root of
389: an external toolchain which will be used to build the
390: tree. For example, if a platform is a TOOLCHAIN_MISSING
391: platform, EXTERNAL_TOOLCHAIN can be used to re-enable the
392: cross-compile framework.
393:
394: If EXTERNAL_TOOLCHAIN is defined, the variable MKGCC is
395: unconditionally assigned the value "no", since the external
396: version of the compiler may not be able to build the library
397: components of the in-tree compiler.
398:
399: NOTE: This variable is not yet used in as many places as
400: it should be. Expect the exact semantics of this variable
401: to change in the short term as parts of the cross-compile
402: framework continue to be cleaned up.
1.1 cgd 403:
1.134 ! lukem 404: <bsd.own.mk> is generally useful when building your own Makefiles so that
1.1 cgd 405: they use the same default owners etc. as the rest of the tree.
1.131 lukem 406:
407:
408: =-=-=-=-= bsd.dep.mk =-=-=-=-=
409:
410: The include file <bsd.dep.mk> contains the default targets for building
1.133 lukem 411: .depend files. It creates .d files from entries in SRCS and DPSRCS
412: that are C, C++, or Objective C source files, and builds .depend from the
413: .d files. All other files in SRCS and all of DPSRCS will be used as
414: dependencies for the .d files. In order for this to function correctly,
1.132 lukem 415: it should be .included after all other .mk files and directives that may
416: modify SRCS or DPSRCS. It uses the following variables:
417:
418: SRCS List of source files to build the program.
419:
420: DPSRCS List of source files which are needed for generating
421: dependencies, but are not needed in ${SRCS}.
1.1 cgd 422:
423:
1.118 lukem 424: =-=-=-=-= bsd.files.mk =-=-=-=-=
1.106 thorpej 425:
1.118 lukem 426: The include file <bsd.files.mk> handles the FILES variables and is included
1.134 ! lukem 427: from <bsd.lib.mk> and <bsd.prog.mk>, and uses the following variables:
1.124 lukem 428:
429: FILES The list of files to install.
430:
431: FILESOWN File owner. [${BINOWN}]
432:
433: FILESGRP File group. [${BINGRP}]
434:
435: FILESMODE File mode. [${BINMODE}]
436:
437: FILESDIR The location to install the files.
438:
439: FILESNAME Optional name to install each file as.
440:
441: FILESDIR.<fn> The location to install the specific file <fn>.
442:
443: FILESNAME.<fn> Optional name to install <fn> as.
1.106 thorpej 444:
445:
1.118 lukem 446: =-=-=-=-= bsd.gcc.mk =-=-=-=-=
1.113 thorpej 447:
448: The include file <bsd.gcc.mk> computes various parameters related to GCC
449: support libraries. It defines no targets. <bsd.own.mk> MUST be included
1.134 ! lukem 450: before <bsd.gcc.mk>.
1.113 thorpej 451:
1.134 ! lukem 452: The primary users of <bsd.gcc.mk> are <bsd.prog.mk> and <bsd.lib.mk>, each
1.113 thorpej 453: of which need to know where to find certain GCC support libraries.
454:
1.134 ! lukem 455: The behavior of <bsd.gcc.mk> is influenced by the EXTERNAL_TOOLCHAIN variable,
1.113 thorpej 456: which is generally set by the user. If EXTERNAL_TOOLCHAIN it set, then
457: the compiler is asked where to find the support libraries, otherwise the
458: support libraries are found in ${DESTDIR}/usr/lib.
459:
1.134 ! lukem 460: <bsd.gcc.mk> sets the following variables:
1.113 thorpej 461:
1.118 lukem 462: _GCC_CRTBEGIN The full path name to crtbegin.o.
463:
464: _GCC_CRTBEGINS The full path name to crtbeginS.o.
465:
466: _GCC_CRTEND The full path name to crtend.o.
467:
468: _GCC_CRTENDS The full path name to crtendS.o.
469:
470: _GCC_LIBGCCDIR The directory where libgcc.a is located.
471:
472:
473: =-=-=-=-= bsd.inc.mk =-=-=-=-=
474:
1.134 ! lukem 475: The include file <bsd.inc.mk> defines the includes target and uses the
1.118 lukem 476: variables:
477:
1.124 lukem 478: INCS The list of include files.
1.118 lukem 479:
480: INCSDIR The location to install the include files.
481:
482: INCSNAME Target name of the include file, if only one; same as
483: FILESNAME, but for include files.
484:
1.134 ! lukem 485: INCSYMLINKS Similar to SYMLINKS in <bsd.links.mk>, except that these
! 486: are installed in the 'includes' target and not the
! 487: (much later) 'install' target.
! 488:
1.118 lukem 489: INCSNAME_<file> The name file <file> should be installed as, if not <file>,
490: same as FILESNAME_<file>, but for include files.
491:
492:
493: =-=-=-=-= bsd.info.mk =-=-=-=-=
494:
495: The include file <bsd.info.mk> is used to generate and install GNU Info
496: documentation from respective Texinfo source files. It defines three
497: implicit targets (.txi.info, .texi.info, and .texinfo.info), and uses the
498: following variables:
499:
500: TEXINFO List of Texinfo source files. Info documentation will
501: consist of single files with the extension replaced by
502: .info.
503:
504: INFOFLAGS Flags to pass to makeinfo. []
505:
506:
507: =-=-=-=-= bsd.kernobj.mk =-=-=-=-=
508:
509: The include file <bsd.kernobj.mk> defines variables related to the
510: location of kernel sources and object directories.
511:
512: KERNSRCDIR Is the location of the top of the kernel src.
1.124 lukem 513: [${_SRC_TOP_}/sys]
1.118 lukem 514:
1.124 lukem 515: KERNARCHDIR Is the location of the machine dependent kernel sources.
516: [arch/${MACHINE}]
1.120 lukem 517:
1.124 lukem 518: KERNCONFDIR Is where the configuration files for kernels are found.
519: [${KERNSRCDIR}/${KERNARCHDIR}/conf]
1.118 lukem 520:
521: KERNOBJDIR Is the kernel build directory. The kernel GENERIC for
522: instance will be compiled in ${KERNOBJDIR}/GENERIC.
523: The default value is
524: ${MAKEOBJDIRPREFIX}${KERNSRCDIR}/${KERNARCHDIR}/compile
525: if it exists or the target 'obj' is being made.
526: Otherwise the default is
527: ${KERNSRCDIR}/${KERNARCHDIR}/compile.
528:
529: It is important that Makefiles (such as those under src/distrib) that
1.134 ! lukem 530: wish to find compiled kernels use <bsd.kernobj.mk> and ${KERNOBJDIR}
1.118 lukem 531: rather than make assumptions about the location of the compiled kernel.
532:
533:
534: =-=-=-=-= bsd.kinc.mk =-=-=-=-=
535:
536: The include file <bsd.kinc.mk> defines the many targets (includes,
537: subdirectories, etc.), and is used by kernel makefiles to handle
538: include file installation. It is intended to be included alone, by
1.134 ! lukem 539: kernel Makefiles. It uses similar variables to <bsd.inc.mk>.
! 540: Please see <bsd.kinc.mk> for more details, and keep the documentation
! 541: in that file up to date.
1.118 lukem 542:
543:
544: =-=-=-=-= bsd.lib.mk =-=-=-=-=
545:
546: The include file <bsd.lib.mk> has support for building libraries. It has
547: the same eight targets as <bsd.prog.mk>: all, clean, cleandir, depend,
548: includes, install, lint, and tags. Additionally, it has a checkver target
549: which checks for installed shared object libraries whose version is greater
550: that the version of the source. It has a limited number of suffixes,
1.134 ! lukem 551: consistent with the current needs of the BSD tree. <bsd.lib.mk> includes
1.118 lukem 552: <bsd.shlib.mk> to get shared library parameters.
553:
554: It sets/uses the following variables:
555:
556: LIB The name of the library to build.
557:
558: LIBDIR Target directory for libraries.
559:
560: SHLIBINSTALLDIR Target directory for shared libraries if ${USE_SHLIBDIR}
561: is "yes".
562:
563: USE_SHLIBDIR If "yes", use ${SHLIBINSTALLDIR} instead of ${LIBDIR}
564: as the path to install shared libraries to.
565: USE_SHLIBDIR must be defined before <bsd.own.mk> is included.
1.130 lukem 566: Default: no
1.118 lukem 567:
568: LINTLIBDIR Target directory for lint libraries.
569:
570: LIBGRP Library group.
571:
572: LIBOWN Library owner.
573:
574: LIBMODE Library mode.
575:
576: LDADD Additional loader objects.
577:
578: MAN The manual pages to be installed (use a .1 - .9 suffix).
579:
580: NOCHECKVER_<library>
581: NOCHECKVER If set, disables checking for installed shared object
582: libraries with versions greater than the source. A
583: particular library name, without the "lib" prefix, may
584: be appended to the variable name to disable the check for
585: only that library.
586:
587: SRCS List of source files to build the library. Suffix types
588: .s, .c, and .f are supported. Note, .s files are preferred
589: to .c files of the same name. (This is not the default for
590: versions of make.)
591:
592: The include file <bsd.lib.mk> includes the file named "../Makefile.inc"
593: if it exists, as well as the include file <bsd.man.mk>.
594:
595: It has rules for building profiled objects; profiled libraries are
596: built by default.
597:
598: Libraries are ranlib'd when made.
599:
600:
601: =-=-=-=-= bsd.links.mk =-=-=-=-=
602:
603: The include file <bsd.links.mk> handles the LINKS and SYMLINKS variables
1.134 ! lukem 604: and is included from from <bsd.lib.mk> and <bsd.prog.mk>.
! 605:
! 606: LINKS The list of hard links, consisting of pairs of paths:
! 607: source-file target-file
! 608: ${DESTDIR} is prepended to both paths before linking.
! 609: For example, to link /bin/test and /bin/[, use:
! 610: LINKS=/bin/test /bin/[
! 611:
! 612: SYMLINKS The list of symbolic links, consisting of pairs of paths:
! 613: source-file target-file
! 614: ${DESTDIR} is only prepended to target-file before linking.
! 615: For example, to symlink /usr/bin/tar to /bin/tar resulting
! 616: in ${DESTDIR}/usr/bin/tar -> /bin/tar:
! 617: SYMLINKS=/bin/tar /usr/bin/tar
1.118 lukem 618:
619:
620: =-=-=-=-= bsd.man.mk =-=-=-=-=
621:
622: The include file <bsd.man.mk> handles installing manual pages and their
623: links.
624:
625: It has a two targets:
626:
627: maninstall:
628: Install the manual page sources and their links.
629: catinstall:
630: Install the preformatted manual pages and their links.
631:
632: It sets/uses the following variables:
633:
634: MANDIR Base path for manual installation.
635:
636: MANGRP Manual group.
637:
638: MANOWN Manual owner.
639:
640: MANMODE Manual mode.
641:
642: MANSUBDIR Subdirectory under the manual page section, i.e. "/vax"
643: or "/tahoe" for machine specific manual pages.
644:
645: MAN The manual pages to be installed (use a .1 - .9 suffix).
646:
647: MLINKS List of manual page links (using a .1 - .9 suffix). The
648: linked-to file must come first, the linked file second,
649: and there may be multiple pairs. The files are soft-linked.
650:
651: The include file <bsd.man.mk> includes a file named "../Makefile.inc" if
652: it exists.
653:
654:
655: =-=-=-=-= bsd.obj.mk =-=-=-=-=
656:
657: The include file <bsd.obj.mk> defines targets related to the creation
658: and use of separated object and source directories.
659:
660: If an environment variable named MAKEOBJDIRPREFIX is set, make(1) uses
661: ${MAKEOBJDIRPREFIX}${.CURDIR} as the name of the object directory if
662: it exists. Otherwise make(1) looks for the existence of a
663: subdirectory (or a symlink to a directory) of the source directory
664: into which built targets should be placed. If an environment variable
665: named MAKEOBJDIR is set, make(1) uses its value as the name of the
666: object directory; failing that, make first looks for a subdirectory
667: named "obj.${MACHINE}", and if that doesn't exist, it looks for "obj".
668:
669: Object directories are not created automatically by make(1) if they
670: don't exist; you need to run a separate "make obj". (This will happen
671: during a top-level build if "MKOBJDIRS" is set to a value other than
672: "no"). When the source directory is a subdirectory of ${BSDSRCDIR} --
673: and this is determined by a simple string prefix comparison -- object
674: directories are created in a separate object directory tree, and a
675: symlink to the object directory in that tree is created in the source
676: directory; otherwise, "make obj" assumes that you're not in the main
677: source tree and that it's not safe to use a separate object tree.
678:
679: Several variables used by <bsd.obj.mk> control exactly what
680: directories and links get created during a "make obj":
681:
682: MAKEOBJDIR If set, this is the component name of the object
683: directory.
684:
685: OBJMACHINE If this is set but MAKEOBJDIR is not set, creates
686: object directories or links named "obj.${MACHINE}";
687: otherwise, just creates ones named "obj".
688:
689: USR_OBJMACHINE If set, and the current directory is a subdirectory of
690: ${BSDSRCDIR}, create object directory in the
691: corresponding subdirectory of ${BSDOBJDIR}.${MACHINE};
692: otherwise, create it in the corresponding subdirectory
693: of ${BSDOBJDIR}
1.113 thorpej 694:
1.118 lukem 695: BUILDID If set, the contents of this variable are appended
696: to the object directory name. If OBJMACHINE is also
697: set, ".${BUILDID}" is added after ".${MACHINE}".
1.113 thorpej 698:
1.106 thorpej 699:
1.118 lukem 700: =-=-=-=-= bsd.prog.mk =-=-=-=-=
1.106 thorpej 701:
1.1 cgd 702: The include file <bsd.prog.mk> handles building programs from one or
703: more source files, along with their manual pages. It has a limited number
1.134 ! lukem 704: of suffixes, consistent with the current needs of the BSD tree.
! 705: <bsd.prog.mk> includes <bsd.shlib.mk> to get shared library parameters.
1.1 cgd 706:
1.16 jtc 707: It has eight targets:
1.1 cgd 708:
709: all:
1.102 thorpej 710: build the program and its manual page. This also
711: creates a GDB initialization file (.gdbinit) in
712: the objdir. The .gdbinit file sets the shared library
713: prefix to ${DESTDIR} to facilitate cross-debugging.
1.1 cgd 714: clean:
715: remove the program, any object files and the files a.out,
1.24 mikel 716: Errs, errs, mklog, and ${PROG}.core.
1.1 cgd 717: cleandir:
718: remove all of the files removed by the target clean, as
719: well as .depend, tags, and any manual pages.
1.42 lukem 720: `distclean' is a synonym for `cleandir'.
1.1 cgd 721: depend:
722: make the dependencies for the source files, and store
723: them in the file .depend.
1.16 jtc 724: includes:
725: install any header files.
1.1 cgd 726: install:
727: install the program and its manual pages; if the Makefile
728: does not itself define the target install, the targets
729: beforeinstall and afterinstall may also be used to cause
730: actions immediately before and after the install target
731: is executed.
732: lint:
733: run lint on the source files
734: tags:
735: create a tags file for the source files.
736:
737: It sets/uses the following variables:
738:
739: BINGRP Binary group.
740:
741: BINOWN Binary owner.
742:
743: BINMODE Binary mode.
744:
745: CLEANFILES Additional files to remove for the clean and cleandir targets.
746:
747: COPTS Additional flags to the compiler when creating C objects.
1.112 thorpej 748:
1.125 lukem 749: COPTS.<fn> Additional flags to the compiler when creating the
750: C objects for <fn>.
751: For <fn>.[ly], "<fn>.c" must be used.
752:
1.112 thorpej 753: CPUFLAGS Additional flags to the compiler/assembler to select
754: CPU instruction set options, CPU tuning options, etc.
1.35 lukem 755:
1.125 lukem 756: CPUFLAGS.<fn> Additional flags to the compiler/assembler for <fn>.
757: For <fn>.[ly], "<fn>.c" must be used.
758:
1.124 lukem 759: CPPFLAGS Additional flags to the C pre-processor.
1.125 lukem 760:
761: CPPFLAGS.<fn> Additional flags to the C pre-processor for <fn>.
762: For <fn>.[ly], "<fn>.c" must be used.
1.102 thorpej 763:
764: GDBINIT List of GDB initialization files to add to "source"
765: directives in the .gdbinit file that is created in the
766: objdir.
1.1 cgd 767:
768: LDADD Additional loader objects. Usually used for libraries.
769: For example, to load with the compatibility and utility
770: libraries, use:
771:
1.5 jtc 772: LDADD+=-lutil -lcompat
1.1 cgd 773:
774: LDFLAGS Additional loader flags.
775:
1.134 ! lukem 776: LINKS See <bsd.links.mk>
! 777:
! 778: SYMLINKS See <bsd.links.mk>
1.1 cgd 779:
1.15 cgd 780: MAN Manual pages (should end in .1 - .9). If no MAN variable is
1.8 cgd 781: defined, "MAN=${PROG}.1" is assumed.
1.1 cgd 782:
783: PROG The name of the program to build. If not supplied, nothing
784: is built.
785:
1.88 thorpej 786: PROG_CXX If defined, the name of the program to build. Also
787: causes <bsd.prog.mk> to link the program with the C++
788: compiler rather than the C compiler. PROG_CXX overrides
789: the value of PROG if PROG is also set.
1.87 thorpej 790:
1.21 christos 791: PROGNAME The name that the above program will be installed as, if
792: different from ${PROG}.
793:
1.37 tv 794: SRCS List of source files to build the program. If SRCS is not
1.1 cgd 795: defined, it's assumed to be ${PROG}.c.
1.108 jwise 796:
797: DPSRCS List of source files which are needed for generating
798: dependencies, but are not needed in ${SRCS}.
1.1 cgd 799:
800: DPADD Additional dependencies for the program. Usually used for
801: libraries. For example, to depend on the compatibility and
802: utility libraries use:
803:
1.5 jtc 804: DPADD+=${LIBCOMPAT} ${LIBUTIL}
1.1 cgd 805:
806: The following libraries are predefined for DPADD:
807:
1.21 christos 808: LIBCRT0?= ${DESTDIR}/usr/lib/crt0.o
1.99 itojun 809: LIBBZ2?= ${DESTDIR}/usr/lib/libbz2.a
1.21 christos 810: LIBC?= ${DESTDIR}/usr/lib/libc.a
811: LIBC_PIC?= ${DESTDIR}/usr/lib/libc_pic.a
1.99 itojun 812: LIBCDK?= ${DESTDIR}/usr/lib/libcdk.a
813: LIBCOM_ERR?= ${DESTDIR}/usr/lib/libcom_err.a
1.21 christos 814: LIBCOMPAT?= ${DESTDIR}/usr/lib/libcompat.a
815: LIBCRYPT?= ${DESTDIR}/usr/lib/libcrypt.a
1.99 itojun 816: LIBCRYPTO?= ${DESTDIR}/usr/lib/libcrypto.a
817: LIBCRYPTO_IDEA?=${DESTDIR}/usr/lib/libcrypto_idea.a
1.105 itojun 818: LIBCRYPTO_MDC2?=${DESTDIR}/usr/lib/libcrypto_mdc2.a
1.99 itojun 819: LIBCRYPTO_RC5?= ${DESTDIR}/usr/lib/libcrypto_rc5.a
1.21 christos 820: LIBCURSES?= ${DESTDIR}/usr/lib/libcurses.a
821: LIBDBM?= ${DESTDIR}/usr/lib/libdbm.a
822: LIBDES?= ${DESTDIR}/usr/lib/libdes.a
823: LIBEDIT?= ${DESTDIR}/usr/lib/libedit.a
1.114 provos 824: LIBEVENT?= ${DESTDIR}/usr/lib/libevent.a
1.73 blymn 825: LIBFORM?= ${DESTDIR}/usr/lib/libform.a
1.21 christos 826: LIBGCC?= ${DESTDIR}/usr/lib/libgcc.a
827: LIBGNUMALLOC?= ${DESTDIR}/usr/lib/libgnumalloc.a
1.99 itojun 828: LIBGSSAPI?= ${DESTDIR}/usr/lib/libgssapi.a
829: LIBHDB?= ${DESTDIR}/usr/lib/libhdb.a
1.70 itojun 830: LIBINTL?= ${DESTDIR}/usr/lib/libintl.a
1.49 itojun 831: LIBIPSEC?= ${DESTDIR}/usr/lib/libipsec.a
1.99 itojun 832: LIBKADM?= ${DESTDIR}/usr/lib/libkadm.a
833: LIBKADM5CLNT?= ${DESTDIR}/usr/lib/libkadm5clnt.a
834: LIBKADM5SRV?= ${DESTDIR}/usr/lib/libkadm5srv.a
835: LIBKAFS?= ${DESTDIR}/usr/lib/libkafs.a
1.21 christos 836: LIBKDB?= ${DESTDIR}/usr/lib/libkdb.a
837: LIBKRB?= ${DESTDIR}/usr/lib/libkrb.a
1.99 itojun 838: LIBKRB5?= ${DESTDIR}/usr/lib/libkrb5.a
839: LIBKSTREAM?= ${DESTDIR}/usr/lib/libkstream.a
1.21 christos 840: LIBKVM?= ${DESTDIR}/usr/lib/libkvm.a
841: LIBL?= ${DESTDIR}/usr/lib/libl.a
842: LIBM?= ${DESTDIR}/usr/lib/libm.a
1.53 blymn 843: LIBMENU?= ${DESTDIR}/usr/lib/libmenu.a
1.21 christos 844: LIBMP?= ${DESTDIR}/usr/lib/libmp.a
1.25 christos 845: LIBNTP?= ${DESTDIR}/usr/lib/libntp.a
1.99 itojun 846: LIBOBJC?= ${DESTDIR}/usr/lib/libobjc.a
847: LIBOSSAUDIO?= ${DESTDIR}/usr/lib/libossaudio.a
1.21 christos 848: LIBPC?= ${DESTDIR}/usr/lib/libpc.a
849: LIBPCAP?= ${DESTDIR}/usr/lib/libpcap.a
1.99 itojun 850: LIBPCI?= ${DESTDIR}/usr/lib/libpci.a
1.21 christos 851: LIBPLOT?= ${DESTDIR}/usr/lib/libplot.a
1.100 thorpej 852: LIBPMC?= ${DESTDIR}/usr/lib/libpmc.a
1.26 kleink 853: LIBPOSIX?= ${DESTDIR}/usr/lib/libposix.a
1.110 thorpej 854: LIBPTHREAD?= ${DESTDIR}/usr/lib/libpthread.a
855: LIBPTHREAD_DBG?=${DESTDIR}/usr/lib/libpthread_dbg.a
1.21 christos 856: LIBRESOLV?= ${DESTDIR}/usr/lib/libresolv.a
1.99 itojun 857: LIBRMT?= ${DESTDIR}/usr/lib/librmt.a
858: LIBROKEN?= ${DESTDIR}/usr/lib/libroken.a
1.21 christos 859: LIBRPCSVC?= ${DESTDIR}/usr/lib/librpcsvc.a
1.110 thorpej 860: LIBRT?= ${DESTDIR}/usr/lib/librt.a
1.21 christos 861: LIBSKEY?= ${DESTDIR}/usr/lib/libskey.a
1.99 itojun 862: LIBSS?= ${DESTDIR}/usr/lib/libss.a
863: LIBSSL?= ${DESTDIR}/usr/lib/libssl.a
864: LIBSKEY?= ${DESTDIR}/usr/lib/libskey.a
865: LIBSL?= ${DESTDIR}/usr/lib/libsl.a
1.21 christos 866: LIBTERMCAP?= ${DESTDIR}/usr/lib/libtermcap.a
1.99 itojun 867: LIBUSBHID?= ${DESTDIR}/usr/lib/libusbhid.a
1.21 christos 868: LIBUTIL?= ${DESTDIR}/usr/lib/libutil.a
869: LIBWRAP?= ${DESTDIR}/usr/lib/libwrap.a
870: LIBY?= ${DESTDIR}/usr/lib/liby.a
871: LIBZ?= ${DESTDIR}/usr/lib/libz.a
1.1 cgd 872:
873: SHAREDSTRINGS If defined, a new .c.o rule is used that results in shared
1.12 christos 874: strings, using xstr(1). Note that this will not work with
875: parallel makes.
1.1 cgd 876:
1.59 jlam 877: STRIPFLAG The flag passed to the install program to cause the binary
1.1 cgd 878: to be stripped.
879:
880: SUBDIR A list of subdirectories that should be built as well.
881: Each of the targets will execute the same target in the
882: subdirectories.
883:
1.21 christos 884: SCRIPTS A list of interpreter scripts [file.{sh,csh,pl,awk,...}].
885: These are installed exactly like programs.
886:
887: SCRIPTSNAME The name that the above program will be installed as, if
888: different from ${SCRIPTS}. These can be further specialized
889: by setting SCRIPTSNAME_<script>.
890:
1.124 lukem 891: FILES See description of <bsd.files.mk>.
1.21 christos 892:
1.106 thorpej 893: SHLINKDIR Target directory for shared linker. See description of
894: <bsd.own.mk> for additional information about this variable.
1.130 lukem 895:
896: USE_LIBSTDCXX If "no", the support libraries needed for C++ programs
897: are set to `-lsupc++ -lm', rather than `-lstdc++ -lm'.
898: Default: yes
1.85 lukem 899:
1.1 cgd 900: The include file <bsd.prog.mk> includes the file named "../Makefile.inc"
901: if it exists, as well as the include file <bsd.man.mk>.
902:
903: Some simple examples:
904:
905: To build foo from foo.c with a manual page foo.1, use:
906:
907: PROG= foo
908:
909: .include <bsd.prog.mk>
910:
911: To build foo from foo.c with a manual page foo.2, add the line:
912:
1.9 cgd 913: MAN= foo.2
1.1 cgd 914:
915: If foo does not have a manual page at all, add the line:
916:
1.75 agc 917: MKMAN= no
1.1 cgd 918:
919: If foo has multiple source files, add the line:
920:
921: SRCS= a.c b.c c.c d.c
922:
923:
1.118 lukem 924: =-=-=-=-= bsd.rpc.mk =-=-=-=-=
925:
926: The include file <bsd.rpc.mk> contains a makefile fragment used to
927: construct source files built by rpcgen.
1.72 sommerfe 928:
1.118 lukem 929: The following macros may be defined in makefiles which include
930: <bsd.rpc.mk> in order to control which files get built and how they
931: are to be built:
1.21 christos 932:
1.118 lukem 933: RPC_INCS: construct .h file from .x file
1.120 lukem 934: RPC_XDRFILES: construct _xdr.c from .x file
1.118 lukem 935: (for marshalling/unmarshalling data types)
936: RPC_SVCFILES: construct _svc.c from .x file
937: (server-side stubs)
938: RPC_SVCFLAGS: Additional flags passed to builds of RPC_SVCFILES.
1.21 christos 939:
1.118 lukem 940: RPC_XDIR: Directory containing .x/.h files
1.23 christos 941:
942:
1.118 lukem 943: =-=-=-=-= bsd.shlib.mk =-=-=-=-=
1.21 christos 944:
1.118 lukem 945: The include file <bsd.shlib.mk> computes parameters for shared library
946: installation and use. It defines no targets. <bsd.own.mk> MUST be
1.134 ! lukem 947: included before <bsd.shlib.mk>.
1.21 christos 948:
1.134 ! lukem 949: <bsd.own.mk> sets the following variables, if they are not already defined
1.118 lukem 950: (defaults are in brackets):
1.21 christos 951:
1.118 lukem 952: SHLIBINSTALLDIR If ${USE_SHLIBDIR} is "yes", use ${SHLIBINSTALLDIR} instead of
953: ${LIBDIR} as the base path for shared library installation.
954: [/lib]
1.21 christos 955:
1.118 lukem 956: SHLIBDIR The path to USE_SHLIBDIR shared libraries to use when building
957: a program. [/lib for programs in /bin and /sbin, /usr/lib
958: for all others.]
1.81 wiz 959:
1.118 lukem 960: _LIBSODIR Set to ${SHLIBINSTALLDIR} if ${USE_SHLIBDIR} is "yes",
961: otherwise set to ${LIBDIR}
1.81 wiz 962:
1.118 lukem 963: SHLINKINSTALLDIR Base path for shared linker. [/libexec]
1.39 cgd 964:
1.118 lukem 965: SHLINKDIR Path to use for shared linker when building a program.
966: [/libexec for programs in /bin and /sbin, /usr/libexec for
967: all others.]
1.39 cgd 968:
1.13 christos 969:
1.118 lukem 970: =-=-=-=-= bsd.subdir.mk =-=-=-=-=
1.13 christos 971:
1.118 lukem 972: The include file <bsd.subdir.mk> contains the default targets for building
1.120 lukem 973: subdirectories. It has the same eight targets as <bsd.prog.mk>: all,
1.118 lukem 974: clean, cleandir, depend, includes, install, lint, and tags. For all of
1.120 lukem 975: the directories listed in the variable SUBDIR, the specified directory
1.118 lukem 976: will be visited and the target made. There is also a default target which
977: allows the command "make subdir" where subdir is any directory listed in
978: the variable SUBDIR.
1.47 tv 979:
1.118 lukem 980: As a special case, the use of a token .WAIT as an entry in SUBDIR acts
981: as a synchronization barrier when multiple make jobs are run; subdirs
982: before the .WAIT must complete before any subdirs after .WAIT are
983: started. See make(1) for some caveats on use of .WAIT and other
984: special sources.
1.47 tv 985:
986:
1.118 lukem 987: =-=-=-=-= bsd.sys.mk =-=-=-=-=
1.47 tv 988:
1.13 christos 989: The include file <bsd.sys.mk> is used by <bsd.prog.mk> and
1.14 cgd 990: <bsd.lib.mk>. It contains overrides that are used when building
1.133 lukem 991: the NetBSD source tree.
992:
993: The following variables control how various files are compiled/built.
994: (Note that these may be overridden in <bsd.own.mk> if USETOOLS=yes):
995:
996: AR Create, modify, and extract from archives. [ar]
997:
998: ARFLAGS Options to ${AR}. [rl]
999:
1000: CC C compiler. [cc]
1001:
1002: CFLAGS Options to ${CC}. [Usually -O or -O2]
1003:
1004: CPP C Pre-Processor. [cpp]
1005:
1006: CPPFLAGS Options to ${CPP}. []
1007:
1008: CPUFLAGS Optimization flags for ${CC}
1009:
1010: CXX C++ compiler. [c++]
1011:
1012: CXXFLAGS Options to ${CXX}. [${CFLAGS}]
1013:
1014: ELF2ECOFF Convert ELF-format executable to ECOFF. [elf2ecoff]
1015:
1016: FC Fortran compiler. [f77]
1017:
1018: FFLAGS Options to {$FC}. [-O]
1019:
1020: INSTALL install(1) command. [install]
1021:
1022: LEX Lexical analyzer. [lex]
1023:
1024: LFLAGS Options to ${LEX}. []
1025:
1026: LD Linker. [ld]
1027:
1028: LDFLAGS Options to ${LD}. []
1029:
1030: LINT C program verifier. [lint]
1031:
1032: LINTFLAGS Options to ${LINT}. [-chapbxzF]
1033:
1034: LORDER List dependencies for object files. [lorder]
1035:
1036: MAKE make(1). [make]
1037:
1038: MKDEP Construct Makefile dependency list. [mkdep]
1039:
1040: NM List symbols from object files. [nm]
1041:
1042: PC Pascal compiler. [pc] (Not present)
1043:
1044: PFLAGS Options to ${PC}. []
1045:
1046: OBJC Objective C compiler. [${CC}]
1047:
1048: OBJCFLAGS Options to ${OBJC}. [${CFLAGS}]
1049:
1050: OBJCOPY Copy and translate object files. [objcopy]
1051:
1052: RANLIB Generate index to archive. [ranlib]
1053:
1054: SHELL Shell. [sh]
1055:
1056: SIZE List section sizes and total size. [size]
1057:
1058: STRIP Discard symbols from object files. [strip]
1059:
1060: TSORT Topological sort of a directed graph. [tsort -q]
1061:
1062: YACC LALR(1) parser generator. [yacc]
1063:
1064: YFLAGS Options to ${YACC}. []
1065:
1066: YHEADER If defined, add "-d" to YFLAGS, and add dependencies
1067: from <file>.y to <file>.h and <file>.c, and add
1068: <foo>.h to CLEANFILES.
1069:
1070: YPREFIX If defined, add "-p ${YPREFIX}" to YFLAGS.
1071:
1.116 lukem 1072:
1073: The following variables are defined to commands to perform the
1074: appropriate operation, with the default in [brackets].
1075: (Note that these are overridden in <bsd.own.mk> if USETOOLS=yes):
1076:
1077: TOOL_ASN1_COMPILE ASN1 compiler. [asn1_compile]
1078:
1079: TOOL_CAP_MKDB Create capability database. [cap_mkdb]
1080:
1081: TOOL_CAT Concatenate and print files. [cat]
1082:
1083: TOOL_CKSUM Display file checksums. [cksum]
1084:
1085: TOOL_COMPILE_ET Error table compiler. [compile_et]
1086:
1087: TOOL_CONFIG Build kernel compilation directories. [config]
1088:
1089: TOOL_CRUNCHGEN Generate crunched binary build environment. [crunchgen]
1090:
1091: TOOL_CTAGS Create a tags file. [ctags]
1092:
1093: TOOL_DB Manipulate db(3) databases. [db]
1094:
1095: TOOL_EQN Format equations for groff. [eqn]
1096:
1097: TOOL_FGEN IEEE 1275 Open Firmware FCode Tokenizer. [fgen]
1098:
1099: TOOL_GENCAT Generate NLS message catalogs. [gencat]
1100:
1101: TOOL_GROFF Front end for groff document formatting system. [groff]
1102:
1103: TOOL_HEXDUMP Ascii, decimal, hexadecimal, octal dump. [hexdump]
1104:
1105: TOOL_INDXBIB Make bibliographic database's inverted index. [indxbib]
1106:
1107: TOOL_INSTALLBOOT Install disk bootstrap software. [installboot]
1108:
1109: TOOL_INSTALL_INFO Update info/dir entries. [install-info]
1110:
1111: TOOL_M4 M4 macro language processor. [m4]
1112:
1113: TOOL_MAKEFS Create file system image from directory tree. [makefs]
1114:
1115: TOOL_MAKEINFO Translate Texinfo documents. [makeinfo]
1116:
1117: TOOL_MAKEWHATIS Create a whatis.db database. [makewhatis]
1118:
1119: TOOL_MDSETIMAGE Set kernel RAM disk image. [mdsetimage]
1120:
1121: TOOL_MENUC Menu compiler. [menuc]
1122:
1123: TOOL_MKCSMAPPER Make charset mapping table. [mkcsmapper]
1124:
1125: TOOL_MKESDB Make encoding scheme database. [mkesdb]
1126:
1127: TOOL_MKLOCALE Make LC_CTYPE locale files. [mklocale]
1128:
1129: TOOL_MKMAGIC Create database for file(1). [file]
1130:
1131: TOOL_MKTEMP Make (unique) temporary file name. [mktemp]
1132:
1133: TOOL_MSGC Simple message list compiler. [msgc]
1134:
1135: TOOL_MTREE Map a directory hierarchy. [mtree]
1136:
1137: TOOL_PAX Manipulate file archives and copy directories. [pax]
1138:
1139: TOOL_PIC Compile pictures for groff. [pic]
1140:
1141: TOOL_PREPMKBOOTIMAGE prep-mkbootimage (XXXBUILDSH). [prep-mkbootimage]
1142:
1143: TOOL_PWD_MKDB Generate the password databases. [pwd_mkdb]
1144:
1145: TOOL_REFER Preprocess bibliographic references for groff. [refer]
1146:
1147: TOOL_ROFF_ASCII Generate ASCII groff output. [nroff]
1148:
1149: TOOL_ROFF_DVI Generate DVI groff output. [${TOOL_GROFF} -Tdvi]
1150:
1151: TOOL_ROFF_HTML Generate HTML groff output.
1.119 lukem 1152: [${TOOL_GROFF} -Tlatin1 -mdoc2html]
1.116 lukem 1153:
1154: TOOL_ROFF_PS Generate PS groff output. [${TOOL_GROFF} -Tps]
1155:
1156: TOOL_ROFF_RAW Generate "raw" groff output. [${TOOL_GROFF} -Z]
1157:
1158: TOOL_RPCGEN Remote Procedure Call (RPC) protocol compiler. [rpcgen]
1159:
1160: TOOL_SOELIM Eliminate .so's from groff input. [soelim]
1.123 lukem 1161:
1162: TOOL_STAT Display file status. [stat]
1.116 lukem 1163:
1164: TOOL_SUNLABEL Read or modify a SunOS disk label. [sunlabel]
1165:
1166: TOOL_TBL Format tables for groff. [tbl]
1167:
1168: TOOL_UUDECODE Uudecode a binary file. [uudecode]
1169:
1170: TOOL_VGRIND Grind nice listings of programs. [vgrind -f]
1171:
1172: TOOL_ZIC Time zone compiler. [zic]
1173:
1.69 sommerfe 1174:
1175: Other variables of note (incomplete list):
1176:
1.82 lukem 1177: WARNS Crank up gcc warning options; the distinct levels are:
1178: WARNS=1
1179: WARNS=2
1180: WARNS=3
1.69 sommerfe 1181:
1182: FORMAT_AUDIT If FORMAT_AUDIT is set, and WFORMAT is set and > 1, turn on
1183: WFORMAT -Wnetbsd-format-audit for extra-stringent format checking.
1.75 agc 1184: WFORMAT belongs in individual makefiles and/or
1185: Makefile.inc files. (set WFORMAT=1 in individual
1186: makefiles if a program is not security critical and is
1187: doing bizarre things with format strings which would
1188: be even uglier if rewritten) FORMAT_AUDIT should go in
1.120 lukem 1189: mk.conf if you're doing format-string auditing.
1.69 sommerfe 1190: FORMAT_AUDIT may go away in time.
1.30 agc 1191:
1192: =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
CVSweb <webmaster@jp.NetBSD.org>