[BACK]Return to bsd.own.mk CVS log [TXT][DIR] Up to [cvs.NetBSD.org] / src / share / mk

Annotation of src/share/mk/bsd.own.mk, Revision 1.985

1.985   ! skrll       1: #      $NetBSD: bsd.own.mk,v 1.984 2016/11/01 14:01:25 christos Exp $
1.611     mrg         2:
                      3: # This needs to be before bsd.init.mk
                      4: .if defined(BSD_MK_COMPAT_FILE)
                      5: .include <${BSD_MK_COMPAT_FILE}>
                      6: .endif
1.64      lukem       7:
                      8: .if !defined(_BSD_OWN_MK_)
                      9: _BSD_OWN_MK_=1
1.24      thorpej    10:
1.169     tv         11: MAKECONF?=     /etc/mk.conf
1.205     tv         12: .-include "${MAKECONF}"
1.13      mycroft    13:
1.341     lukem      14: #
1.310     thorpej    15: # CPU model, derived from MACHINE_ARCH
1.341     lukem      16: #
1.835     matt       17: MACHINE_CPU=   ${MACHINE_ARCH:C/mipse[bl]/mips/:C/mips64e[bl]/mips/:C/sh3e[bl]/sh3/:S/coldfire/m68k/:S/m68000/m68k/:C/arm.*/arm/:C/earm.*/arm/:S/earm/arm/:S/powerpc64/powerpc/:S/aarch64eb/aarch64/:S/or1knd/or1k/:C/riscv../riscv/}
1.310     thorpej    18:
1.341     lukem      19: #
1.418     cl         20: # Subdirectory used below ${RELEASEDIR} when building a release
                     21: #
                     22: RELEASEMACHINEDIR?=    ${MACHINE}
                     23:
                     24: #
                     25: # Subdirectory or path component used for the following paths:
                     26: #   distrib/${RELEASEMACHINE}
                     27: #   distrib/notes/${RELEASEMACHINE}
                     28: #   etc/etc.${RELEASEMACHINE}
                     29: # Used when building a release.
                     30: #
                     31: RELEASEMACHINE?=       ${MACHINE}
                     32:
                     33: #
1.209     tv         34: # NEED_OWN_INSTALL_TARGET is set to "no" by pkgsrc/mk/bsd.pkg.mk to
                     35: # ensure that things defined by <bsd.own.mk> (default targets,
                     36: # INSTALL_FILE, etc.) are not conflicting with bsd.pkg.mk.
1.341     lukem      37: #
1.209     tv         38: NEED_OWN_INSTALL_TARGET?=      yes
                     39:
1.341     lukem      40: #
1.644     skrll      41: # This lists the platforms which do not have working in-tree toolchains.  For
                     42: # the in-tree gcc toolchain, this list is empty.
                     43: #
                     44: # If some future port is not supported by the in-tree toolchain, this should
                     45: # be set to "yes" for that port only.
1.341     lukem      46: #
1.911     martin     47: # .if ${MACHINE} == "playstation2"
                     48: # TOOLCHAIN_MISSING?=  yes
                     49: # .endif
1.817     mrg        50:
1.448     mrg        51: TOOLCHAIN_MISSING?=    no
1.221     thorpej    52:
1.831     justin     53: .if ${MACHINE_CPU} == "aarch64" && !defined(EXTERNAL_TOOLCHAIN) && ${MKLLVM:Uyes} != "no"
1.827     matt       54: MKLLVM?=       yes
                     55: HAVE_LLVM?=    yes
                     56: MKGCC?=                no
                     57: .endif
                     58:
1.676     mrg        59: #
1.770     mrg        60: # GCC Using platforms.
                     61: #
                     62: .if ${MKGCC:Uyes} != "no"
                     63:
1.916     mrg        64: #
                     65: # What GCC is used?
                     66: #
1.911     martin     67: .if ${MACHINE_CPU} == "aarch64"
1.908     christos   68: HAVE_GCC?=     0
1.953     mrg        69: .else
1.908     christos   70: HAVE_GCC?=     53
1.699     abs        71: .endif
1.676     mrg        72:
1.768     mrg        73: #
1.840     mrg        74: # Platforms that can't run a modern GCC natively
                     75: .if ${MACHINE_ARCH} == "m68000"
                     76: MKGCCCMDS?=    no
                     77: .endif
                     78:
                     79: #
1.768     mrg        80: # We import the old gcc as "gcc.old" when upgrading.  EXTERNAL_GCC_SUBDIR is
                     81: # set to the relevant subdirectory in src/external/gpl3 for his HAVE_GCC.
                     82: #
1.906     mrg        83: .if ${HAVE_GCC} == 53
1.768     mrg        84: EXTERNAL_GCC_SUBDIR=   gcc
                     85: .else
                     86: EXTERNAL_GCC_SUBDIR=   /does/not/exist
                     87: .endif
1.859     matt       88: .else
                     89: MKGCCCMDS?=    no
1.770     mrg        90: .endif
                     91:
1.805     joerg      92: .if !empty(MACHINE_ARCH:Mearm*)
1.806     joerg      93: _LIBC_COMPILER_RT.${MACHINE_ARCH}=     yes
1.805     joerg      94: .endif
                     95:
1.827     matt       96: _LIBC_COMPILER_RT.aarch64=     yes
1.977     mrg        97: _LIBC_COMPILER_RT.aarch64eb=   yes
1.805     joerg      98: _LIBC_COMPILER_RT.i386=                yes
1.828     joerg      99: _LIBC_COMPILER_RT.powerpc=     yes
1.832     joerg     100: _LIBC_COMPILER_RT.powerpc64=   yes
1.903     joerg     101: _LIBC_COMPILER_RT.sparc=       yes
                    102: _LIBC_COMPILER_RT.sparc64=     yes
1.805     joerg     103: _LIBC_COMPILER_RT.x86_64=      yes
                    104:
1.836     apb       105: .if ${HAVE_LLVM:Uno} == "yes" && ${_LIBC_COMPILER_RT.${MACHINE_ARCH}:Uno} == "yes"
1.753     joerg     106: HAVE_LIBGCC?=  no
1.752     joerg     107: .else
1.753     joerg     108: HAVE_LIBGCC?=  yes
1.752     joerg     109: .endif
                    110:
1.827     matt      111:
1.810     joerg     112: # ia64 is not support
1.836     apb       113: .if ${HAVE_LLVM:Uno} == "yes" || !empty(MACHINE_ARCH:Mearm*)
1.763     joerg     114: HAVE_LIBGCC_EH?=       no
                    115: .else
                    116: HAVE_LIBGCC_EH?=       yes
                    117: .endif
                    118:
1.916     mrg       119: .if ${MACHINE} == "alpha" || \
                    120:     ${MACHINE} == "hppa" || \
                    121:     ${MACHINE} == "ia64" || \
                    122:     ${MACHINE_CPU} == "mips"
1.721     christos  123: HAVE_SSP?=     no
                    124: .else
                    125: HAVE_SSP?=     yes
1.907     christos  126: .if !defined(NOFORT) && ${USE_FORT:Uno} != "no"
1.721     christos  127: USE_SSP?=      yes
                    128: .endif
                    129: .endif
                    130:
1.916     mrg       131: #
                    132: # What GDB is used?
                    133: #
1.981     skrll     134: .if \
1.975     mrg       135:     ${MACHINE} == "vax" || \
                    136:     ${MACHINE_CPU} == "m68k" || \
                    137:     ${MACHINE_ARCH} == "mips64el" || \
                    138:     ${MACHINE_ARCH} == "mips64eb"
                    139: HAVE_GDB?=     710
                    140: .else
1.970     christos  141: HAVE_GDB?=     712
                    142: .endif
1.886     christos  143:
1.969     christos  144: .if ${HAVE_GDB} == 712
1.967     christos  145: EXTERNAL_GDB_SUBDIR=           gdb
1.969     christos  146: .elif ${HAVE_GDB} == 710
                    147: EXTERNAL_GDB_SUBDIR=           gdb.old
1.894     christos  148: .else
1.967     christos  149: EXTERNAL_GDB_SUBDIR=           /does/not/exist
1.886     christos  150: .endif
                    151:
1.916     mrg       152: #
                    153: # What binutils is used?
                    154: #
1.983     christos  155: .if \
                    156:     ${MACHINE_ARCH} == "i386" || \
                    157:     ${MACHINE_ARCH} == "x86_64"
                    158: HAVE_BINUTILS?=        227
                    159: .else
1.891     christos  160: HAVE_BINUTILS?=        226
1.983     christos  161: .endif
1.886     christos  162:
1.967     christos  163: .if ${HAVE_BINUTILS} == 226
1.982     christos  164: EXTERNAL_BINUTILS_SUBDIR=      binutils.old
                    165: .elif ${HAVE_BINUTILS} == 227
1.889     christos  166: EXTERNAL_BINUTILS_SUBDIR=      binutils
1.886     christos  167: .else
                    168: EXTERNAL_BINUTILS_SUBDIR=      /does/not/exist
                    169: .endif
                    170:
1.713     apb       171: .if empty(.MAKEFLAGS:tW:M*-V .OBJDIR*)
1.489     dsl       172: .if defined(MAKEOBJDIRPREFIX) || defined(MAKEOBJDIR)
                    173: PRINTOBJDIR=   ${MAKE} -r -V .OBJDIR -f /dev/null xxx
                    174: .else
1.488     drochner  175: PRINTOBJDIR=   ${MAKE} -V .OBJDIR
1.489     dsl       176: .endif
1.222     perry     177: .else
1.713     apb       178: PRINTOBJDIR=   echo /error/bsd.own.mk/PRINTOBJDIR # avoid infinite recursion
1.222     perry     179: .endif
                    180:
1.341     lukem     181: #
1.286     lukem     182: # Determine if running in the NetBSD source tree by checking for the
                    183: # existence of build.sh and tools/ in the current or a parent directory,
                    184: # and setting _SRC_TOP_ to the result.
                    185: #
1.287     lukem     186: .if !defined(_SRC_TOP_)                        # {
1.615     christos  187: _SRC_TOP_!= cd "${.CURDIR}"; while :; do \
1.200     jmc       188:                here=`pwd`; \
1.199     jmc       189:                [ -f build.sh  ] && [ -d tools ] && { echo $$here; break; }; \
                    190:                case $$here in /) echo ""; break;; esac; \
1.341     lukem     191:                cd ..; done
1.199     jmc       192:
                    193: .MAKEOVERRIDES+=       _SRC_TOP_
                    194:
1.287     lukem     195: .endif                                 # }
1.222     perry     196:
1.341     lukem     197: #
1.707     apb       198: # If _SRC_TOP_ != "", we're within the NetBSD source tree.
                    199: # * Set defaults for NETBSDSRCDIR and _SRC_TOP_OBJ_.
                    200: # * Define _NETBSD_VERSION_DEPENDS.  Targets that depend on the
                    201: #   NetBSD version, or on variables defined at build time, can
                    202: #   declare a dependency on ${_NETBSD_VERSION_DEPENDS}.
1.287     lukem     203: #
                    204: .if (${_SRC_TOP_} != "")               # {
                    205:
1.288     lukem     206: NETBSDSRCDIR?= ${_SRC_TOP_}
1.180     tv        207:
1.287     lukem     208: .if !defined(_SRC_TOP_OBJ_)
1.615     christos  209: _SRC_TOP_OBJ_!=                cd "${_SRC_TOP_}" && ${PRINTOBJDIR}
1.287     lukem     210: .MAKEOVERRIDES+=       _SRC_TOP_OBJ_
1.286     lukem     211: .endif
                    212:
1.707     apb       213: _NETBSD_VERSION_DEPENDS=       ${_SRC_TOP_OBJ_}/params
                    214: _NETBSD_VERSION_DEPENDS+=      ${NETBSDSRCDIR}/sys/sys/param.h
                    215: _NETBSD_VERSION_DEPENDS+=      ${NETBSDSRCDIR}/sys/conf/newvers.sh
                    216: _NETBSD_VERSION_DEPENDS+=      ${NETBSDSRCDIR}/sys/conf/osrelease.sh
                    217: ${_SRC_TOP_OBJ_}/params: .NOTMAIN .OPTIONAL # created by top level "make build"
                    218:
1.322     lukem     219: .endif # _SRC_TOP_ != ""               # }
1.286     lukem     220:
                    221:
1.310     thorpej   222: .if (${_SRC_TOP_} != "") && \
1.406     lukem     223:     (${TOOLCHAIN_MISSING} == "no" || defined(EXTERNAL_TOOLCHAIN))
1.287     lukem     224: USETOOLS?=     yes
1.286     lukem     225: .endif
1.287     lukem     226: USETOOLS?=     no
                    227:
