fix: find_import didn't work properly for classic tools (#2550)

* fix: find_import didn't work properly for classic tools

* ci: fix all files not being checked in style run
This commit is contained in:
Henry Schreiner 2020-10-05 15:31:00 -04:00 committed by GitHub
parent 1411207711
commit 2a2f52201d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
6 changed files with 10 additions and 8 deletions

View File

@ -22,7 +22,7 @@ jobs:
- uses: pre-commit/action@v2.0.0 - uses: pre-commit/action@v2.0.0
with: with:
# Slow hooks are marked with manual - slow is okay here, run them too # Slow hooks are marked with manual - slow is okay here, run them too
extra_args: --hook-stage manual extra_args: --hook-stage manual --all-files
clang-tidy: clang-tidy:
name: Clang-Tidy name: Clang-Tidy

View File

@ -6,4 +6,3 @@ install with ``find_package(pybind11 CONFIG)``. The interface provided in
either case is functionally identical. either case is functionally identical.
.. cmake-module:: ../../tools/pybind11Config.cmake.in .. cmake-module:: ../../tools/pybind11Config.cmake.in

View File

@ -3,5 +3,5 @@ commonmark==0.9.1
recommonmark==0.6.0 recommonmark==0.6.0
sphinx==3.2.1 sphinx==3.2.1
sphinx_rtd_theme==0.5.0 sphinx_rtd_theme==0.5.0
sphinxcontrib-svg2pdfconverter==1.1.0
sphinxcontrib-moderncmakedomain==3.13 sphinxcontrib-moderncmakedomain==3.13
sphinxcontrib-svg2pdfconverter==1.1.0

View File

@ -196,7 +196,7 @@ else()
endif() endif()
# --------------------- pybind11_check_import ------------------------------- # --------------------- pybind11_find_import -------------------------------
if(NOT _pybind11_nopython) if(NOT _pybind11_nopython)
# Check to see if modules are importable. Use REQUIRED to force an error if # Check to see if modules are importable. Use REQUIRED to force an error if

View File

@ -94,8 +94,9 @@ execute_process(
ERROR_VARIABLE _PYTHON_MODULE_EXTENSION_ERR ERROR_VARIABLE _PYTHON_MODULE_EXTENSION_ERR
OUTPUT_STRIP_TRAILING_WHITESPACE) OUTPUT_STRIP_TRAILING_WHITESPACE)
if (_PYTHON_MODULE_EXTENSION STREQUAL "") if(_PYTHON_MODULE_EXTENSION STREQUAL "")
message(FATAL_ERROR "pybind11 could not query the module file extension, likely the 'distutils'" message(
FATAL_ERROR "pybind11 could not query the module file extension, likely the 'distutils'"
"package is not installed. Full error message:\n${_PYTHON_MODULE_EXTENSION_ERR}") "package is not installed. Full error message:\n${_PYTHON_MODULE_EXTENSION_ERR}")
endif() endif()

View File

@ -191,4 +191,6 @@ function(pybind11_add_module target_name)
endfunction() endfunction()
# Provide general way to call common Python commands in "common" file. # Provide general way to call common Python commands in "common" file.
set(_Python PYTHON) set(_Python
PYTHON
CACHE INTERNAL "" FORCE)