2010-03-01 22:38:44 +00:00
|
|
|
%define compilers gcc g++ cc c++ gcc296 g++296 gcc32 c++32 g++32 gcc34 c++34 g++34 gcc44 g++44 g++-libstdc++-so_7 avr-gcc avr-c++ avr-g++ arm-gp2x-linux-gcc arm-gp2x-linux-c++ arm-gp2x-linux-g++ msp430-gcc
|
|
|
|
%define pkgs gcc, gcc-c++, compat-gcc, compat-gcc-c++, compat-gcc-32, compat-gcc-32-c++, gcc34, gcc34-c++, compat-gcc-34, compat-gcc-34-c++, gcc44, gcc44-c++, libstdc++so7-devel, avr-gcc, avr-gcc-c++, arm-gp2x-linux-gcc, arm-gp2x-linux-gcc-c++, msp430-gcc
|
2004-11-08 04:07:43 +00:00
|
|
|
|
2007-08-19 17:05:06 +00:00
|
|
|
%define abs2rel() perl -MFile::Spec -e 'print File::Spec->abs2rel(@ARGV)' %1 %2
|
|
|
|
%{expand: %%define relccache %(%abs2rel %{_bindir}/ccache %{_libdir}/ccache)}
|
|
|
|
|
2006-08-29 19:56:32 +00:00
|
|
|
Name: ccache
|
2010-09-18 10:28:39 +00:00
|
|
|
Version: 3.1
|
2010-07-03 12:02:48 +00:00
|
|
|
Release: 1%{?dist}
|
2006-08-29 19:56:32 +00:00
|
|
|
Summary: C/C++ compiler cache
|
2004-11-08 04:07:43 +00:00
|
|
|
|
2006-08-29 19:56:32 +00:00
|
|
|
Group: Development/Tools
|
2010-05-13 18:57:13 +00:00
|
|
|
License: GPLv3+
|
2006-08-29 19:56:32 +00:00
|
|
|
URL: http://ccache.samba.org/
|
2010-07-03 12:02:48 +00:00
|
|
|
Source0: http://samba.org/ftp/ccache/%{name}-%{version}.tar.bz2
|
2007-07-29 22:38:31 +00:00
|
|
|
Source1: %{name}.sh.in
|
|
|
|
Source2: %{name}.csh.in
|
2006-08-29 19:56:32 +00:00
|
|
|
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
|
2004-11-08 04:07:43 +00:00
|
|
|
|
2007-08-19 17:05:06 +00:00
|
|
|
BuildRequires: perl(File::Spec)
|
2010-03-01 22:38:44 +00:00
|
|
|
BuildRequires: zlib-devel >= 1.2.3
|
2006-11-10 20:10:10 +00:00
|
|
|
Requires(triggerin): coreutils
|
|
|
|
Requires(triggerpostun): coreutils
|
|
|
|
|
2004-11-08 04:07:43 +00:00
|
|
|
%description
|
2010-03-01 22:38:44 +00:00
|
|
|
ccache is a compiler cache. It speeds up recompilation of C/C++ code
|
|
|
|
by caching previous compiles and detecting when the same compile is
|
|
|
|
being done again. The main focus is to handle the GNU C/C++ compiler
|
|
|
|
(GCC), but it may also work with compilers that mimic GCC good enough.
|
2004-11-08 04:07:43 +00:00
|
|
|
|
|
|
|
|
|
|
|
%prep
|
2010-07-03 12:02:48 +00:00
|
|
|
%setup -q
|
2007-07-29 22:38:31 +00:00
|
|
|
sed -e 's|@LIBDIR@|%{_libdir}|g' -e 's|@CACHEDIR@|%{_var}/cache/ccache|g' \
|
|
|
|
%{SOURCE1} > %{name}.sh
|
|
|
|
sed -e 's|@LIBDIR@|%{_libdir}|g' -e 's|@CACHEDIR@|%{_var}/cache/ccache|g' \
|
|
|
|
%{SOURCE2} > %{name}.csh
|
2010-03-01 22:38:44 +00:00
|
|
|
# Make sure system zlib is used
|
|
|
|
rm -r zlib
|
2004-11-08 04:07:43 +00:00
|
|
|
|
|
|
|
|
|
|
|
%build
|
|
|
|
%configure
|
2007-07-29 22:38:31 +00:00
|
|
|
make %{?_smp_mflags}
|
2004-11-08 04:07:43 +00:00
|
|
|
|
|
|
|
|
|
|
|
%install
|
2004-11-08 04:08:19 +00:00
|
|
|
rm -rf $RPM_BUILD_ROOT %{name}-%{version}.compilers
|
2010-07-03 12:06:34 +00:00
|
|
|
make install DESTDIR=$RPM_BUILD_ROOT
|
2004-11-08 04:07:43 +00:00
|
|
|
install -dm 755 $RPM_BUILD_ROOT%{_sysconfdir}/profile.d
|
2006-02-18 11:43:08 +00:00
|
|
|
install -pm 644 %{name}.sh %{name}.csh $RPM_BUILD_ROOT%{_sysconfdir}/profile.d
|
|
|
|
install -dm 755 $RPM_BUILD_ROOT%{_libdir}/ccache
|
2004-11-08 04:07:43 +00:00
|
|
|
for name in %{compilers} ; do
|
2004-11-08 04:08:19 +00:00
|
|
|
for c in $name %{_target_cpu}-%{_vendor}-%{_target_os}-$name ; do
|
2007-08-19 17:05:06 +00:00
|
|
|
ln -s %{relccache} $RPM_BUILD_ROOT%{_libdir}/ccache/$c
|
2006-02-18 11:43:08 +00:00
|
|
|
echo "%ghost %{_libdir}/ccache/$c" >> %{name}-%{version}.compilers
|
2004-11-08 04:07:43 +00:00
|
|
|
done
|
|
|
|
done
|
2007-07-29 22:38:31 +00:00
|
|
|
install -dm 770 $RPM_BUILD_ROOT%{_var}/cache/ccache
|
2004-11-08 04:07:43 +00:00
|
|
|
|
|
|
|
|
2010-03-01 22:38:44 +00:00
|
|
|
%check
|
|
|
|
make check
|
|
|
|
|
|
|
|
|
2004-11-08 04:07:43 +00:00
|
|
|
%clean
|
|
|
|
rm -fr $RPM_BUILD_ROOT
|
|
|
|
|
|
|
|
|
2007-07-29 22:38:31 +00:00
|
|
|
%pre
|
|
|
|
getent group ccache >/dev/null || groupadd -r ccache || :
|
|
|
|
|
2004-11-08 04:07:43 +00:00
|
|
|
%triggerin -- %{pkgs}
|
|
|
|
for name in %{compilers} ; do
|
2004-11-08 04:08:19 +00:00
|
|
|
for c in $name %{_target_cpu}-%{_vendor}-%{_target_os}-$name ; do
|
2007-08-19 17:05:06 +00:00
|
|
|
[ ! -x %{_bindir}/$c ] || ln -sf %{relccache} %{_libdir}/ccache/$c
|
2004-11-08 04:07:43 +00:00
|
|
|
done
|
|
|
|
done
|
2007-07-29 22:38:31 +00:00
|
|
|
:
|
2004-11-08 04:07:43 +00:00
|
|
|
|
|
|
|
%triggerpostun -- %{pkgs}
|
|
|
|
for name in %{compilers} ; do
|
2004-11-08 04:08:19 +00:00
|
|
|
for c in $name %{_target_cpu}-%{_vendor}-%{_target_os}-$name ; do
|
2006-02-18 11:43:08 +00:00
|
|
|
[ -x %{_bindir}/$c ] || rm -f %{_libdir}/ccache/$c
|
2004-11-08 04:07:43 +00:00
|
|
|
done
|
|
|
|
done
|
2007-07-29 22:38:31 +00:00
|
|
|
:
|
2004-11-08 04:07:43 +00:00
|
|
|
|
|
|
|
|
|
|
|
%files -f %{name}-%{version}.compilers
|
|
|
|
%defattr(-,root,root,-)
|
2010-09-18 10:28:39 +00:00
|
|
|
%doc AUTHORS.* GPL-3.0.txt LICENSE.* MANUAL.* NEWS.* README.*
|
2007-08-19 17:05:06 +00:00
|
|
|
%config(noreplace) %{_sysconfdir}/profile.d/%{name}.*sh
|
2004-11-08 04:08:19 +00:00
|
|
|
%{_bindir}/ccache
|
2006-08-29 19:56:32 +00:00
|
|
|
%dir %{_libdir}/ccache/
|
2007-07-29 22:38:31 +00:00
|
|
|
%attr(2770,root,ccache) %dir %{_var}/cache/ccache/
|
2004-11-08 04:07:43 +00:00
|
|
|
%{_mandir}/man1/ccache.1*
|
|
|
|
|
|
|
|
|
|
|
|
%changelog
|
2010-09-18 10:28:39 +00:00
|
|
|
* Sat Sep 18 2010 Ville Skyttä <ville.skytta@iki.fi> - 3.1-1
|
|
|
|
- Update to 3.1, fixes #610853.
|
|
|
|
- Make sh profile script "nounset" clean.
|
|
|
|
|
2010-07-16 16:28:34 +00:00
|
|
|
* Fri Jul 16 2010 Ville Skyttä <ville.skytta@iki.fi> - 3.0.1-1
|
|
|
|
- Update to 3.0.1.
|
|
|
|
|
2010-07-03 12:02:48 +00:00
|
|
|
* Sat Jul 3 2010 Ville Skyttä <ville.skytta@iki.fi> - 3.0-1
|
|
|
|
- Update to 3.0, no-strip patch no longer needed.
|
|
|
|
|
2010-06-04 19:57:27 +00:00
|
|
|
* Fri Jun 4 2010 Ville Skyttä <ville.skytta@iki.fi> - 3.0-0.2.pre1
|
|
|
|
- Reintroduce minor profile.d script performance improvements.
|
|
|
|
|
2010-05-13 18:57:13 +00:00
|
|
|
* Thu May 13 2010 Ville Skyttä <ville.skytta@iki.fi> - 3.0-0.1.pre1
|
|
|
|
- Update to 3.0pre1 (#591040), license changed to GPLv3+.
|
|
|
|
|
2010-03-01 22:38:44 +00:00
|
|
|
* Mon Mar 1 2010 Ville Skyttä <ville.skytta@iki.fi> - 3.0-0.1.pre0
|
|
|
|
- Update to 3.0pre0, all old patches applied/superseded upstream.
|
|
|
|
Note: old caches will no longer be used, see NEWS for details.
|
|
|
|
- Don't use "pathmunge" in the profile.d sh script to work around #548960.
|
|
|
|
- Patch to avoid stripping the binary during build.
|
|
|
|
- Add auto-symlink support for gcc44(-c++) and msp430-gcc.
|
|
|
|
- Run test suite during build.
|
|
|
|
- Update description.
|
|
|
|
|
2009-12-19 11:44:52 +00:00
|
|
|
* Sat Dec 19 2009 Ville Skyttä <ville.skytta@iki.fi> - 2.4-17
|
|
|
|
- Minor profile.d script performance improvements.
|
|
|
|
- Fix hardcoded /var/cache/ccache in profile.d scripts.
|
|
|
|
|
2009-08-10 17:43:51 +00:00
|
|
|
* Mon Aug 10 2009 Ville Skyttä <ville.skytta@iki.fi> - 2.4-16
|
|
|
|
- Switch #438201 patch URL to Debian patch tracking (original is MIA).
|
|
|
|
|
2009-07-24 18:41:35 +00:00
|
|
|
* Fri Jul 24 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 2.4-15
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild
|
|
|
|
|
2009-02-24 06:39:52 +00:00
|
|
|
* Mon Feb 23 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 2.4-14
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild
|
|
|
|
|
2009-08-10 17:43:51 +00:00
|
|
|
* Wed Mar 19 2008 Ville Skyttä <ville.skytta@iki.fi> - 2.4-13
|
2008-03-19 20:41:35 +00:00
|
|
|
- Apply patch to fix path to saved dependency files (#438201).
|
|
|
|
|
2009-08-10 17:43:51 +00:00
|
|
|
* Sat Feb 9 2008 Ville Skyttä <ville.skytta@iki.fi> - 2.4-12
|
2008-02-09 21:05:57 +00:00
|
|
|
- Rebuild.
|
|
|
|
|
2009-08-10 17:43:51 +00:00
|
|
|
* Tue Oct 2 2007 Ville Skyttä <ville.skytta@iki.fi> - 2.4-11
|
2007-10-02 16:50:35 +00:00
|
|
|
- Apply upstream fix for problems when $HOME is not set (#315441).
|
|
|
|
|
2009-08-10 17:43:51 +00:00
|
|
|
* Wed Aug 22 2007 Ville Skyttä <ville.skytta@iki.fi>
|
2007-08-22 05:30:17 +00:00
|
|
|
- Fix URL to upstream tarball.
|
|
|
|
|
2009-08-10 17:43:51 +00:00
|
|
|
* Sun Aug 19 2007 Ville Skyttä <ville.skytta@iki.fi> - 2.4-10
|
2007-08-16 09:09:14 +00:00
|
|
|
- License: GPLv2+
|
2007-08-19 17:05:06 +00:00
|
|
|
- Make compiler symlinks relative.
|
|
|
|
- Make profile.d scripts noreplace.
|
2007-08-16 09:09:14 +00:00
|
|
|
|
2009-08-10 17:43:51 +00:00
|
|
|
* Mon Jul 30 2007 Ville Skyttä <ville.skytta@iki.fi> - 2.4-9
|
2007-07-29 22:38:31 +00:00
|
|
|
- Use shared cache dir for users in the ccache group by default
|
|
|
|
(#247760, based on Andy Shevchenko's work).
|
|
|
|
- Fix outdated hardlink info in cache sharing docs.
|
|
|
|
- Add auto-symlink support for avr-gcc(-c++) and arm-gp2x-linux-gcc(-c++).
|
|
|
|
- Make triggers always exit with a zero exit status.
|
|
|
|
|
2009-08-10 17:43:51 +00:00
|
|
|
* Thu Mar 15 2007 Ville Skyttä <ville.skytta@iki.fi> - 2.4-8
|
2007-03-15 10:40:54 +00:00
|
|
|
- Bypass cache with --coverage, -fprofile-arcs and -ftest-coverage
|
|
|
|
(upstream CVS and Matt Fago, #231462).
|
|
|
|
|
2009-08-10 17:43:51 +00:00
|
|
|
* Fri Nov 10 2006 Ville Skyttä <ville.skytta@iki.fi> - 2.4-7
|
2006-11-10 20:10:10 +00:00
|
|
|
- Require coreutils for triggers (#215030).
|
|
|
|
|
2009-08-10 17:43:51 +00:00
|
|
|
* Wed Aug 9 2006 Ville Skyttä <ville.skytta@iki.fi> - 2.4-6
|
2006-08-29 19:56:32 +00:00
|
|
|
- Add auto-symlink support for compat-gcc-34(-c++).
|
|
|
|
- Untabify, escape macros in changelog.
|
|
|
|
|
2009-08-10 17:43:51 +00:00
|
|
|
* Tue May 16 2006 Ville Skyttä <ville.skytta@iki.fi> - 2.4-5
|
2006-05-16 19:09:50 +00:00
|
|
|
- Add auto-symlink support for g++-libstdc++-so_7.
|
|
|
|
|
2009-08-10 17:43:51 +00:00
|
|
|
* Sat Nov 26 2005 Ville Skyttä <ville.skytta@iki.fi> - 2.4-4
|
2006-02-18 11:43:08 +00:00
|
|
|
- Drop "bin" from compiler symlink path.
|
|
|
|
- Make profile.d snippets non-executable (#35714).
|
|
|
|
|
2009-08-10 17:43:51 +00:00
|
|
|
* Sun May 1 2005 Ville Skyttä <ville.skytta@iki.fi> - 2.4-3
|
2005-05-04 19:21:00 +00:00
|
|
|
- Auto-symlink update: add compat-gcc-32 and compat-gcc-32-c++, drop
|
|
|
|
bunch of no longer relevant compilers.
|
|
|
|
|
2005-05-04 19:53:51 +00:00
|
|
|
* Fri Apr 7 2005 Michael Schwendt <mschwendt[AT]users.sf.net> - 2.4-2
|
2005-04-06 22:11:33 +00:00
|
|
|
- rebuilt
|
|
|
|
|
2009-08-10 17:43:51 +00:00
|
|
|
* Sun Sep 26 2004 Ville Skyttä <ville.skytta@iki.fi> - 0:2.4-0.fdr.1
|
2004-11-08 04:08:19 +00:00
|
|
|
- Update to 2.4.
|
|
|
|
- Add symlinking support for gcc4 and gcc4-c++.
|
|
|
|
- Move the ccache executable to %%{_bindir}.
|
|
|
|
- Include more docs.
|
|
|
|
|
2009-08-10 17:43:51 +00:00
|
|
|
* Fri Jun 25 2004 Ville Skyttä <ville.skytta@iki.fi> - 0:2.3-0.fdr.5
|
2004-11-08 04:07:43 +00:00
|
|
|
- Add support for gcc33 and g++33.
|
|
|
|
|
2009-08-10 17:43:51 +00:00
|
|
|
* Thu Jun 10 2004 Ville Skyttä <ville.skytta@iki.fi> - 0:2.3-0.fdr.4
|
2004-11-08 04:07:43 +00:00
|
|
|
- Fix hardcoded lib path in profile.d scriptlets (bug 1558).
|
|
|
|
|
2009-08-10 17:43:51 +00:00
|
|
|
* Mon May 3 2004 Ville Skyttä <ville.skytta@iki.fi> - 0:2.3-0.fdr.3
|
2004-11-08 04:07:43 +00:00
|
|
|
- Add support for gcc34 and g++34, and
|
|
|
|
%%{_target_cpu}-%%{_vendor}-%%{_target_os}-* variants.
|
|
|
|
|
2009-08-10 17:43:51 +00:00
|
|
|
* Thu Nov 13 2003 Ville Skyttä <ville.skytta@iki.fi> - 0:2.3-0.fdr.2
|
2004-11-08 04:07:43 +00:00
|
|
|
- Add overriding symlinks for gcc-ssa and g++-ssa (bug 963).
|
|
|
|
|
2009-08-10 17:43:51 +00:00
|
|
|
* Tue Nov 11 2003 Ville Skyttä <ville.skytta@iki.fi> - 0:2.3-0.fdr.1
|
2004-11-08 04:07:43 +00:00
|
|
|
- Update to 2.3.
|
|
|
|
- Implement triggers to keep list of "aliased" compilers up to date on the fly.
|
|
|
|
- Add gcc32 and a bunch of legacy packages to the list of overridden compilers.
|
|
|
|
|
2009-08-10 17:43:51 +00:00
|
|
|
* Sat Aug 2 2003 Ville Skyttä <ville.skytta@iki.fi> - 0:2.2-0.fdr.6
|
2004-11-08 04:07:43 +00:00
|
|
|
- Add c++ to the list of overridden compilers (bug 548).
|
|
|
|
- Own everything including dirs under %%{_libdir}/ccache (bug 529).
|
|
|
|
- %%{buildroot} -> $RPM_BUILD_ROOT.
|
|
|
|
- Fix man page permissions.
|
|
|
|
- Use %%{?_smp_mflags}.
|
|
|
|
- Other cosmetic specfile tweaks.
|
|
|
|
|
|
|
|
* Fri Mar 29 2003 Warren Togami <warren@togami.com> 2.2-0.fdr.5
|
|
|
|
- Epoch: 0
|
|
|
|
- Remove /usr/lib/ccache/sbin from PATH
|
|
|
|
|
|
|
|
* Fri Mar 28 2003 Warren Togami <warren@togami.com> 2.2-0.fdr.4
|
|
|
|
- Add BuildRequires: autoconf >= 0:2.52
|
|
|
|
- Add Requires: gcc, gcc-c++ (minimal expectation of compilers)
|
|
|
|
|
|
|
|
* Fri Mar 28 2003 Warren Togami <warren@togami.com> 2.2-0.fdr.3
|
2006-08-29 19:56:32 +00:00
|
|
|
- No longer use %%ghost, symlinks always exist
|
2004-11-08 04:07:43 +00:00
|
|
|
|
|
|
|
* Thu Mar 27 2003 Warren Togami <warren@togami.com> 2.2-0.fdr.2
|
|
|
|
- Move symlinks to /usr/lib/ccache/bin
|
|
|
|
- Use /etc/profile.d/ccache.* scripts to add it to PATH
|
|
|
|
As long as it is before /usr/bin it is good.
|
|
|
|
|
|
|
|
* Thu Mar 27 2003 Warren Togami <warren@togami.com> 2.2-0.fdr.1
|
|
|
|
- Move symlinks to /bin since it seems to be at the beginning of PATH of all users
|
|
|
|
before /usr/bin, the location of the real compiler.
|
2006-08-29 19:56:32 +00:00
|
|
|
- Package symlinks rather than create and remove during %%post and %%postun
|
2004-11-08 04:07:43 +00:00
|
|
|
|
|
|
|
* Thu Feb 20 2003 Warren Togami <warren@togami.com> 2.2-4.fedora.1
|
|
|
|
- Fedora
|
|
|
|
|
|
|
|
* Thu Feb 20 2003 Samir M. Nassar <rpm@redconcepts.net> 2.2-3.redconcepts
|
|
|
|
- Added symlinks to g++
|
|
|
|
- Removed symlink removal in post
|
|
|
|
|
|
|
|
* Thu Feb 20 2003 Samir M. Nassar <rpm@redconcepts.net> 2.2-2.redconcepts
|
|
|
|
- Cleans symlinks if present to make upgrades easier
|
|
|
|
|
|
|
|
* Thu Feb 20 2003 Samir M. Nassar <rpm@redconcepts.net> 2.2-1.redconcepts
|
|
|
|
- Upgraded to ccache 2.2
|
|
|
|
|
|
|
|
* Tue Feb 04 2003 Samir M. Nassar <rpm@redconcepts.net> 2.1.1-4.redconcepts
|
2006-08-29 19:56:32 +00:00
|
|
|
- Using %%post to create the soft symlinks
|
|
|
|
- Using %%postun to remove the soft symlinks
|
2004-11-08 04:07:43 +00:00
|
|
|
- Thanks to Che <che666@uni.de> for the help
|
|
|
|
- Packaged as user
|
|
|
|
|
|
|
|
* Sun Jan 19 2003 Samir M. Nassar <rpm@redconcepts.net> 2.1.1-3.redconcepts
|
|
|
|
- make a soft symlink between ccache and gcc
|
|
|
|
- make a soft symlink between ccache and cc
|
|
|
|
|
|
|
|
* Thu Jan 16 2003 Samir M. Nassar <rpm@redconcepts.net> 2.1.1-2.redconcepts
|
|
|
|
- Normalized spec file.
|
|
|
|
|
|
|
|
* Wed Jan 15 2003 Samir M, Nassar <rpm@redconcepts.net> 2.1.1-1.redconcepts
|
|
|
|
- Using ccache 2.2.1 sources
|
|
|
|
- Changed release to redconcepts for consistency
|
|
|
|
|
|
|
|
* Wed Oct 22 2002 Samir M. Nassar <rpm.redconcepts.net> 1.9-1.rcn
|
|
|
|
- Initial RedConcepts.NET (rcn) build for Red Hat Linux 8.0
|