1.286     lukem     228:
1.468     matt      229: .if ${MACHINE_ARCH} == "mips" || ${MACHINE_ARCH} == "mips64" || \
1.495     scw       230:     ${MACHINE_ARCH} == "sh3"
1.180     tv        231: .BEGIN:
                    232:        @echo "Must set MACHINE_ARCH to one of ${MACHINE_ARCH}eb or ${MACHINE_ARCH}el"
                    233:        @false
1.310     thorpej   234: .elif defined(REQUIRETOOLS) && \
1.406     lukem     235:       (${TOOLCHAIN_MISSING} == "no" || defined(EXTERNAL_TOOLCHAIN)) && \
1.310     thorpej   236:       ${USETOOLS} == "no"
1.180     tv        237: .BEGIN:
1.203     tv        238:        @echo "USETOOLS=no, but this component requires a version-specific host toolchain"
1.180     tv        239:        @false
                    240: .endif
                    241:
1.341     lukem     242: #
1.204     tv        243: # Host platform information; may be overridden
1.341     lukem     244: #
1.762     christos  245: .include <bsd.host.mk>
1.204     tv        246:
1.275     lukem     247: .if ${USETOOLS} == "yes"                                               # {
                    248:
1.341     lukem     249: #
1.204     tv        250: # Provide a default for TOOLDIR.
1.341     lukem     251: #
1.199     jmc       252: .if !defined(TOOLDIR)
1.339     lukem     253: TOOLDIR:=      ${_SRC_TOP_OBJ_}/tooldir.${HOST_OSTYPE}
1.204     tv        254: .MAKEOVERRIDES+= TOOLDIR
1.199     jmc       255: .endif
1.180     tv        256:
1.341     lukem     257: #
1.320     thorpej   258: # This is the prefix used for the NetBSD-sourced tools.
1.341     lukem     259: #
1.320     thorpej   260: _TOOL_PREFIX?= nb
                    261:
1.341     lukem     262: #
1.318     thorpej   263: # If an external toolchain base is specified, use it.
1.341     lukem     264: #
                    265: .if defined(EXTERNAL_TOOLCHAIN)                                                # {
1.318     thorpej   266: AR=            ${EXTERNAL_TOOLCHAIN}/bin/${MACHINE_GNU_PLATFORM}-ar
                    267: AS=            ${EXTERNAL_TOOLCHAIN}/bin/${MACHINE_GNU_PLATFORM}-as
                    268: LD=            ${EXTERNAL_TOOLCHAIN}/bin/${MACHINE_GNU_PLATFORM}-ld
                    269: NM=            ${EXTERNAL_TOOLCHAIN}/bin/${MACHINE_GNU_PLATFORM}-nm
                    270: OBJCOPY=       ${EXTERNAL_TOOLCHAIN}/bin/${MACHINE_GNU_PLATFORM}-objcopy
                    271: OBJDUMP=       ${EXTERNAL_TOOLCHAIN}/bin/${MACHINE_GNU_PLATFORM}-objdump
                    272: RANLIB=                ${EXTERNAL_TOOLCHAIN}/bin/${MACHINE_GNU_PLATFORM}-ranlib
1.854     pooka     273: READELF=       ${EXTERNAL_TOOLCHAIN}/bin/${MACHINE_GNU_PLATFORM}-readelf
1.318     thorpej   274: SIZE=          ${EXTERNAL_TOOLCHAIN}/bin/${MACHINE_GNU_PLATFORM}-size
1.854     pooka     275: STRINGS=       ${EXTERNAL_TOOLCHAIN}/bin/${MACHINE_GNU_PLATFORM}-strings
1.318     thorpej   276: STRIP=         ${EXTERNAL_TOOLCHAIN}/bin/${MACHINE_GNU_PLATFORM}-strip
                    277:
1.667     joerg     278: TOOL_CC.gcc=           ${EXTERNAL_TOOLCHAIN}/bin/${MACHINE_GNU_PLATFORM}-gcc
                    279: TOOL_CPP.gcc=          ${EXTERNAL_TOOLCHAIN}/bin/${MACHINE_GNU_PLATFORM}-cpp
                    280: TOOL_CXX.gcc=          ${EXTERNAL_TOOLCHAIN}/bin/${MACHINE_GNU_PLATFORM}-c++
                    281: TOOL_FC.gcc=           ${EXTERNAL_TOOLCHAIN}/bin/${MACHINE_GNU_PLATFORM}-g77
                    282: TOOL_OBJC.gcc=         ${EXTERNAL_TOOLCHAIN}/bin/${MACHINE_GNU_PLATFORM}-gcc
1.714     pooka     283:
                    284: TOOL_CC.clang=         ${EXTERNAL_TOOLCHAIN}/bin/${MACHINE_GNU_PLATFORM}-clang
                    285: TOOL_CPP.clang=                ${EXTERNAL_TOOLCHAIN}/bin/${MACHINE_GNU_PLATFORM}-clang-cpp
                    286: TOOL_CXX.clang=                ${EXTERNAL_TOOLCHAIN}/bin/${MACHINE_GNU_PLATFORM}-clang++
                    287: TOOL_OBJC.clang=       ${EXTERNAL_TOOLCHAIN}/bin/${MACHINE_GNU_PLATFORM}-clang
1.341     lukem     288: .else                                                                  # } {
1.204     tv        289: # Define default locations for common tools.
1.341     lukem     290: .if ${USETOOLS_BINUTILS:Uyes} == "yes"                                 #  {
1.232     tv        291: AR=            ${TOOLDIR}/bin/${MACHINE_GNU_PLATFORM}-ar
                    292: AS=            ${TOOLDIR}/bin/${MACHINE_GNU_PLATFORM}-as
1.234     thorpej   293: LD=            ${TOOLDIR}/bin/${MACHINE_GNU_PLATFORM}-ld
                    294: NM=            ${TOOLDIR}/bin/${MACHINE_GNU_PLATFORM}-nm
                    295: OBJCOPY=       ${TOOLDIR}/bin/${MACHINE_GNU_PLATFORM}-objcopy
                    296: OBJDUMP=       ${TOOLDIR}/bin/${MACHINE_GNU_PLATFORM}-objdump
                    297: RANLIB=                ${TOOLDIR}/bin/${MACHINE_GNU_PLATFORM}-ranlib
1.854     pooka     298: READELF=       ${TOOLDIR}/bin/${MACHINE_GNU_PLATFORM}-readelf
1.234     thorpej   299: SIZE=          ${TOOLDIR}/bin/${MACHINE_GNU_PLATFORM}-size
1.854     pooka     300: STRINGS=       ${TOOLDIR}/bin/${MACHINE_GNU_PLATFORM}-strings
1.234     thorpej   301: STRIP=         ${TOOLDIR}/bin/${MACHINE_GNU_PLATFORM}-strip
                    302:
1.667     joerg     303: # GCC supports C, C++, Fortran and Objective C
                    304: TOOL_CC.gcc=           ${TOOLDIR}/bin/${MACHINE_GNU_PLATFORM}-gcc
                    305: TOOL_CPP.gcc=          ${TOOLDIR}/bin/${MACHINE_GNU_PLATFORM}-cpp
                    306: TOOL_CXX.gcc=          ${TOOLDIR}/bin/${MACHINE_GNU_PLATFORM}-c++
                    307: TOOL_FC.gcc=           ${TOOLDIR}/bin/${MACHINE_GNU_PLATFORM}-g77
                    308: TOOL_OBJC.gcc=         ${TOOLDIR}/bin/${MACHINE_GNU_PLATFORM}-gcc
1.341     lukem     309: .endif                                                                 #  }
1.519     gmcgarry  310:
1.667     joerg     311: # Clang supports C, C++ and Objective C
                    312: TOOL_CC.clang=         ${TOOLDIR}/bin/${MACHINE_GNU_PLATFORM}-clang
                    313: TOOL_CPP.clang=                ${TOOLDIR}/bin/${MACHINE_GNU_PLATFORM}-clang-cpp
                    314: TOOL_CXX.clang=                ${TOOLDIR}/bin/${MACHINE_GNU_PLATFORM}-clang++
                    315: TOOL_OBJC.clang=       ${TOOLDIR}/bin/${MACHINE_GNU_PLATFORM}-clang
                    316:
                    317: # PCC supports C and Fortran
                    318: TOOL_CC.pcc=           ${TOOLDIR}/bin/${MACHINE_GNU_PLATFORM}-pcc
1.900     plunky    319: TOOL_CPP.pcc=          ${TOOLDIR}/bin/${MACHINE_GNU_PLATFORM}-pcpp
1.824     plunky    320: TOOL_CXX.pcc=          ${TOOLDIR}/bin/${MACHINE_GNU_PLATFORM}-p++
1.519     gmcgarry  321:
1.662     joerg     322: #
                    323: # Make sure DESTDIR is set, so that builds with these tools always
                    324: # get appropriate -nostdinc, -nostdlib, etc. handling.  The default is
                    325: # <empty string>, meaning start from /, the root directory.
                    326: #
                    327: DESTDIR?=
                    328:
                    329: .if !defined(HOSTPROG) && !defined(HOSTLIB)
                    330: .  if ${DESTDIR} != ""
1.659     mrg       331: CPPFLAGS+=     --sysroot=${DESTDIR}
1.657     christos  332: LDFLAGS+=      --sysroot=${DESTDIR}
1.662     joerg     333: .  else
1.661     christos  334: CPPFLAGS+=     --sysroot=/
                    335: LDFLAGS+=      --sysroot=/
1.662     joerg     336: .  endif
1.657     christos  337: .endif
1.341     lukem     338: .endif # EXTERNAL_TOOLCHAIN                                            # }
1.234     thorpej   339:
1.210     thorpej   340: DBSYM=         ${TOOLDIR}/bin/${MACHINE_GNU_PLATFORM}-dbsym
1.675     tsutsui   341: ELF2AOUT=      ${TOOLDIR}/bin/${_TOOL_PREFIX}m68k-elf2aout
1.320     thorpej   342: ELF2ECOFF=     ${TOOLDIR}/bin/${_TOOL_PREFIX}mips-elf2ecoff
1.496     joerg     343: INSTALL=       ${TOOLDIR}/bin/${MACHINE_GNU_PLATFORM}-install
1.320     thorpej   344: LEX=           ${TOOLDIR}/bin/${_TOOL_PREFIX}lex
1.215     tv        345: LINT=          CC=${CC:Q} ${TOOLDIR}/bin/${MACHINE_GNU_PLATFORM}-lint
1.338     lukem     346: LORDER=                NM=${NM:Q} MKTEMP=${TOOL_MKTEMP:Q} ${TOOLDIR}/bin/${_TOOL_PREFIX}lorder
1.320     thorpej   347: MKDEP=         CC=${CC:Q} ${TOOLDIR}/bin/${_TOOL_PREFIX}mkdep
1.754     mrg       348: MKDEPCXX=      CC=${CXX:Q} ${TOOLDIR}/bin/${_TOOL_PREFIX}mkdep
1.483     christos  349: PAXCTL=                ${TOOLDIR}/bin/${_TOOL_PREFIX}paxctl
1.320     thorpej   350: TSORT=         ${TOOLDIR}/bin/${_TOOL_PREFIX}tsort -q
                    351: YACC=          ${TOOLDIR}/bin/${_TOOL_PREFIX}yacc
1.338     lukem     352:
1.426     jmc       353: TOOL_AMIGAAOUT2BB=     ${TOOLDIR}/bin/${_TOOL_PREFIX}amiga-aout2bb
                    354: TOOL_AMIGAELF2BB=      ${TOOLDIR}/bin/${_TOOL_PREFIX}amiga-elf2bb
                    355: TOOL_AMIGATXLT=                ${TOOLDIR}/bin/${_TOOL_PREFIX}amiga-txlt
1.338     lukem     356: TOOL_ASN1_COMPILE=     ${TOOLDIR}/bin/${_TOOL_PREFIX}asn1_compile
1.535     apb       357: TOOL_AWK=              ${TOOLDIR}/bin/${_TOOL_PREFIX}awk
1.338     lukem     358: TOOL_CAP_MKDB=         ${TOOLDIR}/bin/${_TOOL_PREFIX}cap_mkdb
                    359: TOOL_CAT=              ${TOOLDIR}/bin/${_TOOL_PREFIX}cat
                    360: TOOL_CKSUM=            ${TOOLDIR}/bin/${_TOOL_PREFIX}cksum
1.684     joerg     361: TOOL_CLANG_TBLGEN=             ${TOOLDIR}/bin/${_TOOL_PREFIX}clang-tblgen
1.338     lukem     362: TOOL_COMPILE_ET=       ${TOOLDIR}/bin/${_TOOL_PREFIX}compile_et
                    363: TOOL_CONFIG=           ${TOOLDIR}/bin/${_TOOL_PREFIX}config
                    364: TOOL_CRUNCHGEN=                MAKE=${.MAKE:Q} ${TOOLDIR}/bin/${_TOOL_PREFIX}crunchgen
                    365: TOOL_CTAGS=            ${TOOLDIR}/bin/${_TOOL_PREFIX}ctags
