rpms/ccache/EL-5 ccache-2.4-hardlink-doc.patch, NONE, 1.1 ccache.csh.in, NONE, 1.1 ccache.sh.in, NONE, 1.1 ccache.spec, 1.15, 1.16
Ville Skytta (scop)
fedora-extras-commits at redhat.com
Sun Aug 19 18:09:48 UTC 2007
Author: scop
Update of /cvs/pkgs/rpms/ccache/EL-5
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv1769
Modified Files:
ccache.spec
Added Files:
ccache-2.4-hardlink-doc.patch ccache.csh.in ccache.sh.in
Log Message:
Sync with Rawhide.
ccache-2.4-hardlink-doc.patch:
--- NEW FILE ccache-2.4-hardlink-doc.patch ---
Index: ccache.1
===================================================================
RCS file: /cvsroot/ccache/ccache.1,v
retrieving revision 1.26
diff -u -r1.26 ccache.1
--- ccache.1 24 Nov 2005 21:10:08 -0000 1.26
+++ ccache.1 21 Jul 2007 21:03:32 -0000
@@ -330,7 +330,7 @@
.IP o
Use the same \fBCCACHE_DIR\fP environment variable setting
.IP o
-Set the \fBCCACHE_NOLINK\fP environment variable
+Unset the \fBCCACHE_HARDLINK\fP environment variable
.IP o
Make sure everyone sets the CCACHE_UMASK environment variable
to 002, this ensures that cached files are accessible to everyone in
Index: ccache.yo
===================================================================
RCS file: /cvsroot/ccache/ccache.yo,v
retrieving revision 1.27
diff -u -r1.27 ccache.yo
--- ccache.yo 24 Nov 2005 21:54:09 -0000 1.27
+++ ccache.yo 21 Jul 2007 21:03:32 -0000
@@ -289,7 +289,7 @@
itemize(
it() Use the same bf(CCACHE_DIR) environment variable setting
- it() Set the bf(CCACHE_NOLINK) environment variable
+ it() Unset the bf(CCACHE_HARDLINK) environment variable
it() Make sure everyone sets the CCACHE_UMASK environment variable
to 002, this ensures that cached files are accessible to everyone in
the group.
Index: web/ccache-man.html
===================================================================
RCS file: /cvsroot/ccache/web/ccache-man.html,v
retrieving revision 1.25
diff -u -r1.25 ccache-man.html
--- web/ccache-man.html 13 Sep 2004 10:38:17 -0000 1.25
+++ web/ccache-man.html 21 Jul 2007 21:03:32 -0000
@@ -256,7 +256,7 @@
following conditions need to be met:
<p><ul>
<li > Use the same <strong>CCACHE_DIR</strong> environment variable setting
- <li > Set the <strong>CCACHE_NOLINK</strong> environment variable
+ <li > Unset the <strong>CCACHE_HARDLINK</strong> environment variable
<li > Make sure everyone sets the CCACHE_UMASK environment variable
to 002, this ensures that cached files are accessible to everyone in
the group.
--- NEW FILE ccache.csh.in ---
# Use ccache by default. Users who don't want that can set the CCACHE_DISABLE
# environment variable in their personal profile.
if ( "$path" !~ *@LIBDIR@/ccache* ) then
set path = ( @LIBDIR@/ccache $path )
endif
# If @CACHEDIR@ is writable, use a shared cache there. Users who don't
# want that even if they have that write permission can set the CCACHE_DIR
# and unset the CCACHE_UMASK environment variables in their personal profile.
if ( ! $?CCACHE_DIR && -d @CACHEDIR@ && -w @CACHEDIR@ ) then
setenv CCACHE_DIR /var/cache/ccache
setenv CCACHE_UMASK 002
unsetenv CCACHE_HARDLINK
endif
--- NEW FILE ccache.sh.in ---
# Use ccache by default. Users who don't want that can set the CCACHE_DISABLE
# environment variable in their personal profile.
if ! echo "$PATH" | grep -qw @LIBDIR@/ccache ; then
PATH="@LIBDIR@/ccache:$PATH"
fi
# If @CACHEDIR@ is writable, use a shared cache there. Users who don't
# want that even if they have that write permission can set the CCACHE_DIR
# and unset the CCACHE_UMASK environment variables in their personal profile.
if [ -z "$CCACHE_DIR" -a -d @CACHEDIR@ -a -w @CACHEDIR@ ] ; then
export CCACHE_DIR=/var/cache/ccache
export CCACHE_UMASK=002
unset CCACHE_HARDLINK
fi
Index: ccache.spec
===================================================================
RCS file: /cvs/pkgs/rpms/ccache/EL-5/ccache.spec,v
retrieving revision 1.15
retrieving revision 1.16
diff -u -r1.15 -r1.16
--- ccache.spec 18 Mar 2007 12:20:13 -0000 1.15
+++ ccache.spec 19 Aug 2007 18:09:14 -0000 1.16
@@ -1,19 +1,26 @@
-%define compilers gcc g++ cc c++ gcc296 g++296 gcc32 c++32 g++32 gcc34 c++34 g++34 g++-libstdc++-so_7
-%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++, libstdc++so7-devel
+%define compilers gcc g++ cc c++ gcc296 g++296 gcc32 c++32 g++32 gcc34 c++34 g++34 g++-libstdc++-so_7 avr-gcc avr-c++ avr-g++ arm-gp2x-linux-gcc arm-gp2x-linux-c++ arm-gp2x-linux-g++
+%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++, libstdc++so7-devel, avr-gcc, avr-gcc-c++, arm-gp2x-linux-gcc, arm-gp2x-linux-gcc-c++
+
+%define abs2rel() perl -MFile::Spec -e 'print File::Spec->abs2rel(@ARGV)' %1 %2
+%{expand: %%define relccache %(%abs2rel %{_bindir}/ccache %{_libdir}/ccache)}
Name: ccache
Version: 2.4
-Release: 8%{?dist}
+Release: 10%{?dist}
Summary: C/C++ compiler cache
Group: Development/Tools
-License: GPL
+License: GPLv2+
URL: http://ccache.samba.org/
Source0: http://ccache.samba.org/ftp/ccache/%{name}-%{version}.tar.gz
+Source1: %{name}.sh.in
+Source2: %{name}.csh.in
Patch0: %{name}-html-links.patch
Patch1: %{name}-2.4-coverage-231462.patch
+Patch2: %{name}-2.4-hardlink-doc.patch
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
+BuildRequires: perl(File::Spec)
Requires(triggerin): coreutils
Requires(triggerpostun): coreutils
@@ -28,21 +35,16 @@
%setup -q
%patch0 -p0
%patch1 -p0
+%patch2 -p0
+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
%build
%configure
-%{__make} %{?_smp_mflags}
-cat <<EOF > %{name}.sh
-if ! echo "\$PATH" | grep -q %{_libdir}/ccache ; then
- PATH="%{_libdir}/ccache:\$PATH"
-fi
-EOF
-cat <<EOF > %{name}.csh
-if ( "\$path" !~ *%{_libdir}/ccache* ) then
- set path = ( %{_libdir}/ccache \$path )
-endif
-EOF
+make %{?_smp_mflags}
%install
@@ -53,22 +55,28 @@
install -dm 755 $RPM_BUILD_ROOT%{_libdir}/ccache
for name in %{compilers} ; do
for c in $name %{_target_cpu}-%{_vendor}-%{_target_os}-$name ; do
- ln -s %{_bindir}/ccache $RPM_BUILD_ROOT%{_libdir}/ccache/$c
+ ln -s %{relccache} $RPM_BUILD_ROOT%{_libdir}/ccache/$c
echo "%ghost %{_libdir}/ccache/$c" >> %{name}-%{version}.compilers
done
done
+install -dm 770 $RPM_BUILD_ROOT%{_var}/cache/ccache
%clean
rm -fr $RPM_BUILD_ROOT
+%pre
+getent group ccache >/dev/null || groupadd -r ccache || :
+
+
%triggerin -- %{pkgs}
for name in %{compilers} ; do
for c in $name %{_target_cpu}-%{_vendor}-%{_target_os}-$name ; do
- [ ! -x %{_bindir}/$c ] || ln -sf %{_bindir}/ccache %{_libdir}/ccache/$c
+ [ ! -x %{_bindir}/$c ] || ln -sf %{relccache} %{_libdir}/ccache/$c
done
done
+:
%triggerpostun -- %{pkgs}
for name in %{compilers} ; do
@@ -76,18 +84,32 @@
[ -x %{_bindir}/$c ] || rm -f %{_libdir}/ccache/$c
done
done
+:
%files -f %{name}-%{version}.compilers
%defattr(-,root,root,-)
%doc COPYING README web/*.html
-%config %{_sysconfdir}/profile.d/%{name}.*sh
+%config(noreplace) %{_sysconfdir}/profile.d/%{name}.*sh
%{_bindir}/ccache
%dir %{_libdir}/ccache/
+%attr(2770,root,ccache) %dir %{_var}/cache/ccache/
%{_mandir}/man1/ccache.1*
%changelog
+* Sun Aug 19 2007 Ville Skyttä <ville.skytta at iki.fi> - 2.4-10
+- License: GPLv2+
+- Make compiler symlinks relative.
+- Make profile.d scripts noreplace.
+
+* Mon Jul 30 2007 Ville Skyttä <ville.skytta at iki.fi> - 2.4-9
+- 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.
+
* Thu Mar 15 2007 Ville Skyttä <ville.skytta at iki.fi> - 2.4-8
- Bypass cache with --coverage, -fprofile-arcs and -ftest-coverage
(upstream CVS and Matt Fago, #231462).
More information about the fedora-extras-commits
mailing list