blob: 49922847797fb144bc22353cf67286dce130a9f0 [file] [log] [blame]
Reid Spencer72c41252006-03-23 23:22:16 +00001=pod
2
3=head1 NAME
4
5llvm-config - Print LLVM compilation options
6
7=head1 SYNOPSIS
8
9B<llvm-config> I<option> [I<components>...]
10
11=head1 DESCRIPTION
12
13B<llvm-config> makes it easier to build applications that use LLVM. It can
14print the compiler flags, linker flags and object libraries needed to link
15against LLVM.
16
17=head1 EXAMPLES
18
19To link against the JIT:
20
21 g++ `llvm-config --cxxflags` -o HowToUseJIT.o -c HowToUseJIT.cpp
22 g++ `llvm-config --ldflags` -o HowToUseJIT HowToUseJIT.o \
23 `llvm-config --libs engine bcreader scalaropts`
24
25=head1 OPTIONS
26
27=over
28
29=item B<--version>
30
31Print the version number of LLVM.
32
33=item B<--help>
34
35Print a summary of B<llvm-config> arguments.
36
37=item B<--prefix>
38
39Print the installation prefix for LLVM.
40
41=item B<--bindir>
42
43Print the installation directory for LLVM binaries.
44
45=item B<--includedir>
46
47Print the installation directory for LLVM headers.
48
49=item B<--libdir>
50
51Print the installation directory for LLVM libraries.
52
53=item B<--cxxflags>
54
55Print the C++ compiler flags needed to use LLVM headers.
56
57=item B<--ldflags>
58
59Print the flags needed to link against LLVM libraries.
60
61=item B<--libs>
62
63Print all the libraries needed to link against the specified LLVM
64I<components>, including any dependencies.
65
66=item B<--libnames>
67
68Similar to B<--libs>, but prints the bare filenames of the libraries
69without B<-l> or pathnames. Useful for linking against a not-yet-installed
70copy of LLVM.
71
72=item B<--components>
73
74Print all valid component names.
75
76=item B<--targets-built>
77
78Print the component names for all targets supported by this copy of LLVM.
79
80=back
81
82=head1 COMPONENTS
83
84To print a list of all available components, run B<llvm-config
85--components>. In most cases, components correspond directly to LLVM
86libraries. Useful "virtual" components include:
87
88=over
89
90=item B<all>
91
92Includes all LLVM libaries. The default if no components are specified.
93
94=item B<backend>
95
96Includes either a native backend or the C backend.
97
98=item B<engine>
99
100Includes either a native JIT or the bytecode interpreter.
101
102=back
103
104=head1 EXIT STATUS
105
106If B<llvm-config> succeeds, it will exit with 0. Otherwise, if an error
107occurs, it will exit with a non-zero value.
108
109=head1 AUTHORS
110
111Maintained by the LLVM Team (L<http://llvm.org>).
112
113=cut