diff --git a/pki-core.spec b/pki-core.spec index 020b31a..e3bc9a9 100644 --- a/pki-core.spec +++ b/pki-core.spec @@ -10,7 +10,7 @@ BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) # specify '_unitdir' macro for platforms that don't use 'systemd' %if 0%{?rhel} || 0%{?fedora} < 16 -%define _unitdir /lib/systemd/system +%define _unitdir %{_unitdir} %endif # tomcatjss requires versioning since version 2.0.0 requires tomcat6 @@ -373,6 +373,8 @@ Requires: pki-selinux = %{version}-%{release} Requires(post): systemd-units Requires(preun): systemd-units Requires(postun): systemd-units +Conflicts: systemd < 38 +Conflicts: filesystem < 3 %else %if 0%{?fedora} >= 15 Requires(post): chkconfig @@ -437,7 +439,8 @@ This package is a part of the PKI Core used by the Certificate System. %setup -q - +#FIXME +sed -i -e 's#/lib/systemd/system#%{_unitdir}#g' cmake/Modules/DefineInstallationPaths.cmake %clean %{__rm} -rf %{buildroot} @@ -538,7 +541,7 @@ fi if [ -d /etc/sysconfig/pki/ca ]; then for inst in `ls /etc/sysconfig/pki/ca`; do if [ ! -e "/etc/systemd/system/pki-cad.target.wants/pki-cad@${inst}.service" ]; then - ln -s "/lib/systemd/system/pki-cad@.service" \ + ln -s "%{_unitdir}/pki-cad@.service" \ "/etc/systemd/system/pki-cad.target.wants/pki-cad@${inst}.service" [ -L /var/lib/${inst}/${inst} ] && unlink /var/lib/${inst}/${inst} ln -s /usr/sbin/tomcat6-sysd /var/lib/${inst}/${inst}