Skip to content

Commit d04aa8b

Browse files
authored
Merge pull request #163 from igaw/build-check-python-devel
build: Detect if Python.h header is present
2 parents 085e60f + 0aa9527 commit d04aa8b

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

libnvme/meson.build

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,8 @@ if want_python != 'false'
1515
python3 = import('python').find_installation('python3')
1616
py3_dep = python3.dependency(required: want_python == 'true')
1717
swig = find_program('swig', required: want_python == 'true')
18-
have_python_support = py3_dep.found() and swig.found()
18+
header_found = cc.has_header('Python.h', dependencies: py3_dep)
19+
have_python_support = py3_dep.found() and swig.found() and header_found
1920
else
2021
have_python_support = false
2122
endif

0 commit comments

Comments
 (0)