Skip to content

Commit

Permalink
Merge pull request ceph#27067 from SUSE/wip-fix-38788
Browse files Browse the repository at this point in the history
cmake: remove cython 0.29's subinterpreter check during install

Reviewed-by: Kefu Chai <[email protected]>
  • Loading branch information
tchaikov authored Mar 22, 2019
2 parents 81268eb + 108462e commit 96775c6
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion cmake/modules/Distutils.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,7 @@ function(distutils_add_cython_module name src)
string(REPLACE " " ";" cflags ${CMAKE_C_FLAGS})
list(APPEND cflags -iquote${CMAKE_SOURCE_DIR}/src/include -w)
# This little bit of magic wipes out __Pyx_check_single_interpreter()
# Note: this is reproduced in distutils_install_cython_module
list(APPEND cflags -D'void0=dead_function\(void\)')
list(APPEND cflags -D'__Pyx_check_single_interpreter\(ARG\)=ARG \#\# 0')
set(PY_CC ${compiler_launcher} ${CMAKE_C_COMPILER} ${c_compiler_arg1} ${cflags})
Expand Down Expand Up @@ -80,7 +81,9 @@ function(distutils_install_cython_module name)
install(CODE "
set(ENV{CC} \"${PY_CC}\")
set(ENV{LDSHARED} \"${PY_LDSHARED}\")
set(ENV{CPPFLAGS} \"-iquote${CMAKE_SOURCE_DIR}/src/include\")
set(ENV{CPPFLAGS} \"-iquote${CMAKE_SOURCE_DIR}/src/include
-D'void0=dead_function\(void\)' \
-D'__Pyx_check_single_interpreter\(ARG\)=ARG \#\# 0'\")
set(ENV{LDFLAGS} \"-L${CMAKE_LIBRARY_OUTPUT_DIRECTORY}\")
set(ENV{CYTHON_BUILD_DIR} \"${CMAKE_CURRENT_BINARY_DIR}\")
set(ENV{CEPH_LIBDIR} \"${CMAKE_LIBRARY_OUTPUT_DIRECTORY}\")
Expand Down

0 comments on commit 96775c6

Please sign in to comment.