OSDN Git Service

Reland: [clang driver] Move default module cache from system temporary directory
authorDavid Zarzycki <dave@znu.io>
Tue, 23 Jun 2020 09:43:51 +0000 (05:43 -0400)
committerDavid Zarzycki <dave@znu.io>
Sat, 27 Jun 2020 09:35:15 +0000 (05:35 -0400)
commitdab859d1bf250c4d0299ac505e2a6773c56b6503
tree356de9b8d4efde741b0b469db8c894ab718100c4
parentdf813dc09e1bf5260d8f5cce3643ec90c68cd426
Reland: [clang driver] Move default module cache from system temporary directory

This fixes a unit test. Otherwise here is the original commit:

1) Shared writable directories like /tmp are a security problem.
2) Systems provide dedicated cache directories these days anyway.
3) This also refines LLVM's cache_directory() on Darwin platforms to use
   the Darwin per-user cache directory.

Reviewers: compnerd, aprantl, jakehehrlich, espindola, respindola, ilya-biryukov, pcc, sammccall

Reviewed By: compnerd, sammccall

Subscribers: hiraditya, llvm-commits, cfe-commits

Tags: #clang, #llvm

Differential Revision: https://reviews.llvm.org/D82362
clang/docs/ReleaseNotes.rst
clang/include/clang/Driver/Driver.h
clang/lib/Driver/ToolChains/Clang.cpp
clang/test/Driver/modules-cache-path.m
clang/unittests/Driver/ModuleCacheTest.cpp
llvm/lib/Support/Unix/Path.inc
llvm/unittests/Support/Path.cpp