1.620     darran    366: TOOL_CTFCONVERT=       ${TOOLDIR}/bin/${_TOOL_PREFIX}ctfconvert
                    367: TOOL_CTFMERGE=         ${TOOLDIR}/bin/${_TOOL_PREFIX}ctfmerge
1.885     christos  368: TOOL_CVSLATEST=                ${TOOLDIR}/bin/${_TOOL_PREFIX}cvslatest
1.338     lukem     369: TOOL_DB=               ${TOOLDIR}/bin/${_TOOL_PREFIX}db
1.730     matt      370: TOOL_DISKLABEL=                ${TOOLDIR}/bin/nbdisklabel
1.338     lukem     371: TOOL_EQN=              ${TOOLDIR}/bin/${_TOOL_PREFIX}eqn
1.532     apb       372: TOOL_FDISK=            ${TOOLDIR}/bin/${MACHINE_GNU_PLATFORM}-fdisk
1.338     lukem     373: TOOL_FGEN=             ${TOOLDIR}/bin/${_TOOL_PREFIX}fgen
1.439     thorpej   374: TOOL_GENASSYM=         ${TOOLDIR}/bin/${_TOOL_PREFIX}genassym
1.338     lukem     375: TOOL_GENCAT=           ${TOOLDIR}/bin/${_TOOL_PREFIX}gencat
1.446     jmc       376: TOOL_GMAKE=            ${TOOLDIR}/bin/${_TOOL_PREFIX}gmake
1.947     nonaka    377: TOOL_GPT=              ${TOOLDIR}/bin/${_TOOL_PREFIX}gpt
1.881     joerg     378: # grep exists in src/tools, but is not hooked up into the build.
                    379: #TOOL_GREP=            ${TOOLDIR}/bin/${_TOOL_PREFIX}grep
                    380: TOOL_GREP=             grep
1.338     lukem     381: TOOL_GROFF=            PATH=${TOOLDIR}/lib/groff:$${PATH} ${TOOLDIR}/bin/${_TOOL_PREFIX}groff
                    382: TOOL_HEXDUMP=          ${TOOLDIR}/bin/${_TOOL_PREFIX}hexdump
1.427     jmc       383: TOOL_HP300MKBOOT=      ${TOOLDIR}/bin/${_TOOL_PREFIX}hp300-mkboot
1.767     skrll     384: TOOL_HPPAMKBOOT=       ${TOOLDIR}/bin/${_TOOL_PREFIX}hppa-mkboot
1.338     lukem     385: TOOL_INDXBIB=          ${TOOLDIR}/bin/${_TOOL_PREFIX}indxbib
                    386: TOOL_INSTALLBOOT=      ${TOOLDIR}/bin/${_TOOL_PREFIX}installboot
                    387: TOOL_INSTALL_INFO=     ${TOOLDIR}/bin/${_TOOL_PREFIX}install-info
1.492     apb       388: TOOL_JOIN=             ${TOOLDIR}/bin/${_TOOL_PREFIX}join
1.684     joerg     389: TOOL_LLVM_TBLGEN=              ${TOOLDIR}/bin/${_TOOL_PREFIX}llvm-tblgen
1.338     lukem     390: TOOL_M4=               ${TOOLDIR}/bin/${_TOOL_PREFIX}m4
1.405     matt      391: TOOL_MACPPCFIXCOFF=    ${TOOLDIR}/bin/${_TOOL_PREFIX}macppc-fixcoff
1.338     lukem     392: TOOL_MAKEFS=           ${TOOLDIR}/bin/${_TOOL_PREFIX}makefs
                    393: TOOL_MAKEINFO=         ${TOOLDIR}/bin/${_TOOL_PREFIX}makeinfo
1.858     matt      394: TOOL_MAKEKEYS=         ${TOOLDIR}/bin/${_TOOL_PREFIX}makekeys
                    395: TOOL_MAKESTRS=         ${TOOLDIR}/bin/${_TOOL_PREFIX}makestrs
1.338     lukem     396: TOOL_MAKEWHATIS=       ${TOOLDIR}/bin/${_TOOL_PREFIX}makewhatis
1.588     joerg     397: TOOL_MANDOC_ASCII=     ${TOOLDIR}/bin/${_TOOL_PREFIX}mandoc -Tascii
1.653     njoly     398: TOOL_MANDOC_HTML=      ${TOOLDIR}/bin/${_TOOL_PREFIX}mandoc -Thtml
1.588     joerg     399: TOOL_MANDOC_LINT=      ${TOOLDIR}/bin/${_TOOL_PREFIX}mandoc -Tlint
1.338     lukem     400: TOOL_MDSETIMAGE=       ${TOOLDIR}/bin/${MACHINE_GNU_PLATFORM}-mdsetimage
                    401: TOOL_MENUC=            MENUDEF=${TOOLDIR}/share/misc ${TOOLDIR}/bin/${_TOOL_PREFIX}menuc
1.675     tsutsui   402: TOOL_M68KELF2AOUT=     ${TOOLDIR}/bin/${_TOOL_PREFIX}m68k-elf2aout
1.425     jmc       403: TOOL_MIPSELF2ECOFF=    ${TOOLDIR}/bin/${_TOOL_PREFIX}mips-elf2ecoff
1.338     lukem     404: TOOL_MKCSMAPPER=       ${TOOLDIR}/bin/${_TOOL_PREFIX}mkcsmapper
                    405: TOOL_MKESDB=           ${TOOLDIR}/bin/${_TOOL_PREFIX}mkesdb
                    406: TOOL_MKLOCALE=         ${TOOLDIR}/bin/${_TOOL_PREFIX}mklocale
                    407: TOOL_MKMAGIC=          ${TOOLDIR}/bin/${_TOOL_PREFIX}file
1.723     jmcneill  408: TOOL_MKNOD=            ${TOOLDIR}/bin/${_TOOL_PREFIX}mknod
1.338     lukem     409: TOOL_MKTEMP=           ${TOOLDIR}/bin/${_TOOL_PREFIX}mktemp
1.650     matt      410: TOOL_MKUBOOTIMAGE=     ${TOOLDIR}/bin/${_TOOL_PREFIX}mkubootimage
1.712     jkunz     411: TOOL_ELFTOSB=          ${TOOLDIR}/bin/${_TOOL_PREFIX}elftosb
1.338     lukem     412: TOOL_MSGC=             MSGDEF=${TOOLDIR}/share/misc ${TOOLDIR}/bin/${_TOOL_PREFIX}msgc
                    413: TOOL_MTREE=            ${TOOLDIR}/bin/${_TOOL_PREFIX}mtree
1.690     joerg     414: TOOL_NBPERF=           ${TOOLDIR}/bin/${_TOOL_PREFIX}perf
1.803     phx       415: TOOL_NCDCS=            ${TOOLDIR}/bin/${_TOOL_PREFIX}ibmnws-ncdcs
1.338     lukem     416: TOOL_PAX=              ${TOOLDIR}/bin/${_TOOL_PREFIX}pax
                    417: TOOL_PIC=              ${TOOLDIR}/bin/${_TOOL_PREFIX}pic
1.632     mrg       418: TOOL_PIGZ=             ${TOOLDIR}/bin/${_TOOL_PREFIX}pigz
1.599     uebayasi  419: TOOL_PKG_CREATE=       ${TOOLDIR}/bin/${_TOOL_PREFIX}pkg_create
1.506     garbled   420: TOOL_POWERPCMKBOOTIMAGE=${TOOLDIR}/bin/${_TOOL_PREFIX}powerpc-mkbootimage
1.338     lukem     421: TOOL_PWD_MKDB=         ${TOOLDIR}/bin/${_TOOL_PREFIX}pwd_mkdb
                    422: TOOL_REFER=            ${TOOLDIR}/bin/${_TOOL_PREFIX}refer
                    423: TOOL_ROFF_ASCII=       PATH=${TOOLDIR}/lib/groff:$${PATH} ${TOOLDIR}/bin/${_TOOL_PREFIX}nroff
1.818     dholland  424: TOOL_ROFF_DOCASCII=    ${TOOL_GROFF} -Tascii
                    425: TOOL_ROFF_DOCHTML=     ${TOOL_GROFF} -Thtml
1.338     lukem     426: TOOL_ROFF_DVI=         ${TOOL_GROFF} -Tdvi
1.340     lukem     427: TOOL_ROFF_HTML=                ${TOOL_GROFF} -Tlatin1 -mdoc2html
1.338     lukem     428: TOOL_ROFF_PS=          ${TOOL_GROFF} -Tps
                    429: TOOL_ROFF_RAW=         ${TOOL_GROFF} -Z
1.501     nakayama  430: TOOL_RPCGEN=           RPCGEN_CPP=${CPP:Q} ${TOOLDIR}/bin/${_TOOL_PREFIX}rpcgen
1.454     gdamore   431: TOOL_SED=              ${TOOLDIR}/bin/${_TOOL_PREFIX}sed
1.656     elric     432: TOOL_SLC=              ${TOOLDIR}/bin/${_TOOL_PREFIX}slc
1.338     lukem     433: TOOL_SOELIM=           ${TOOLDIR}/bin/${_TOOL_PREFIX}soelim
1.882     christos  434: TOOL_SORTINFO=         ${TOOLDIR}/bin/${_TOOL_PREFIX}sortinfo
1.532     apb       435: TOOL_SPARKCRC=         ${TOOLDIR}/bin/${_TOOL_PREFIX}sparkcrc
1.342     lukem     436: TOOL_STAT=             ${TOOLDIR}/bin/${_TOOL_PREFIX}stat
1.530     apb       437: TOOL_STRFILE=          ${TOOLDIR}/bin/${_TOOL_PREFIX}strfile
1.338     lukem     438: TOOL_SUNLABEL=         ${TOOLDIR}/bin/${_TOOL_PREFIX}sunlabel
                    439: TOOL_TBL=              ${TOOLDIR}/bin/${_TOOL_PREFIX}tbl
1.616     roy       440: TOOL_TIC=              ${TOOLDIR}/bin/${_TOOL_PREFIX}tic
1.338     lukem     441: TOOL_UUDECODE=         ${TOOLDIR}/bin/${_TOOL_PREFIX}uudecode
                    442: TOOL_VGRIND=           ${TOOLDIR}/bin/${_TOOL_PREFIX}vgrind -f
1.823     christos  443: TOOL_VFONTEDPR=                ${TOOLDIR}/libexec/${_TOOL_PREFIX}vfontedpr
1.338     lukem     444: TOOL_ZIC=              ${TOOLDIR}/bin/${_TOOL_PREFIX}zic
1.180     tv        445:
1.538     apb       446: .else  # USETOOLS != yes                                               # } {
                    447:
1.667     joerg     448: # Clang supports C, C++ and Objective C
                    449: TOOL_CC.clang=         clang
                    450: TOOL_CPP.clang=                clang-cpp
                    451: TOOL_CXX.clang=                clang++
                    452: TOOL_OBJC.clang=       clang
                    453:
                    454: # GCC supports C, C++, Fortran and Objective C
                    455: TOOL_CC.gcc=   gcc
                    456: TOOL_CPP.gcc=  cpp
                    457: TOOL_CXX.gcc=  c++
                    458: TOOL_FC.gcc=   g77
                    459: TOOL_OBJC.gcc= gcc
                    460:
                    461: # PCC supports C and Fortran
                    462: TOOL_CC.pcc=           pcc
1.900     plunky    463: TOOL_CPP.pcc=          pcpp
1.824     plunky    464: TOOL_CXX.pcc=          p++
1.667     joerg     465:
1.538     apb       466: TOOL_AMIGAAOUT2BB=     amiga-aout2bb
                    467: TOOL_AMIGAELF2BB=      amiga-elf2bb
                    468: TOOL_AMIGATXLT=                amiga-txlt
                    469: TOOL_ASN1_COMPILE=     asn1_compile
                    470: TOOL_AWK=              awk
                    471: TOOL_CAP_MKDB=         cap_mkdb
                    472: TOOL_CAT=              cat
                    473: TOOL_CKSUM=            cksum
1.684     joerg     474: TOOL_CLANG_TBLGEN=     clang-tblgen
1.538     apb       475: TOOL_COMPILE_ET=       compile_et
                    476: TOOL_CONFIG=           config
                    477: TOOL_CRUNCHGEN=                crunchgen
                    478: TOOL_CTAGS=            ctags
1.620     darran    479: TOOL_CTFCONVERT=       ctfconvert
                    480: TOOL_CTFMERGE=         ctfmerge
1.885     christos  481: TOOL_CVSLATEST=                cvslatest
1.538     apb       482: TOOL_DB=               db
                    483: TOOL_DISKLABEL=                disklabel
                    484: TOOL_EQN=              eqn
                    485: TOOL_FDISK=            fdisk
                    486: TOOL_FGEN=             fgen
                    487: TOOL_GENASSYM=         genassym
                    488: TOOL_GENCAT=           gencat
                    489: TOOL_GMAKE=            gmake
