File tree Expand file tree Collapse file tree 1 file changed +10
-2
lines changed Expand file tree Collapse file tree 1 file changed +10
-2
lines changed Original file line number Diff line number Diff line change @@ -15,7 +15,15 @@ add_test(NAME pywraps2_test COMMAND
1515set_property (TEST pywraps2_test PROPERTY ENVIRONMENT
1616 "PYTHONPATH=$ENV{PYTHONPATH} :${PROJECT_BINARY_DIR} /python" )
1717
18+ execute_process (COMMAND ${Python3_EXECUTABLE} -c
19+ "from distutils import sysconfig; print(sysconfig.get_python_lib(prefix=''))"
20+ OUTPUT_VARIABLE CMAKE_INSTALL_PYLIBDIR_DEFAULT
21+ OUTPUT_STRIP_TRAILING_WHITESPACE)
22+
23+ set (CMAKE_INSTALL_PYLIBDIR "${CMAKE_INSTALL_PYLIBDIR_DEFAULT} "
24+ CACHE STRING "Python site-packages installation directory" )
25+
1826# Install the wrapper.
19- install (TARGETS _pywraps2 DESTINATION ${Python3_SITELIB} )
27+ install (TARGETS _pywraps2 DESTINATION " ${CMAKE_INSTALL_PYLIBDIR} " )
2028install (FILES "${PROJECT_BINARY_DIR} /python/pywraps2.py"
21- DESTINATION ${Python3_SITELIB} )
29+ DESTINATION " ${CMAKE_INSTALL_PYLIBDIR} " )
You can’t perform that action at this time.
0 commit comments