Update python2/3 builds
This commit is contained in:
parent
663355215a
commit
4a0fc8c327
22
libtdb.spec
22
libtdb.spec
@ -6,6 +6,16 @@
|
|||||||
%global with_python2 1
|
%global with_python2 1
|
||||||
%endif
|
%endif
|
||||||
|
|
||||||
|
%if (0%{?with_python2} == 1 && 0%{?with_python3} == 0)
|
||||||
|
# We need to sent env PYTHON for python2 only build
|
||||||
|
%global export_waf_python export PYTHON=%{__python2}
|
||||||
|
%endif
|
||||||
|
|
||||||
|
%if (0%{?with_python2} == 1 && 0%{?with_python3} == 1)
|
||||||
|
# python3 is default and therefore python2 need to be set as extra-python
|
||||||
|
%global extra_python --extra-python=%{__python2}
|
||||||
|
%endif
|
||||||
|
|
||||||
Name: libtdb
|
Name: libtdb
|
||||||
Version: 1.3.17
|
Version: 1.3.17
|
||||||
Release: 1%{?dist}
|
Release: 1%{?dist}
|
||||||
@ -70,24 +80,20 @@ Python3 bindings for libtdb
|
|||||||
%autosetup -n tdb-%{version} -p1
|
%autosetup -n tdb-%{version} -p1
|
||||||
|
|
||||||
%build
|
%build
|
||||||
%if 0%{?with_python3}
|
%{?export_waf_python}
|
||||||
PY3_CONFIG_FLAGS=--extra-python=%{__python3}
|
|
||||||
%else
|
|
||||||
PY3_CONFIG_FLAGS=""
|
|
||||||
%endif
|
|
||||||
|
|
||||||
%configure --disable-rpath \
|
%configure --disable-rpath \
|
||||||
--bundled-libraries=NONE \
|
--bundled-libraries=NONE \
|
||||||
--builtin-libraries=replace \
|
--builtin-libraries=replace \
|
||||||
$PY3_CONFIG_FLAGS
|
%{?extra_python}
|
||||||
|
|
||||||
make %{?_smp_mflags} V=1
|
make %{?_smp_mflags} V=1
|
||||||
|
|
||||||
%check
|
%check
|
||||||
|
%{?export_waf_python}
|
||||||
make %{?_smp_mflags} check
|
make %{?_smp_mflags} check
|
||||||
|
|
||||||
%install
|
%install
|
||||||
|
%{?export_waf_python}
|
||||||
make install DESTDIR=$RPM_BUILD_ROOT
|
make install DESTDIR=$RPM_BUILD_ROOT
|
||||||
|
|
||||||
# Shared libraries need to be marked executable for
|
# Shared libraries need to be marked executable for
|
||||||
|
Loading…
Reference in New Issue
Block a user