[PATCH] D87928: Provide -fsource-dir flag in Clang

Petr Hosek via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Sep 18 12:17:14 PDT 2020


phosek created this revision.
Herald added subscribers: llvm-commits, cfe-commits, dang, hiraditya.
Herald added projects: clang, LLVM.
phosek requested review of this revision.
Herald added a subscriber: ormris.

This flag can be used to relativize source paths againts a given
directory.  Compared to -f*-prefix-map flags, it avoids the absolute
path on the compiler command line analogously to -fdebug-compile-dir,
which is important  distributed compilation scenarios.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D87928

Files:
  clang/include/clang/Basic/CodeGenOptions.h
  clang/include/clang/Driver/Options.td
  clang/include/clang/Lex/PreprocessorOptions.h
  clang/lib/CodeGen/CoverageMappingGen.cpp
  clang/lib/CodeGen/CoverageMappingGen.h
  clang/lib/Driver/ToolChains/Clang.cpp
  clang/lib/Frontend/CompilerInvocation.cpp
  clang/lib/Lex/PPMacroExpansion.cpp
  clang/test/CoverageMapping/source_dir.c
  clang/test/Preprocessor/file_test.c
  llvm/include/llvm/Support/Path.h
  llvm/lib/Support/Path.cpp
  llvm/unittests/Support/Path.cpp

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D87928.292868.patch
Type: text/x-patch
Size: 11108 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20200918/546c9925/attachment.bin>


More information about the llvm-commits mailing list