1.947     nonaka    490: TOOL_GPT=              gpt
1.557     sketch    491: TOOL_GREP=             grep
1.538     apb       492: TOOL_GROFF=            groff
                    493: TOOL_HEXDUMP=          hexdump
                    494: TOOL_HP300MKBOOT=      hp300-mkboot
1.767     skrll     495: TOOL_HPPAMKBOOT=       hppa-mkboot
1.538     apb       496: TOOL_INDXBIB=          indxbib
                    497: TOOL_INSTALLBOOT=      installboot
                    498: TOOL_INSTALL_INFO=     install-info
                    499: TOOL_JOIN=             join
1.684     joerg     500: TOOL_LLVM_TBLGEN=      llvm-tblgen
1.538     apb       501: TOOL_M4=               m4
                    502: TOOL_MACPPCFIXCOFF=    macppc-fixcoff
                    503: TOOL_MAKEFS=           makefs
                    504: TOOL_MAKEINFO=         makeinfo
1.858     matt      505: TOOL_MAKEKEYS=         makekeys
                    506: TOOL_MAKESTRS=         makestrs
1.538     apb       507: TOOL_MAKEWHATIS=       /usr/libexec/makewhatis
1.629     joerg     508: TOOL_MANDOC_ASCII=     mandoc -Tascii
1.716     joerg     509: TOOL_MANDOC_HTML=      mandoc -Thtml
1.629     joerg     510: TOOL_MANDOC_LINT=      mandoc -Tlint
1.538     apb       511: TOOL_MDSETIMAGE=       mdsetimage
                    512: TOOL_MENUC=            menuc
1.675     tsutsui   513: TOOL_M68KELF2AOUT=     m68k-elf2aout
1.538     apb       514: TOOL_MIPSELF2ECOFF=    mips-elf2ecoff
                    515: TOOL_MKCSMAPPER=       mkcsmapper
                    516: TOOL_MKESDB=           mkesdb
                    517: TOOL_MKLOCALE=         mklocale
                    518: TOOL_MKMAGIC=          file
1.723     jmcneill  519: TOOL_MKNOD=            mknod
1.538     apb       520: TOOL_MKTEMP=           mktemp
1.650     matt      521: TOOL_MKUBOOTIMAGE=     mkubootimage
1.712     jkunz     522: TOOL_ELFTOSB=          elftosb
1.538     apb       523: TOOL_MSGC=             msgc
                    524: TOOL_MTREE=            mtree
1.616     roy       525: TOOL_NBPERF=           nbperf
1.803     phx       526: TOOL_NCDCS=            ncdcs
1.538     apb       527: TOOL_PAX=              pax
                    528: TOOL_PIC=              pic
1.632     mrg       529: TOOL_PIGZ=             pigz
1.599     uebayasi  530: TOOL_PKG_CREATE=       pkg_create
1.538     apb       531: TOOL_POWERPCMKBOOTIMAGE=       powerpc-mkbootimage
                    532: TOOL_PWD_MKDB=         pwd_mkdb
                    533: TOOL_REFER=            refer
                    534: TOOL_ROFF_ASCII=       nroff
1.818     dholland  535: TOOL_ROFF_DOCASCII=    ${TOOL_GROFF} -Tascii
                    536: TOOL_ROFF_DOCHTML=     ${TOOL_GROFF} -Thtml
1.538     apb       537: TOOL_ROFF_DVI=         ${TOOL_GROFF} -Tdvi
                    538: TOOL_ROFF_HTML=                ${TOOL_GROFF} -Tlatin1 -mdoc2html
                    539: TOOL_ROFF_PS=          ${TOOL_GROFF} -Tps
                    540: TOOL_ROFF_RAW=         ${TOOL_GROFF} -Z
                    541: TOOL_RPCGEN=           rpcgen
                    542: TOOL_SED=              sed
                    543: TOOL_SOELIM=           soelim
1.883     wiz       544: TOOL_SORTINFO=         sortinfo
1.538     apb       545: TOOL_SPARKCRC=         sparkcrc
                    546: TOOL_STAT=             stat
                    547: TOOL_STRFILE=          strfile
                    548: TOOL_SUNLABEL=         sunlabel
                    549: TOOL_TBL=              tbl
1.616     roy       550: TOOL_TIC=              tic
1.538     apb       551: TOOL_UUDECODE=         uudecode
                    552: TOOL_VGRIND=           vgrind -f
1.822     christos  553: TOOL_VFONTEDPR=                /usr/libexec/vfontedpr
1.538     apb       554: TOOL_ZIC=              zic
                    555:
                    556: .endif # USETOOLS != yes                                               # }
1.272     lukem     557:
1.890     christos  558: # Standalone code should not be compiled with PIE or CTF
                    559: # Should create a better test
                    560: .if defined(BINDIR) && ${BINDIR} == "/usr/mdec"
                    561: NOPIE=                 # defined
                    562: NOCTF=                 # defined
1.946     christos  563: .elif ${MACHINE} == "sun2"
                    564: NOPIE=                 # we don't have PIC, so no PIE
1.890     christos  565: .endif
                    566:
1.667     joerg     567: # Fallback to ensure that all variables are defined to something
                    568: TOOL_CC.false=         false
                    569: TOOL_CPP.false=                false
                    570: TOOL_CXX.false=                false
                    571: TOOL_FC.false=         false
                    572: TOOL_OBJC.false=       false
                    573:
1.817     mrg       574: AVAILABLE_COMPILER?=   ${HAVE_PCC:Dpcc} ${HAVE_LLVM:Dclang} ${HAVE_GCC:Dgcc} ${EXTERNAL_TOOLCHAIN:Dgcc} false
1.667     joerg     575:
                    576: .for _t in CC CPP CXX FC OBJC
                    577: ACTIVE_${_t}=  ${AVAILABLE_COMPILER:@.c.@ ${ !defined(UNSUPPORTED_COMPILER.${.c.}) && defined(TOOL_${_t}.${.c.}) :? ${.c.} : }@:[1]}
                    578: SUPPORTED_${_t}=${AVAILABLE_COMPILER:Nfalse:@.c.@ ${ !defined(UNSUPPORTED_COMPILER.${.c.}) && defined(TOOL_${_t}.${.c.}) :? ${.c.} : }@}
                    579: .endfor
                    580: # make bugs prevent moving this into the .for loop
                    581: CC=            ${TOOL_CC.${ACTIVE_CC}}
                    582: CPP=           ${TOOL_CPP.${ACTIVE_CPP}}
                    583: CXX=           ${TOOL_CXX.${ACTIVE_CXX}}
                    584: FC=            ${TOOL_FC.${ACTIVE_FC}}
                    585: OBJC=          ${TOOL_OBJC.${ACTIVE_OBJC}}
                    586:
1.756     matt      587: # For each ${MACHINE_CPU}, list the ports that use it.
1.827     matt      588: MACHINES.aarch64=      evbarm64
1.756     matt      589: MACHINES.alpha=                alpha
                    590: MACHINES.arm=          acorn26 acorn32 cats epoc32 evbarm hpcarm \
                    591:                        iyonix netwinder shark zaurus
                    592: MACHINES.coldfire=     evbcf
                    593: MACHINES.i386=         i386
                    594: MACHINES.ia64=         ia64
1.767     skrll     595: MACHINES.hppa=         hppa
1.756     matt      596: MACHINES.m68000=       sun2
                    597: MACHINES.m68k=         amiga atari cesfic hp300 luna68k mac68k \
                    598:                        news68k next68k sun3 x68k
                    599: MACHINES.mips=         arc cobalt algor cobalt emips evbmips ews4800mips \
                    600:                        hpcmips mipsco newsmips pmax sbmips sgimips
1.835     matt      601: MACHINES.or1k=         or1k
1.756     matt      602: MACHINES.powerpc=      amigappc bebox evbppc ibmnws macppc mvmeppc \
                    603:                        ofppc prep rs6000 sandpoint
1.835     matt      604: MACHINES.riscv=                riscv
1.756     matt      605: MACHINES.sh3=          dreamcast evbsh3 hpcsh landisk mmeye
1.757     matt      606: MACHINES.sparc=                sparc sparc64
1.756     matt      607: MACHINES.sparc64=      sparc64
                    608: MACHINES.vax=          vax
                    609: MACHINES.x86_64=       amd64
                    610:
1.775     matt      611: # for crunchide & ldd, define the OBJECT_FMTS used by a MACHINE_ARCH
                    612: #
                    613: OBJECT_FMTS=
1.939     scole     614: .if    ${MACHINE_ARCH} != "alpha" && ${MACHINE_ARCH} != "ia64"
1.775     matt      615: OBJECT_FMTS+=  elf32
                    616: .endif
                    617: .if    ${MACHINE_ARCH} == "alpha" || ${MACHINE_ARCH:M*64*} != ""
                    618: OBJECT_FMTS+=  elf64
                    619: .endif
                    620:
1.674     tsutsui   621: # OBJCOPY flags to create a.out binaries for old firmware
                    622: # shared among src/distrib and ${MACHINE}/conf/Makefile.${MACHINE}.inc
                    623: .if ${MACHINE_CPU} == "arm"
                    624: OBJCOPY_ELF2AOUT_FLAGS?=       \
                    625:        -O a.out-arm-netbsd     \
                    626:        -R .ident               \
                    627:        -R .ARM.attributes      \
1.704     matt      628:        -R .ARM.exidx           \
1.748     martin    629:        -R .ARM.extab           \
1.899     skrll     630:        -R .SUNW_ctf            \
1.674     tsutsui   631:        -R .arm.atpcs           \
                    632:        -R .comment             \
                    633:        -R .debug_abbrev        \
1.735     matt      634:        -R .debug_aranges       \
1.674     tsutsui   635:        -R .debug_info          \
                    636:        -R .debug_line          \
                    637:        -R .debug_frame         \
                    638:        -R .debug_loc           \
                    639:        -R .debug_pubnames      \
1.735     matt      640:        -R .debug_pubtypes      \
1.837     skrll     641:        -R .debug_ranges        \
1.674     tsutsui   642:        -R .debug_str           \
1.745     joerg     643:        -R .eh_frame            \
1.674     tsutsui   644:        -R .note.netbsd.ident
                    645: .endif
                    646:
1.341     lukem     647: #
1.272     lukem     648: # Targets to check if DESTDIR or RELEASEDIR is provided
                    649: #
                    650: .if !target(check_DESTDIR)
                    651: check_DESTDIR: .PHONY .NOTMAIN
                    652: .if !defined(DESTDIR)
                    653:        @echo "setenv DESTDIR before doing that!"
                    654:        @false
                    655: .else
                    656:        @true
                    657: .endif
                    658: .endif
                    659:
                    660: .if !target(check_RELEASEDIR)
                    661: check_RELEASEDIR: .PHONY .NOTMAIN
                    662: .if !defined(RELEASEDIR)
                    663:        @echo "setenv RELEASEDIR before doing that!"
                    664:        @false
                    665: .else
                    666:        @true
                    667: .endif
                    668: .endif
                    669:
1.341     lukem     670: #
1.306     lukem     671: # Build a dynamically linked /bin and /sbin, with the necessary shared
                    672: # libraries moved from /usr/lib to /lib and the shared linker moved
                    673: # from /usr/libexec to /lib
                    674: #
1.315     thorpej   675: # Note that if the BINDIR is not /bin or /sbin, then we always use the
                    676: # non-DYNAMICROOT behavior (i.e. it is only enabled for programs in /bin
                    677: # and /sbin).  See <bsd.shlib.mk>.
                    678: #
1.311     lukem     679: MKDYNAMICROOT?=        yes
1.306     lukem     680:
1.939     scole     681: # For ia64, ld.elf_so not yet implemented
                    682: .if ${MACHINE_ARCH} == "ia64"
                    683: MKDYNAMICROOT= no
                    684: .endif
                    685:
1.341     lukem     686: #
1.287     lukem     687: # Where the system object and source trees are kept; can be configurable
                    688: # by the user in case they want them in ~/foosrc and ~/fooobj (for example).
                    689: #
                    690: BSDSRCDIR?=    /usr/src
                    691: BSDOBJDIR?=    /usr/obj
1.288     lukem     692: NETBSDSRCDIR?= ${BSDSRCDIR}
1.1       cgd       693:
1.61      lukem     694: BINGRP?=       wheel
                    695: BINOWN?=       root
1.1       cgd       696: BINMODE?=      555
1.4       mycroft   697: NONBINMODE?=   444
1.17      brezak    698:
1.646     pooka     699: # These are here mainly because we don't want suid root in case
                    700: # a Makefile defines BINMODE.
                    701: RUMPBINGRP?=   wheel
                    702: RUMPBINOWN?=   root
                    703: RUMPBINMODE?=  555
                    704: RUMPNONBINMODE?=444
                    705:
