]> git.pld-linux.org Git - packages/ccache.git/blob - ccache.spec
- better pl
[packages/ccache.git] / ccache.spec
1 Summary:        Compiler cache
2 Summary(pl.UTF-8):      Pamięć podręczna dla kompilatora
3 Summary(pt_BR.UTF-8):   Cache para compiladores C/C++
4 Name:           ccache
5 Version:        3.1.10
6 Release:        1
7 License:        GPL v3
8 Group:          Development/Tools
9 Source0:        http://www.samba.org/ftp/ccache/%{name}-%{version}.tar.xz
10 # Source0-md5:  20cd43818f84e3208fb4859e9679060e
11 Patch0:         %{name}-nohash_size_mtime.patch
12 URL:            http://ccache.samba.org/
13 BuildRequires:  automake
14 BuildRequires:  tar >= 1:1.22
15 BuildRequires:  xz
16 BuildRequires:  zlib-devel >= 1.2.3
17 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
18
19 %define         _libdir         %{_prefix}/%{_lib}/%{name}
20
21 %description
22 ccache is a compiler cache. It acts as a caching pre-processor to
23 C/C++ compilers, using the -E compiler switch and a hash to detect
24 when a compilation can be satisfied from cache. This often results in
25 a 5 to 10 times speedup in common compilations.
26
27 %description -l pl.UTF-8
28 ccache to pamięć podręczna dla kompilatora - działa jako cachujący
29 preprocesor dla kompilatorów C/C++, wykorzystujący opcję kompilatora
30 -E oraz tablicę haszującą do wykrywania, czy do kompilacji wystarczy
31 zawartość pamięci podręcznej. Daje to zazwyczaj przyspieszenie
32 kompilacji 5 do 10 razy.
33
34 %description -l pt_BR.UTF-8
35 ccache é um cache para compiladores. Ele funciona mantendo um cache de
36 pré-processamento para compiladores C/C++ utilizando-se do parâmetro
37 - -E e de um hash para detectar quando uma compilação pode ser
38   reaproveitada de um cache armazenado em disco. O ganho de tempo em
39   compilações comuns pode chegar a uma escala de até 10 vezes em relação
40   ao tempo normal.
41
42 %package wrapper
43 Summary:        Symlinks for c++/cc/g++/gcc
44 Summary(pl.UTF-8):      Dowiązania symboliczne do c++/cc/g++/gcc
45 Group:          Development/Tools
46 Requires:       %{name} = %{version}-%{release}
47
48 %description wrapper
49 This package contains the softlinks to ccache for each compiler.
50
51 %description wrapper -l pl.UTF-8
52 Ten pakiet zawiera dowiązania symboliczne do ccache dla każdego
53 kompilatora.
54
55 %prep
56 %setup -q
57 %patch0 -p1
58
59 # Make sure system zlib is used
60 %{__rm} -r zlib
61
62 %build
63 cp -f /usr/share/automake/config.* .
64 CPPFLAGS="%{rpmcppflags} -D_FILE_OFFSET_BITS=64"
65 %configure
66
67 %{__make}
68
69 %install
70 rm -rf $RPM_BUILD_ROOT
71 install -d $RPM_BUILD_ROOT/etc/env.d
72
73 %{__make} install \
74         DESTDIR=$RPM_BUILD_ROOT
75
76 for X in CCACHE_DIR CCACHE_TEMPDIR CCACHE_LOGFILE CCACHE_PATH CCACHE_CC CCACHE_PREFIX \
77         CCACHE_DISABLE CCACHE_READONLY CCACHE_CPP2 CCACHE_NOSTATS CCACHE_NLEVELS \
78         CCACHE_HARDLINK CCACHE_RECACHE CCACHE_UMASK CCACHE_HASHDIR CCACHE_UNIFY \
79         CCACHE_EXTENSION CCACHE_NOHASH_SIZE_MTIME
80 do
81         echo "#${X}=\"\"" > $RPM_BUILD_ROOT/etc/env.d/${X}
82 done
83
84 install -d $RPM_BUILD_ROOT{%{_bindir},%{_libdir},/etc/profile.d}
85 for cc in cc c++ g++ gcc %{_target_cpu}-pld-linux-gcc %{_target_cpu}-pld-linux-g++; do
86         ln -s ../../bin/%{name} $RPM_BUILD_ROOT%{_libdir}/$cc
87 done
88 echo 'export PATH=%{_libdir}:$PATH' > \
89         $RPM_BUILD_ROOT/etc/profile.d/%{name}.sh
90
91 %clean
92 rm -rf $RPM_BUILD_ROOT
93
94 %files
95 %defattr(644,root,root,755)
96 %doc AUTHORS.txt MANUAL.txt NEWS.txt README.txt
97 %attr(755,root,root) %{_bindir}/ccache
98 %{_mandir}/man1/ccache.1.*
99 %config(noreplace,missingok) %verify(not md5 mtime size) /etc/env.d/CCACHE_*
100
101 %files wrapper
102 %defattr(644,root,root,755)
103 %attr(755,root,root) /etc/profile.d/%{name}.sh
104 %dir %{_libdir}
105 %attr(755,root,root) %{_libdir}/c++
106 %attr(755,root,root) %{_libdir}/cc
107 %attr(755,root,root) %{_libdir}/g++
108 %attr(755,root,root) %{_libdir}/gcc
109 %attr(755,root,root) %{_libdir}/%{_target_cpu}-pld-linux-g++
110 %attr(755,root,root) %{_libdir}/%{_target_cpu}-pld-linux-gcc
This page took 0.11487 seconds and 4 git commands to generate.