Skip to content

Commit

Permalink
bump pybind11 to 2.11.1 (#1172)
Browse files Browse the repository at this point in the history
* bump pybind11 to 2.11.1

* Bump minimum cmake to 3.27

* Bump pybind11 version in root CMakeLists.txt

* Remove unused define from cmake_args in setup.py

* minor updates to Python build files
  • Loading branch information
molpopgen committed Aug 18, 2023
1 parent 5346072 commit ecc0e27
Show file tree
Hide file tree
Showing 6 changed files with 12 additions and 9 deletions.
6 changes: 3 additions & 3 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
cmake_minimum_required(VERSION 3.15)
cmake_minimum_required(VERSION 3.27)
project(fwdpy11)

set(CMAKE_CXX_EXTENSIONS OFF)
Expand All @@ -15,8 +15,8 @@ endif()

find_package(pybind11)
message(STATUS "Found pybind11: ${pybind11_VERSION}")
if(${pybind11_VERSION} VERSION_LESS '2.10.0')
message(FATAL_ERROR "pybind11 version must be >= '2.10.0'")
if(${pybind11_VERSION} VERSION_LESS '2.11.1')
message(FATAL_ERROR "pybind11 version must be >= '2.11.1'")
endif()
add_definitions(-DPYBIND11_VERSION="${pybind11_VERSION}")

Expand Down
8 changes: 7 additions & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,12 @@
[build-system]
# We need setup.cfg support, which setuptools indtroduced in 30.3.0.
requires = ["setuptools>=30.3.0", "wheel", "setuptools_scm", "pybind11[global]==2.10.0"]
requires = [
"setuptools>=30.3.0",
"wheel",
"setuptools_scm",
"pybind11[global]==2.11.1",
]
build-backend = "setuptools.build_meta"

[tool.setuptools_scm]
write_to = "fwdpy11/_version.py"
Expand Down
2 changes: 1 addition & 1 deletion requirements/conda_minimal_deps.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
intervaltree
pybind11==2.10.0
pybind11==2.11.1
numpy
scipy
attrs>=0.19.2
Expand Down
2 changes: 1 addition & 1 deletion requirements/development.txt
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# NOTE: any pinning should also be coordinated
# with requirements.in and doc/requirements.in
# and may require regenerating the .txt files.
pybind11[global]==2.10.0
pybind11[global]==2.11.1
intervaltree
numpy
scipy
Expand Down
1 change: 0 additions & 1 deletion setup.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@ classifiers =
License :: OSI Approved :: GNU General Public License v3 or later (GPLv3+)

[options]
packages = fwdpy11
zip_safe = False # https://mypy.readthedocs.io/en/latest/installed_packages.html
include_package_data = True
python_requires = >=3.8, <3.12
Expand Down
2 changes: 0 additions & 2 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,6 @@ def build_extension(self, ext):
cmake_args = [
"-DCMAKE_LIBRARY_OUTPUT_DIRECTORY=" + extdir,
"-DCMAKE_ARCHIVE_OUTPUT_DIRECTORY=" + parent + "/lib/",
"-DPYTHON_EXECUTABLE=" + sys.executable,
"-DCMAKE_BUILD=OFF",
]

Expand Down Expand Up @@ -186,5 +185,4 @@ def build_extension(self, ext):
cmdclass={"build_ext": CMakeBuild},
packages=PKGS,
package_data=generated_package_data,
zip_safe=False,
)

0 comments on commit ecc0e27

Please sign in to comment.