diff options
author | Mark Kettenis <kettenis@cvs.openbsd.org> | 2017-03-27 15:32:39 +0000 |
---|---|---|
committer | Mark Kettenis <kettenis@cvs.openbsd.org> | 2017-03-27 15:32:39 +0000 |
commit | ccf2c7b227d4d11c90245fbeb8524480ba781522 (patch) | |
tree | b3289a1dde65298ca17f666857aeaacd5357d9b0 /gnu/usr.bin | |
parent | ef66f2575a1847449d9fd4e12b8897fdc4b4a58b (diff) |
Do not clobber the default compiler/linker links unless COMPILER_VERSION is
set to clang.
ok jsg@
Diffstat (limited to 'gnu/usr.bin')
-rw-r--r-- | gnu/usr.bin/clang/clang/Makefile | 15 | ||||
-rw-r--r-- | gnu/usr.bin/clang/lld/Makefile | 4 |
2 files changed, 12 insertions, 7 deletions
diff --git a/gnu/usr.bin/clang/clang/Makefile b/gnu/usr.bin/clang/clang/Makefile index 7f593850313..a4c0d025201 100644 --- a/gnu/usr.bin/clang/clang/Makefile +++ b/gnu/usr.bin/clang/clang/Makefile @@ -1,4 +1,4 @@ -# $OpenBSD: Makefile,v 1.6 2017/01/24 08:44:47 patrick Exp $ +# $OpenBSD: Makefile,v 1.7 2017/03/27 15:32:38 kettenis Exp $ .include <bsd.own.mk> @@ -13,15 +13,18 @@ LDADD+= -ltermlib DPADD+= ${LIBTERMLIB} LINKS= ${BINDIR}/clang ${BINDIR}/clang++ \ - ${BINDIR}/clang ${BINDIR}/clang-cpp \ - ${BINDIR}/clang ${BINDIR}/cc \ + ${BINDIR}/clang ${BINDIR}/clang-cpp +MLINKS= clang.1 clang++.1 \ + clang.1 clang-cpp.1 + +.if ${COMPILER_VERSION:L} == "clang" +LINKS+= ${BINDIR}/clang ${BINDIR}/cc \ ${BINDIR}/clang ${BINDIR}/c++ \ ${BINDIR}/clang ${LIBEXECDIR}/cpp -MLINKS= clang.1 clang++.1 \ - clang.1 clang-cpp.1 \ - clang.1 cc.1 \ +MLINKS+=clang.1 cc.1 \ clang.1 c++.1 \ clang.1 cpp.1 +.endif CPPFLAGS+= -I${.CURDIR}/../../../llvm/tools/clang/include diff --git a/gnu/usr.bin/clang/lld/Makefile b/gnu/usr.bin/clang/lld/Makefile index 60c941043f1..f068790dc0d 100644 --- a/gnu/usr.bin/clang/lld/Makefile +++ b/gnu/usr.bin/clang/lld/Makefile @@ -1,4 +1,4 @@ -# $OpenBSD: Makefile,v 1.6 2017/01/24 08:44:47 patrick Exp $ +# $OpenBSD: Makefile,v 1.7 2017/03/27 15:32:38 kettenis Exp $ .include <bsd.own.mk> @@ -10,7 +10,9 @@ NOMAN= LDADD+= -ltermlib DPADD+= ${LIBTERMLIB} +.if ${COMPILER_VERSION:L} == "clang" LINKS= ${BINDIR}/ld.lld ${BINDIR}/ld +.endif CPPFLAGS+= ${CLANG_INCLUDES} CPPFLAGS+= -I${.CURDIR}/../../../llvm/tools/lld/include |