Welcome to ZaiNaLe Developer Community-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
1.4k views
in Technique[技术] by (71.8m points)

OpenCV php-opencv symbol lookup error: /usr/lib/php/20190902/opencv.so: undefined symbol: _ZN2cv3dnn14dnn4_v2020090821readNetFromTensorflowEPKcmS3_m

I get this error when attempting to use opencv.so in a php script : symbol lookup error: /usr/lib/php/20190902/opencv.so: undefined symbol: _ZN2cv3dnn14dnn4_v2020090821readNetFromTensorflowEPKcmS3_m

Here is my environnement: Debian 10, php7.4, OpenCV 4.5 correctly installed from the source:

pkg-config --modversion opencv4
4.5.0

And:

python3 -c "import cv2; print(cv2.__version__)"
4.5.1-dev

opencv.so was installed using this: https://github.com/php-opencv/php-opencv/wiki/Installation

apt update && apt install -y wget && 
wget https://raw.githubusercontent.com/php-opencv/php-opencv-packages/master/opencv_4.5.0_amd64.deb && dpkg -i opencv_4.5.0_amd64.deb && rm opencv_4.5.0_amd64.deb && 
wget https://raw.githubusercontent.com/php-opencv/php-opencv-packages/master/php-opencv_7.4-4.5.0_amd64.deb && dpkg -i php-opencv_7.4-4.5.0_amd64.deb && rm php-opencv_7.4-4.5.0_amd64.deb

I enabled the extension in both /etc/php/7.4/cli/php.ini and /etc/php/7.4/apache2/php.ini by adding :

extension=opencv.so

Don't see why I got this error. Searched for hours. Any help welcome.


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)
等待大神答复

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to ZaiNaLe Developer Community-Open, Learning and Share
...