]> TLD Linux GIT Repositories - packages/llvm.git/blob - llvm.spec
d4ecdd54083b25c51a4c6798115869d646319d97
[packages/llvm.git] / llvm.spec
1 #
2 # Conditional build:
3 %bcond_without  lldb    # LLDB debugger
4 %bcond_without  polly   # Polly cache-locality optimization, auto-parallelism and vectorization
5 %bcond_without  rt      # compiler-rt libraries
6 %bcond_without  ocaml   # OCaml binding
7 %bcond_without  doc     # HTML docs and man pages
8 %bcond_with     apidocs # doxygen docs (HUGE, so they are not built by default)
9 %bcond_with     tests   # run tests
10
11 Summary:        The Low Level Virtual Machine (An Optimizing Compiler Infrastructure)
12 Summary(pl.UTF-8):      Niskopoziomowa maszyna wirtualna (infrastruktura kompilatora optymalizującego)
13 Name:           llvm
14 Version:        3.5.1
15 Release:        3
16 License:        University of Illinois/NCSA Open Source License
17 Group:          Development/Languages
18 #Source0Download: http://llvm.org/releases/download.html
19 Source0:        http://llvm.org/releases/%{version}/%{name}-%{version}.src.tar.xz
20 # Source0-md5:  2d3d8004f38852aa679e5945b8ce0b14
21 Source1:        http://llvm.org/releases/%{version}/cfe-%{version}.src.tar.xz
22 # Source1-md5:  93f9532f8f7e6f1d8e5c1116907051cb
23 Source2:        http://llvm.org/releases/%{version}/compiler-rt-%{version}.src.tar.xz
24 # Source2-md5:  d626cfb8a9712cb92b820798ab5bc1f8
25 Source3:        http://llvm.org/releases/%{version}/lldb-%{version}.src.tar.xz
26 # Source3-md5:  cc5ea8a414c62c33e760517f8929a204
27 Source4:        http://llvm.org/releases/%{version}/polly-%{version}.src.tar.xz
28 # Source4-md5:  b02e005a54e0911ccd8b7f1ca039cb51
29 Source5:        http://llvm.org/releases/%{version}/clang-tools-extra-%{version}.src.tar.xz
30 # Source5-md5:  f13f31ed3038acadc6fa63fef812a246
31 Source6:        http://llvm.org/releases/%{version}/lld-%{version}.src.tar.xz
32 # Source6-md5:  173be02b7ff4e5e31fbb0a591a03d7a3
33 Patch0:         %{name}-config.patch
34 # Data files should be installed with timestamps preserved
35 Patch1:         %{name}-2.6-timestamp.patch
36 Patch2:         %{name}-tld.patch
37 Patch3:         %{name}-polly-update.patch
38 Patch4:         %{name}-lldb.patch
39 Patch5:         %{name}-lldb-atomic.patch
40 Patch6:         %{name}-lld-link.patch
41 URL:            http://llvm.org/
42 BuildRequires:  autoconf >= 2.60
43 BuildRequires:  automake >= 1:1.9.6
44 BuildRequires:  bash
45 BuildRequires:  bison
46 BuildRequires:  flex
47 BuildRequires:  gcc >= 5:3.4
48 # gcc4 might be installed, but not current __cc
49 %if "%(echo %{cc_version} | cut -d. -f1,2)" < "3.4"
50 BuildRequires:  __cc >= 3.4
51 %endif
52 BuildRequires:  groff
53 BuildRequires:  libltdl-devel
54 BuildRequires:  libtool >= 2:1.5.22
55 BuildRequires:  libstdc++-devel >= 5:3.4
56 BuildRequires:  ocaml-ocamldoc
57 BuildRequires:  perl-base >= 1:5.6
58 BuildRequires:  perl-tools-pod
59 BuildRequires:  rpm-pythonprov
60 %{?with_doc:BuildRequires:      sphinx-pdg}
61 BuildRequires:  tar >= 1:1.22
62 BuildRequires:  xz
63 %if %{with apidocs}
64 BuildRequires:  doxygen
65 BuildRequires:  graphviz
66 %endif
67 %if %{with tests}
68 BuildRequires:  dejagnu
69 BuildRequires:  python
70 BuildRequires:  tcl-devel
71 %endif
72 %if %{with lldb}
73 BuildRequires:  libedit-devel
74 BuildRequires:  libxml2-devel >= 2
75 BuildRequires:  ncurses-ext-devel
76 BuildRequires:  python-devel >= 2
77 %endif
78 %if %{with polly}
79 BuildRequires:  cloog-isl-devel
80 # >= 0.18.2-2
81 BuildRequires:  gmp-devel
82 BuildRequires:  isl-devel >= 0.13
83 # optional
84 BuildRequires:  pluto-devel
85 BuildRequires:  scoplib-devel >= 0.2.1-2
86 #cuda-devel
87 %endif
88 Requires:       %{name}-libs = %{version}-%{release}
89 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
90
91 %define         _sysconfdir     /etc/%{name}
92
93 # strip corrupts: $RPM_BUILD_ROOT/usr/lib64/llvm-gcc/bin/llvm-c++ ...
94 %define         _noautostrip    .*/\\(libmud.*\\.a\\|bin/llvm-.*\\|lib.*++\\.a\\)
95
96 %description
97 LLVM is a compiler infrastructure designed for compile-time,
98 link-time, runtime, and idle-time optimization of programs from
99 arbitrary programming languages. LLVM is written in C++ and has been
100 developed since 2000 at the University of Illinois and Apple. It
101 currently supports compilation of C and C++ programs using clang
102 frontend.
103
104 %description -l pl.UTF-8
105 LLVM to infrastruktura kompilatora zaprojektowana do optymalizacji
106 czasu kompilowania, linkowania, działania i bezczynności programów w
107 dowolnych językach programowania. Jest napisana w C++, rozwijana od
108 roku 2000 przez Uniwersytet w Illinois i Apple. Aktualnie obsługuje
109 kompilację programów w C i C++ przy użyciu frontendu clang.
110
111 %package libs
112 Summary:        LLVM shared library
113 Summary(pl.UTF-8):      Biblioteka współdzielona LLVM-a
114 Group:          Libraries
115 Conflicts:      llvm < 3.2
116
117 %description libs
118 LLVM shared library.
119
120 %description libs -l pl.UTF-8
121 Biblioteka współdzielona LLVM-a.
122
123 %package devel
124 Summary:        Static libraries and header files for LLVM
125 Summary(pl.UTF-8):      Biblioteki statyczne i pliki nagłówkowe dla LLVM-a
126 Group:          Development/Languages
127 Requires:       %{name}-libs = %{version}-%{release}
128 Requires:       libstdc++-devel >= 6:3.4
129
130 %description devel
131 This package contains static libraries and header files needed to
132 develop new native programs that use the LLVM infrastructure.
133
134 %description devel -l pl.UTF-8
135 Ten pakiet zawiera biblioteki statyczne oraz pliki nagłówkowe
136 potrzebne do tworzenia nowych programów natywnych wykorzystujących
137 infrastrukturę LLVM.
138
139 %package doc
140 Summary:        Documentation for LLVM
141 Summary(pl.UTF-8):      Dokumentacja do LLVM-a
142 Group:          Documentation
143 # does not require base
144
145 %description doc
146 Documentation for the LLVM compiler infrastructure.
147
148 %description doc -l pl.UTF-8
149 Dokumentacja do infrastruktury kompilatorów LLVM.
150
151 %package apidocs
152 Summary:        API documentation for LLVM
153 Summary(pl.UTF-8):      Dokumentacja API LLVM-a
154 Group:          Development/Languages
155 Requires:       %{name}-doc = %{version}-%{release}
156
157 %description apidocs
158 API documentation for the LLVM compiler infrastructure.
159
160 %description apidocs -l pl.UTF-8
161 Dokumentacja API infrastruktury kompilatorów LLVM.
162
163 %package polly
164 Summary:        Polyhedral optimizations for LLVM
165 Summary(pl.UTF-8):      Optymalizacje wielościanowe dla LLVM-a
166 Group:          Development/Tools
167 URL:            http://polly.llvm.org/
168 Requires:       %{name} = %{version}-%{release}
169
170 %description polly
171 Polly is a high-level loop and data-locality optimizer and
172 optimization infrastructure for LLVM. It uses an abstract mathematical
173 representation based on integer polyhedra to analyze and optimize the
174 memory access pattern of a program.
175
176 %description polly -l pl.UTF-8
177 Polly to wysokopoziomowy optymalizator i infrastruktura LLVM-a do
178 optymalizacji pętli i położenia danych. Wykorzystuje abstrakcyjną
179 reprezentację matematyczną opartą na wielościanach całkowitoliczbowych
180 do analizy i optymalizacji wzorców dostępu do pamięci przez program.
181
182 %package polly-devel
183 Summary:        Header files for LLVM Polly optimization infrastructure
184 Summary(pl.UTF-8):      Pliki nagłówkowe infrastruktury optymalizacji LLVM-a Polly
185 Group:          Development/Libraries
186 URL:            http://polly.llvm.org/
187 Requires:       %{name}-devel = %{version}-%{release}
188 Requires:       %{name}-polly = %{version}-%{release}
189
190 %description polly-devel
191 Header files for LLVM Polly optimization infrastructure.
192
193 %description polly-devel -l pl.UTF-8
194 Pliki nagłówkowe infrastruktury optymalizacji LLVM-a Polly.
195
196 %package -n clang
197 Summary:        A C language family frontend for LLVM
198 Summary(pl.UTF-8):      Frontend LLVM-a do języków z rodziny C
199 License:        NCSA
200 Group:          Development/Languages
201 Requires:       %{name} = %{version}-%{release}
202
203 %description -n clang
204 clang: noun 1. A loud, resonant, metallic sound. 2. The strident call
205 of a crane or goose. 3. C-language family front-end toolkit.
206
207 The goal of the Clang project is to create a new C, C++, Objective C
208 and Objective C++ front-end for the LLVM compiler. Its tools are built
209 as libraries and designed to be loosely-coupled and extendable.
210
211 %description -n clang -l pl.UTF-8
212 clang (z angielskiego): 1. głośny, rezonujący, metaliczny dźwięk; 2.
213 piskliwy odgłos żurawia lub gęsi; 3. narzędzia frontendowe dla języków
214 z rodziny C.
215
216 Celem projektu Clang jest utworzenie nowego frontendu dla kompilatora
217 LLVM do języków C, C++, Objective C i Objective C++. Narzędzia są
218 budowane jako biblioteki i zaprojektowane z myślą o swobodnym łączeniu
219 i rozszerzaniu.
220
221 %package -n clang-analyzer
222 Summary:        A source code analysis framework
223 Summary(pl.UTF-8):      Szkielet do analizy kodu źródłowego
224 License:        NCSA
225 Group:          Development/Languages
226 Requires:       clang = %{version}-%{release}
227 # not picked up automatically since files are currently not instaled
228 # in standard Python hierarchies yet
229 Requires:       python
230
231 %description -n clang-analyzer
232 The Clang Static Analyzer consists of both a source code analysis
233 framework and a standalone tool that finds bugs in C and Objective-C
234 programs. The standalone tool is invoked from the command-line, and is
235 intended to run in tandem with a build of a project or code base.
236
237 %description -n clang-analyzer -l pl.UTF-8
238 Clang Static Analyzer składa się ze szkieletu do analizy kodu
239 źródłowego oraz samodzielnego narzędzia znajdującego błędy w
240 programach w C i C++. Narzędzie jest wywoływane z linii poleceń, z
241 myślą o uruchamianiu wraz z kompilacją projektu lub kodu.
242
243 %package -n clang-devel
244 Summary:        Header files for Clang
245 Summary(pl.UTF-8):      Pliki nagłówkowe Clanga
246 Group:          Development/Languages
247 Requires:       %{name}-devel = %{version}-%{release}
248 Requires:       clang = %{version}-%{release}
249
250 %description -n clang-devel
251 This package contains header files for the Clang compiler.
252
253 %description -n clang-devel -l pl.UTF-8
254 Ten pakiet zawiera pliki nagłówkowe kompilatora Clang.
255
256 %package -n clang-doc
257 Summary:        Documentation for Clang
258 Summary(pl.UTF-8):      Dokumentacja do Clanga
259 Group:          Documentation
260 Requires:       %{name} = %{version}-%{release}
261
262 %description -n clang-doc
263 Documentation for the Clang compiler front-end.
264
265 %description -n clang-doc -l pl.UTF-8
266 Dokumentacja do frontendu kompilatora Clang.
267
268 %package -n clang-apidocs
269 Summary:        API documentation for Clang
270 Summary(pl.UTF-8):      Dokumentacja API Clanga
271 Group:          Development/Languages
272 Requires:       clang-doc = %{version}-%{release}
273
274 %description -n clang-apidocs
275 API documentation for the Clang compiler.
276
277 %description -n clang-apidocs -l pl.UTF-8
278 Dokumentacja API kompilatora Clang.
279
280 %package -n clang-tools-extra
281 Summary:        Extra tools for Clang
282 Summary(pl.UTF-8):      Dodatkowe narzędzia do kompilatora Clang
283 Group:          Development/Tools
284 URL:            http://clang.llvm.org/docs/ClangTools.html
285 Requires:       clang = %{version}-%{release}
286
287 %description -n clang-tools-extra
288 Extra tools for Clang.
289
290 %description -n clang-tools-extra -l pl.UTF-8
291 Dodatkowe narzędzia do kompilatora Clang.
292
293 %package -n lld
294 Summary:        The LLVM linker
295 Summary(pl.UTF-8):      Konsolidator z projektu LLVM
296 Group:          Development/Libraries
297 URL:            http://lld.llvm.org/
298 Requires:       %{name} = %{version}-%{release}
299
300 %description -n lld
301 lld is a new set of modular code for creating linker tools.
302
303 %description -n lld -l pl.UTF-8
304 lld to nowy zbiór modularnego kodu do tworzenia narzędzi
305 konsolidujących.
306
307 %package -n lld-devel
308 Summary:        Development files for LLD linker tools
309 Summary(pl.UTF-8):      Pliki programistyczne narzędzi konsolidujących LLD
310 Group:          Development/Tools
311 URL:            http://lld.llvm.org/
312 Requires:       %{name}-devel = %{version}-%{release}
313
314 %description -n lld-devel
315 Development files for LLD linker tools.
316
317 %description -n lld-devel -l pl.UTF-8
318 Pliki programistyczne narzędzi konsolidujących LLD.
319
320 %package -n lldb
321 Summary:        Next generation high-performance debugger
322 Summary(pl.UTF-8):      Wydajny debugger nowej generacji
323 Group:          Development/Debuggers
324 URL:            http://lldb.llvm.org/
325 Requires:       %{name} = %{version}-%{release}
326
327 %description -n lldb
328 LLDB is a next generation, high-performance debugger. It is built as a
329 set of reusable components which highly leverage existing libraries in
330 the larger LLVM Project, such as the Clang expression parser and LLVM
331 disassembler.
332
333 %description -n lldb -l pl.UTF-8
334 LLDB to wydajny debugger nowej generacji. Jest zbudowany w oparciu o
335 komponenty wielokrotnego użytku, wykorzystujące istniejące biblioteki
336 w projekcie LLVM, takie jak analizator wyrażeń kompilatora Clang oraz
337 disasembler LLVM.
338
339 %package -n lldb-devel
340 Summary:        Development files for LLDB debugger
341 Summary(pl.UTF-8):      Pliki programistyczne debuggera LLDB
342 Group:          Development/Libraries
343 URL:            http://lldb.llvm.org/
344 Requires:       %{name}-devel = %{version}-%{release}
345 Requires:       clang-devel = %{version}-%{release}
346 Requires:       lldb = %{version}-%{release}
347
348 %description -n lldb-devel
349 Development files for LLDB debugger.
350
351 %description -n lldb-devel -l pl.UTF-8
352 Pliki programistyczne debuggera LLDB.
353
354 %package ocaml
355 Summary:        OCaml binding for LLVM
356 Summary(pl.UTF-8):      Wiązanie OCamla do LLVM-a
357 Group:          Libraries
358 Requires:       %{name} = %{version}-%{release}
359 %requires_eq    ocaml-runtime
360
361 %description ocaml
362 OCaml binding for LLVM.
363
364 %description ocaml -l pl.UTF-8
365 Wiązanie OCamla do LLVM-a.
366
367 %package ocaml-devel
368 Summary:        Development files for LLVM OCaml binding
369 Summary(pl.UTF-8):      Pliki programistyczne wiązania OCamla do LLVM-a
370 Group:          Development/Libraries
371 Requires:       %{name}-devel = %{version}-%{release}
372 Requires:       %{name}-ocaml = %{version}-%{release}
373
374 %description ocaml-devel
375 The llvm-ocaml-devel package contains libraries and signature files
376 for developing applications that use llvm-ocaml binding.
377
378 %description ocaml-devel -l pl.UTF-8
379 Ten pakiet zawiera biblioteki i pliki sygnatur do tworzenia aplikacji
380 wykorzystujących wiązanie llvm-ocaml.
381
382 %package ocaml-doc
383 Summary:        Documentation for LLVM's OCaml binding
384 Summary(pl.UTF-8):      Dokumentacja wiązania OCamla do LLVM-a
385 Group:          Documentation
386 Requires:       %{name}-ocaml = %{version}-%{release}
387
388 %description ocaml-doc
389 HTML documentation for LLVM's OCaml binding.
390
391 %description ocaml-doc -l pl.UTF-8
392 Dokumentacja HTML wiązania OCamla do LLVM-a.
393
394 %prep
395 %setup -q -n %{name}-%{version}.src -a1 %{?with_rt:-a2} %{?with_lldb:-a3} %{?with_polly:-a4} -a5 -a6
396 mv cfe-%{version}.src tools/clang
397 %{?with_rt:mv compiler-rt-%{version}.src projects/compiler-rt}
398 %{?with_lldb:mv lldb-%{version}.src tools/lldb}
399 %{?with_polly:mv polly-%{version}.src tools/polly}
400 mv clang-tools-extra-%{version}.src tools/clang/tools/extra
401 mv lld-%{version}.src tools/lld
402
403 %patch0 -p1
404 %patch1 -p1
405 %patch2 -p1
406 %{?with_polly:%patch3 -p1}
407 %if %{with lldb}
408 %patch4 -p1
409 %endif
410 %patch6 -p1
411
412 # configure does not properly specify libdir
413 %{__sed} -i 's|(PROJ_prefix)/lib|(PROJ_prefix)/%{_lib}|g' Makefile.config.in
414 # clang resources
415 %{__sed} -i 's|(PROJ_prefix)/lib/|(PROJ_prefix)/%{_lib}/|g' tools/clang/lib/Headers/Makefile
416 %{__sed} -i 's|"lib"|"%{_lib}"|' tools/clang/lib/Driver/Driver.cpp
417
418 grep -rl /usr/bin/env tools utils | xargs sed -i -e '1{
419         s,^#!.*bin/env python,#!%{__python},
420         s,^#!.*bin/env perl,#!%{__perl},
421 }'
422
423 %build
424 install -d obj
425 %if "%{_lib}" != "lib"
426 # workaround for clang relative search paths building
427 install -d obj/Release
428 ln -snf lib obj/Release/%{_lib}
429 %endif
430
431 cd autoconf
432 %{__aclocal} -I m4
433 %{__autoconf} -o ../configure configure.ac
434 cd ..
435 %{__autoheader} -I autoconf -I autoconf/m4 autoconf/configure.ac
436 %if %{with polly}
437 cd tools/polly/autoconf
438 %{__aclocal} -I m4 -I ../../../autoconf/m4
439 %{__autoconf} -o ../configure configure.ac
440 cd ..
441 %{__autoheader} -I autoconf -I autoconf/m4 -I ../../../autoconf/m4 autoconf/configure.ac
442 cd ../..
443 %endif
444
445 # Disabling assertions now, rec. by pure and needed for OpenGTL
446 # TESTFIX no PIC on ix86: http://llvm.org/bugs/show_bug.cgi?id=3801
447 #
448 # bash specific 'test a < b'
449 cd obj
450 CPPFLAGS="%{rpmcppflags} -D_FILE_OFFSET_BITS=64"
451 bash ../%configure \
452         --datadir=%{_datadir}/%{name}-%{version} \
453         --disable-assertions \
454         --enable-cxx11 \
455 %ifarch %{ix86}
456         --disable-pic \
457 %endif
458         --disable-static \
459         --enable-bindings=%{?with_ocaml:ocaml}%{!?with_ocaml:none} \
460         --enable-debug-runtime \
461 %if %{with apidocs}
462         --enable-doxygen \
463 %endif
464         --enable-experimental-targets=R600 \
465         --enable-jit \
466         --enable-optimized \
467         --enable-shared \
468         --with-pic
469
470 %{__make} \
471         VERBOSE=1 \
472         REQUIRES_RTTI=1 \
473         OPTIMIZE_OPTION="%{rpmcflags} %{rpmcppflags}"
474
475 %if %{with tests}
476 %{__make} check 2>&1 | tee llvm-testlog.txt
477 %{__make} -C tools/clang test 2>&1 | tee clang-testlog.txt
478 %endif
479
480 cd ..
481
482 %if %{with doc}
483 %{__make} -C docs -f Makefile.sphinx man
484 %{__make} -C tools/clang/tools/extra/docs html
485 %endif
486
487 %install
488 rm -rf $RPM_BUILD_ROOT
489 %{__make} -C obj -j1 install \
490         PROJ_docsdir=/moredocs \
491         DESTDIR=$RPM_BUILD_ROOT
492
493 # Static analyzer not installed by default:
494 # http://clang-analyzer.llvm.org/installation#OtherPlatforms
495 install -d $RPM_BUILD_ROOT%{_libdir}/clang-analyzer
496 # create launchers
497 for f in scan-{build,view}; do
498         ln -s %{_libdir}/clang-analyzer/$f/$f $RPM_BUILD_ROOT%{_bindir}/$f
499         cp -pr tools/clang/tools/$f $RPM_BUILD_ROOT%{_libdir}/clang-analyzer
500 done
501 %{__mv} $RPM_BUILD_ROOT%{_libdir}/clang-analyzer/scan-build/scan-build.1 $RPM_BUILD_ROOT%{_mandir}/man1
502 %py_comp $RPM_BUILD_ROOT%{_libdir}/clang-analyzer/scan-view
503 %py_ocomp $RPM_BUILD_ROOT%{_libdir}/clang-analyzer/scan-view
504 %py_postclean %{_libdir}/clang-analyzer/scan-view
505
506 %if %{with doc}
507 install -d $RPM_BUILD_ROOT%{_mandir}/man1
508 cp -p docs/_build/man/*.1 $RPM_BUILD_ROOT%{_mandir}/man1
509 # these tools are not installed
510 %{__rm} $RPM_BUILD_ROOT%{_mandir}/man1/{FileCheck,llvm-build}.1
511 # make links
512 echo '.so llvm-ar.1' > $RPM_BUILD_ROOT%{_mandir}/man1/llvm-ranlib.1
513 %endif
514
515 # Move documentation back to build directory
516 rm -rf moredocs
517 mv $RPM_BUILD_ROOT/moredocs .
518 %{__rm} -v moredocs/*.tar.gz
519 %{__rm} -v moredocs/ocamldoc/html/*.tar.gz
520
521 # and separate the apidoc
522 %if %{with apidocs}
523 rm -rf apidoc clang-apidoc
524 mv moredocs/html/doxygen apidoc
525 cp -a tools/clang/docs/doxygen/html clang-apidoc
526 %endif
527
528 # And prepare Clang documentation
529 rm -rf clang-docs
530 install -d clang-docs
531 for f in LICENSE.TXT NOTES.txt README.txt; do
532         ln tools/clang/$f clang-docs
533 done
534
535 # Get rid of erroneously installed example files.
536 %{__rm} -v $RPM_BUILD_ROOT%{_libdir}/*LLVMHello.*
537 # parts of test suite
538 %{__rm} $RPM_BUILD_ROOT%{_bindir}/{FileCheck,count,not}
539 %{__rm} $RPM_BUILD_ROOT%{_bindir}/linker-script-test
540
541 # remove documentation makefiles:
542 # they require the build directory to work
543 rm -rf moredocs/examples
544 cp -a examples moredocs/examples
545 find moredocs/examples -name Makefile | xargs -0r rm -f
546
547 %clean
548 rm -rf $RPM_BUILD_ROOT
549
550 %post   libs -p /sbin/ldconfig
551 %postun libs -p /sbin/ldconfig
552
553 %post   -n clang -p /sbin/ldconfig
554 %postun -n clang -p /sbin/ldconfig
555
556 %post   -n lldb -p /sbin/ldconfig
557 %postun -n lldb -p /sbin/ldconfig
558
559 %files
560 %defattr(644,root,root,755)
561 %doc CREDITS.TXT LICENSE.TXT README.txt %{?with_tests:llvm-testlog.txt}
562 %attr(755,root,root) %{_bindir}/bugpoint
563 %attr(755,root,root) %{_bindir}/llc
564 %attr(755,root,root) %{_bindir}/lli
565 %attr(755,root,root) %{_bindir}/lli-child-target
566 %attr(755,root,root) %{_bindir}/llvm-ar
567 %attr(755,root,root) %{_bindir}/llvm-as
568 %attr(755,root,root) %{_bindir}/llvm-bcanalyzer
569 %attr(755,root,root) %{_bindir}/llvm-cov
570 %attr(755,root,root) %{_bindir}/llvm-diff
571 %attr(755,root,root) %{_bindir}/llvm-dis
572 %attr(755,root,root) %{_bindir}/llvm-dwarfdump
573 %attr(755,root,root) %{_bindir}/llvm-extract
574 %attr(755,root,root) %{_bindir}/llvm-link
575 %attr(755,root,root) %{_bindir}/llvm-mc
576 %attr(755,root,root) %{_bindir}/llvm-mcmarkup
577 %attr(755,root,root) %{_bindir}/llvm-nm
578 %attr(755,root,root) %{_bindir}/llvm-objdump
579 %attr(755,root,root) %{_bindir}/llvm-profdata
580 %attr(755,root,root) %{_bindir}/llvm-ranlib
581 %attr(755,root,root) %{_bindir}/llvm-readobj
582 %attr(755,root,root) %{_bindir}/llvm-rtdyld
583 %attr(755,root,root) %{_bindir}/llvm-size
584 %attr(755,root,root) %{_bindir}/llvm-stress
585 %attr(755,root,root) %{_bindir}/llvm-symbolizer
586 %attr(755,root,root) %{_bindir}/llvm-tblgen
587 %attr(755,root,root) %{_bindir}/macho-dump
588 %attr(755,root,root) %{_bindir}/opt
589 %if %{with doc}
590 %{_mandir}/man1/bugpoint.1*
591 %{_mandir}/man1/lit.1*
592 %{_mandir}/man1/llc.1*
593 %{_mandir}/man1/lli.1*
594 %{_mandir}/man1/llvm-ar.1*
595 %{_mandir}/man1/llvm-as.1*
596 %{_mandir}/man1/llvm-bcanalyzer.1*
597 %{_mandir}/man1/llvm-cov.1*
598 %{_mandir}/man1/llvm-diff.1*
599 %{_mandir}/man1/llvm-dis.1*
600 %{_mandir}/man1/llvm-dwarfdump.1*
601 %{_mandir}/man1/llvm-extract.1*
602 %{_mandir}/man1/llvm-link.1*
603 %{_mandir}/man1/llvm-nm.1*
604 %{_mandir}/man1/llvm-profdata.1*
605 %{_mandir}/man1/llvm-ranlib.1*
606 %{_mandir}/man1/llvm-readobj.1*
607 %{_mandir}/man1/llvm-stress.1*
608 %{_mandir}/man1/llvm-symbolizer.1*
609 %{_mandir}/man1/opt.1*
610 %{_mandir}/man1/tblgen.1*
611 %endif
612
613 %files libs
614 %defattr(644,root,root,755)
615 %attr(755,root,root) %{_libdir}/libLLVM-%{version}.so
616 %attr(755,root,root) %{_libdir}/libLLVM-3.5.so
617
618 %files devel
619 %defattr(644,root,root,755)
620 %attr(755,root,root) %{_bindir}/llvm-config
621 %{_libdir}/libLLVM*.a
622 %ifarch %{x8664}
623 %attr(755,root,root) %{_libdir}/BugpointPasses.so
624 %attr(755,root,root) %{_libdir}/libLTO.so
625 %{_libdir}/libLTO.a
626 %endif
627 %{_includedir}/llvm
628 %{_includedir}/llvm-c
629 %dir %{_datadir}/llvm
630 %{_datadir}/llvm/cmake
631 %if %{with doc}
632 %{_mandir}/man1/llvm-config.1*
633 %endif
634
635 %files doc
636 %defattr(644,root,root,755)
637 %doc moredocs/examples moredocs/html
638
639 %if %{with apidocs}
640 %files apidocs
641 %defattr(644,root,root,755)
642 %doc apidoc/*
643 %endif
644
645 %if %{with polly}
646 %files polly
647 %defattr(644,root,root,755)
648 %doc tools/polly/{CREDITS.txt,LICENSE.txt,README}
649 %attr(755,root,root) %{_libdir}/LLVMPolly.so
650
651 %files polly-devel
652 %defattr(644,root,root,755)
653 %{_includedir}/polly
654 %endif
655
656 %files -n clang
657 %defattr(644,root,root,755)
658 %doc clang-docs/{LICENSE.TXT,NOTES.txt,README.txt} %{?with_tests:clang-testlog.txt}
659 %attr(755,root,root) %{_bindir}/c-index-test
660 %attr(755,root,root) %{_bindir}/clang
661 %attr(755,root,root) %{_bindir}/clang++
662 %attr(755,root,root) %{_bindir}/clang-check
663 %attr(755,root,root) %{_bindir}/clang-format
664 %attr(755,root,root) %{_bindir}/clang-tblgen
665 %attr(755,root,root) %{_libdir}/libclang.so
666 %dir %{_libdir}/clang
667 %dir %{_libdir}/clang/%{version}
668 %{_libdir}/clang/%{version}/include
669 %if %{with rt}
670 %{_libdir}/clang/%{version}/lib
671 %endif
672 %{_mandir}/man1/clang.1*
673
674 %files -n clang-analyzer
675 %defattr(644,root,root,755)
676 %attr(755,root,root) %{_bindir}/scan-build
677 %attr(755,root,root) %{_bindir}/scan-view
678 %{_mandir}/man1/scan-build.1*
679 %dir %{_libdir}/clang-analyzer
680
681 %dir %{_libdir}/clang-analyzer/scan-build
682 %{_libdir}/clang-analyzer/scan-build/*.css
683 %{_libdir}/clang-analyzer/scan-build/*.js
684 %attr(755,root,root) %{_libdir}/clang-analyzer/scan-build/scan-build
685 %attr(755,root,root) %{_libdir}/clang-analyzer/scan-build/*-analyzer
686
687 %dir %{_libdir}/clang-analyzer/scan-view
688 %attr(755,root,root) %{_libdir}/clang-analyzer/scan-view/scan-view
689 %{_libdir}/clang-analyzer/scan-view/Resources
690 %{_libdir}/clang-analyzer/scan-view/*.py[co]
691
692 %files -n clang-devel
693 %defattr(644,root,root,755)
694 %{_libdir}/libclang*.a
695 %{_includedir}/clang
696 %{_includedir}/clang-c
697
698 %files -n clang-doc
699 %defattr(644,root,root,755)
700 %doc tools/clang/docs/*.{css,html,png,txt}
701
702 %if %{with apidocs}
703 %files -n clang-apidocs
704 %defattr(644,root,root,755)
705 %doc clang-apidoc/*
706 %endif
707
708 %files -n clang-tools-extra
709 %defattr(644,root,root,755)
710 %doc tools/clang/tools/extra/{CODE_OWNERS.TXT,README.txt,docs/_build/html/{*.html,*.js,_static}}
711 %attr(755,root,root) %{_bindir}/clang-apply-replacements
712 %attr(755,root,root) %{_bindir}/clang-modernize
713 %attr(755,root,root) %{_bindir}/clang-query
714 %attr(755,root,root) %{_bindir}/clang-tidy
715 %attr(755,root,root) %{_bindir}/pp-trace
716 %{_libdir}/libmodernizeCore.a
717
718 %files -n lld
719 %defattr(644,root,root,755)
720 %doc tools/lld/{LICENSE.TXT,README.md}
721 %attr(755,root,root) %{_bindir}/lld
722
723 %files -n lld-devel
724 %defattr(644,root,root,755)
725 %{_libdir}/liblldCore.a
726 %{_libdir}/liblldDriver.a
727 %{_libdir}/liblldELF.a
728 %{_libdir}/liblldMachO.a
729 %{_libdir}/liblldNative.a
730 %{_libdir}/liblldPECOFF.a
731 %{_libdir}/liblldPasses.a
732 %{_libdir}/liblldReaderWriter.a
733 %{_libdir}/liblldYAML.a
734 %{_libdir}/liblld*ELFTarget.a
735 %{_includedir}/lld
736
737 %if %{with lldb}
738 %files -n lldb
739 %defattr(644,root,root,755)
740 %attr(755,root,root) %{_bindir}/lldb
741 %attr(755,root,root) %{_bindir}/lldb-gdbserver
742 %attr(755,root,root) %{_bindir}/lldb-mi
743 %attr(755,root,root) %{_bindir}/lldb-platform
744 %attr(755,root,root) %{_libdir}/liblldb.so
745 %dir %{py_sitedir}/lldb
746 %attr(755,root,root) %{py_sitedir}/lldb/_lldb.so
747 %attr(755,root,root) %{py_sitedir}/readline.so
748
749 %files -n lldb-devel
750 %defattr(644,root,root,755)
751 %{_libdir}/liblldb*.a
752 %{_includedir}/lldb
753 %endif
754
755 %if %{with ocaml}
756 %files ocaml
757 %defattr(644,root,root,755)
758 %{_libdir}/ocaml/META.llvm*
759 %attr(755,root,root) %{_libdir}/ocaml/dllllvm*.so
760 %{_libdir}/ocaml/llvm*.cma
761 %{_libdir}/ocaml/llvm*.cmi
762
763 %files ocaml-devel
764 %defattr(644,root,root,755)
765 %{_libdir}/libllvm*.a
766 %{_libdir}/ocaml/libLLVM*.a
767 %{_libdir}/ocaml/libllvm*.a
768 %{_libdir}/ocaml/llvm*.a
769 %{_libdir}/ocaml/llvm*.cmx*
770 %{_libdir}/ocaml/llvm*.mli
771
772 %files ocaml-doc
773 %defattr(644,root,root,755)
774 %doc moredocs/ocamldoc/html/*
775 %endif