Closed TailyDuan closed 4 years ago
I met the same question. Do you have any solution? I ran it in the windows @TailyDuan
添加 opencv的路径
swig -I/home/mory/projects/opencv-swig/lib -c++ `pkg-config --cflags opencv` -python interface.i
添加 opencv的路径
swig -I/home/mory/projects/opencv-swig/lib -c++ `pkg-config --cflags opencv` -python interface.i
I am getting the same error even if I use the same command suggested by you.
swig -c++ -python -Iopencv-swig/lib/
pkg-config --cflags opencv
file.i
Try
`pkg-config --cflags opencv`
instead of
pkg-config --cflags opencv
@siriusdemon Yes I did that only. I found the solution that we need to specify the path for opencv2 i.e. /usr/include (in case of linux).
swig -c++ -python -Iopencv-swig/lib -I/usr/include `pkg-config --cflags opencv` file.i
@TailyDuan, has this solution worked for you?
I run swig -I/home/ubuntu64/swig_libs -c++ -python my_lib.i, but show these error, why?
swig -I/home/ubuntu64/swig_libs -c++ -python my_lib.i