--- openafs.spec.orig 2014-05-25 21:15:54.539027644 -0400 +++ openafs.spec 2014-05-25 21:16:27.836268275 -0400 @@ -4,7 +4,7 @@ %define pkgvers 1.6.10 # for beta/rc releases make pkgrel 0. # for real releases make pkgrel 1 (or more for extra releases) -%define pkgrel 0.pre1 +%define pkgrel 0.pre1.99.scripts.%{scriptsversion} %{!?fedorakmod: %define fedorakmod 1} %{!?build_dkmspkg: %define build_dkmspkg 1} @@ -249,9 +249,15 @@ %if %{build_modules} BuildRequires: kernel-devel %endif +BuildRequires: libtool ExclusiveArch: %{ix86} x86_64 ia64 s390 s390x sparc64 ppc ppc64 +Patch1000: openafs-scripts.patch +Patch1002: openafs-systemd-crond.patch +Patch1003: openafs-systemd-csdb.patch +%define _default_patch_fuzz 2 + # http://dl.openafs.org/dl/openafs/candidate/%{afsvers}/... Source0: http://www.openafs.org/dl/openafs/%{afsvers}/openafs-%{afsvers}-src.tar.bz2 Source1: http://www.openafs.org/dl/openafs/%{afsvers}/openafs-%{afsvers}-doc.tar.bz2 @@ -331,6 +337,7 @@ %if %{build_userspace} %package client +Provides: scripts-openafs-client Requires: binutils, openafs = %{version} %if 0%{?fedora} >= 15 || 0%{?rhel} >= 7 Requires: systemd-units @@ -382,6 +389,7 @@ %package -n dkms-%{name} Summary: DKMS-ready kernel source for AFS distributed filesystem Group: Development/Kernel +Provides: scripts-dkms-%{name} Provides: openafs-kernel = %{version} %if %{fedorakmod} Provides: %{name}-kmod = %{version} @@ -403,6 +411,7 @@ %if %{build_authlibs} %package authlibs +Provides: scripts-openafs-authlibs Summary: OpenAFS authentication shared libraries Group: Networking/Filesystems @@ -419,6 +428,7 @@ %endif %package authlibs-devel +Provides: scripts-openafs-authlibs-devel %if %{build_authlibs} Requires: openafs-authlibs = %{version}-%{release} %endif @@ -437,6 +447,7 @@ libraries. %package devel +Provides: scripts-openafs-devel Summary: OpenAFS Development Libraries and Headers Group: Development/Filesystems Requires: openafs = %{version}-%{release} @@ -466,6 +477,7 @@ administrators. %package kernel-source +Provides: scripts-openafs-kernel-source Summary: OpenAFS Kernel Module source tree Group: Networking/Filesystems Provides: openafs-kernel = %{version} @@ -515,6 +527,7 @@ %if %{krb5support} %package krb5 +Provides: scripts-openafs-krb5 Summary: OpenAFS programs to use with krb5 Requires: openafs = %{version} Group: Networking/Filesystems @@ -541,7 +554,7 @@ %if %{build_modules} %if %{fedorakmod} -%{expand:%(%{kmodtool} rpmtemplate %{kmod_name} %{kverrel} %{depmod} %{kvariants} 2>/dev/null)} +%{expand:%(%{kmodtool} rpmtemplate %{kmod_name} %{kverrel} %{depmod} %{kvariants} | sed '/^%package/ aProvides: scripts-kmod-openafs' 2>/dev/null)} %else @@ -698,6 +711,11 @@ #%setup -q -n %{srcdir} %setup -q -b 1 -n %{srcdir} +# Apply the Scripts patch +%patch1000 -p1 -b .scripts +%patch1002 -p1 -b .systemd-crond +%patch1003 -p1 -b .systemd-csdb + ############################################################################## # # building @@ -871,6 +889,8 @@ %endif %endif +./regen.sh + ./configure --with-afs-sysname=${sysname} \ --prefix=%{_prefix} \ --libdir=%{_libdir} \ @@ -1267,6 +1287,13 @@ rm -f $RPM_BUILD_ROOT%{_libdir}/libafsrpc.so rm -f $RPM_BUILD_ROOT%{_libdir}/libafsauthent.so.* rm -f $RPM_BUILD_ROOT%{_libdir}/libafsrpc.so.* +%else +chmod +x $RPM_BUILD_ROOT%{_libdir}/libafsauthent.so +chmod +x $RPM_BUILD_ROOT%{_libdir}/libafsrpc.so +chmod +x $RPM_BUILD_ROOT%{_libdir}/libafsauthent.so.* +chmod +x $RPM_BUILD_ROOT%{_libdir}/libafsrpc.so.* +chmod +x $RPM_BUILD_ROOT%{_libdir}/libkopenafs.so +chmod +x $RPM_BUILD_ROOT%{_libdir}/libkopenafs.so.* %endif %endif