3 # The include file <bsd.own.mk> set common variables for owner,
4 # group, mode, and directories. Defaults are in brackets.
9 # DESTDIR Change the tree where the file gets installed. [not set]
11 # DISTDIR Change the tree where the file for a distribution
12 # gets installed (see /usr/src/release/Makefile). [not set]
14 # COMPRESS_CMD Program to compress documents.
15 # Output is to stdout. [gzip -cn]
17 # COMPRESS_EXT File name extension of ${COMPRESS_CMD} command. [.gz]
19 # BINOWN Binary owner. [root]
21 # BINGRP Binary group. [wheel]
23 # BINMODE Binary mode. [555]
25 # NOBINMODE Mode for non-executable files. [444]
27 # LIBDIR Base path for libraries. [/usr/lib]
29 # LIBCOMPATDIR Base path for compat libraries. [/usr/lib/compat]
31 # LIBDATADIR Base path for misc. utility data files. [/usr/libdata]
33 # LIBEXECDIR Base path for system daemons and utilities. [/usr/libexec]
35 # LINTLIBDIR Base path for lint libraries. [/usr/libdata/lint]
37 # SHLIBDIR Base path for shared libraries. [${LIBDIR}]
39 # LIBOWN Library owner. [${BINOWN}]
41 # LIBGRP Library group. [${BINGRP}]
43 # LIBMODE Library mode. [${NOBINMODE}]
46 # KMODDIR Base path for loadable kernel modules
47 # (see kld(4)). [/boot/kernel]
49 # KMODOWN Kernel and KLD owner. [${BINOWN}]
51 # KMODGRP Kernel and KLD group. [${BINGRP}]
53 # KMODMODE KLD mode. [${BINMODE}]
56 # SHAREDIR Base path for architecture-independent ascii
57 # text files. [/usr/share]
59 # SHAREOWN ASCII text file owner. [root]
61 # SHAREGRP ASCII text file group. [wheel]
63 # SHAREMODE ASCII text file mode. [${NOBINMODE}]
66 # CONFDIR Base path for configuration files. [/etc]
68 # CONFOWN Configuration file owner. [root]
70 # CONFGRP Configuration file group. [wheel]
72 # CONFMODE Configuration file mode. [644]
75 # DOCDIR Base path for system documentation (e.g. PSD, USD,
76 # handbook, FAQ etc.). [${SHAREDIR}/doc]
78 # DOCOWN Documentation owner. [${SHAREOWN}]
80 # DOCGRP Documentation group. [${SHAREGRP}]
82 # DOCMODE Documentation mode. [${NOBINMODE}]
85 # INFODIR Base path for GNU's hypertext system
86 # called Info (see info(1)). [${SHAREDIR}/info]
88 # INFOOWN Info owner. [${SHAREOWN}]
90 # INFOGRP Info group. [${SHAREGRP}]
92 # INFOMODE Info mode. [${NOBINMODE}]
95 # MANDIR Base path for manual installation. [${SHAREDIR}/man/man]
97 # MANOWN Manual owner. [${SHAREOWN}]
99 # MANGRP Manual group. [${SHAREGRP}]
101 # MANMODE Manual mode. [${NOBINMODE}]
104 # NLSDIR Base path for National Language Support files
105 # installation. [${SHAREDIR}/nls]
107 # NLSOWN National Language Support files owner. [${SHAREOWN}]
109 # NLSGRP National Language Support files group. [${SHAREGRP}]
111 # NLSMODE National Language Support files mode. [${NOBINMODE}]
113 # INCLUDEDIR Base path for standard C include files [/usr/include]
115 .if !target(__<bsd.own.mk>__)
118 .if !defined(_WITHOUT_SRCCONF)
119 SRCCONF?= /etc/src.conf
120 .if exists(${SRCCONF})
121 .include "${SRCCONF}"
131 .if defined(MODULES_WITH_WORLD)
132 KMODDIR?= /boot/modules
134 KMODDIR?= /boot/kernel
138 KMODMODE?= ${BINMODE}
141 LIBCOMPATDIR?= /usr/lib/compat
142 LIBDATADIR?= /usr/libdata
143 LIBEXECDIR?= /usr/libexec
144 LINTLIBDIR?= /usr/libdata/lint
148 LIBMODE?= ${NOBINMODE}
152 SHAREDIR?= /usr/share
155 SHAREMODE?= ${NOBINMODE}
162 MANDIR?= ${SHAREDIR}/man/man
165 MANMODE?= ${NOBINMODE}
167 DOCDIR?= ${SHAREDIR}/doc
170 DOCMODE?= ${NOBINMODE}
172 INFODIR?= ${SHAREDIR}/info
173 INFOOWN?= ${SHAREOWN}
174 INFOGRP?= ${SHAREGRP}
175 INFOMODE?= ${NOBINMODE}
177 NLSDIR?= ${SHAREDIR}/nls
180 NLSMODE?= ${NOBINMODE}
182 INCLUDEDIR?= /usr/include
185 .if !defined(DEBUG_FLAGS)
189 COMPRESS_CMD?= gzip -cn
192 .if !defined(_WITHOUT_SRCCONF)
194 # Define MK_* variables (which are either "yes" or "no") for users
195 # to set via WITH_*/WITHOUT_* in /etc/src.conf and override in the
196 # make(1) environment.
197 # These should be tested with `== "no"' or `!= "no"' in makefiles.
198 # The NO_* variables should only be set by makefiles.
202 # Supported NO_* options (if defined, MK_* will be forced to "no",
203 # regardless of user's setting).
209 .if defined(NO_${var})
215 # Compat NO_* options (same as above, except their use is deprecated).
217 .if !defined(BURN_BRIDGES)
281 .if defined(NO_${var})
282 #.warning NO_${var} is deprecated in favour of WITHOUT_${var}=
286 .endif # !defined(BURN_BRIDGES)
289 # Older-style variables that enabled behaviour when set.
291 .if defined(YES_HESIOD)
294 .if defined(MAKE_IDEA)
299 # MK_* options which default to "yes".
403 WPA_SUPPLICANT_EAPOL \
406 .if defined(WITH_${var}) && defined(WITHOUT_${var})
407 .error WITH_${var} and WITHOUT_${var} can't both be set.
409 .if defined(MK_${var})
410 .error MK_${var} can't be set by a user.
412 .if defined(WITHOUT_${var})
420 # MK_* options which default to "no".
430 .if defined(WITH_${var}) && defined(WITHOUT_${var})
431 .error WITH_${var} and WITHOUT_${var} can't both be set.
433 .if defined(MK_${var})
434 .error MK_${var} can't be set by a user.
436 .if defined(WITH_${var})
444 # Force some options off if their dependencies are off.
445 # Order is somewhat important.
447 .if ${MK_LIBPTHREAD} == "no"
451 .if ${MK_LIBTHR} == "no"
455 .if ${MK_BIND} == "no"
459 MK_BIND_LIBS_LWRES:= no
465 .if ${MK_BIND_MTREE} == "no"
469 .if ${MK_CDDL} == "no"
473 .if ${MK_CRYPT} == "no"
479 .if ${MK_IPX} == "no"
483 .if ${MK_MAIL} == "no"
488 .if ${MK_NETGRAPH} == "no"
493 .if ${MK_OPENSSL} == "no"
502 .if ${MK_TEXTPROC} == "no"
506 .if ${MK_TOOLCHAIN} == "no"
511 # Set defaults for the MK_*_SUPPORT variables.
515 # MK_*_SUPPORT options which default to "yes" unless their corresponding
516 # MK_* variable is set to "no".
529 .if defined(WITH_${var}_SUPPORT) && defined(WITHOUT_${var}_SUPPORT)
530 .error WITH_${var}_SUPPORT and WITHOUT_${var}_SUPPORT can't both be set.
532 .if defined(MK_${var}_SUPPORT)
533 .error MK_${var}_SUPPORT can't be set by a user.
535 .if defined(WITHOUT_${var}_SUPPORT) || ${MK_${var}} == "no"
536 MK_${var}_SUPPORT:= no
538 MK_${var}_SUPPORT:= yes
543 # MK_* options whose default value depends on another option.
548 .if defined(WITH_${vv:H}) && defined(WITHOUT_${vv:H})
549 .error WITH_${vv:H} and WITHOUT_${vv:H} can't both be set.
551 .if defined(MK_${vv:H})
552 .error MK_${vv:H} can't be set by a user.
554 .if defined(WITH_${vv:H})
556 .elif defined(WITHOUT_${vv:H})
559 MK_${vv:H}:= ${MK_${vv:T}}
563 .endif # !_WITHOUT_SRCCONF
565 .endif # !target(__<bsd.own.mk>__)