Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 27 Jun 2022 23:39:50 +0200
From:      Mario Marietto <marietto2008@gmail.com>
To:        freebsd-python@freebsd.org
Subject:   pkg-static: Unable to access file /usr/ports/graphics/opencv/work/stage/usr/local/lib/python3.9/site-packages/cv2/__init__.py:No such file or directory
Message-ID:  <CA%2B1FSijerhVxvo45YHboXVTz04eL6SXaYecXobkAAGDqQ4mGbg@mail.gmail.com>

index | next in thread | raw e-mail

[-- Attachment #1 --]
Hello.

I'm playing a little bit with sikulix. I'm trying to learn how it works
because I want to automatize the daily tasks of my FreeBSD 13.1-RELEASE.
So,as soon as I have implemented my first "click on the image"
function,I've got the error message that you see below and I don't know how
to fix it :











*[error] RunTime:loadLib: libopencv_java430.so (failed) probably dependent
libs missing: Can't load library:
/root/.Sikulix/SikulixLibs/libopencv_java430.so [error] Save your work,
correct the problem and restart the IDE! [error] see:
https://github.com/RaiMan/SikuliX1/wiki/macOS-Linux:-Support-Libraries-for-OpenCV-4
<https://github.com/RaiMan/SikuliX1/wiki/macOS-Linux:-Support-Libraries-for-OpenCV-4>;
TERMINATING: problem with native library: libopencv_java430.so [error]
script [ click_image ] stopped with error in line 1 [error]
java.lang.ExceptionInInitializerError (
java.lang.ExceptionInInitializerError ) [error] --- Traceback --- error
source first line: module ( function ) statement 1: main ( <module> )
click("1656348124939.png") [error] --- Traceback --- end --------------*


At this point I tried to compile opencv from ports enabling JAVA like this :

mario@marietto:/usr/ports/graphics/opencv # make (enabled JAVA)
mario@marietto:/usr/ports/graphics/opencv # make install


but it didn't work :


.........

===>  Installing for opencv-4.5.5_7
===>  Checking if opencv is already installed
===>   Registering installation for opencv-4.5.5_7
pkg-static: Unable to access file
/usr/ports/graphics/opencv/work/stage/usr/local/lib/python3.9/site-packages/cv2/__init__.py:No
such file or directory
pkg-static: Unable to access file
/usr/ports/graphics/opencv/work/stage/usr/local/lib/python3.9/site-packages/cv2/config-3.9.py:No
such file or directory
pkg-static: Unable to access file
/usr/ports/graphics/opencv/work/stage/usr/local/lib/python3.9/site-packages/cv2/config.py:No
such file or directory
pkg-static: Unable to access file
/usr/ports/graphics/opencv/work/stage/usr/local/lib/python3.9/site-packages/cv2/gapi/__init__.py:No
such file or directory
pkg-static: Unable to access file
/usr/ports/graphics/opencv/work/stage/usr/local/lib/python3.9/site-packages/cv2/load_config_py2.py:No
such file or directory
pkg-static: Unable to access file
/usr/ports/graphics/opencv/work/stage/usr/local/lib/python3.9/site-packages/cv2/load_config_py3.py:No
such file or directory
pkg-static: Unable to access file
/usr/ports/graphics/opencv/work/stage/usr/local/lib/python3.9/site-packages/cv2/mat_wrapper/__init__.py:No
such file or directory
pkg-static: Unable to access file
/usr/ports/graphics/opencv/work/stage/usr/local/lib/python3.9/site-packages/cv2/misc/__init__.py:No
such file or directory
pkg-static: Unable to access file
/usr/ports/graphics/opencv/work/stage/usr/local/lib/python3.9/site-packages/cv2/misc/version.py:No
such file or directory
pkg-static: Unable to access file
/usr/ports/graphics/opencv/work/stage/usr/local/lib/python3.9/site-packages/cv2/python-3.9/cv2.cpython-39.so:No
such file or directory
pkg-static: Unable to access file
/usr/ports/graphics/opencv/work/stage/usr/local/lib/python3.9/site-packages/cv2/utils/__init__.py:No
such file or directory
*** Error code 1

Stop.
make[1]: stopped in /usr/ports/graphics/opencv
*** Error code 1

Stop.
make: stopped in /usr/ports/graphics/opencv


I suppose that the error depends on the fact that I'm using python 3.8 as
default but it wants python 3.9 ?

mario@marietto:/home/marietto # python --version
Python 3.8.13

What's the right procedure to upgrade it (if I should do this,because I'm
not sure). I tried to remove python38,but I think that it's not the right
choice :

