[meego-commits] 10998: New package devel:tools:sdk:target/icecream

Reto Zingg no_reply at build.meego.com
Fri Dec 17 12:27:39 UTC 2010


Hi,
Adding new package icecream in project devel:tools:sdk:target. Please review and accept ASAP.

Justification for this new package:

Feature 9670 - [FEA] request icecream in meego

Thank You,
Reto Zingg

[This message was auto-generated]

---

Request #10998:

  submit:   home:rzingg/icecream(r17) -> devel:tools:sdk:target/icecream


Message:
    Feature 9670 - [FEA] request icecream in meego

State:   new          2010-12-17T04:27:39 rzingg
Comment: None


This is a NEW package in devel:tools:sdk:target project.
The files in the new package:
icecream/
  |__  icecc-0.9.6.tar.bz2
  |__  icecream-cleanup-manpage.patch
  |__  icecream-manpages.tar.bz2
  |__  icecream-rename-scheduler.patch
  |__  icecream.changes
  |__  icecream.sh.in
  |__  icecream.spec
  |__  initscript-iceccd
  |__  initscript-scheduler

The content of the spec file, icecream.spec:
===================================================================
Name:		icecream
Version:	0.9.6
Release:        0
Summary:	Distributed compiler

Group:		Development/Tools
License:	GPLv2+
URL:		http://en.opensuse.org/Icecream
Source0:	http://ftp.suse.com/pub/projects/icecream/icecc-%{version}.tar.bz2
Source1:	icecream.sh.in
Source2:	initscript-iceccd
Source3:	initscript-scheduler
# tarball extracted from http://download.opensuse.org/repositories/home:/coolo/openSUSE_Factory/src/icecream-0.9.5-3.1.src.rpm:
Source4:	%{name}-manpages.tar.bz2
Patch0:		%{name}-rename-scheduler.patch
Patch1:         %{name}-cleanup-manpage.patch

BuildRoot:	%{_tmppath}/%{name}-%{version}-%{release}-root

Requires(post): chkconfig, ldconfig  
Requires(pre):  shadow-utils  
Requires(preun): chkconfig, fastinit
Requires(postun): chkconfig, fastinit

# description copied from Debian icecc package
%description
Icecream is a distributed compile system. It allows parallel compiling by
distributing the compile jobs to several nodes of a compile network running the
icecc daemon. The icecc scheduler routes the jobs and provides status and
statistics information to the icecc monitor. Each compile node can accept one
or more compile jobs depending on the number of processors and the settings of
the daemon. Link jobs and other jobs which cannot be distributed are executed
locally on the node where the compilation is started.

%package	devel
Summary:	Development files for %{name}
Group:		Development/Libraries
Requires:	%{name} = %{version}-%{release}

%description	devel
This package contains development files for %{name}.

%prep
%setup -q -a 4 -n icecc-%{version}
%patch0 -p1
%patch1 -p1 -d mans
sed -e 's|@LIBDIR@|%{_libdir}|g' %{SOURCE1} > icecream.sh
mkdir meego
cp -p %{SOURCE2} %{SOURCE3} meego

%build
%configure --disable-static --enable-shared

make %{?_smp_mflags}

%install
rm -rf %{buildroot}
make install DESTDIR=%{buildroot}
rm -f %{buildroot}/%{_libdir}/libicecc.la

# move the symlinks elsewhere
mkdir -p %{buildroot}/%{_libdir}/icecc/bin
for i in cc gcc c++ g++; do
	ln -s %{_bindir}/icecc %{buildroot}/%{_libdir}/icecc/bin/$i
	rm -f %{buildroot}/%{_bindir}/$i
done

# install manpages
mkdir -p %{buildroot}/%{_mandir}/man{1,7,8}
mv mans/scheduler.1 mans/icecc-scheduler.1
for i in mans/*.1 mans/*.7; do
	install -m 644 $i %{buildroot}/%{_mandir}/man${i##*.}
done

# install config file and initscripts
install -D -m 644 suse/sysconfig.icecream %{buildroot}/%{_sysconfdir}/sysconfig/icecream
install -D -m 755 meego/initscript-iceccd %{buildroot}/%{_sysconfdir}/rc.d/init.d/iceccd
install -D -m 755 meego/initscript-scheduler \
 	%{buildroot}/%{_sysconfdir}/rc.d/init.d/icecc-scheduler
install -d -m 755 %{buildroot}/%{_sysconfdir}/profile.d
install -p -m 644 icecream.sh %{buildroot}/%{_sysconfdir}/profile.d

# create default working dir
mkdir -p %{buildroot}/%{_localstatedir}/cache/icecream


%pre
/usr/sbin/groupadd -f -r icecream
/usr/bin/id icecream >/dev/null 2>&1 || \
	/usr/sbin/useradd -r -g icecream -c 'Icecream distributed compiler' \
	-s /sbin/nologin -d %{_localstatedir}/cache/icecream icecream 

%post
/sbin/ldconfig
if [ "$1" -le 1 ]; then # First install
	/sbin/chkconfig --add icecc-scheduler
	/sbin/chkconfig --add iceccd
fi

exit 0

%preun
if [ "$1" -eq 0 ]; then # Final removal
	/sbin/service iceccd stop > /dev/null 2>&1
	/sbin/service icecc-scheduler stop > /dev/null 2>&1
	/sbin/chkconfig --del iceccd
	/sbin/chkconfig --del icecc-scheduler
	rm -rf %{_localstatedir}/cache/icecream
fi
exit 0

%postun
/sbin/ldconfig
if [ "$1" -ge 1 ]; then # Upgrade
	/sbin/service iceccd restart > /dev/null 2>&1
	/sbin/service icecc-scheduler restart > /dev/null 2>&1
fi
exit 0

%clean
rm -rf %{buildroot}

%files
%defattr(-,root,root,-)
%doc COPYING README NEWS TODO
%{_bindir}/icecc
%{_bindir}/icerun
%dir %{_libdir}/icecc/
%dir %{_libdir}/icecc/bin/
%{_libdir}/icecc/bin/cc
%{_libdir}/icecc/bin/gcc
%{_libdir}/icecc/bin/c++
%{_libdir}/icecc/bin/g++
%{_libdir}/icecc/icecc-create-env
%{_libdir}/libicecc.so.*
%{_sbindir}/iceccd
%{_sbindir}/icecc-scheduler
%config(noreplace) %{_sysconfdir}/sysconfig/icecream
%config(noreplace) %{_sysconfdir}/profile.d/icecream.*sh
%{_sysconfdir}/rc.d/init.d/iceccd
%{_sysconfdir}/rc.d/init.d/icecc-scheduler
%{_localstatedir}/cache/icecream
%{_mandir}/man*/*

%files devel
%defattr(-,root,root,-)
%dir %{_includedir}/icecc/
%{_includedir}/icecc/*.h
%{_libdir}/libicecc.so
%{_libdir}/pkgconfig/icecc.pc


===================================================================




More information about the MeeGo-commits mailing list