Re-instate r125819 and r125820 with no functionality change

llvm-svn: 126060
diff --git a/clang/examples/PrintFunctionNames/CMakeLists.txt b/clang/examples/PrintFunctionNames/CMakeLists.txt
index 58b4603..86793ce 100644
--- a/clang/examples/PrintFunctionNames/CMakeLists.txt
+++ b/clang/examples/PrintFunctionNames/CMakeLists.txt
@@ -1,34 +1,11 @@
 set(MODULE TRUE)
 
 set( LLVM_USED_LIBS
-  clangFrontendTool
   clangFrontend
-  clangDriver
-  clangSerialization
-  clangCodeGen
-  clangParse
-  clangSema
-  clangStaticAnalyzerFrontend
-  clangStaticAnalyzerCheckers
-  clangStaticAnalyzerCore
-  clangAnalysis
-  clangIndex
-  clangRewrite
   clangAST
-  clangLex
-  clangBasic
   )
 
-# Why do we have to link to all this just to print out function names?
-set( LLVM_LINK_COMPONENTS
-  ${LLVM_TARGETS_TO_BUILD}
-  asmparser
-  bitreader
-  bitwriter
-  codegen
-  ipo
-  selectiondag
-  )
+set( LLVM_LINK_COMPONENTS support mc)
 
 add_clang_library(PrintFunctionNames PrintFunctionNames.cpp)
 
diff --git a/clang/examples/clang-interpreter/main.cpp b/clang/examples/clang-interpreter/main.cpp
index 835a5a9..a99766f 100644
--- a/clang/examples/clang-interpreter/main.cpp
+++ b/clang/examples/clang-interpreter/main.cpp
@@ -17,7 +17,6 @@
 #include "clang/Frontend/FrontendDiagnostic.h"
 #include "clang/Frontend/TextDiagnosticPrinter.h"
 
-#include "llvm/LLVMContext.h"
 #include "llvm/Module.h"
 #include "llvm/Config/config.h"
 #include "llvm/ADT/OwningPtr.h"
@@ -130,7 +129,6 @@
 
   // Create a compiler instance to handle the actual work.
   CompilerInstance Clang;
-  Clang.setLLVMContext(new llvm::LLVMContext);
   Clang.setInvocation(CI.take());
 
   // Create the compilers actual diagnostics engine.