aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBryan Drewery <bdrewery@FreeBSD.org>2016-06-17 16:46:58 +0000
committerBryan Drewery <bdrewery@FreeBSD.org>2016-06-17 16:46:58 +0000
commitbc2abcfdef445d4884b996c8f4806d1931b9ab1c (patch)
tree499746355e48ee8c2972a1d72ad2811b19caf28f
parentda64d1122de93d1ef2f21e92f08da3fbf5a987e1 (diff)
downloadsrc-bc2abcfdef445d4884b996c8f4806d1931b9ab1c.tar.gz
src-bc2abcfdef445d4884b996c8f4806d1931b9ab1c.zip
Add clang-format under WITH_CLANG_EXTRAS.
Reviewed by: dim Approved by: re (gjb) Sponsored by: EMC / Isilon Storage Division Differential Revision: https://reviews.freebsd.org/D6856
Notes
Notes: svn path=/head/; revision=301993
-rw-r--r--lib/clang/Makefile4
-rw-r--r--lib/clang/libclangformat/Makefile20
-rw-r--r--lib/clang/libclangformat/Makefile.depend15
-rw-r--r--lib/clang/libclangtoolingcore/Makefile19
-rw-r--r--lib/clang/libclangtoolingcore/Makefile.depend15
-rw-r--r--targets/pseudo/clang/Makefile.depend1
-rw-r--r--tools/build/mk/OptionalObsoleteFiles.inc1
-rw-r--r--usr.bin/clang/Makefile1
-rw-r--r--usr.bin/clang/clang-format/Makefile23
-rw-r--r--usr.bin/clang/clang-format/Makefile.depend32
10 files changed, 130 insertions, 1 deletions
diff --git a/lib/clang/Makefile b/lib/clang/Makefile
index 71e52024da26..a42a6daa9994 100644
--- a/lib/clang/Makefile
+++ b/lib/clang/Makefile
@@ -90,7 +90,9 @@ SUBDIR= libclanganalysis \
libllvmx86utils
.if ${MK_CLANG_EXTRAS} != "no"
-SUBDIR+=libllvmdebuginfodwarf \
+SUBDIR+=libclangformat \
+ libclangtoolingcore \
+ libllvmdebuginfodwarf \
libllvmdebuginfopdb \
libllvmlibdriver \
libllvmlto \
diff --git a/lib/clang/libclangformat/Makefile b/lib/clang/libclangformat/Makefile
new file mode 100644
index 000000000000..6d82a58093b1
--- /dev/null
+++ b/lib/clang/libclangformat/Makefile
@@ -0,0 +1,20 @@
+# $FreeBSD$
+
+.include <bsd.own.mk>
+
+LIB= clangformat
+
+SRCDIR= tools/clang/lib/Format
+
+SRCS= BreakableToken.cpp \
+ ContinuationIndenter.cpp \
+ Format.cpp \
+ FormatToken.cpp \
+ TokenAnnotator.cpp \
+ UnwrappedLineFormatter.cpp \
+ UnwrappedLineParser.cpp \
+ WhitespaceManager.cpp
+
+TGHDRS= DiagnosticCommonKinds
+
+.include "../clang.lib.mk"
diff --git a/lib/clang/libclangformat/Makefile.depend b/lib/clang/libclangformat/Makefile.depend
new file mode 100644
index 000000000000..3e7f3f5e7165
--- /dev/null
+++ b/lib/clang/libclangformat/Makefile.depend
@@ -0,0 +1,15 @@
+# $FreeBSD$
+# Autogenerated - do NOT edit!
+
+DIRDEPS = \
+ include \
+ include/xlocale \
+ lib/libc++ \
+ lib/msun \
+
+
+.include <dirdeps.mk>
+
+.if ${DEP_RELDIR} == ${_DEP_RELDIR}
+# local dependencies - needed for -jN in clean tree
+.endif
diff --git a/lib/clang/libclangtoolingcore/Makefile b/lib/clang/libclangtoolingcore/Makefile
new file mode 100644
index 000000000000..5f7b5e3b1cc6
--- /dev/null
+++ b/lib/clang/libclangtoolingcore/Makefile
@@ -0,0 +1,19 @@
+# $FreeBSD$
+
+.include <bsd.own.mk>
+
+LIB= clangtoolingcore
+
+SRCDIR= tools/clang/lib/Tooling/Core
+CFLAGS+= -I${LLVM_SRCS}/tools
+SRCS= Lookup.cpp \
+ Replacement.cpp
+
+TGHDRS= AttrList \
+ Attrs \
+ CommentCommandList \
+ DeclNodes \
+ DiagnosticCommonKinds \
+ StmtNodes
+
+.include "../clang.lib.mk"
diff --git a/lib/clang/libclangtoolingcore/Makefile.depend b/lib/clang/libclangtoolingcore/Makefile.depend
new file mode 100644
index 000000000000..3e7f3f5e7165
--- /dev/null
+++ b/lib/clang/libclangtoolingcore/Makefile.depend
@@ -0,0 +1,15 @@
+# $FreeBSD$
+# Autogenerated - do NOT edit!
+
+DIRDEPS = \
+ include \
+ include/xlocale \
+ lib/libc++ \
+ lib/msun \
+
+
+.include <dirdeps.mk>
+
+.if ${DEP_RELDIR} == ${_DEP_RELDIR}
+# local dependencies - needed for -jN in clean tree
+.endif
diff --git a/targets/pseudo/clang/Makefile.depend b/targets/pseudo/clang/Makefile.depend
index 10ee9216af6e..daf81899f437 100644
--- a/targets/pseudo/clang/Makefile.depend
+++ b/targets/pseudo/clang/Makefile.depend
@@ -21,6 +21,7 @@ DIRDEPS+= \
.if ${MK_CLANG_EXTRAS} == "yes"
DIRDEPS+= \
usr.bin/clang/bugpoint \
+ usr.bin/clang/clang-format \
usr.bin/clang/llc \
usr.bin/clang/lli \
usr.bin/clang/llvm-ar \
diff --git a/tools/build/mk/OptionalObsoleteFiles.inc b/tools/build/mk/OptionalObsoleteFiles.inc
index 8a56228d7bc4..5bda73c9a201 100644
--- a/tools/build/mk/OptionalObsoleteFiles.inc
+++ b/tools/build/mk/OptionalObsoleteFiles.inc
@@ -1237,6 +1237,7 @@ OLD_FILES+=usr/share/man/man1/llvm-tblgen.1.gz
.if ${MK_CLANG_EXTRAS} == no
OLD_FILES+=usr/bin/bugpoint
+OLD_FILES+=usr/bin/clang-format
OLD_FILES+=usr/bin/llc
OLD_FILES+=usr/bin/lli
OLD_FILES+=usr/bin/llvm-ar
diff --git a/usr.bin/clang/Makefile b/usr.bin/clang/Makefile
index 692b6c806590..5d4c514baa8f 100644
--- a/usr.bin/clang/Makefile
+++ b/usr.bin/clang/Makefile
@@ -7,6 +7,7 @@ SUBDIR= clang clang-tblgen llvm-tblgen
.if !defined(TOOLS_PREFIX)
.if ${MK_CLANG_EXTRAS} != "no"
SUBDIR+=bugpoint \
+ clang-format \
llc \
lli \
llvm-ar \
diff --git a/usr.bin/clang/clang-format/Makefile b/usr.bin/clang/clang-format/Makefile
new file mode 100644
index 000000000000..86e0d8d34bf1
--- /dev/null
+++ b/usr.bin/clang/clang-format/Makefile
@@ -0,0 +1,23 @@
+# $FreeBSD$
+
+MAN=
+.include <bsd.own.mk>
+
+PROG_CXX=clang-format
+
+SRCDIR= tools/clang/tools/clang-format
+SRCS= ClangFormat.cpp
+
+LIBDEPS=clangrewrite \
+ clanglex \
+ clangformat \
+ clangbasic \
+ clangast \
+ clangtoolingcore \
+ llvmmc \
+ llvmcore \
+ llvmsupport \
+
+TGHDRS= DiagnosticCommonKinds
+
+.include "../clang.prog.mk"
diff --git a/usr.bin/clang/clang-format/Makefile.depend b/usr.bin/clang/clang-format/Makefile.depend
new file mode 100644
index 000000000000..6c4e251a3e77
--- /dev/null
+++ b/usr.bin/clang/clang-format/Makefile.depend
@@ -0,0 +1,32 @@
+# $FreeBSD$
+# Autogenerated - do NOT edit!
+
+DIRDEPS = \
+ gnu/lib/csu \
+ gnu/lib/libgcc \
+ include \
+ include/xlocale \
+ lib/${CSU_DIR} \
+ lib/clang/libclangast \
+ lib/clang/libclangbasic \
+ lib/clang/libclangformat \
+ lib/clang/libclanglex \
+ lib/clang/libclangrewrite \
+ lib/clang/libclangtoolingcore \
+ lib/clang/libllvmcore \
+ lib/clang/libllvmmc \
+ lib/clang/libllvmsupport \
+ lib/libc \
+ lib/libc++ \
+ lib/libcompiler_rt \
+ lib/libthr \
+ lib/msun \
+ lib/ncurses/ncursesw \
+ usr.bin/clang/clang-tblgen.host \
+
+
+.include <dirdeps.mk>
+
+.if ${DEP_RELDIR} == ${_DEP_RELDIR}
+# local dependencies - needed for -jN in clean tree
+.endif