-# $OpenBSD: Makefile,v 1.6 2017/01/24 08:44:47 patrick Exp $
+# $OpenBSD: Makefile,v 1.7 2017/04/10 13:36:04 kettenis Exp $
.include <bsd.own.mk>
LLVM_V= 4.0.0
CLANG_INTR_INCDIR= /usr/lib/clang/${LLVM_V}/include
+TBLGEN= ${.OBJDIR}/../../../clang-tblgen/clang-tblgen
+CLANG_INC=${.CURDIR}/../../../../../llvm/tools/clang/include
+
.PATH: ${.CURDIR}/../../../../../llvm/tools/clang/lib/Headers
+GEN=
HEADERS= stdalign.h \
stdatomic.h \
stdnoreturn.h \
module.modulemap \
.if ${MACHINE_ARCH} == "aarch64" || ${MACHINE_ARCH} == "arm"
-HEADERS+= arm_acle.h
+GEN+= arm_neon.h
+HEADERS+= arm_acle.h ${GEN}
.elif ${MACHINE_ARCH} == "amd64" || ${MACHINE_ARCH} == "i386"
HEADERS+= adxintrin.h \
ammintrin.h \
# Nothing here so far ...
clean cleandir:
- # Nothing here so far ...
+ rm -f ${GEN}
install includes: ${HEADERS}
${INSTALL} -d -o ${SHAREOWN} -g ${SHAREGRP} -m ${DIRMODE} \
${INSTALL} ${INSTALL_COPY} -m 444 ${.ALLSRC} \
${DESTDIR}${CLANG_INTR_INCDIR}
+arm_neon.h: ${CLANG_INC}/clang/Basic/arm_neon.td
+ ${TBLGEN} -gen-arm-neon -o ${.TARGET} ${.ALLSRC}
+
.include <bsd.obj.mk>