icecc/icecc.spec

220 lines
6.9 KiB
RPMSpec
Raw Permalink Normal View History

### AUTOUPDATE-OFF: 1
%define userid 65425
%define groupid 65425
Name: icecc
Version: 1.3.1
Release: 2mamba
Summary: A distributed build system based on distcc
Group: Development/Tools
Vendor: openmamba
Distribution: openmamba
Packager: Silvan Calarco <silvan.calarco@mambasoft.it>
URL: https://github.com/icecc/icecream
Source: https://github.com/icecc/icecream.git/%{version}/icecream-%{version}.tar.bz2
Source2: icecc-initscript
Source3: icecream-sysconfig
Source4: icecream-logrotate
Source5: icecc-profile
Source6: icecream-monitor
Patch0: %{name}-0.9.7-arm_platform_map.patch
Patch1: %{name}-0.9.7-x86_64-map-to-i686-for-now.patch
Patch2: icecc-0.9.98.1-sysconfig-openmamba.patch
Patch3: icecc-1.0.1-increase_MAX_BUSY_INSTALLING.patch
Patch4: icecc-1.0.1-dont_map_x86_to_x86_64.patch
License: GPL
## AUTOBUILDREQ-BEGIN
BuildRequires: glibc-devel
BuildRequires: libacl-devel
BuildRequires: libarchive-devel
BuildRequires: libattr-devel
BuildRequires: libb2-devel
BuildRequires: libbzip2-devel
BuildRequires: libcap-ng-devel
BuildRequires: libgcc
BuildRequires: libgomp-devel
BuildRequires: liblz4-devel
BuildRequires: liblzma-devel
BuildRequires: liblzo-devel
BuildRequires: libnettle-devel
BuildRequires: libopenssl-devel
BuildRequires: libstdc++6-devel
BuildRequires: libxml2-devel
BuildRequires: libz-devel
BuildRequires: libzstd-devel
## AUTOBUILDREQ-END
BuildRequires: libclang-devel
BuildRequires: pkg-config
BuildRequires: docbook2X
Requires: gcc
Requires: gcc-c++
Requires: gcc-cpp
Requires: /usr/bin/expect
%description
Icecream was created by SUSE based on distcc. Like distcc, Icecream takes compile jobs from a (KDE) build and distributes it among remote machines allowing a parallel build. But unlike distcc, Icecream uses a central server that dynamically schedules the compile jobs to the fastest free server. This advantage pays off mostly for shared computers, if you're the only user on x machines, you have full control over them.
%debug_package
%prep
%setup -q -n icecream-%{version}
#%patch0 -p1
%patch2 -p1
#%patch3 -p1
./autogen.sh
%build
%configure
%make DOCBOOK2X=db2x_docbook2man
%install
[ "%{buildroot}" != / ] && rm -rf "%{buildroot}"
%makeinstall
##
## Install icecream init script
#mkdir -p %{buildroot}%{_initrddir}
#install -m 755 %{SOURCE2} %{buildroot}%{_initrddir}/icecream
mkdir -p %{buildroot}%{_sysconfdir}/sysconfig
install -m 644 suse/sysconfig.icecream %{buildroot}%{_sysconfdir}/sysconfig/icecream
mkdir -p %{buildroot}/var/cache/icecream
#mkdir -p %{buildroot}%{_mandir}/man{1,7}
#for i in mans/*.1 mans/*.7; do
# install -m 644 $i %{buildroot}%{_mandir}/man`echo $i | sed -e 's,.*\(.\)$,\1,'`/`basename $i`
#done
install -m 644 -D %{SOURCE4} %{buildroot}%{_sysconfdir}/logrotate.d/icecream
#install -D -m0755 %{SOURCE5} %{buildroot}%{_sysconfdir}/profile.d/icecream.sh
install -D -m0755 %{SOURCE6} %{buildroot}%{_bindir}/icecream-monitor
install -d -m0755 %{buildroot}%{_localstatedir}/log/icecream
for f in c++ cc g++ gcc; do
ln -s %{_bindir}/icecc %{buildroot}%{_libexecdir}/icecc/bin/%{_host}-$f
done
%clean
[ "%{buildroot}" != / ] && rm -rf "%{buildroot}"
%pre
if [ $1 -ge 1 ]; then
userdel icecream 2>/dev/null || :
groupdel icecream 2>/dev/null || :
/usr/sbin/groupadd -r -g %{groupid} icecc 2> /dev/null || :
/usr/sbin/useradd -r -g %{userid} -s /bin/false -c "Icecream Daemon" -d /var/cache/icecream icecc 2> /dev/null || :
fi
%post
if [ $1 -eq 1 ]; then
service icecream start
fi
if [ $1 -ge 1 ]; then
chkconfig --add icecream
fi
:
%preun
if [ $1 -eq 0 ]; then
service icecream stop
chkconfig --del icecream
fi
:
%postun
if [ $1 -eq 0 ]; then
groupdel icecc 2>/dev/null || :
userdel icecc 2>/dev/null || :
fi
:
%files
%defattr(-,root,root)
#%{_sysconfdir}/profile.d/icecream.sh
%{_sysconfdir}/logrotate.d/icecream
%config(noreplace) %{_sysconfdir}/sysconfig/icecream
%{_bindir}/icecc
%{_bindir}/icerun
%{_bindir}/icecream-monitor
%{_bindir}/icecc-create-env
%{_bindir}/icecc-test-env
%{_sbindir}/iceccd
%{_sbindir}/icecc-scheduler
%attr(0755,icecc,icecc) %dir /var/cache/icecream
%dir %{_includedir}/icecc
%{_includedir}/icecc/*.h
#%{_libdir}/icecc/icecc-create-env
%{_libdir}/libicecc.a
%{_libdir}/libicecc.la
%dir %{_libexecdir}/icecc
%dir %{_libexecdir}/icecc/bin
%{_libexecdir}/icecc/bin/c++
%{_libexecdir}/icecc/bin/cc
%{_libexecdir}/icecc/bin/clang
%{_libexecdir}/icecc/bin/clang++
%{_libexecdir}/icecc/bin/g++
%{_libexecdir}/icecc/bin/gcc
%{_libexecdir}/icecc/bin/%{_host}-c++
%{_libexecdir}/icecc/bin/%{_host}-cc
%{_libexecdir}/icecc/bin/%{_host}-g++
%{_libexecdir}/icecc/bin/%{_host}-gcc
%{_libexecdir}/icecc/compilerwrapper
%{_libexecdir}/icecc/icecc-create-env
%attr(-,icecc,icecc) %dir %{_localstatedir}/log/icecream
%{_libdir}/pkgconfig/icecc.pc
%{_mandir}/man1/icecc.1*
%{_mandir}/man1/iceccd.1*
%{_mandir}/man1/icecc-create-env.1*
%{_mandir}/man1/icecc-scheduler.1*
%{_mandir}/man1/icerun.1*
%{_mandir}/man7/icecream.7*
%doc COPYING
%changelog
* Sun Feb 20 2022 Silvan Calarco <silvan.calarco@mambasoft.it> 1.3.1-2mamba
- remove profile script setting RPM_BUILD_NCPUS to 2*cpus + 1
* Tue May 11 2021 Silvan Calarco <silvan.calarco@mambasoft.it> 1.3.1-1mamba
- update to 1.3.1
* Wed Jun 18 2014 Silvan Calarco <silvan.calarco@mambasoft.it> 1.0.1-6mamba
- scheduler: patch to increase MAX_BUSY_INSTALLING time from 2 minutes to 20
* Mon Jun 02 2014 Silvan Calarco <silvan.calarco@mambasoft.it> 1.0.1-5mamba
- remove x86_64-map-to-i686 patch no longer needed now
* Sat May 24 2014 Silvan Calarco <silvan.calarco@mambasoft.it> 1.0.1-4mamba
- fix profile script for x86_64
* Tue Apr 29 2014 Silvan Calarco <silvan.calarco@mambasoft.it> 1.0.1-3mamba
- provide required directory /var/log/icecream
* Thu Jul 25 2013 Silvan Calarco <silvan.calarco@mambasoft.it> 1.0.1-2mamba
- added llvm-clang-devel build requirement
* Sun Jul 21 2013 Automatic Build System <autodist@mambasoft.it> 1.0.1-1mamba
- automatic update by autodist
* Sun May 19 2013 Automatic Build System <autodist@mambasoft.it> 1.0.0-1mamba
- update to 1.0.0
* Sat Jan 05 2013 Automatic Build System <autodist@mambasoft.it> 0.9.98.1-1mamba
- automatic version update by autodist
* Tue Jul 31 2012 Silvan Calarco <silvan.calarco@mambasoft.it> 0.9.7-5mamba
- added expect script icecream-monitor
- require gcc, gcc-c++ and /usr/bin/expect
* Sat Apr 07 2012 Silvan Calarco <silvan.calarco@mambasoft.it> 0.9.7-4mamba
- add a patch to map x86_64 as equivalent to i686 to allow exporting builds from x86_64 kernel + 32 bit o.s. machine
* Fri Feb 24 2012 Silvan Calarco <silvan.calarco@mambasoft.it> 0.9.7-3mamba
- added default sysconfig and logrotate files
* Fri Feb 24 2012 Silvan Calarco <silvan.calarco@mambasoft.it> 0.9.7-2mamba
- added iniscript, man pages, icecream user and group
- added symlinks to icecc for platform based gcc commands
* Fri Feb 24 2012 Silvan Calarco <silvan.calarco@mambasoft.it> 0.9.7-1mamba
- package created by autospec