1.31      christos  706: MANDIR?=       /usr/share/man
1.61      lukem     707: MANGRP?=       wheel
                    708: MANOWN?=       root
1.4       mycroft   709: MANMODE?=      ${NONBINMODE}
1.697     joerg     710: MANINSTALL?=   ${_MANINSTALL}
1.115     tv        711:
                    712: INFODIR?=      /usr/share/info
                    713: INFOGRP?=      wheel
                    714: INFOOWN?=      root
                    715: INFOMODE?=     ${NONBINMODE}
1.4       mycroft   716:
                    717: LIBDIR?=       /usr/lib
1.315     thorpej   718:
1.4       mycroft   719: LINTLIBDIR?=   /usr/libdata/lint
                    720: LIBGRP?=       ${BINGRP}
                    721: LIBOWN?=       ${BINOWN}
                    722: LIBMODE?=      ${NONBINMODE}
                    723:
1.135     simonb    724: DOCDIR?=       /usr/share/doc
1.61      lukem     725: DOCGRP?=       wheel
                    726: DOCOWN?=       root
1.135     simonb    727: DOCMODE?=      ${NONBINMODE}
1.15      jtc       728:
                    729: NLSDIR?=       /usr/share/nls
1.61      lukem     730: NLSGRP?=       wheel
                    731: NLSOWN?=       root
1.15      jtc       732: NLSMODE?=      ${NONBINMODE}
1.25      explorer  733:
1.508     ad        734: KMODULEGRP?=   wheel
                    735: KMODULEOWN?=   root
                    736: KMODULEMODE?=  ${NONBINMODE}
                    737:
1.155     itojun    738: LOCALEDIR?=    /usr/share/locale
                    739: LOCALEGRP?=    wheel
                    740: LOCALEOWN?=    root
                    741: LOCALEMODE?=   ${NONBINMODE}
1.1       cgd       742:
1.453     rpaulo    743: FIRMWAREDIR?=  /libdata/firmware
                    744: FIRMWAREGRP?=  wheel
                    745: FIRMWAREOWN?=  root
                    746: FIRMWAREMODE?= ${NONBINMODE}
                    747:
1.465     lukem     748: DEBUGDIR?=     /usr/libdata/debug
                    749: DEBUGGRP?=     wheel
                    750: DEBUGOWN?=     root
                    751: DEBUGMODE?=    ${NONBINMODE}
                    752:
1.341     lukem     753: #
                    754: # Data-driven table using make variables to control how
1.264     thorpej   755: # toolchain-dependent targets and shared libraries are built
                    756: # for different platforms and object formats.
                    757: #
1.296     thorpej   758: # OBJECT_FMT:          currently either "ELF" or "a.out".
1.264     thorpej   759: #
1.499     simonb    760: # All platforms are ELF.
1.341     lukem     761: #
1.264     thorpej   762: OBJECT_FMT=    ELF
                    763:
1.341     lukem     764: #
1.310     thorpej   765: # If this platform's toolchain is missing, we obviously cannot build it.
1.341     lukem     766: #
1.406     lukem     767: .if ${TOOLCHAIN_MISSING} != "no"
1.572     skrll     768: MKBINUTILS:= no
1.310     thorpej   769: MKGDB:= no
                    770: MKGCC:= no
                    771: .endif
                    772:
1.341     lukem     773: #
1.310     thorpej   774: # If we are using an external toolchain, we can still build the target's
1.572     skrll     775: # binutils, but we cannot build GCC's support libraries, since those are
1.310     thorpej   776: # tightly-coupled to the version of GCC being used.
1.341     lukem     777: #
1.310     thorpej   778: .if defined(EXTERNAL_TOOLCHAIN)
                    779: MKGCC:= no
                    780: .endif
                    781:
1.830     matt      782: # No GDB support for aarch64
                    783: MKGDB.aarch64= no
1.977     mrg       784: MKGDB.aarch64eb=no
1.834     matt      785: MKGDB.or1k=    no
1.835     matt      786: MKGDB.riscv32= no
                    787: MKGDB.riscv64= no
1.834     matt      788:
                    789: # No kernel modules for or1k (yet)
                    790: MKKMOD.or1k=   no
1.835     matt      791: MKKMOD.riscv32=        no
                    792: MKKMOD.riscv64=        no
1.834     matt      793:
                    794: # No profiling for or1k (yet)
                    795: MKPROFILE.or1k=        no
1.835     matt      796: MKPROFILE.riscv32=no
                    797: MKPROFILE.riscv64=no
1.830     matt      798:
1.341     lukem     799: #
1.165     fredette  800: # The m68000 port is incomplete.
1.341     lukem     801: #
1.165     fredette  802: .if ${MACHINE_ARCH} == "m68000"
1.230     tv        803: NOPIC=         # defined
1.458     mrg       804: MKISCSI=       no
                    805: # XXX GCC 4 outputs mcount() calling sequences that try to load values
                    806: # from over 64KB away and this fails to assemble.
1.671     mrg       807: .if defined(HAVE_GCC)
1.458     mrg       808: NOPROFILE=     # defined
                    809: .endif
1.32      thorpej   810: .endif
1.122     simonb    811:
1.341     lukem     812: #
1.441     skrll     813: # The ia64 port is incomplete.
                    814: #
1.830     matt      815: MKLINT.ia64=   no
                    816: MKGDB.ia64=    no
1.441     skrll     817:
                    818: #
1.327     thorpej   819: # On the MIPS, all libs are compiled with ABIcalls (and are thus PIC),
                    820: # not just shared libraries, so don't build the _pic version.
1.341     lukem     821: #
1.598     uebayasi  822: .if ${MACHINE_ARCH} == "mipsel" || ${MACHINE_ARCH} == "mipseb" || \
                    823:     ${MACHINE_ARCH} == "mips64el" || ${MACHINE_ARCH} == "mips64eb"
1.327     thorpej   824: MKPICLIB:=     no
                    825: .endif
                    826:
1.857     matt      827: # PowerPC64 and AArch64 ABI's are PIC
                    828: MKPICLIB.powerpc64=    no
                    829: #MKPICLIB.aarch64=     no
                    830:
1.341     lukem     831: #
1.327     thorpej   832: # On VAX using ELF, all objects are PIC, not just shared libraries,
1.613     matt      833: # so don't build the _pic version.
1.341     lukem     834: #
1.830     matt      835: MKPICLIB.vax=  no
1.327     thorpej   836:
1.341     lukem     837: #
1.122     simonb    838: # Location of the file that contains the major and minor numbers of the
                    839: # version of a shared library.  If this file exists a shared library
                    840: # will be built by <bsd.lib.mk>.
1.341     lukem     841: #
1.122     simonb    842: SHLIB_VERSION_FILE?= ${.CURDIR}/shlib_version
1.69      tv        843:
1.341     lukem     844: #
1.69      tv        845: # GNU sources and packages sometimes see architecture names differently.
1.341     lukem     846: #
1.827     matt      847: GNU_ARCH.aarch64eb=aarch64_be
1.739     matt      848: GNU_ARCH.coldfire=m5407
1.702     matt      849: GNU_ARCH.earm=arm
1.741     matt      850: GNU_ARCH.earmhf=arm
1.702     matt      851: GNU_ARCH.earmeb=armeb
1.722     matt      852: GNU_ARCH.earmhfeb=armeb
1.741     matt      853: GNU_ARCH.earmv4=armv4
1.742     matt      854: GNU_ARCH.earmv4eb=armv4eb
                    855: GNU_ARCH.earmv5=arm
                    856: GNU_ARCH.earmv5eb=armeb
                    857: GNU_ARCH.earmv6=armv6
                    858: GNU_ARCH.earmv6hf=armv6
                    859: GNU_ARCH.earmv6eb=armv6eb
                    860: GNU_ARCH.earmv6hfeb=armv6eb
                    861: GNU_ARCH.earmv7=armv7
                    862: GNU_ARCH.earmv7hf=armv7
1.741     matt      863: GNU_ARCH.earmv7eb=armv7eb
                    864: GNU_ARCH.earmv7hfeb=armv7eb
1.560     drochner  865: GNU_ARCH.i386=i486
                    866: GCC_CONFIG_ARCH.i386=i486
1.563     ad        867: GCC_CONFIG_TUNE.i386=nocona
                    868: GCC_CONFIG_TUNE.x86_64=nocona
1.261     thorpej   869: GNU_ARCH.m68000=m68010
1.150     itojun    870: GNU_ARCH.sh3eb=sh
1.236     thorpej   871: GNU_ARCH.sh3el=shle
1.468     matt      872: GNU_ARCH.mips64eb=mips64
1.172     tv        873: MACHINE_GNU_ARCH=${GNU_ARCH.${MACHINE_ARCH}:U${MACHINE_ARCH}}
1.161     tv        874:
1.341     lukem     875: #
1.161     tv        876: # In order to identify NetBSD to GNU packages, we sometimes need
                    877: # an "elf" tag for historically a.out platforms.
