1 // Check that clang-scan-deps works with cc1 command lines
4 // RUN: split-file %s %t
12 //--- module.modulemap
13 module header1
{ header
"header.h" }
15 //--- cdb.json.template
17 "file": "DIR/modules_cc1.cpp",
19 "command": "clang -cc1 DIR/modules_cc1.cpp -fimplicit-module-maps -o modules_cc1.o"
22 // RUN: sed "s|DIR|%/t|g" %t/cdb.json.template > %t/cdb.json
23 // RUN: clang-scan-deps -compilation-database %t/cdb.json -j 1 -mode preprocess-dependency-directives > %t/result
24 // RUN: cat %t/result | sed 's:\\\\\?:/:g' | FileCheck %s -DPREFIX=%/t
26 // CHECK: modules_cc1.o:
27 // CHECK-NEXT: [[PREFIX]]/modules_cc1.cpp
28 // CHECK-NEXT: [[PREFIX]]/module.modulemap
29 // CHECK-NEXT: [[PREFIX]]/header.h