blob: 56eb9ed57755dfa0c4daaf15c23cd75f17091817 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
|
# $OpenBSD: Makefile,v 1.1 2019/03/05 01:55:18 jsg Exp $
PROG= llvm-config
BINDIR= /usr/bin
NOMAN=
NATIVE_ARCHS=AArch64 ARM Mips PowerPC Sparc X86
PYTHON= python2
LLVMBUILD= ${.CURDIR}/../../../llvm/utils/llvm-build/llvm-build
.include <bsd.own.mk>
SRCS= llvm-config.cpp
CPPFLAGS+= -I${.CURDIR}
llvm-config.o: BuildVariables.inc LibraryDependencies.inc
BuildVariables.inc: ${.CURDIR}/BuildVariables.inc.def
cp ${.CURDIR}/BuildVariables.inc.def ${.OBJDIR}/BuildVariables.inc
echo "#define LLVM_TARGETS_BUILT \"${LLVM_ARCH} AMDGPU\"" >> \
${.OBJDIR}/BuildVariables.inc
LibraryDependencies.inc:
cp ${.CURDIR}/LibraryDependencies.inc.${LLVM_ARCH} \
${.OBJDIR}/LibraryDependencies.inc
LLVM_LIBDEPS= LLVMTableGen LLVMSupport
reconf:
.for arch in ${NATIVE_ARCHS}
${PYTHON} -B ${LLVMBUILD} \
--native-target ${LLVM_ARCH} \
--enable-targets "${arch} AMDGPU" \
--write-library-table ${.CURDIR}/LibraryDependencies.inc.${arch}
.endfor
CLEANFILES+= BuildVariables.inc LibraryDependencies.inc
.PATH: ${.CURDIR}/../../../llvm/tools/llvm-config
.include <bsd.prog.mk>
|