1.341     lukem     878: #
1.729     matt      879: .if (!empty(MACHINE_ARCH:Mearm*))
1.742     matt      880: MACHINE_GNU_PLATFORM?=${MACHINE_GNU_ARCH}--netbsdelf-${MACHINE_ARCH:C/eb//:C/v[4-7]//:S/earm/eabi/}
1.702     matt      881: .elif (${MACHINE_GNU_ARCH} == "arm" || \
1.294     thorpej   882:      ${MACHINE_GNU_ARCH} == "armeb" || \
1.168     matt      883:      ${MACHINE_ARCH} == "i386" || \
1.494     matt      884:      ${MACHINE_CPU} == "m68k" || \
1.235     thorpej   885:      ${MACHINE_GNU_ARCH} == "sh" || \
1.236     thorpej   886:      ${MACHINE_GNU_ARCH} == "shle" || \
1.168     matt      887:      ${MACHINE_ARCH} == "sparc" || \
                    888:      ${MACHINE_ARCH} == "vax")
1.318     thorpej   889: MACHINE_GNU_PLATFORM?=${MACHINE_GNU_ARCH}--netbsdelf
1.161     tv        890: .else
1.318     thorpej   891: MACHINE_GNU_PLATFORM?=${MACHINE_GNU_ARCH}--netbsd
1.161     tv        892: .endif
1.153     itojun    893:
1.759     skrll     894: .if !empty(MACHINE_ARCH:M*arm*)
1.758     joerg     895: # Flags to pass to CC for using the old APCS ABI on ARM for compat or stand.
                    896: ARM_APCS_FLAGS=        -mabi=apcs-gnu -mfloat-abi=soft
1.850     matt      897: ARM_APCS_FLAGS+=${${ACTIVE_CC} == "gcc":? -marm :}
1.758     joerg     898: ARM_APCS_FLAGS+=${${ACTIVE_CC} == "clang":? -target ${MACHINE_GNU_ARCH}--netbsdelf -B ${TOOLDIR}/${MACHINE_GNU_PLATFORM}/bin :}
                    899: .endif
                    900:
1.776     joerg     901: GENASSYM_CPPFLAGS+=    ${${ACTIVE_CC} == "clang":? -no-integrated-as :}
                    902:
1.160     tv        903: TARGETS+=      all clean cleandir depend dependall includes \
1.880     pooka     904:                install lint obj regress tags html analyze describe \
                    905:                rumpdescribe
1.485     dsl       906: PHONY_NOTMAIN =        all clean cleandir depend dependall distclean includes \
1.669     drochner  907:                install lint obj regress beforedepend afterdepend \
1.142     phil      908:                beforeinstall afterinstall realinstall realdepend realall \
1.880     pooka     909:                html subdir-all subdir-install subdir-depend analyze describe \
                    910:                rumpdescribe
1.485     dsl       911: .PHONY:                ${PHONY_NOTMAIN}
                    912: .NOTMAIN:      ${PHONY_NOTMAIN}
1.58      agc       913:
1.406     lukem     914: .if ${NEED_OWN_INSTALL_TARGET} != "no"
1.56      drochner  915: .if !target(install)
1.485     dsl       916: install:       beforeinstall .WAIT subdir-install realinstall .WAIT afterinstall
                    917: beforeinstall:
                    918: subdir-install:
                    919: realinstall:
                    920: afterinstall:
                    921: .endif
                    922: all:           realall subdir-all
                    923: subdir-all:
                    924: realall:
                    925: depend:                realdepend subdir-depend
                    926: subdir-depend:
                    927: realdepend:
                    928: distclean:     cleandir
                    929: cleandir:      clean
1.205     tv        930:
                    931: dependall:     .NOTMAIN realdepend .MAKE
1.615     christos  932:        @cd "${.CURDIR}"; ${MAKE} realall
1.132     mycroft   933: .endif
1.116     lukem     934:
1.341     lukem     935: #
1.116     lukem     936: # Define MKxxx variables (which are either yes or no) for users
1.350     lukem     937: # to set in /etc/mk.conf and override in the make environment.
1.116     lukem     938: # These should be tested with `== "no"' or `!= "no"'.
1.340     lukem     939: # The NOxxx variables should only be set by Makefiles.
1.116     lukem     940: #
1.466     lukem     941: # Please keep etc/Makefile and share/man/man5/mk.conf.5 in sync
                    942: # with changes to the MK* variables here.
                    943: #
1.116     lukem     944:
1.341     lukem     945: #
1.230     tv        946: # Supported NO* options (if defined, MK* will be forced to "no",
                    947: # regardless of user's mk.conf setting).
1.341     lukem     948: #
1.503     dholland  949: # Source makefiles should set NO*, and not MK*, and must do so before
                    950: # including bsd.own.mk.
                    951: #
1.422     lukem     952: .for var in \
1.534     apb       953:        NOCRYPTO NODOC NOHTML NOINFO NOLINKLIB NOLINT NOMAN NONLS NOOBJ NOPIC \
1.984     christos  954:        NOPICINSTALL NOPROFILE NOSHARE NOSTATICLIB NODEBUGLIB
1.503     dholland  955: .if defined(${var})
                    956: MK${var:S/^NO//}:=     no
1.230     tv        957: .endif
                    958: .endfor
1.268     ross      959:
1.341     lukem     960: #
                    961: # Older-style variables that enabled behaviour when set.
                    962: #
                    963: .for var in MANZ UNPRIVED UPDATE
                    964: .if defined(${var})
                    965: MK${var}:=     yes
1.268     ross      966: .endif
1.341     lukem     967: .endfor
1.230     tv        968:
1.536     mrg       969: #
                    970: # MK* options which have variable defaults.
                    971: #
1.978     mrg       972: # aarch64eb is not yet supported.
                    973: #
1.779     matt      974: .if ${MACHINE_ARCH} == "x86_64" || ${MACHINE_ARCH} == "sparc64" \
                    975:     || ${MACHINE_ARCH} == "mips64eb" || ${MACHINE_ARCH} == "mips64el" \
1.978     mrg       976:     || ${MACHINE_ARCH} == "powerpc64" || ${MACHINE_ARCH} == "aarch64" \
1.929     mrg       977:     || ${MACHINE_ARCH} == "riscv64" || !empty(MACHINE_ARCH:Mearm*)
1.852     martin    978: MKCOMPAT?=     yes
1.536     mrg       979: .else
                    980: # Don't let this build where it really isn't supported.
                    981: MKCOMPAT:=     no
1.934     mrg       982: .endif
                    983:
                    984: .if ${MKCOMPAT} == "no"
1.859     matt      985: MKCOMPATTESTS:=        no
                    986: MKCOMPATX11:=  no
1.536     mrg       987: .endif
                    988:
1.856     matt      989: .if ${MACHINE_ARCH} == "x86_64" || ${MACHINE_ARCH} == "i386" \
                    990:     || ${MACHINE_ARCH} == "mips64eb" || ${MACHINE_ARCH} == "mips64el" \
                    991:     || (${MACHINE} == "evbppc" && ${MACHINE_ARCH} == "powerpc")
1.670     mrg       992: MKCOMPATMODULES?=      yes
                    993: .else
                    994: MKCOMPATMODULES:=      no
                    995: .endif
                    996:
1.341     lukem     997: #
1.647     matt      998: # Default mips64 to softfloat now.
1.738     matt      999: # arm is always softfloat unless it isn't
1.649     pooka    1000: # emips is always softfloat.
1.738     matt     1001: # coldfire is always softfloat
1.834     matt     1002: # or1k is always softfloat
1.647     matt     1003: #
1.649     pooka    1004: .if ${MACHINE_ARCH} == "mips64eb" || ${MACHINE_ARCH} == "mips64el" || \
1.722     matt     1005:     (${MACHINE_CPU} == "arm" && ${MACHINE_ARCH:M*hf*} == "") || \
1.834     matt     1006:     ${MACHINE_ARCH} == "coldfire" || ${MACHINE_CPU} == "or1k" || \
1.722     matt     1007:     ${MACHINE} == "emips"
1.647     matt     1008: MKSOFTFLOAT?=  yes
                   1009: .endif
                   1010:
1.649     pooka    1011: .if ${MACHINE} == "emips"
                   1012: SOFTFLOAT_BITS=        32
                   1013: .endif
                   1014:
1.709     alnsn    1015: .if ${MACHINE_ARCH} == "i386" || \
1.710     alnsn    1016:     ${MACHINE_ARCH} == "x86_64" || \
                   1017:     ${MACHINE_ARCH} == "sparc"
1.709     alnsn    1018: MKSLJIT?=      yes
                   1019: .else
1.715     alnsn    1020: MKSLJIT?=      no
1.709     alnsn    1021: .endif
                   1022:
1.647     matt     1023: #
1.572     skrll    1024: # MK* backward compatibility.
                   1025: #
                   1026: .if defined(MKBFD)
                   1027: MKBINUTILS?=   ${MKBFD}
                   1028: .endif
                   1029:
                   1030: #
1.846     pooka    1031: # We want to build zfs only for amd64 by default for now.
1.603     uebayasi 1032: #
1.846     pooka    1033: .if ${MACHINE} == "amd64"
1.621     he       1034: MKZFS?=                yes
1.603     uebayasi 1035: .endif
                   1036:
                   1037: #
1.884     riz      1038: # DTrace works on amd64, i386 and earm*
                   1039: #
                   1040:
                   1041: .if ${MACHINE_ARCH} == "i386" || \
                   1042:     ${MACHINE_ARCH} == "x86_64" || \
                   1043:     !empty(MACHINE_ARCH:Mearm*)
                   1044: MKDTRACE?=     yes
                   1045: MKCTF?=                yes
                   1046: .endif
                   1047: #
1.919     christos 1048: # PIE is enabled on amd64 by default
                   1049: #
1.925     christos 1050: .if ${MACHINE_ARCH} == "i386" || \
                   1051:     ${MACHINE_ARCH} == "x86_64" || \
1.948     christos 1052:     ${MACHINE_CPU} == "arm" || \
1.957     christos 1053:     ${MACHINE_CPU} == "m68k" || \
1.966     christos 1054:     ${MACHINE_CPU} == "mips" || \
1.948     christos 1055:     ${MACHINE_CPU} == "sh3" || \
1.925     christos 1056:     ${MACHINE} == "sparc64"
1.919     christos 1057: MKPIE?=                yes
1.920     martin   1058: .else
                   1059: MKPIE?=                no
                   1060: .endif
                   1061:
1.919     christos 1062: #
1.936     christos 1063: # RELRO is enabled on i386 and amd64 by default
                   1064: #
                   1065: .if ${MACHINE_ARCH} == "i386" || \
                   1066:     ${MACHINE_ARCH} == "x86_64"
                   1067: MKRELRO?=      partial
                   1068: .else
                   1069: MKRELRO?=      no
                   1070: .endif
                   1071:
                   1072: #
1.230     tv       1073: # MK* options which default to "yes".
1.341     lukem    1074: #
1.600     uebayasi 1075: _MKVARS.yes= \
1.514     gmcgarry 1076:        MKATF \
1.572     skrll    1077:        MKBINUTILS \
1.695     joerg    1078:        MKCRYPTO MKCOMPLEX MKCVS MKCXX \
1.504     lukem    1079:        MKDOC \
1.764     matt     1080:        MKGCC MKGDB MKGROFF \
1.524     lukem    1081:        MKHESIOD MKHTML \
1.504     lukem    1082:        MKIEEEFP MKINET6 MKINFO MKIPFILTER MKISCSI \
                   1083:        MKKERBEROS \
1.570     dyoung   1084:        MKKMOD \
1.749     matt     1085:        MKLDAP MKLIBSTDCXX MKLINKLIB MKLVM \
1.695     joerg    1086:        MKMAN MKMANDOC \
1.583     tsarna   1087:        MKMDNS \
1.694     joerg    1088:        MKMAKEMANDB \
1.525     christos 1089:        MKNLS \
1.640     rmind    1090:        MKNPF \
1.504     lukem    1091:        MKOBJ \
1.664     haad     1092:        MKPAM MKPERFUSE \
1.519     gmcgarry 1093:        MKPF MKPIC MKPICINSTALL MKPICLIB MKPOSTFIX MKPROFILE \
1.703     christos 1094:        MKRUMP \
1.504     lukem    1095:        MKSHARE MKSKEY MKSTATICLIB \
1.945     christos 1096:        MKUNBOUND \
1.567     mrg      1097:        MKX11FONTS \
1.504     lukem    1098:        MKYP
1.600     uebayasi 1099: .for var in ${_MKVARS.yes}
1.830     matt     1100: ${var}?=       ${${var}.${MACHINE_ARCH}:Uyes}
1.230     tv       1101: .endfor
                   1102:
1.341     lukem    1103: #
1.764     matt     1104: # MKGCCCMDS is only valid if we are building GCC so make it dependent on that.
                   1105: #
1.765     matt     1106: _MKVARS.yes += MKGCCCMDS
1.764     matt     1107: MKGCCCMDS?=    ${MKGCC}
                   1108:
                   1109: #
1.606     he       1110: # Exceptions to the above:
                   1111: #
1.848     martin   1112: .if ${MACHINE} == "acorn26"    # page size is prohibitive
                   1113: MKKMOD=                no
                   1114: .endif
1.606     he       1115:
1.939     scole    1116: # Rump doesn't work yet on ia64
                   1117: .if ${MACHINE} == "ia64"
                   1118: MKRUMP=                no
                   1119: .endif
                   1120:
1.606     he       1121: #
1.623     mrg      1122: # MK* options which default to "no".  Note that MKZFS has a different
                   1123: # default for some platforms, see above.
1.341     lukem    1124: #
1.600     uebayasi 1125: _MKVARS.no= \
1.695     joerg    1126:        MKBSDGREP MKBSDTAR \
1.859     matt     1127:        MKCATPAGES MKCOMPATTESTS MKCOMPATX11 MKCRYPTO_RC5 MKCTF MKDEBUG \
1.820     dholland 1128:        MKDEBUGLIB MKDTRACE MKEXTSRC MKGROFFHTMLDOC \
1.751     joerg    1129:        MKKYUA MKLLD MKLLDB MKLINT \
1.725     joerg    1130:        MKMANZ MKMCLINKER MKOBJDIRS \
1.727     joerg    1131:        MKLIBCXX MKLLVM MKPCC \
1.631     mrg      1132:        MKPIGZGZIP \
1.648     he       1133:        MKREPRO \
1.708     christos 1134:        MKSOFTFLOAT MKSTRIPIDENT MKTPM \
1.731     mbalmer  1135:        MKUNPRIVED MKUPDATE MKX11 MKX11MOTIF MKZFS
1.600     uebayasi 1136: .for var in ${_MKVARS.no}
1.830     matt     1137: ${var}?=       ${${var}.${MACHINE_ARCH}:Uno}
1.230     tv       1138: .endfor
                   1139:
1.341     lukem    1140: #
1.733     mrg      1141: # Which platforms build the xorg-server drivers (as opposed
                   1142: # to just Xnest and Xvfb.)
                   1143: #
1.862     mrg      1144: .if ${MACHINE} == "alpha"      || \
1.734     mrg      1145:     ${MACHINE} == "amd64"      || \
1.878     phx      1146:     ${MACHINE} == "amiga"      || \
1.734     mrg      1147:     ${MACHINE} == "bebox"      || \
                   1148:     ${MACHINE} == "cats"       || \
                   1149:     ${MACHINE} == "dreamcast"  || \
                   1150:     ${MACHINE} == "ews4800mips"        || \
                   1151:     ${MACHINE} == "evbarm"     || \
                   1152:     ${MACHINE} == "evbmips"    || \
                   1153:     ${MACHINE} == "hp300"      || \
                   1154:     ${MACHINE} == "hpcarm"     || \
                   1155:     ${MACHINE} == "hpcmips"    || \
                   1156:     ${MACHINE} == "hpcsh"      || \
                   1157:     ${MACHINE} == "i386"       || \
1.876     rjs      1158:     ${MACHINE} == "ibmnws"     || \
1.734     mrg      1159:     ${MACHINE} == "luna68k"    || \
1.874     rjs      1160:     ${MACHINE} == "mac68k"     || \
1.734     mrg      1161:     ${MACHINE} == "macppc"     || \
                   1162:     ${MACHINE} == "netwinder"  || \
                   1163:     ${MACHINE} == "newsmips"   || \
                   1164:     ${MACHINE} == "prep"       || \
                   1165:     ${MACHINE} == "ofppc"      || \
                   1166:     ${MACHINE} == "sgimips"    || \
                   1167:     ${MACHINE} == "shark"      || \
                   1168:     ${MACHINE} == "sparc"      || \
                   1169:     ${MACHINE} == "sparc64"    || \
                   1170:     ${MACHINE} == "vax"                || \
1.862     mrg      1171:     ${MACHINE} == "zaurus"
1.734     mrg      1172: MKXORG_SERVER?=yes
1.733     mrg      1173: .else
1.734     mrg      1174: MKXORG_SERVER?=no
1.733     mrg      1175: .endif
                   1176:
                   1177: #
1.230     tv       1178: # Force some options off if their dependencies are off.
1.341     lukem    1179: #
                   1180:
1.613     matt     1181: .if ${MKCXX} == "no"
                   1182: MKATF:=                no
                   1183: MKGROFF:=      no
1.724     jmmv     1184: MKKYUA:=       no
1.613     matt     1185: .endif
                   1186:
1.230     tv       1187: .if ${MKCRYPTO} == "no"
                   1188: MKKERBEROS:=   no
1.634     mrg      1189: MKLDAP:=       no
1.340     lukem    1190: .endif
                   1191:
                   1192: .if ${MKMAN} == "no"
1.341     lukem    1193: MKCATPAGES:=   no
1.340     lukem    1194: MKHTML:=       no
1.116     lukem    1195: .endif
                   1196:
1.697     joerg    1197: _MANINSTALL=   maninstall
                   1198: .if ${MKCATPAGES} != "no"
                   1199: _MANINSTALL+=  catinstall
                   1200: .endif
                   1201: .if ${MKHTML} != "no"
                   1202: _MANINSTALL+=  htmlinstall
                   1203: .endif
                   1204:
1.117     lukem    1205: .if ${MKLINKLIB} == "no"
1.507     lukem    1206: MKLINT:=       no
1.230     tv       1207: MKPICINSTALL:= no
                   1208: MKPROFILE:=    no
1.327     thorpej  1209: .endif
                   1210:
                   1211: .if ${MKPIC} == "no"
                   1212: MKPICLIB:=     no
1.116     lukem    1213: .endif
                   1214:
1.230     tv       1215: .if ${MKOBJ} == "no"
                   1216: MKOBJDIRS:=    no
1.116     lukem    1217: .endif
                   1218:
1.117     lukem    1219: .if ${MKSHARE} == "no"
1.230     tv       1220: MKCATPAGES:=   no
                   1221: MKDOC:=                no
                   1222: MKINFO:=       no
1.341     lukem    1223: MKHTML:=       no
1.230     tv       1224: MKMAN:=                no
                   1225: MKNLS:=                no
1.116     lukem    1226: .endif
1.276     thorpej  1227:
1.812     joerg    1228: .if !empty(MACHINE_ARCH:Mearm*)
                   1229: _NEEDS_LIBCXX.${MACHINE_ARCH}= yes
                   1230: .endif
1.903     joerg    1231: _NEEDS_LIBCXX.aarch64=         yes
1.977     mrg      1232: _NEEDS_LIBCXX.aarch64eb=       yes
1.832     joerg    1233: _NEEDS_LIBCXX.i386=            yes
                   1234: _NEEDS_LIBCXX.powerpc=         yes
                   1235: _NEEDS_LIBCXX.powerpc64=       yes
1.903     joerg    1236: _NEEDS_LIBCXX.sparc=           yes
                   1237: _NEEDS_LIBCXX.sparc64=         yes
1.832     joerg    1238: _NEEDS_LIBCXX.x86_64=          yes
1.812     joerg    1239:
                   1240: .if ${MKLLVM} == "yes" && ${_NEEDS_LIBCXX.${MACHINE_ARCH}:Uno} == "yes"
                   1241: MKLIBCXX:=     yes
                   1242: .endif
                   1243:
1.341     lukem    1244: #
                   1245: # install(1) parameters.
                   1246: #
                   1247: COPY?=         -c
                   1248: .if ${MKUPDATE} == "no"
                   1249: PRESERVE?=
                   1250: .else
                   1251: PRESERVE?=     -p
                   1252: .endif
                   1253: RENAME?=       -r
                   1254: HRDLINK?=      -l h
1.444     christos 1255: SYMLINK?=      -l s
1.341     lukem    1256:
                   1257: METALOG?=      ${DESTDIR}/METALOG
                   1258: METALOG.add?=  ${TOOL_CAT} -l >> ${METALOG}
                   1259: .if (${_SRC_TOP_} != "")       # only set INSTPRIV if inside ${NETBSDSRCDIR}
                   1260: .if ${MKUNPRIVED} != "no"
1.562     apb      1261: INSTPRIV.unpriv=-U -M ${METALOG} -D ${DESTDIR} -h sha256
1.341     lukem    1262: .else
                   1263: INSTPRIV.unpriv=
                   1264: .endif
                   1265: INSTPRIV?=     ${INSTPRIV.unpriv} -N ${NETBSDSRCDIR}/etc
                   1266: .endif
1.410     lukem    1267: STRIPFLAG?=
1.341     lukem    1268:
1.406     lukem    1269: .if ${NEED_OWN_INSTALL_TARGET} != "no"
1.341     lukem    1270: INSTALL_DIR?=          ${INSTALL} ${INSTPRIV} -d
                   1271: INSTALL_FILE?=         ${INSTALL} ${INSTPRIV} ${COPY} ${PRESERVE} ${RENAME}
                   1272: INSTALL_LINK?=         ${INSTALL} ${INSTPRIV} ${HRDLINK} ${RENAME}
                   1273: INSTALL_SYMLINK?=      ${INSTALL} ${INSTPRIV} ${SYMLINK} ${RENAME}
                   1274: .endif
                   1275:
                   1276: #
1.351     lukem    1277: # Set defaults for the USE_xxx variables.
                   1278: #
                   1279:
                   1280: #
1.433     lukem    1281: # USE_* options which default to "no" and will be forced to "no" if their
                   1282: # corresponding MK* variable is set to "no".
                   1283: #
1.505     lukem    1284: .for var in USE_SKEY
                   1285: .if (${${var:S/USE_/MK/}} == "no")
                   1286: ${var}:= no
                   1287: .else
                   1288: ${var}?= no
                   1289: .endif
                   1290: .endfor
1.433     lukem    1291:
                   1292: #
1.351     lukem    1293: # USE_* options which default to "yes" unless their corresponding MK*
                   1294: # variable is set to "no".
1.341     lukem    1295: #
1.512     lukem    1296: .for var in USE_HESIOD USE_INET6 USE_KERBEROS USE_LDAP USE_PAM USE_YP
1.504     lukem    1297: .if (${${var:S/USE_/MK/}} == "no")
                   1298: ${var}:= no
1.276     thorpej  1299: .else
1.504     lukem    1300: ${var}?= yes
1.276     thorpej  1301: .endif
1.351     lukem    1302: .endfor
                   1303:
                   1304: #
                   1305: # USE_* options which default to "yes".
                   1306: #
1.504     lukem    1307: .for var in USE_JEMALLOC
                   1308: ${var}?= yes
1.497     ad       1309: .endfor
1.300     tron     1310:
1.341     lukem    1311: #
1.445     jmc      1312: # USE_* options which default to "no".
                   1313: #
1.639     mrg      1314: # For now, disable pigz as compressor by default
1.641     ahoka    1315: .for var in USE_PIGZGZIP USE_LIBTRE
1.639     mrg      1316: ${var}?= no
                   1317: .endfor
1.357     lukem    1318:
1.825     apb      1319: #
1.826     apb      1320: # TOOL_GZIP and friends.  These might refer to TOOL_PIGZ or to the host gzip.
1.825     apb      1321: #
1.672     matt     1322: .if ${USE_PIGZGZIP} != "no"
                   1323: TOOL_GZIP=             ${TOOL_PIGZ}
1.825     apb      1324: GZIP_N_FLAG?=          -nT
1.672     matt     1325: .else
                   1326: TOOL_GZIP=             gzip
1.825     apb      1327: GZIP_N_FLAG?=          -n
1.672     matt     1328: .endif
1.825     apb      1329: TOOL_GZIP_N=           ${TOOL_GZIP} ${GZIP_N_FLAG}
1.672     matt     1330:
1.357     lukem    1331: #
1.522     mrg      1332: # Where X11 sources are and where it is installed to.
1.357     lukem    1333: #
1.587     apb      1334: .if !defined(X11SRCDIR)
                   1335: .if exists(${NETBSDSRCDIR}/../xsrc)
1.615     christos 1336: X11SRCDIR!=            cd "${NETBSDSRCDIR}/../xsrc" && pwd
1.587     apb      1337: .else
                   1338: X11SRCDIR=             /usr/xsrc
                   1339: .endif
                   1340: .endif # !defined(X11SRCDIR)
                   1341:
1.357     lukem    1342: X11SRCDIR.local?=      ${X11SRCDIR}/local
1.522     mrg      1343: X11ROOTDIR?=           /usr/X11R7
1.357     lukem    1344: X11BINDIR?=            ${X11ROOTDIR}/bin
1.417     lukem    1345: X11ETCDIR?=            /etc/X11
1.357     lukem    1346: X11FONTDIR?=           ${X11ROOTDIR}/lib/X11/fonts
                   1347: X11INCDIR?=            ${X11ROOTDIR}/include
                   1348: X11LIBDIR?=            ${X11ROOTDIR}/lib/X11
                   1349: X11MANDIR?=            ${X11ROOTDIR}/man
1.635     mrg      1350: X11SHAREDIR?=          ${X11ROOTDIR}/share
1.858     matt     1351: X11USRLIBDIR?=         ${X11ROOTDIR}/lib${MLIBDIR:D/${MLIBDIR}}
1.417     lukem    1352:
1.516     mrg      1353: #
                   1354: # New modular-xorg based builds
                   1355: #
                   1356: X11SRCDIRMIT?=         ${X11SRCDIR}/external/mit
                   1357: .for _lib in \
                   1358:        FS ICE SM X11 XScrnSaver XTrap Xau Xcomposite Xcursor Xdamage \
1.860     mrg      1359:        Xdmcp Xevie Xext Xfixes Xfont Xft Xi Xinerama Xmu Xpresent Xpm \
1.516     mrg      1360:        Xrandr Xrender Xres Xt Xtst Xv XvMC Xxf86dga Xxf86misc Xxf86vm drm \
1.942     mrg      1361:        epoxy fontenc xkbfile xkbui Xaw Xfontcache pciaccess xcb xshmfence \
1.789     mrg      1362:        pthread-stubs
1.516     mrg      1363: X11SRCDIR.${_lib}?=            ${X11SRCDIRMIT}/lib${_lib}/dist
                   1364: .endfor
                   1365:
                   1366: .for _proto in \
                   1367:        xcmisc xext xf86bigfont bigreqs input kb x fonts fixes scrnsaver \
1.788     mrg      1368:        xinerama dri2 dri3 render resource record video xf86dga xf86misc \
1.635     mrg      1369:        xf86vidmode composite damage trap gl randr fontcache xf86dri \
1.788     mrg      1370:        present xcb-
1.516     mrg      1371: X11SRCDIR.${_proto}proto?=             ${X11SRCDIRMIT}/${_proto}proto/dist
                   1372: .endfor
                   1373:
1.931     mrg      1374: # During transition from xorg-server 1.10 to 1.18
1.956     mrg      1375: .if \
1.980     mrg      1376:     ${MACHINE} == "alpha"      || \
                   1377:     ${MACHINE} == "amiga"      || \
                   1378:     ${MACHINE} == "bebox"      || \
                   1379:     ${MACHINE} == "cats"       || \
                   1380:     ${MACHINE} == "dreamcast"  || \
                   1381:     ${MACHINE} == "ews4800mips"        || \
                   1382:     ${MACHINE} == "hp300"      || \
                   1383:     ${MACHINE} == "hpcarm"     || \
                   1384:     ${MACHINE} == "hpcmips"    || \
                   1385:     ${MACHINE} == "hpcsh"      || \
                   1386:     ${MACHINE} == "ibmnws"     || \
                   1387:     ${MACHINE} == "luna68k"    || \
                   1388:     ${MACHINE} == "mac68k"     || \
                   1389:     ${MACHINE} == "netwinder"  || \
                   1390:     ${MACHINE} == "newsmips"   || \
                   1391:     ${MACHINE} == "prep"       || \
                   1392:     ${MACHINE} == "sgimips"    || \
                   1393:     ${MACHINE} == "vax"                || \
                   1394:     ${MACHINE} == "zaurus"
                   1395: HAVE_XORG_SERVER_VER?=110
                   1396: .else
1.952     jakllsch 1397: HAVE_XORG_SERVER_VER?=118
                   1398: .endif
1.941     mrg      1399:
1.944     mrg      1400: .if ${HAVE_XORG_SERVER_VER} == "118"
1.931     mrg      1401: XORG_SERVER_SUBDIR?=xorg-server
1.943     mrg      1402: . if ${MACHINE} == "amd64" || ${MACHINE} == "i386"
                   1403: HAVE_XORG_GLAMOR?=     yes
                   1404: . endif
1.931     mrg      1405: .else
                   1406: XORG_SERVER_SUBDIR?=xorg-server.old
                   1407: .endif
                   1408:
                   1409: X11SRCDIR.xorg-server?=                ${X11SRCDIRMIT}/${XORG_SERVER_SUBDIR}/dist
1.943     mrg      1410: HAVE_XORG_GLAMOR?=     no
                   1411:
                   1412: # Build glamor extension?
1.931     mrg      1413:
1.516     mrg      1414: .for _dir in \
1.843     snj      1415:        xtrans fontconfig freetype evieext mkfontscale bdftopcf \
1.931     mrg      1416:        xkbcomp xorg-cf-files imake xbiff xkeyboard-config \
1.517     mrg      1417:        xbitmaps appres xeyes xev xedit sessreg pixman \
1.838     mrg      1418:        beforelight bitmap editres makedepend fonttosfnt fslsfonts fstobdf \
1.843     snj      1419:        glu glw mesa-demos MesaGLUT MesaLib MesaLib7 \
                   1420:        ico iceauth listres lndir \
1.516     mrg      1421:        luit xproxymanagementprotocol mkfontdir oclock proxymngr rgb \
1.861     mrg      1422:        rstart setxkbmap showfont smproxy twm viewres \
                   1423:        x11perf xauth xcalc xclipboard \
1.843     snj      1424:        xclock xcmsdb xconsole xditview xdpyinfo xdriinfo xdm \
1.516     mrg      1425:        xfd xf86dga xfindproxy xfontsel xfwp xgamma xgc xhost xinit \
                   1426:        xkill xload xlogo xlsatoms xlsclients xlsfonts xmag xmessage \
                   1427:        xmh xmodmap xmore xman xprop xrandr xrdb xrefresh xset \
                   1428:        xsetmode xsetpointer xsetroot xsm xstdcmap xvidtune xvinfo \
1.843     snj      1429:        xwininfo xwud xkbprint xkbevd \
                   1430:        xterm xwd xfs xfsinfo xtrap xkbutils xkbcomp \
1.732     mrg      1431:        xkeyboard-config xinput xcb-util xorg-docs \
1.516     mrg      1432:        font-adobe-100dpi font-adobe-75dpi font-adobe-utopia-100dpi \
                   1433:        font-adobe-utopia-75dpi font-adobe-utopia-type1 \
                   1434:        font-alias \
                   1435:        font-bh-100dpi font-bh-75dpi font-bh-lucidatypewriter-100dpi \
                   1436:        font-bh-lucidatypewriter-75dpi font-bh-ttf font-bh-type1 \
                   1437:        font-bitstream-100dpi font-bitstream-75dpi font-bitstream-type1 \
                   1438:        font-cursor-misc font-daewoo-misc font-dec-misc font-ibm-type1 \
                   1439:        font-isas-misc font-jis-misc font-misc-misc font-mutt-misc \
1.554     tron     1440:        font-sony-misc font-util ttf-bitstream-vera encodings
1.516     mrg      1441: X11SRCDIR.${_dir}?=            ${X11SRCDIRMIT}/${_dir}/dist
                   1442: .endfor
                   1443:
1.518     mrg      1444: .for _i in \
1.652     mrg      1445:        elographics keyboard mouse synaptics vmmouse void ws
1.518     mrg      1446: X11SRCDIR.xf86-input-${_i}?=   ${X11SRCDIRMIT}/xf86-input-${_i}/dist
                   1447: .endfor
                   1448:
1.963     mrg      1449: # xf86-video-modesetting move into the server build.
                   1450: EXTRA_DRIVERS=
                   1451: .if ${HAVE_XORG_SERVER_VER} == "118"
                   1452: X11SRCDIR.xf86-video-modesetting=${X11SRCDIR.xorg-server}/hw/xfree86/drivers/modesetting
                   1453: .else
                   1454: EXTRA_DRIVERS= modesetting
                   1455: .endif
                   1456:
1.518     mrg      1457: .for _v in \
1.942     mrg      1458:        ag10e amdgpu apm ark ast ati ati-kms chips cirrus crime \
1.879     jmcneill 1459:        geode glint i128 i740 igs imstt intel intel-old \
1.963     mrg      1460:        ${EXTRA_DRIVERS} mach64 mga \
1.875     mrg      1461:        neomagic newport nouveau nsc nv nvxbox openchrome pnozz \
1.942     mrg      1462:        r128 rendition \
1.626     mrg      1463:        s3 s3virge savage siliconmotion sis suncg14 \
                   1464:        suncg6 sunffb sunleo suntcx \
1.843     snj      1465:        tdfx tga trident tseng vesa vga vmware wsfb xgi
1.518     mrg      1466: X11SRCDIR.xf86-video-${_v}?=   ${X11SRCDIRMIT}/xf86-video-${_v}/dist
                   1467: .endfor
                   1468:
1.847     mrg      1469: # Only install the radeon firmware on DRM-happy systems.
                   1470: .if ${MACHINE_ARCH} == "x86_64" || ${MACHINE_ARCH} == "i386"
                   1471: MKRADEONFIRMWARE?=             yes
                   1472: .endif
                   1473: MKRADEONFIRMWARE?=             no
                   1474:
1.516     mrg      1475: X11DRI?=                       yes
                   1476: X11LOADABLE?=                  yes
1.374     lukem    1477:
                   1478:
                   1479: #
1.598     uebayasi 1480: # Where extsrc sources are and where it is installed to.
                   1481: #
                   1482: .if !defined(EXTSRCSRCDIR)
                   1483: .if exists(${NETBSDSRCDIR}/../extsrc)
1.615     christos 1484: EXTSRCSRCDIR!=         cd "${NETBSDSRCDIR}/../extsrc" && pwd
1.598     uebayasi 1485: .else
                   1486: EXTSRCSRCDIR=          /usr/extsrc
                   1487: .endif
                   1488: .endif # !defined(EXTSRCSRCDIR)
                   1489:
                   1490: EXTSRCROOTDIR?=                /usr/ext
                   1491: EXTSRCBINDIR?=         ${EXTSRCROOTDIR}/bin
                   1492: EXTSRCETCDIR?=         /etc/ext
                   1493: EXTSRCINCDIR?=         ${EXTSRCROOTDIR}/include
                   1494: EXTSRCLIBDIR?=         ${EXTSRCROOTDIR}/lib/ext
                   1495: EXTSRCMANDIR?=         ${EXTSRCROOTDIR}/man
                   1496: EXTSRCUSRLIBDIR?=      ${EXTSRCROOTDIR}/lib
                   1497:
                   1498: #
1.414     lukem    1499: # MAKEDIRTARGET dir target [extra make(1) params]
1.612     mrg      1500: #      run "cd $${dir} && ${MAKEDIRTARGETENV} ${MAKE} [params] $${target}", with a pretty message
1.414     lukem    1501: #
1.612     mrg      1502: MAKEDIRTARGETENV?=
1.414     lukem    1503: MAKEDIRTARGET=\
                   1504:        @_makedirtarget() { \
                   1505:                dir="$$1"; shift; \
                   1506:                target="$$1"; shift; \
                   1507:                case "$${dir}" in \
                   1508:                /*)     this="$${dir}/"; \
                   1509:                        real="$${dir}" ;; \
                   1510:                .)      this="${_THISDIR_}"; \
                   1511:                        real="${.CURDIR}" ;; \
                   1512:                *)      this="${_THISDIR_}$${dir}/"; \
                   1513:                        real="${.CURDIR}/$${dir}" ;; \
                   1514:                esac; \
                   1515:                show=$${this:-.}; \
                   1516:                echo "$${target} ===> $${show%/}$${1:+  (with: $$@)}"; \
                   1517:                cd "$${real}" \
1.612     mrg      1518:                && ${MAKEDIRTARGETENV} ${MAKE} _THISDIR_="$${this}" "$$@" $${target}; \
1.414     lukem    1519:        }; \
                   1520:        _makedirtarget
                   1521:
                   1522: #
1.374     lukem    1523: # MAKEVERBOSE support.  Levels are:
1.549     apb      1524: #      0       Minimal output ("quiet")
                   1525: #      1       Describe what is occurring
                   1526: #      2       Describe what is occurring and echo the actual command
                   1527: #      3       Ignore the effect of the "@" prefix in make commands
                   1528: #      4       Trace shell commands using the shell's -x flag
1.374     lukem    1529: #
                   1530: MAKEVERBOSE?=          2
                   1531:
                   1532: .if ${MAKEVERBOSE} == 0
                   1533: _MKMSG?=       @\#
                   1534: _MKSHMSG?=     : echo
                   1535: _MKSHECHO?=    : echo
1.380     lukem    1536: .SILENT:
1.374     lukem    1537: .elif ${MAKEVERBOSE} == 1
                   1538: _MKMSG?=       @echo '   '
                   1539: _MKSHMSG?=     echo '   '
                   1540: _MKSHECHO?=    : echo
1.380     lukem    1541: .SILENT:
1.549     apb      1542: .else  # MAKEVERBOSE >= 2
1.374     lukem    1543: _MKMSG?=       @echo '\#  '
                   1544: _MKSHMSG?=     echo '\#  '
                   1545: _MKSHECHO?=    echo
1.380     lukem    1546: .SILENT: __makeverbose_dummy_target__
1.549     apb      1547: .endif # MAKEVERBOSE >= 2
                   1548: .if ${MAKEVERBOSE} >= 3
                   1549: .MAKEFLAGS:    -dl
                   1550: .endif # ${MAKEVERBOSE} >= 3
                   1551: .if ${MAKEVERBOSE} >= 4
                   1552: .MAKEFLAGS:    -dx
                   1553: .endif # ${MAKEVERBOSE} >= 4
1.374     lukem    1554:
                   1555: _MKMSG_BUILD?=         ${_MKMSG} "  build "
                   1556: _MKMSG_CREATE?=                ${_MKMSG} " create "
                   1557: _MKMSG_COMPILE?=       ${_MKMSG} "compile "
                   1558: _MKMSG_FORMAT?=                ${_MKMSG} " format "
                   1559: _MKMSG_INSTALL?=       ${_MKMSG} "install "
                   1560: _MKMSG_LINK?=          ${_MKMSG} "   link "
                   1561: _MKMSG_LEX?=           ${_MKMSG} "    lex "
                   1562: _MKMSG_REMOVE?=                ${_MKMSG} " remove "
                   1563: _MKMSG_YACC?=          ${_MKMSG} "   yacc "
1.391     lukem    1564:
                   1565: _MKSHMSG_CREATE?=      ${_MKSHMSG} " create "
                   1566: _MKSHMSG_INSTALL?=     ${_MKSHMSG} "install "
1.374     lukem    1567:
1.394     lukem    1568: _MKTARGET_BUILD?=      ${_MKMSG_BUILD} ${.CURDIR:T}/${.TARGET}
                   1569: _MKTARGET_CREATE?=     ${_MKMSG_CREATE} ${.CURDIR:T}/${.TARGET}
                   1570: _MKTARGET_COMPILE?=    ${_MKMSG_COMPILE} ${.CURDIR:T}/${.TARGET}
                   1571: _MKTARGET_FORMAT?=     ${_MKMSG_FORMAT} ${.CURDIR:T}/${.TARGET}
                   1572: _MKTARGET_INSTALL?=    ${_MKMSG_INSTALL} ${.TARGET}
                   1573: _MKTARGET_LINK?=       ${_MKMSG_LINK} ${.CURDIR:T}/${.TARGET}
                   1574: _MKTARGET_LEX?=                ${_MKMSG_LEX} ${.CURDIR:T}/${.TARGET}
                   1575: _MKTARGET_REMOVE?=     ${_MKMSG_REMOVE} ${.TARGET}
                   1576: _MKTARGET_YACC?=       ${_MKMSG_YACC} ${.CURDIR:T}/${.TARGET}
1.64      lukem    1577:
1.592     joerg    1578: .if ${MKMANDOC} == "yes"
                   1579: TARGETS+=      lintmanpages
                   1580: .endif
                   1581:
1.855     matt     1582: TESTSBASE=     /usr/tests${MLIBDIR:D/${MLIBDIR}}
1.638     jmmv     1583:
1.897     riz      1584: # Override with tools versions if needed
                   1585: .if ${MKCTF:Uno} != "no" && !defined(NOCTF)
                   1586: CTFCONVERT=    ${TOOL_CTFCONVERT}
                   1587: CTFMERGE=      ${TOOL_CTFMERGE}
                   1588: .endif
                   1589:
1.347     lukem    1590: .endif # !defined(_BSD_OWN_MK_)

CVSweb <webmaster@jp.NetBSD.org>