Recurse into the extra tools repo the correct way from the Makefile
build system. Thanks to Nick for pointing at the actual construct which
should be used here.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@161609 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/tools/Makefile b/tools/Makefile
index dad767c..e7aa2fa 100644
--- a/tools/Makefile
+++ b/tools/Makefile
@@ -9,9 +9,12 @@
 
 CLANG_LEVEL := ..
 
-DIRS := driver libclang c-index-test arcmt-test c-arcmt-test diagtool \
-        clang-check $(patsubst %/Makefile,%,$(wildcard extra/Makefile))
-
 include $(CLANG_LEVEL)/../../Makefile.config
 
+DIRS := driver libclang c-index-test arcmt-test c-arcmt-test diagtool \
+        clang-check
+
+# Recurse into the extra repository of tools if present.
+OPTIONAL_DIRS := extra
+
 include $(CLANG_LEVEL)/Makefile