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

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

1.149   ! reyk        1: #      $OpenBSD: bsd.own.mk,v 1.148 2014/04/13 08:35:27 brad Exp $
1.7       deraadt     2: #      $NetBSD: bsd.own.mk,v 1.24 1996/04/13 02:08:09 thorpej Exp $
                      3:
1.15      millert     4: # Host-specific overrides
1.7       deraadt     5: .if defined(MAKECONF) && exists(${MAKECONF})
                      6: .include "${MAKECONF}"
                      7: .elif exists(/etc/mk.conf)
                      8: .include "/etc/mk.conf"
1.26      art         9: .endif
1.1       deraadt    10:
1.51      espie      11: # Set `WARNINGS' to `yes' to add appropriate warnings to each compilation
                     12: WARNINGS?=     no
1.15      millert    13: # Set `SKEY' to `yes' to build with support for S/key authentication.
                     14: SKEY?=         yes
                     15: # Set `KERBEROS5' to `yes' to build with support for Kerberos5 authentication.
1.149   ! reyk       16: KERBEROS5?=    no
1.19      downsj     17: # Set `YP' to `yes' to build with support for NIS/YP.
1.15      millert    18: YP?=           yes
1.32      niklas     19: # Set `DEBUGLIBS' to `yes' to build libraries with debugging symbols
1.33      marc       20: DEBUGLIBS?=    no
1.71      espie      21:
1.145     miod       22: GCC3_ARCH=m88k vax
1.139     miod       23: BINUTILS217_ARCH=hppa64 ia64
1.127     deraadt    24:
1.131     deraadt    25: # arm needs binutils-2.17, which still lacks W^X support
1.142     deraadt    26: # sparc has not been tried
1.144     deraadt    27: # m88k unknown
                     28: # hppa64 unknown
1.147     pascal     29: PIE_ARCH=alpha amd64 hppa i386 mips64 mips64el powerpc sh sparc64
1.106     drahn      30:
                     31: .for _arch in ${MACHINE_ARCH}
1.141     miod       32: .if !empty(GCC3_ARCH:M${_arch})
                     33: COMPILER_VERSION?=gcc3
                     34: .else
1.101     espie      35: COMPILER_VERSION?=gcc4
1.107     drahn      36: .endif
                     37:
                     38: .if !empty(BINUTILS217_ARCH:M${_arch})
                     39: BINUTILS_VERSION=binutils-2.17
                     40: .else
                     41: BINUTILS_VERSION=binutils
1.72      mickey     42: .endif
1.121     pascal     43:
                     44: .if !empty(PIE_ARCH:M${_arch})
1.137     miod       45: NOPIE_FLAGS?=-fno-pie
                     46: NOPIE_LDFLAGS?=-nopie
                     47: PIE_DEFAULT?=${DEFAULT_PIE_DEF}
1.121     pascal     48: .else
1.137     miod       49: NOPIE_FLAGS?=
                     50: PIE_DEFAULT?=
1.121     pascal     51: .endif
1.106     drahn      52: .endfor
1.117     matthew    53:
                     54: .if ${COMPILER_VERSION} == "gcc4"
                     55: VISIBILITY_HIDDEN?=-fvisibility=hidden
                     56: .endif
1.32      niklas     57:
1.1       deraadt    58: # where the system object and source trees are kept; can be configurable
                     59: # by the user in case they want them in ~/foosrc and ~/fooobj, for example
                     60: BSDSRCDIR?=    /usr/src
                     61: BSDOBJDIR?=    /usr/obj
                     62:
                     63: BINGRP?=       bin
1.9       deraadt    64: BINOWN?=       root
1.1       deraadt    65: BINMODE?=      555
                     66: NONBINMODE?=   444
1.28      espie      67: DIRMODE?=      755
1.1       deraadt    68:
1.18      tholo      69: SHAREDIR?=     /usr/share
                     70: SHAREGRP?=     bin
                     71: SHAREOWN?=     root
                     72: SHAREMODE?=    ${NONBINMODE}
1.1       deraadt    73:
1.105     schwarze   74: MANDIR?=       /usr/share/man/man
1.1       deraadt    75: MANGRP?=       bin
1.9       deraadt    76: MANOWN?=       root
1.1       deraadt    77: MANMODE?=      ${NONBINMODE}
                     78:
                     79: LIBDIR?=       /usr/lib
                     80: LIBGRP?=       ${BINGRP}
                     81: LIBOWN?=       ${BINOWN}
                     82: LIBMODE?=      ${NONBINMODE}
                     83:
