Skip to content

Commit

Permalink
make-srpm.sh: build require Python 2 only when needed
Browse files Browse the repository at this point in the history
  • Loading branch information
irushchyshyn authored and kdudka committed Jan 15, 2018
1 parent 1ebea2c commit 7398733
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions make-srpm.sh
Original file line number Diff line number Diff line change
Expand Up @@ -82,10 +82,9 @@ License: GPLv3+
URL: https://github.com/kdudka/%{name}
Source0: https://github.com/kdudka/%{name}/releases/download/%{name}-%{version}/%{name}-%{version}.tar.xz
BuildRequires: GitPython
BuildRequires: cmake
BuildRequires: help2man
BuildRequires: python-devel
%if !(0%{?fedora} >= 19 || 0%{?rhel} >= 7)
BuildRequires: python-argparse
%endif
Expand All @@ -98,6 +97,8 @@ BuildRequires: python3-devel
%global csmock_python_executable %{__python3}
%global csmock_python_sitelib %{python3_sitelib}
%else
BuildRequires: GitPython
BuildRequires: python-devel
%if 0%{?rhel} && 0%{?rhel} <= 6
%{!?__python2: %global __python2 /usr/bin/python2}
%{!?python2_sitelib: %global python2_sitelib %(%{__python2} -c "from distutils.sysconfig import get_python_lib; print(get_python_lib())")}
Expand Down

0 comments on commit 7398733

Please sign in to comment.