s/%define/%global/

This commit is contained in:
Kaleb S KEITHLEY 2015-12-24 16:41:50 -05:00
parent 4b94bf439e
commit b0dbd8a747

View File

@ -60,7 +60,7 @@
%{?_without_bd:%global _without_bd --disable-bd-xlator}
%if ( 0%{?rhel} && 0%{?rhel} < 6 || 0%{?sles_version} )
%define _without_bd --disable-bd-xlator
%global _without_bd --disable-bd-xlator
%endif
# if you wish to compile an rpm without the qemu-block support...
@ -69,7 +69,7 @@
%if ( 0%{?rhel} && 0%{?rhel} < 6 )
# xlators/features/qemu-block fails to build on RHEL5, disable it
%define _without_qemu_block --disable-qemu-block
%global _without_qemu_block --disable-qemu-block
%endif
# Disable data-tiering on EL5, sqlite is too old
@ -90,9 +90,9 @@
%endif
%if 0%{?_tmpfilesdir:1}
%define _with_tmpfilesdir --with-tmpfilesdir=%{_tmpfilesdir}
%global _with_tmpfilesdir --with-tmpfilesdir=%{_tmpfilesdir}
%else
%define _with_tmpfilesdir --without-tmpfilesdir
%global _with_tmpfilesdir --without-tmpfilesdir
%endif
# there is no systemtap support! Perhaps some day there will be
@ -106,28 +106,28 @@
%if ( 0%{?_with_systemd:1} )
%if ( 0%{_for_fedora_koji_builds} )
%define _init_enable() /bin/true ;
%global _init_enable() /bin/true ;
%else
%define _init_enable() /bin/systemctl enable %1.service ;
%global _init_enable() /bin/systemctl enable %1.service ;
%endif
%define _init_disable() /bin/systemctl disable %1.service ;
%define _init_restart() /bin/systemctl try-restart %1.service ;
%define _init_start() /bin/systemctl start %1.service ;
%define _init_stop() /bin/systemctl stop %1.service ;
%define _init_install() install -D -p -m 0644 %1 %{buildroot}%{_unitdir}/%2.service ;
%global _init_disable() /bin/systemctl disable %1.service ;
%global _init_restart() /bin/systemctl try-restart %1.service ;
%global _init_start() /bin/systemctl start %1.service ;
%global _init_stop() /bin/systemctl stop %1.service ;
%global _init_install() install -D -p -m 0644 %1 %{buildroot}%{_unitdir}/%2.service ;
# can't seem to make a generic macro that works
%define _init_glusterd %{_unitdir}/glusterd.service
%define _init_glusterfsd %{_unitdir}/glusterfsd.service
%global _init_glusterd %{_unitdir}/glusterd.service
%global _init_glusterfsd %{_unitdir}/glusterfsd.service
%else
%define _init_enable() /sbin/chkconfig --add %1 ;
%define _init_disable() /sbin/chkconfig --del %1 ;
%define _init_restart() /sbin/service %1 condrestart &>/dev/null ;
%define _init_start() /sbin/service %1 start &>/dev/null ;
%define _init_stop() /sbin/service %1 stop &>/dev/null ;
%define _init_install() install -D -p -m 0755 %1 %{buildroot}%{_sysconfdir}/init.d/%2 ;
%global _init_enable() /sbin/chkconfig --add %1 ;
%global _init_disable() /sbin/chkconfig --del %1 ;
%global _init_restart() /sbin/service %1 condrestart &>/dev/null ;
%global _init_start() /sbin/service %1 start &>/dev/null ;
%global _init_stop() /sbin/service %1 stop &>/dev/null ;
%global _init_install() install -D -p -m 0755 %1 %{buildroot}%{_sysconfdir}/init.d/%2 ;
# can't seem to make a generic macro that works
%define _init_glusterd %{_sysconfdir}/init.d/glusterd
%define _init_glusterfsd %{_sysconfdir}/init.d/glusterfsd
%global _init_glusterd %{_sysconfdir}/init.d/glusterd
%global _init_glusterfsd %{_sysconfdir}/init.d/glusterfsd
%endif
%if ( 0%{_for_fedora_koji_builds} )
@ -141,8 +141,8 @@
%{!?_pkgdocdir: %global _pkgdocdir %{_docdir}/%{name}-%{version}}
%if ( 0%{?rhel} && 0%{?rhel} < 6 )
# _sharedstatedir is not provided by RHEL5
%define _sharedstatedir /var/lib
# _sharedstatedir is not provided by RHEL5
%global _sharedstatedir /var/lib
%endif
# We do not want to generate useless provides and requires for xlator
@ -151,14 +151,14 @@
#
# TODO: RHEL5 does not have a convenient solution
%if ( 0%{?rhel} == 6 )
# filter_setup exists in RHEL6 only
%filter_provides_in %{_libdir}/glusterfs/%{version}/
%global __filter_from_req %{?__filter_from_req} | grep -v -P '^(?!lib).*\.so.*$'
%filter_setup
# filter_setup exists in RHEL6 only
%filter_provides_in %{_libdir}/glusterfs/%{version}/
%global __filter_from_req %{?__filter_from_req} | grep -v -P '^(?!lib).*\.so.*$'
%filter_setup
%else
# modern rpm and current Fedora do not generate requires when the
# provides are filtered
%global __provides_exclude_from ^%{_libdir}/glusterfs/%{version}/.*$
# modern rpm and current Fedora do not generate requires when the
# provides are filtered
%global __provides_exclude_from ^%{_libdir}/glusterfs/%{version}/.*$
%endif
@ -691,7 +691,6 @@ mkdir -p %{buildroot}%{_localstatedir}/log/glusterfsd
mkdir -p %{buildroot}%{_localstatedir}/run/gluster
touch %{buildroot}%{python_sitelib}/gluster/__init__.py
# Remove unwanted files from all the shared libraries
find %{buildroot}%{_libdir} -name '*.a' -delete
find %{buildroot}%{_libdir} -name '*.la' -delete
@ -1299,6 +1298,9 @@ fi
%endif
%changelog
* Thu Dec 24 2015 Kaleb S. KEITHLEY <kkeithle[at]redhat.com>
- s/%define/%global/
* Mon Nov 9 2015 Kaleb S. KEITHLEY <kkeithle[at]redhat.com> - 3.7.6-1
- GlusterFS 3.7.6 GA