mario@marietto:/home/marietto # pkg remove python38

Checking integrity... done (0 conflicting)
Deinstallation has been requested for the following 580 packages (of 0
packages in the universe)...

but If I don't remove python38 from packages,I can't compile python 3.9
from ports. So,what ?

take also in consideration that I have installed some python packages :

mario@marietto:/home/marietto # pkg remove python39

Checking integrity... done (0 conflicting)
Deinstallation has been requested for the following 6 packages (of 0
packages in the universe):

Installed packages to be REMOVED:
       asciidoc: 10.2.0
       py39-cython: 0.29.30_1
       py39-numpy: 1.22.4_1,1
       py39-setuptools: 62.1.0_1
       python: 3.9_3,2
       python39: 3.9.13

Number of packages to be removed: 6

but I haven't removed them,since I'm not sure if I should do this. I don't
know what to do.

-- 
Mario.

[-- Attachment #2 --]
<div dir="ltr">Hello.<br>
<br>
I&#39;m playing a little bit with sikulix. I&#39;m trying to learn how it works 
because I want to automatize the daily tasks of my FreeBSD 13.1-RELEASE.
 So,as soon as I have implemented my first &quot;click on the image&quot; 
function,I&#39;ve got the error message that you see below and I don&#39;t know 
how to fix it :<br>
<br>
<b>[error] RunTime:loadLib: libopencv_java430.so (failed) probably dependent libs missing:<br>
Can&#39;t load library: /root/.Sikulix/SikulixLibs/libopencv_java430.so<br>
[error] Save your work, correct the problem and restart the IDE!<br>
[error] see: <a href="https://github.com/RaiMan/SikuliX1/wiki/macOS-Linux:-Support-Libraries-for-OpenCV-4" target="_blank" class="gmail-link gmail-link--external" rel="nofollow ugc noopener">https://github.com/RaiMan/SikuliX1/wiki/macOS-Linux:-Support-Libraries-for-OpenCV-4</a><br>;
TERMINATING: problem with native library: libopencv_java430.so<br>
[error] script [ click_image ] stopped with error in line 1<br>
[error] java.lang.ExceptionInInitializerError ( java.lang.ExceptionInInitializerError )<br>
[error] --- Traceback --- error source first<br>
line: module ( function ) statement <br>
1: main (  &lt;module&gt; )     click(&quot;1656348124939.png&quot;)<br>
[error] --- Traceback --- end --------------</b><br>
<div><br></div><div><br></div><div>At this point I tried to compile opencv from ports enabling JAVA like this :<br></div><div><br></div><div><div class="gmail-bbCodeBlock gmail-bbCodeBlock--screenLimited gmail-bbCodeBlock--code"><div class="gmail-bbCodeBlock-content" dir="ltr">
		<pre class="gmail-bbCodeCode" dir="ltr"><code>mario@marietto:/usr/ports/graphics/opencv # make (enabled JAVA)
mario@marietto:/usr/ports/graphics/opencv # make install</code></pre>
	</div>
</div><br>
but it didn&#39;t work :<br>


	
	


<div class="gmail-bbCodeBlock gmail-bbCodeBlock--screenLimited gmail-bbCodeBlock--code">
	<div class="gmail-bbCodeBlock-title"></div>
	<div class="gmail-bbCodeBlock-content" dir="ltr">
		<pre class="gmail-bbCodeCode" dir="ltr"><code><br>.........

===&gt;  Installing for opencv-4.5.5_7
===&gt;  Checking if opencv is already installed
===&gt;   Registering installation for opencv-4.5.5_7
pkg-static: Unable to access file /usr/ports/graphics/opencv/work/stage/usr/local/lib/python3.9/site-packages/cv2/__init__.py:No such file or directory
pkg-static: Unable to access file /usr/ports/graphics/opencv/work/stage/usr/local/lib/python3.9/site-packages/cv2/config-3.9.py:No such file or directory
pkg-static: Unable to access file /usr/ports/graphics/opencv/work/stage/usr/local/lib/python3.9/site-packages/cv2/config.py:No such file or directory
pkg-static: Unable to access file /usr/ports/graphics/opencv/work/stage/usr/local/lib/python3.9/site-packages/cv2/gapi/__init__.py:No such file or directory
pkg-static: Unable to access file /usr/ports/graphics/opencv/work/stage/usr/local/lib/python3.9/site-packages/cv2/load_config_py2.py:No such file or directory
pkg-static: Unable to access file /usr/ports/graphics/opencv/work/stage/usr/local/lib/python3.9/site-packages/cv2/load_config_py3.py:No such file or directory
pkg-static: Unable to access file /usr/ports/graphics/opencv/work/stage/usr/local/lib/python3.9/site-packages/cv2/mat_wrapper/__init__.py:No such file or directory
pkg-static: Unable to access file /usr/ports/graphics/opencv/work/stage/usr/local/lib/python3.9/site-packages/cv2/misc/__init__.py:No such file or directory
pkg-static: Unable to access file /usr/ports/graphics/opencv/work/stage/usr/local/lib/python3.9/site-packages/cv2/misc/version.py:No such file or directory
pkg-static: Unable to access file /usr/ports/graphics/opencv/work/stage/usr/local/lib/python3.9/site-packages/cv2/python-3.9/cv2.cpython-39.so:No such file or directory
pkg-static: Unable to access file /usr/ports/graphics/opencv/work/stage/usr/local/lib/python3.9/site-packages/cv2/utils/__init__.py:No such file or directory
*** Error code 1

Stop.
make[1]: stopped in /usr/ports/graphics/opencv
*** Error code 1

Stop.
make: stopped in /usr/ports/graphics/opencv</code></pre>
	</div>
</div></div><div><br></div><div>I suppose that the error depends on the fact that I&#39;m using python 3.8 as default but it wants python 3.9 ?</div><div><br></div><div><span style="font-family:monospace"><span style="color:rgb(0,0,0);background-color:rgb(255,255,255)">mario@marietto:/home/marietto # python --version
</span><br>Python 3.8.13<br>
</span></div><div><span style="font-family:monospace"><br></span></div><div>What&#39;s the right procedure to upgrade it (if I should do this,because I&#39;m not sure). I tried to remove python38,but I think that it&#39;s not the right choice :</div><div><br></div><div><span style="font-family:monospace"><span style="color:rgb(0,0,0);background-color:rgb(255,255,255)">mario@marietto:/home/marietto # pkg remove python38
</span><br></span></div><div><span style="font-family:monospace"><br></span></div><div><span style="font-family:monospace">Checking integrity... done (0 conflicting)
<br>Deinstallation has been requested for the following 580 packages (of 0 packages in the universe)...</span></div><div><span style="font-family:monospace"><br></span></div><div>but If I don&#39;t remove python38 from packages,I can&#39;t compile python 3.9 from ports. So,what ? <br></div><div><br></div><div><span style="font-family:monospace"><span style="color:rgb(0,0,0);background-color:rgb(255,255,255)">take also in consideration that I have installed some python packages :<br></span></span></div><div><span style="font-family:monospace"><span style="color:rgb(0,0,0);background-color:rgb(255,255,255)"><br></span></span></div><div><span style="font-family:monospace"><span style="color:rgb(0,0,0);background-color:rgb(255,255,255)">mario@marietto:/home/marietto # pkg remove python39         </span><br></span></div><div><span style="font-family:monospace"><br></span></div><div><span style="font-family:monospace">Checking integrity... done (0 conflicting)
<br>Deinstallation has been requested for the following 6 packages (of 0 packages in the universe):
<br>
<br>Installed packages to be REMOVED:
<br>        asciidoc: 10.2.0
<br>        py39-cython: 0.29.30_1
<br>        py39-numpy: 1.22.4_1,1
<br>        py39-setuptools: 62.1.0_1
<br>        python: 3.9_3,2
<br>        python39: 3.9.13
<br>
<br>Number of packages to be removed: 6<br>
</span></div><div><span style="font-family:monospace"><br></span></div><div><span style="font-family:monospace">but I haven&#39;t removed them,since I&#39;m not sure if I should do this. I don&#39;t know what to do.<br></span></div><div><br></div><div>-- <br><div dir="ltr" class="gmail_signature" data-smartmail="gmail_signature">Mario.<br></div></div></div>
help

Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CA%2B1FSijerhVxvo45YHboXVTz04eL6SXaYecXobkAAGDqQ4mGbg>