1 # $NetBSD: link.mk,v 1.5 2013/09/29 12:11:59 joerg Exp $
6 LIB_BASE
= ${NETBSDSRCDIR}/tools
/llvm-lib
8 LIB_BASE
= ${LLVM_TOPLEVEL}/lib
11 .for l in
${MCLINKER_LIBS}
12 MCLINKER_OBJDIR.
${l}!= cd
${LIB_BASE}/libMCLinker
${l} && ${PRINTOBJDIR}
13 LDADD
+= -L
${MCLINKER_OBJDIR.
${l}} -lMCLinker
${l}
14 DPADD
+= ${MCLINKER_OBJDIR.
${l}}/libMCLinker
${l}.a
17 .for l in
${LLDB_LIBS}
18 LLDB_OBJDIR.
${l}!= cd
${LIB_BASE}/liblldb
${l} && ${PRINTOBJDIR}
19 LDADD
+= -L
${LLDB_OBJDIR.
${l}} -llldb
${l}
20 DPADD
+= ${LLDB_OBJDIR.
${l}}/liblldb
${l}.a
23 .for l in
${CLANG_LIBS}
24 CLANG_OBJDIR.
${l}!= cd
${LIB_BASE}/lib
${l} && ${PRINTOBJDIR}
25 LDADD
+= -L
${CLANG_OBJDIR.
${l}} -l
${l}
26 DPADD
+= ${CLANG_OBJDIR.
${l}}/lib
${l}.a
30 LLD_OBJDIR.
${l}!= cd
${LIB_BASE}/lib
${l} && ${PRINTOBJDIR}
31 LDADD
+= -L
${LLD_OBJDIR.
${l}} -l
${l}
32 DPADD
+= ${LLD_OBJDIR.
${l}}/lib
${l}.a
35 .for l in
${LLVM_LIBS}
36 LLVM_OBJDIR.
${l}!= cd
${LIB_BASE}/libLLVM
${l} && ${PRINTOBJDIR}
37 LDADD
+= -L
${LLVM_OBJDIR.
${l}} -lLLVM
${l}
38 DPADD
+= ${LLVM_OBJDIR.
${l}}/libLLVM
${l}.a
42 LDADD_NEED_DL
= cat
${LLVM_TOOLCONF_OBJDIR}/need-dl
2> /dev
/null
43 LDADD_NEED_TERMINFO
= cat
${LLVM_TOOLCONF_OBJDIR}/need-terminfo
2> /dev
/null
44 LDADD
+= ${LDADD_NEED_DL
:sh
} ${LDADD_NEED_TERMINFO
:sh
}
47 DPADD
+= ${LIBTERMINFO}
50 .if defined
(__MINIX
) && defined
(HOSTPROG
) && ${HOST_OSTYPE
:C
/\
-.
*//} != "Minix"
53 LDADD
+= -lc
++ -lmthread
54 .
endif # defined(__MINIX)