rpms/icecream/F-8 icecream-compile-fix.patch, NONE, 1.1 icecream.spec, 1.4, 1.5

Michal Schmidt (michich) fedora-extras-commits at redhat.com
Sun Feb 10 23:41:29 UTC 2008


Author: michich

Update of /cvs/pkgs/rpms/icecream/F-8
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv1746

Modified Files:
	icecream.spec 
Added Files:
	icecream-compile-fix.patch 
Log Message:
* Sun Feb 10 2008 Michal Schmidt <mschmidt at redhat.com> - 0.8.0-10.20080117svn
- Compile fix (added missing #includes).
- Conditional building of SELinux policy and documentation.
- Fix build on RHEL5.


icecream-compile-fix.patch:

--- NEW FILE icecream-compile-fix.patch ---
diff -up icecream-0.8.0/client/remote.cpp.orig icecream-0.8.0/client/remote.cpp
--- icecream-0.8.0/client/remote.cpp.orig	2008-02-10 22:15:20.000000000 +0100
+++ icecream-0.8.0/client/remote.cpp	2008-02-10 22:18:09.000000000 +0100
@@ -38,6 +38,7 @@
 #include <unistd.h>
 #include <stdio.h>
 #include <errno.h>
+#include <limits.h>
 #include <map>
 #include <algorithm>
 #include <netinet/in.h>
diff -up icecream-0.8.0/client/local.cpp.orig icecream-0.8.0/client/local.cpp
--- icecream-0.8.0/client/local.cpp.orig	2008-02-10 22:14:30.000000000 +0100
+++ icecream-0.8.0/client/local.cpp	2008-02-10 22:16:20.000000000 +0100
@@ -27,6 +27,7 @@
 #include <unistd.h>
 #include <string.h>
 #include <errno.h>
+#include <limits.h>
 #ifdef HAVE_SIGNAL_H
 #include <signal.h>
 #endif
diff -up icecream-0.8.0/client/main.cpp.orig icecream-0.8.0/client/main.cpp
--- icecream-0.8.0/client/main.cpp.orig	2008-02-10 22:13:09.000000000 +0100
+++ icecream-0.8.0/client/main.cpp	2008-02-10 22:18:20.000000000 +0100
@@ -48,6 +48,7 @@
 #include <fcntl.h>
 #include <errno.h>
 #include <signal.h>
+#include <limits.h>
 #include <cassert>
 #include <sys/time.h>
 #include <comm.h>


Index: icecream.spec
===================================================================
RCS file: /cvs/pkgs/rpms/icecream/F-8/icecream.spec,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -r1.4 -r1.5
--- icecream.spec	17 Jan 2008 13:09:55 -0000	1.4
+++ icecream.spec	10 Feb 2008 23:40:52 -0000	1.5
@@ -1,6 +1,19 @@
+%bcond_without	doc
+
+%if 0%{?fedora}
+%bcond_without  fedora
+%bcond_without	selinux
+%else
+%bcond_with	fedora
+# I'd need to modify the policy a bit to make it work on RHEL,
+# so default to off when not building for Fedora.
+%bcond_with	selinux
+%endif
+
+
 Name:		icecream
 Version:	0.8.0
-Release:	8.20080117svn%{?dist}
+Release:	10.20080117svn%{?dist}
 Summary:	Distributed compiler
 
 Group:		Development/Tools
@@ -24,12 +37,15 @@
 Patch0:		icecream-make-it-cool.patch.bz2
 Patch1:		icecream-rename-scheduler.patch
 Patch2:		icecream-cleanup-conffile.patch
+Patch3:		icecream-compile-fix.patch
 
 BuildRoot:	%{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
 
 BuildRequires:	automake autoconf libtool symlinks
 # To build manpages from KDE-style Docbook sources:
-BuildRequires:	kdelibs kdelibs-devel
+%{?with_doc:BuildRequires:	%{!?el5:kdelibs3 kdelibs3-devel} %{?el5:kdelibs kdelibs-devel}}
+
+%if %{with selinux}
 # For SELinux protection:
 BuildRequires:	checkpolicy selinux-policy-devel hardlink
 %define selinux_policyver %(sed -e 's,.*selinux-policy-\\([^/]*\\)/.*,\\1,' /usr/share/selinux/devel/policyhelp) 
@@ -37,8 +53,8 @@
 Requires:	selinux-policy >= %{selinux_policyver}
 %endif
 %define selinux_variants mls strict targeted 
+%endif
 
-%bcond_without	fedora
 BuildRequires:	fedora-usermgmt-devel
 %{?FE_USERADD_REQ}
 Requires(post):		chkconfig policycoreutils
@@ -72,6 +88,7 @@
 %patch0 -p1
 %patch1 -p0
 %patch2 -p0
+%patch3 -p1
 make -f Makefile.cvs
 sed -e 's|@LIBDIR@|%{_libdir}|g' %{SOURCE1} > icecream.sh
 sed -e 's|@LIBDIR@|%{_libdir}|g' %{SOURCE2} > icecream.csh
@@ -83,6 +100,8 @@
 %build
 %configure --disable-static --enable-shared
 make %{?_smp_mflags}
+
+%if %{with doc}
 pushd doc
 for i in man-*.docbook; do
 	meinproc --stylesheet %{_datadir}/apps/ksgmltools2/customization/kde-man.xsl $i
@@ -91,6 +110,9 @@
 	mv manpage.troff $manfile
 done
 popd
+%endif
+
+%if %{with selinux}
 pushd SELinux
 for selinuxvariant in %{selinux_variants}; do
 	make NAME=${selinuxvariant} -f %{_datadir}/selinux/devel/Makefile
@@ -98,6 +120,7 @@
 	make NAME=${selinuxvariant} -f %{_datadir}/selinux/devel/Makefile clean
 done
 popd
+%endif
 
 %install
 rm -rf %{buildroot}
@@ -114,12 +137,14 @@
 # relativize the symlinks
 symlinks -cs %{buildroot}/%{_libdir}/icecc/bin
 
+%if %{with doc}
 # install manpages
 mkdir -p %{buildroot}/%{_mandir}/man{1,7,8}
 mv doc/scheduler.1 doc/icecc-scheduler.1
 for i in doc/*.1 doc/*.7; do
 	install -m 644 $i %{buildroot}/%{_mandir}/man${i##*.}
 done
+%endif
 
 # install config file and initscripts
 install -D -m 644 suse/sysconfig.icecream %{buildroot}/%{_sysconfdir}/sysconfig/icecream
@@ -132,6 +157,7 @@
 # create default working dir
 mkdir -p %{buildroot}/%{_localstatedir}/cache/icecream
 
+%if %{with selinux}
 for selinuxvariant in %{selinux_variants}; do
 	install -d %{buildroot}/%{_datadir}/selinux/${selinuxvariant}
 	install -p -m 644 -D SELinux/icecream.pp.${selinuxvariant} \
@@ -139,6 +165,7 @@
 done
 # Hardlink identical policy module packages together
 /usr/sbin/hardlink -cv %{buildroot}%{_datadir}/selinux
+%endif
 
 %pre
 # https://fedoraproject.org/wiki/PackageUserRegistry
@@ -149,16 +176,18 @@
 %post
 /sbin/ldconfig
 # if [ "$1" -le 1 ]; then # First install
+%if %{with selinux}
 for selinuxvariant in %{selinux_variants}; do
 	semodule -s ${selinuxvariant} -i \
 		%{_datadir}/selinux/${selinuxvariant}/icecream.pp 2>/dev/null ||:
 done
 fixfiles -R %{name} restore ||:
-restorecon -R %{_localstatedir}/cache/icecream ||:
-restorecon %{_localstatedir}/log/iceccd ||:
+restorecon -R %{_localstatedir}/cache/icecream 2>/dev/null ||:
+restorecon %{_localstatedir}/log/iceccd 2>/dev/null ||:
 semanage port -a -t iceccd_port_t -p tcp 10245 2>/dev/null ||:
 semanage port -a -t icecc_scheduler_port_t -p tcp 8765 2>/dev/null ||:
 semanage port -a -t icecc_scheduler_port_t -p udp 8765 2>/dev/null ||:
+%endif
 # fi
 /sbin/chkconfig --add iceccd
 /sbin/chkconfig --add icecc-scheduler
@@ -171,12 +200,16 @@
 	/sbin/chkconfig --del iceccd
 	/sbin/chkconfig --del icecc-scheduler
 #	rm -rf %{_localstatedir}/cache/icecream
+
+%if %{with selinux}
 	semanage port -d -t iceccd_port_t -p tcp 10245 2>/dev/null ||:
 	semanage port -d -t icecc_scheduler_port_t -p tcp 8765 2>/dev/null ||:
 	semanage port -d -t icecc_scheduler_port_t -p udp 8765 2>/dev/null ||:
 	for selinuxvariant in %{selinux_variants}; do
 		semodule -s ${selinuxvariant} -r icecream 2>/dev/null ||:
 	done
+%endif
+
 fi
 exit 0
 
@@ -203,13 +236,13 @@
 %{_libdir}/libicecc.so.*
 %{_sbindir}/iceccd
 %{_sbindir}/icecc-scheduler
-%{_mandir}/man*/*
 %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
-%{_datadir}/selinux/*/icecream.pp
+%{?with_doc:%{_mandir}/man*/*}
+%{?with_selinux:%{_datadir}/selinux/*/icecream.pp}
 
 %files devel
 %{_includedir}/icecc/*.h
@@ -217,9 +250,20 @@
 %{_libdir}/pkgconfig/icecc.pc
 
 %changelog
+* Sun Feb 10 2008 Michal Schmidt <mschmidt at redhat.com> - 0.8.0-10.20080117svn
+- Compile fix (added missing #includes).
+- Conditional building of SELinux policy and documentation.
+- Fix build on RHEL5.
+
+* Tue Jan 29 2008 Michal Schmidt <mschmidt at redhat.com> - 0.8.0-9.20080117svn
+- SELinux policy fixes.
+
 * Thu Jan 17 2008 Michal Schmidt <mschmidt at redhat.com> - 0.8.0-8.20080117svn
 - Update to current icecream-make-it-cool branch.
 
+* Tue Jan  8 2008 Michal Schmidt <mschmidt at redhat.com> - 0.8.0-7.20071101svn
+- Build fix. meinproc is now in kdelibs3. BuildRequire that instead of kdelibs.
+
 * Thu Nov 29 2007 Michal Schmidt <mschmidt at redhat.com> - 0.8.0-6.20071101svn
 - Rewritten the profile scripts to make icecream work together with ccache.
 




More information about the fedora-extras-commits mailing list