Home | History | Annotate | Line # | Download | only in libc
      1  1.21     skrll # $NetBSD: Makefile.inc,v 1.21 2021/04/27 09:14:24 skrll Exp $
      2  1.14     joerg 
      3  1.14     joerg .include <bsd.own.mk>
      4   1.1  christos 
      5   1.1  christos COMMON_DIR:=${.PARSEDIR}
      6  1.19   hannken COMMON_CODEDIRS=atomic gen gmon inet md misc net rpc stdlib string sys
      7  1.17  riastrad COMMON_CODEDIRS+=hash/sha1 hash/sha2 hash/sha3 hash/rmd160 hash/murmurhash
      8   1.1  christos 
      9  1.10       mrg .if defined(COMMON_MACHINE_ARCH) && !empty(COMMON_MACHINE_ARCH) && \
     10  1.10       mrg     exists(${COMMON_DIR}/arch/${COMMON_MACHINE_ARCH})
     11  1.10       mrg COMMON_ARCHSUBDIR=	${COMMON_MACHINE_ARCH}
     12  1.16      matt .elif defined(COMMON_MACHINE_CPU) && !empty(COMMON_MACHINE_CPU) && \
     13  1.16      matt     exists(${COMMON_DIR}/arch/${COMMON_MACHINE_CPU})
     14  1.16      matt COMMON_ARCHSUBDIR=	${COMMON_MACHINE_CPU}
     15  1.10       mrg .elif defined(LIBKERN_ARCH) && !empty(LIBKERN_ARCH) && \
     16   1.3  christos     exists(${KERNDIR}/arch/${LIBKERN_ARCH})
     17   1.3  christos COMMON_ARCHSUBDIR=	${LIBKERN_ARCH}
     18   1.3  christos .elif exists(${COMMON_DIR}/arch/${MACHINE_ARCH})
     19   1.3  christos COMMON_ARCHSUBDIR=	${MACHINE_ARCH}
     20   1.1  christos .elif exists(${COMMON_DIR}/arch/${MACHINE_CPU})
     21   1.3  christos COMMON_ARCHSUBDIR=	${MACHINE_CPU}
     22   1.5      yamt .endif
     23   1.1  christos 
     24   1.1  christos COMMON_ARCHDIR=${COMMON_DIR}/arch/${COMMON_ARCHSUBDIR}
     25   1.1  christos 
     26   1.1  christos .for i in ${COMMON_CODEDIRS}
     27   1.1  christos .if exists(${COMMON_DIR}/$i)
     28   1.1  christos .PATH.c: ${COMMON_DIR}/$i
     29   1.1  christos .endif
     30   1.8  nakayama .if exists(${COMMON_ARCHDIR}/${i}/Makefile.inc)
     31   1.8  nakayama .include "${COMMON_ARCHDIR}/${i}/Makefile.inc"
     32   1.8  nakayama .endif
     33  1.11     joerg .if !empty(CPPFLAGS:M-DLIBKERN_OPTIMISE_SPACE) && \
     34  1.11     joerg     exists(${COMMON_ARCHDIR}/$i/small)
     35  1.11     joerg .PATH.S: ${COMMON_ARCHDIR}/$i/small
     36  1.11     joerg .endif
     37  1.11     joerg 
     38   1.1  christos .if exists(${COMMON_ARCHDIR}/$i)
     39   1.7        ad .PATH.c: ${COMMON_ARCHDIR}/$i
     40   1.1  christos .PATH.S: ${COMMON_ARCHDIR}/$i
     41   1.1  christos .endif
     42   1.1  christos .endfor
     43   1.1  christos 
     44   1.5      yamt CPPFLAGS+=-I${COMMON_DIR}/quad -I${COMMON_DIR}/string
     45   1.5      yamt .if defined(COMMON_ARCHSUBDIR)
     46   1.5      yamt CPPFLAGS+=-I${COMMON_ARCHDIR}/string
     47  1.21     skrll CPPFLAGS+=-I${COMMON_ARCHDIR}/atomic
     48   1.5      yamt .endif
     49  1.20  riastrad CPPFLAGS+=-I${COMMON_DIR}/hash/sha3
     50