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