cmake finds wrong python libs

前端 未结 4 2031

I\'m new to CMake and have trouble understanding some usage concepts.

I\'m calling a python script from a c++ program:

#include 
...
Py_I         


        
4条回答
  •  栀梦
    栀梦 (楼主)
    2021-02-04 03:21

    You can setup manually on cmake libs \usr\share\cmake-3.2.3\Modules\FindPythonLibs.cmake:

    set(PYTHON_LIBRARY "\\usr\\lib\\python2.7")
    set(PYTHON_INCLUDE_DIR "\\usr\\include\\python2.7")
    

提交回复
热议问题