]> git.proxmox.com Git - mirror_corosync-qdevice.git/blobdiff - corosync-qdevice.spec.in
LICENSE: Update copyright date
[mirror_corosync-qdevice.git] / corosync-qdevice.spec.in
index 7305e0d49b34346c8e4e3a84ca77e57ffdc3dce5..1179167a6251188f9e11e8def559c4b033627b29 100644 (file)
@@ -5,8 +5,9 @@
 # Conditionals
 # Invoke "rpmbuild --without <feature>" or "rpmbuild --with <feature>"
 # to disable or enable specific features
-%bcond_with runautogen
-%bcond_with systemd
+%@bcond_userflags@ userflags
+%@bcond_runautogen@ runautogen
+%@bcond_systemd@ systemd
 
 %global gitver %{?numcomm:.%{numcomm}}%{?alphatag:.%{alphatag}}%{?dirty:.%{dirty}}
 %global gittarver %{?numcomm:.%{numcomm}}%{?alphatag:-%{alphatag}}%{?dirty:-%{dirty}}
@@ -64,13 +65,17 @@ BuildRequires: autoconf automake libtool
 %endif
 
 %{configure} \
+%if %{with userflags}
+       --enable-user-flags \
+%endif
 %if %{with systemd}
        --enable-systemd \
 %endif
        --enable-qdevices \
        --enable-qnetd \
        --with-initddir=%{_initrddir} \
-       --with-systemddir=%{_unitdir}
+       --with-systemddir=%{_unitdir} \
+       --docdir=%{_docdir}
 
 make %{_smp_mflags}
 
@@ -82,10 +87,10 @@ make install DESTDIR=%{buildroot}
 rm -rf %{buildroot}%{_docdir}/*
 mkdir -p %{buildroot}%{_sysconfdir}/sysconfig
 # /etc/sysconfig/corosync-qdevice
-install -m 644 init/corosync-qdevice.sysconfig.example \
+install -p -m 644 init/corosync-qdevice.sysconfig.example \
    %{buildroot}%{_sysconfdir}/sysconfig/corosync-qdevice
 # /etc/sysconfig/corosync-qnetd
-install -m 644 init/corosync-qnetd.sysconfig.example \
+install -p -m 644 init/corosync-qnetd.sysconfig.example \
    %{buildroot}%{_sysconfdir}/sysconfig/corosync-qnetd
 
 %if %{with systemd}
@@ -125,6 +130,7 @@ fi
 %endif
 
 %files
+%license LICENSE
 %dir %{_sysconfdir}/corosync/qdevice
 %dir %config(noreplace) %{_sysconfdir}/corosync/qdevice/net
 %dir %{_localstatedir}/run/corosync-qdevice
@@ -185,6 +191,7 @@ fi
 %endif
 
 %files -n corosync-qnetd
+%license LICENSE
 %dir %config(noreplace) %attr(770, coroqnetd, coroqnetd) %{_sysconfdir}/corosync/qnetd
 %dir %attr(770, coroqnetd, coroqnetd) %{_localstatedir}/run/corosync-qnetd
 %{_bindir}/corosync-qnetd