]> granicus.if.org Git - clang/commit
Frontend: Add a CC1 flag to dump module dependencies to a directory
authorJustin Bogner <mail@justinbogner.com>
Thu, 19 Jun 2014 19:36:03 +0000 (19:36 +0000)
committerJustin Bogner <mail@justinbogner.com>
Thu, 19 Jun 2014 19:36:03 +0000 (19:36 +0000)
commit329c41fc3dddc19b8d77419560fa30ac2ed0ee51
treecb1454301f5a23cb4e13fad8270d1fda199a8864
parentb6fcb1e475ea0d1395915c1d56a195128f654837
Frontend: Add a CC1 flag to dump module dependencies to a directory

This adds the -module-dependency-dir to clang -cc1, which specifies a
directory to copy all of a module's dependencies into in a form
suitable to be used as a VFS using -ivfsoverlay with the generated
vfs.yaml.

This is useful for crashdumps that involve modules, so that the module
dependencies will be intact when a crash report script is used to
reproduce a problem on another machine.

We currently encode the absolute path to the dump directory, due to
limitations in the VFS system. Until we can handle relative paths in
the VFS, users of the VFS map may need to run a simple search and
replace in the file.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@211303 91177308-0d34-0410-b5e6-96231b3b80d8
include/clang/Driver/Options.td
include/clang/Frontend/CompilerInstance.h
include/clang/Frontend/DependencyOutputOptions.h
include/clang/Frontend/Utils.h
lib/Frontend/CMakeLists.txt
lib/Frontend/CompilerInstance.cpp
lib/Frontend/CompilerInvocation.cpp
lib/Frontend/ModuleDependencyCollector.cpp [new file with mode: 0644]
test/Modules/dependency-dump-dependent-module.m [new file with mode: 0644]
test/Modules/dependency-dump.m [new file with mode: 0644]