clang 17.0.0git
DependencyOutputOptions.h
Go to the documentation of this file.
1//===--- DependencyOutputOptions.h ------------------------------*- C++ -*-===//
2//
3// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4// See https://llvm.org/LICENSE.txt for license information.
5// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6//
7//===----------------------------------------------------------------------===//
8
9#ifndef LLVM_CLANG_FRONTEND_DEPENDENCYOUTPUTOPTIONS_H
10#define LLVM_CLANG_FRONTEND_DEPENDENCYOUTPUTOPTIONS_H
11
13#include <string>
14#include <vector>
15
16namespace clang {
17
18/// ShowIncludesDestination - Destination for /showIncludes output.
20
21/// DependencyOutputFormat - Format for the compiler dependency file.
23
24/// ExtraDepKind - The kind of extra dependency file.
30};
31
32/// DependencyOutputOptions - Options for controlling the compiler dependency
33/// file generation.
35public:
36 unsigned IncludeSystemHeaders : 1; ///< Include system header dependencies.
37 unsigned ShowHeaderIncludes : 1; ///< Show header inclusions (-H).
38 unsigned UsePhonyTargets : 1; ///< Include phony targets for each
39 /// dependency, which can avoid some 'make'
40 /// problems.
41 unsigned AddMissingHeaderDeps : 1; ///< Add missing headers to dependency list
42 unsigned IncludeModuleFiles : 1; ///< Include module file dependencies.
43 unsigned ShowSkippedHeaderIncludes : 1; ///< With ShowHeaderIncludes, show
44 /// also includes that were skipped
45 /// due to the "include guard
46 /// optimization" or #pragma once.
47
48 /// The format of header information.
50
51 /// Determine whether header information should be filtered.
53
54 /// Destination of cl.exe style /showIncludes info.
56
57 /// The format for the dependency file.
59
60 /// The file to write dependency output to.
61 std::string OutputFile;
62
63 /// The file to write header include output to. This is orthogonal to
64 /// ShowHeaderIncludes (-H) and will include headers mentioned in the
65 /// predefines buffer. If the output file is "-", output will be sent to
66 /// stderr.
68
69 /// A list of names to use as the targets in the dependency file; this list
70 /// must contain at least one entry.
71 std::vector<std::string> Targets;
72
73 /// A list of extra dependencies (filename and kind) to be used for every
74 /// target.
75 std::vector<std::pair<std::string, ExtraDepKind>> ExtraDeps;
76
77 /// In /showIncludes mode, pretend the main TU is a header with this name.
79
80 /// The file to write GraphViz-formatted header dependencies to.
81 std::string DOTOutputFile;
82
83 /// The directory to copy module dependencies to when collecting them.
85
86public:
92};
93
94} // end namespace clang
95
96#endif
Defines enums used when emitting included header information.
DependencyOutputOptions - Options for controlling the compiler dependency file generation.
ShowIncludesDestination ShowIncludesDest
Destination of cl.exe style /showIncludes info.
std::string DOTOutputFile
The file to write GraphViz-formatted header dependencies to.
unsigned AddMissingHeaderDeps
Add missing headers to dependency list.
HeaderIncludeFormatKind HeaderIncludeFormat
The format of header information.
std::string ModuleDependencyOutputDir
The directory to copy module dependencies to when collecting them.
DependencyOutputFormat OutputFormat
The format for the dependency file.
std::string OutputFile
The file to write dependency output to.
unsigned UsePhonyTargets
Include phony targets for each dependency, which can avoid some 'make' problems.
HeaderIncludeFilteringKind HeaderIncludeFiltering
Determine whether header information should be filtered.
std::vector< std::string > Targets
A list of names to use as the targets in the dependency file; this list must contain at least one ent...
unsigned ShowSkippedHeaderIncludes
With ShowHeaderIncludes, show also includes that were skipped due to the "include guard optimizatio...
std::vector< std::pair< std::string, ExtraDepKind > > ExtraDeps
A list of extra dependencies (filename and kind) to be used for every target.
std::string ShowIncludesPretendHeader
In /showIncludes mode, pretend the main TU is a header with this name.
unsigned IncludeModuleFiles
Include module file dependencies.
std::string HeaderIncludeOutputFile
The file to write header include output to.
unsigned IncludeSystemHeaders
Include system header dependencies.
unsigned ShowHeaderIncludes
Show header inclusions (-H).
HeaderIncludeFilteringKind
Whether header information is filtered or not.
Definition: HeaderInclude.h:27
@ HIFIL_None
Definition: HeaderInclude.h:27
ExtraDepKind
ExtraDepKind - The kind of extra dependency file.
DependencyOutputFormat
DependencyOutputFormat - Format for the compiler dependency file.
@ None
The alignment was not explicit in code.
HeaderIncludeFormatKind
The format in which header information is emitted.
Definition: HeaderInclude.h:22
@ HIFMT_Textual
Definition: HeaderInclude.h:22
ShowIncludesDestination
ShowIncludesDestination - Destination for /showIncludes output.