xref: /llvm-project/flang/test/Driver/response-file.f90 (revision 1c0b03f6e706978f2e87408f7fd5e4c846d6c9a8)
1! Test that the driver can process response files.
2
3! RUN: echo "-DTEST" > %basename_t.rsp
4! RUN: %flang -E -cpp @%basename_t.rsp %s -o - | FileCheck %s
5! RUN: %flang_fc1 -E -cpp @%basename_t.rsp %s -o - | FileCheck %s
6! RUN: not %flang %basename_t.rsp %s -o /dev/null
7! RUN: not %flang_fc1 %basenamt_t.rsp %s -o /dev/null
8
9! CHECK-LABEL: program test
10! CHECK: end program
11
12#ifdef TEST
13program test
14end program
15#else
16We should have read the define from the response file.
17#endif
18