Sophie

Sophie

distrib > Mageia > 4 > x86_64 > by-pkgid > 1adef2d36b4892e4a2ebc56764154456 > files > 4

colorgcc-1.3.2-14.mga4.src.rpm

%define name colorgcc
%define version 1.3.2
%define release %mkrel 14

Summary: GCC output colorizer
Name: %{name}
Version: %{version}
Release: %{release}
Source0: %{name}-%{version}.tar.bz2
Patch0: colorgcc-1.3.2-mdkconf.patch
Patch1: colorgcc-1.3.2-handle-translated-output.patch
License: GPL
Group: Development/C
Url: http://www.schlueters.de/colorgcc.html
Requires: gcc
Obsoletes: gcc2.96-colorgcc
Obsoletes: gcc-colorgcc <= 4.2.1
Provides: gcc-colorgcc <= 4.2.1
BuildArch: noarch
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-buildroot

%description
ColorGCC is a Perl wrapper to colorize the output of compilers with
warning and error messages matching the GCC output format.

This package is configured to run with the associated system compiler. If you
want to use it for another compiler (e.g. gcc 2.96), you may have to define
gccVersion: 2.96 and uncomment the respective compiler paths in
%{_sysconfdir}/colorgccrc for a system-wide effect, or in ~/.colorgccrc for
your user only.

%prep
%setup -q
%patch0 -p1 -b .mdkconf
%patch1 -p1 -b .i18n

cat <<'EOF' > colorgcc.sh
case ":${PATH}:" in
    :: )
	PATH=%{_datadir}/%{name}
	export PATH
    ;;
    *:%{_datadir}/%{name}:* )
	: Already set
    ;;
    * )
	PATH=%{_datadir}/%{name}:$PATH
	export PATH
    ;;
esac
EOF

cat <<'EOF' > colorgcc.csh
if ( $?PATH ) then
    switch (:${PATH}:)
	case *":%{_datadir}/%{name}:"* :
		breaksw
	default :
		setenv PATH %{_datadir}/%{name}:$PATH
		breaksw
	endsw
else
   setenv PATH %{_datadir}/%{name}
endif
EOF

%build

%install
rm -rf %{buildroot}

install -D -m 755 colorgcc     %{buildroot}%{_bindir}/colorgcc
install -D -m 644 colorgccrc   %{buildroot}%{_sysconfdir}/colorgccrc
install -D -m 644 colorgcc.sh  %{buildroot}%{_sysconfdir}/profile.d/20colorgcc.sh
install -D -m 644 colorgcc.csh %{buildroot}%{_sysconfdir}/profile.d/20colorgcc.csh
# nb: prefixing colorgcc.sh by "20" so that it is sourced before 80icecream.sh

install -d %{buildroot}%{_datadir}/%{name}
ln -s ../../bin/colorgcc %{buildroot}%{_datadir}/%{name}/colorgcc
for i in gcc cc g++ c++ gfortran gcj; do
    ln -s colorgcc %{buildroot}%{_datadir}/%{name}/$i
done

%clean
rm -rf %{buildroot}

%files
%defattr(-,root,root)
%doc COPYING CREDITS ChangeLog
%config(noreplace) %{_sysconfdir}/colorgccrc
%{_sysconfdir}/profile.d/*
%{_bindir}/colorgcc
%{_datadir}/colorgcc





%changelog
* Fri Oct 18 2013 umeabot <umeabot> 1.3.2-14.mga4
+ Revision: 503462
- Mageia 4 Mass Rebuild

* Fri Jan 11 2013 umeabot <umeabot> 1.3.2-13.mga3
+ Revision: 348062
- Mass Rebuild - https://wiki.mageia.org/en/Feature:Mageia3MassRebuild

* Sun May 15 2011 pterjan <pterjan> 1.3.2-12.mga1
+ Revision: 98918
- Rebuild for fixed find-requires

* Fri Feb 04 2011 ahmad <ahmad> 1.3.2-11.mga1
+ Revision: 46812
- imported package colorgcc


* Sun Dec 05 2010 Oden Eriksson <oeriksson@mandriva.com> 1.3.2-11mdv2011.0
+ Revision: 610152
- rebuild

* Tue Nov 03 2009 Andrey Borzenkov <arvidjaar@mandriva.org> 1.3.2-10mdv2010.1
+ Revision: 460412
- do not duplicate PATH entry on recursive shell invocation

* Wed Sep 02 2009 Thierry Vignaud <tv@mandriva.org> 1.3.2-9mdv2010.0
+ Revision: 424937
- rebuild

* Wed Jul 23 2008 Thierry Vignaud <tv@mandriva.org> 1.3.2-8mdv2009.0
+ Revision: 243606
- rebuild

* Fri Dec 21 2007 Olivier Blin <oblin@mandriva.com> 1.3.2-6mdv2008.1
+ Revision: 136330
- restore BuildRoot

  + Thierry Vignaud <tv@mandriva.org>
    - kill re-definition of %%buildroot on Pixel's request

* Tue Sep 18 2007 Guillaume Rousse <guillomovitch@mandriva.org> 1.3.2-6mdv2008.0
+ Revision: 89587
- rebuild

* Mon Aug 06 2007 Pixel <pixel@mandriva.com> 1.3.2-5mdv2008.0
+ Revision: 59559
- rebuild for build system test

* Mon Aug 06 2007 Pixel <pixel@mandriva.com> 1.3.2-4mdv2008.0
+ Revision: 59553
- rebuild for build system test

* Mon Aug 06 2007 Pixel <pixel@mandriva.com> 1.3.2-3mdv2008.0
+ Revision: 59543
- rebuild for build system test

* Mon Aug 06 2007 Pixel <pixel@mandriva.com> 1.3.2-2mdv2008.0
+ Revision: 59484
- fix parsing warnings as warnings when messages are translated (#32282)

* Wed Jul 11 2007 Pixel <pixel@mandriva.com> 1.3.2-1mdv2008.0
+ Revision: 51263
- standalone package which replaces gcc-colorgcc
- uses its own path to be independant of installed gcc
- Create colorgcc