Compare commits
No commits in common. "c8-stream-3.9" and "c9-beta" have entirely different histories.
c8-stream-
...
c9-beta
2
.gitignore
vendored
2
.gitignore
vendored
@ -1 +1 @@
|
||||
SOURCES/pybind11-2.7.1.tar.gz
|
||||
SOURCES/pybind11-2.6.2.tar.gz
|
||||
|
@ -1 +1 @@
|
||||
8ddca54a17e646aa3e42488b0a0cb250f8b8ed83 SOURCES/pybind11-2.7.1.tar.gz
|
||||
e340be2d61439deaf7bdd4bd273bb8c51b713f26 SOURCES/pybind11-2.6.2.tar.gz
|
||||
|
@ -7,33 +7,48 @@
|
||||
# Whether to run the tests, enabled by default
|
||||
%bcond_without tests
|
||||
|
||||
%if 0%{?fedora} >= 30 || 0%{?rhel} >= 9
|
||||
%global python2_enabled 0
|
||||
%else
|
||||
%global python2_enabled 1
|
||||
%endif
|
||||
|
||||
%global python3_enabled 1
|
||||
|
||||
Name: pybind11
|
||||
Version: 2.7.1
|
||||
Release: 1%{?dist}
|
||||
Version: 2.6.2
|
||||
Release: 4%{?dist}
|
||||
Summary: Seamless operability between C++11 and Python
|
||||
License: BSD
|
||||
URL: https://github.com/pybind/pybind11
|
||||
Source0: https://github.com/pybind/pybind11/archive/v%{version}/%{name}-%{version}.tar.gz
|
||||
|
||||
# Exclude i686 arch. Due to a modularity issue it's being added to the
|
||||
# x86_64 compose of CRB, but we don't want to ship it at all.
|
||||
# See: https://projects.engineering.redhat.com/browse/RCM-72605
|
||||
ExcludeArch: i686
|
||||
|
||||
# Patch out header path
|
||||
Patch1: pybind11-2.6.1-hpath.patch
|
||||
|
||||
BuildRequires: make
|
||||
|
||||
%if %{python2_enabled}
|
||||
# Needed to build the python libraries
|
||||
BuildRequires: python%{python3_pkgversion}-devel
|
||||
BuildRequires: python%{python3_pkgversion}-rpm-macros
|
||||
BuildRequires: python%{python3_pkgversion}-setuptools
|
||||
BuildRequires: python2-devel
|
||||
BuildRequires: python2-setuptools
|
||||
# These are only needed for the checks
|
||||
%if %{with tests}
|
||||
BuildRequires: python%{python3_pkgversion}-pytest
|
||||
BuildRequires: python%{python3_pkgversion}-numpy
|
||||
BuildRequires: python%{python3_pkgversion}-scipy
|
||||
BuildRequires: python2-pytest
|
||||
BuildRequires: python2-numpy
|
||||
BuildRequires: python2-scipy
|
||||
%endif
|
||||
%endif
|
||||
|
||||
%if %{python3_enabled}
|
||||
# Needed to build the python libraries
|
||||
BuildRequires: python3-devel
|
||||
BuildRequires: python3-setuptools
|
||||
# These are only needed for the checks
|
||||
%if %{with tests}
|
||||
BuildRequires: python3-pytest
|
||||
BuildRequires: python3-numpy
|
||||
BuildRequires: python3-scipy
|
||||
%endif
|
||||
%endif
|
||||
|
||||
BuildRequires: eigen3-devel
|
||||
@ -48,40 +63,48 @@ C++ code.
|
||||
%description
|
||||
%{base_description}
|
||||
|
||||
|
||||
%package -n python%{python3_pkgversion}-%{name}-devel
|
||||
%package devel
|
||||
Summary: Development headers for pybind11
|
||||
|
||||
# This package does not have namespaced file locations, so if we build the
|
||||
# pybind11-devel subpackage in any other module as well, the files from these
|
||||
# packages will conflict. The package name is namespaced so that customers can
|
||||
# decide which to install, but the packages will conflict with each other.
|
||||
Provides: %{name}-devel = %{version}-%{release}
|
||||
Conflicts: %{name}-devel < %{version}-%{release}
|
||||
|
||||
# https://fedoraproject.org/wiki/Packaging:Guidelines#Packaging_Header_Only_Libraries
|
||||
Provides: %{name}-static = %{version}-%{release}
|
||||
Provides: python%{python3_pkgversion}-%{name}-static = %{version}-%{release}
|
||||
Obsoletes: python39-%{name}-devel < %{version}-%{release}
|
||||
# For dir ownership
|
||||
Requires: cmake
|
||||
|
||||
%description -n python%{python3_pkgversion}-%{name}-devel
|
||||
%description devel
|
||||
%{base_description}
|
||||
|
||||
This package contains the development headers for pybind11.
|
||||
|
||||
%package -n python%{python3_pkgversion}-%{name}
|
||||
%if %{python2_enabled}
|
||||
%package -n python2-%{name}
|
||||
Summary: %{summary}
|
||||
%{?python_provide:%python_provide python%{python3_pkgversion}-pybind11}
|
||||
%{?python_provide:%python_provide python2-pybind11}
|
||||
Requires: %{name}-devel%{?_isa} = %{version}-%{release}
|
||||
|
||||
Requires: python%{python3_pkgversion}-%{name}-devel%{?_isa} = %{version}-%{release}
|
||||
Requires: python%{python3_pkgversion}-setuptools
|
||||
%description -n python2-%{name}
|
||||
%{base_description}
|
||||
|
||||
%description -n python%{python3_pkgversion}-%{name}
|
||||
This package contains the Python 2 files.
|
||||
%endif
|
||||
|
||||
%if %{python3_enabled}
|
||||
%package -n python3-%{name}
|
||||
Summary: %{summary}
|
||||
%{?python_provide:%python_provide python3-pybind11}
|
||||
|
||||
Requires: %{name}-devel%{?_isa} = %{version}-%{release}
|
||||
|
||||
%if !%{python2_enabled}
|
||||
# Take care of upgrade path
|
||||
Obsoletes: python2-%{name} < %{version}-%{release}
|
||||
%endif
|
||||
|
||||
%description -n python3-%{name}
|
||||
%{base_description}
|
||||
|
||||
This package contains the Python 3 files.
|
||||
|
||||
%endif
|
||||
|
||||
%prep
|
||||
%setup -q
|
||||
@ -89,51 +112,93 @@ This package contains the Python 3 files.
|
||||
|
||||
%build
|
||||
pys=""
|
||||
%if %{python2_enabled}
|
||||
pys="$pys python2"
|
||||
%endif
|
||||
%if %{python3_enabled}
|
||||
pys="$pys python3"
|
||||
%endif
|
||||
for py in $pys; do
|
||||
mkdir $py
|
||||
cd $py
|
||||
# When -DCMAKE_BUILD_TYPE is set to Release, the tests in %%check segfault.
|
||||
# When -DCMAKE_BUILD_TYPE is set to Release, the tests in %%check might segfault.
|
||||
# However, we do not ship any binaries, and therefore Debug
|
||||
# build type does not affect the results.
|
||||
%cmake .. -DCMAKE_BUILD_TYPE=Debug -DPYTHON_EXECUTABLE=%{__python3} -DPYBIND11_INSTALL=TRUE -DUSE_PYTHON_INCLUDE_DIR=FALSE %{!?with_tests:-DPYBIND11_TEST=OFF}
|
||||
%make_build
|
||||
cd ..
|
||||
# https://bugzilla.redhat.com/show_bug.cgi?id=1921199
|
||||
%cmake -B $py -DCMAKE_BUILD_TYPE=Debug -DPYTHON_EXECUTABLE=%{_bindir}/$py -DPYBIND11_INSTALL=TRUE -DUSE_PYTHON_INCLUDE_DIR=FALSE %{!?with_tests:-DPYBIND11_TEST=OFF}
|
||||
%make_build -C $py
|
||||
done
|
||||
|
||||
%if %{python2_enabled}
|
||||
%py2_build
|
||||
%endif
|
||||
%if %{python3_enabled}
|
||||
%py3_build
|
||||
%endif
|
||||
|
||||
%if %{with tests}
|
||||
%check
|
||||
%if %{python2_enabled}
|
||||
make -C python2 check %{?_smp_mflags}
|
||||
%endif
|
||||
%if %{python3_enabled}
|
||||
make -C python3 check %{?_smp_mflags}
|
||||
%endif
|
||||
%endif
|
||||
|
||||
%install
|
||||
# Doesn't matter if both installs run
|
||||
%if %{python2_enabled}
|
||||
%make_install -C python2
|
||||
%endif
|
||||
%if %{python3_enabled}
|
||||
%make_install -C python3
|
||||
%endif
|
||||
# Force install to arch-ful directories instead.
|
||||
%if %{python2_enabled}
|
||||
PYBIND11_USE_CMAKE=true %py2_install "--install-purelib" "%{python2_sitearch}"
|
||||
%endif
|
||||
%if %{python3_enabled}
|
||||
PYBIND11_USE_CMAKE=true %py3_install "--install-purelib" "%{python3_sitearch}"
|
||||
%endif
|
||||
|
||||
%files -n python%{python3_pkgversion}-%{name}-devel
|
||||
%files devel
|
||||
%license LICENSE
|
||||
%doc README.rst
|
||||
%{_includedir}/pybind11/
|
||||
%{_datadir}/cmake/pybind11/
|
||||
%{_bindir}/pybind11-config
|
||||
|
||||
%files -n python%{python3_pkgversion}-%{name}
|
||||
%if %{python2_enabled}
|
||||
%files -n python2-%{name}
|
||||
%{python2_sitearch}/%{name}/
|
||||
%{python2_sitearch}/%{name}-%{version}-py?.?.egg-info
|
||||
%endif
|
||||
|
||||
%if %{python3_enabled}
|
||||
%files -n python3-%{name}
|
||||
%{python3_sitearch}/%{name}/
|
||||
%{python3_sitearch}/%{name}-%{version}-py%{python3_version}.egg-info
|
||||
|
||||
%endif
|
||||
|
||||
%changelog
|
||||
* Fri Oct 01 2021 Charalampos Stratakis <cstratak@redhat.com> - 2.7.1-1
|
||||
- Update to 2.7.1
|
||||
- Resolves: rhbz#2000212
|
||||
* Tue Feb 08 2022 Tomas Orsava <torsava@redhat.com> - 2.6.2-4
|
||||
- Add automatically generated Obsoletes tag with the python39- prefix
|
||||
for smoother upgrade from RHEL8
|
||||
- Manually add Provides and Obsoletes for python39-pybind11-devel
|
||||
- Related: rhbz#1990421
|
||||
|
||||
* Mon Jan 18 2021 Tomas Orsava <torsava@redhat.com> - 2.6.1-2
|
||||
- Convert from Fedora to the python39 module in RHEL8
|
||||
- Resolves: rhbz#1877430
|
||||
* Tue Aug 10 2021 Mohan Boddu <mboddu@redhat.com> - 2.6.2-3
|
||||
- Rebuilt for IMA sigs, glibc 2.34, aarch64 flags
|
||||
Related: rhbz#1991688
|
||||
|
||||
* Fri Apr 16 2021 Mohan Boddu <mboddu@redhat.com> - 2.6.2-2
|
||||
- Rebuilt for RHEL 9 BETA on Apr 15th 2021. Related: rhbz#1947937
|
||||
|
||||
* Wed Jan 27 2021 Susi Lehtola <jussilehtola@fedoraproject.org> - 2.6.2-1
|
||||
- Update to 2.6.2.
|
||||
|
||||
* Wed Jan 27 2021 Fedora Release Engineering <releng@fedoraproject.org> - 2.6.1-2
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild
|
||||
|
||||
* Thu Nov 12 2020 Susi Lehtola <jussilehtola@fedoraproject.org> - 2.6.1-1
|
||||
- Update to 2.6.1.
|
||||
|
Loading…
Reference in New Issue
Block a user