From 83d46be31e56be9708495a832345bcec7499f904 Mon Sep 17 00:00:00 2001 From: Douglas Gregor Date: Thu, 2 Feb 2012 00:54:52 +0000 Subject: Introduce a -cc1 option "-dependency-graphviz" that determines header dependencies and outputs them in GraphViz format. llvm-svn: 149575 --- clang/lib/Frontend/CompilerInstance.cpp | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'clang/lib/Frontend/CompilerInstance.cpp') diff --git a/clang/lib/Frontend/CompilerInstance.cpp b/clang/lib/Frontend/CompilerInstance.cpp index 1501da4..97dc708 100644 --- a/clang/lib/Frontend/CompilerInstance.cpp +++ b/clang/lib/Frontend/CompilerInstance.cpp @@ -275,7 +275,11 @@ void CompilerInstance::createPreprocessor() { const DependencyOutputOptions &DepOpts = getDependencyOutputOpts(); if (!DepOpts.OutputFile.empty()) AttachDependencyFileGen(*PP, DepOpts); + if (!DepOpts.GraphvizOutputFile.empty()) + AttachDependencyGraphGen(*PP, DepOpts.GraphvizOutputFile, + getHeaderSearchOpts().Sysroot); + // Handle generating header include information, if requested. if (DepOpts.ShowHeaderIncludes) AttachHeaderIncludeGen(*PP); -- cgit v1.1