1.119     haesbaer   84: DOCDIR?=       /usr/share/doc
1.1       deraadt    85: DOCGRP?=       bin
1.9       deraadt    86: DOCOWN?=       root
1.119     haesbaer   87: DOCMODE?=      ${NONBINMODE}
1.5       tholo      88:
                     89: LKMDIR?=       /usr/lkm
                     90: LKMGRP?=       ${BINGRP}
                     91: LKMOWN?=       ${BINOWN}
                     92: LKMMODE?=      ${NONBINMODE}
1.1       deraadt    93:
                     94: NLSDIR?=       /usr/share/nls
                     95: NLSGRP?=       bin
1.9       deraadt    96: NLSOWN?=       root
1.1       deraadt    97: NLSMODE?=      ${NONBINMODE}
1.93      espie      98:
                     99: LOCALEDIR?=    /usr/share/locale
                    100: LOCALEGRP?=    wheel
                    101: LOCALEOWN?=    root
                    102: LOCALEMODE?=   ${NONBINMODE}
1.119     haesbaer  103:
                    104: .if !defined(CDIAGFLAGS)
                    105: CDIAGFLAGS=    -Wall -Wpointer-arith -Wuninitialized -Wstrict-prototypes
1.143     martynas  106: CDIAGFLAGS+=   -Wmissing-prototypes -Wunused -Wsign-compare
1.119     haesbaer  107: CDIAGFLAGS+=   -Wshadow
1.120     sthen     108: .  if ${COMPILER_VERSION} == "gcc4"
                    109: CDIAGFLAGS+=   -Wdeclaration-after-statement
                    110: .  endif
1.119     haesbaer  111: .endif
1.56      espie     112:
1.57      espie     113: # Shared files for system gnu configure, not used yet
                    114: GNUSYSTEM_AUX_DIR?=${BSDSRCDIR}/share/gnu
1.1       deraadt   115:
1.17      millert   116: INSTALL_COPY?= -c
1.13      niklas    117: .ifndef DEBUG
1.17      millert   118: INSTALL_STRIP?=        -s
1.13      niklas    119: .endif
1.12      downsj    120:
                    121: # This may be changed for _single filesystem_ configurations (such as
                    122: # routers and other embedded systems); normal systems should leave it alone!
1.11      downsj    123: STATIC?=       -static
1.1       deraadt   124:
                    125: # Define SYS_INCLUDE to indicate whether you want symbolic links to the system
                    126: # source (``symlinks''), or a separate copy (``copies''); (latter useful
                    127: # in environments where it's not possible to keep /sys publicly readable)
                    128: #SYS_INCLUDE=  symlinks
                    129:
                    130: # don't try to generate PIC versions of libraries on machines
                    131: # which don't support PIC.
1.134     miod      132: .if ${MACHINE_ARCH} == "vax"
1.1       deraadt   133: NOPIC=
1.58      drahn     134: .endif
                    135:
1.86      pvalchev  136: # pic relocation flags.
1.96      martin    137: .if (${MACHINE_ARCH} == "alpha") || (${MACHINE_ARCH} == "sparc64")
1.100     deraadt   138: PICFLAG?=-fPIC
1.86      pvalchev  139: .else
1.100     deraadt   140: PICFLAG?=-fpic
1.62      art       141: .endif
1.86      pvalchev  142:
1.95      brad      143: .if ${MACHINE_ARCH} == "sparc" || ${MACHINE_ARCH} == "sparc64"
1.58      drahn     144: ASPICFLAG=-KPIC
1.121     pascal    145: .endif
                    146:
1.129     kettenis  147: .if ${MACHINE_ARCH} == "alpha" || ${MACHINE_ARCH} == "powerpc" || \
                    148:     ${MACHINE_ARCH} == "sparc64"
1.121     pascal    149: # big PIE
                    150: DEFAULT_PIE_DEF=-DPIE_DEFAULT=2
                    151: .else
                    152: # small pie
                    153: DEFAULT_PIE_DEF=-DPIE_DEFAULT=1
1.14      rahnds    154: .endif
                    155:
                    156: # don't try to generate PROFILED versions of libraries on machines
                    157: # which don't support profiling.
1.87      miod      158: .if 0
1.14      rahnds    159: NOPROFILE=
1.1       deraadt   160: .endif
1.31      espie     161:
                    162: BSD_OWN_MK=Done
1.41      espie     163:
                    164: .PHONY: spell clean cleandir obj manpages print all \
1.98      espie     165:        depend beforedepend afterdepend cleandepend subdirdepend \
1.115     jsg       166:        all cleanman nlsinstall cleannls includes \
1.41      espie     167:        beforeinstall realinstall maninstall afterinstall install