Open jzy3d opened 2 years ago
Hi Martin,
Apologies for the delay, this is the output that I get on Linux Mint 20 with -Djogamp.debug.IOUtil:
/opt/astropixelprocessor$ ./astropixelprocessor
IOUtil.getTempRoot(): tempX1 , used true
IOUtil.getTempRoot(): tempX3
So it seems that we have a clear permissions issue here somehow. The odd thing is that my application copies other native libs for another dependency into /tmp without any issues. I wrote the code myself to make a folder in a OS temp folder and copy the lib there myself so I can load the native lib with System.Load();
These are copied by my own java code and java will load these native libs at application startup:
mabula@mabula-virtual-machine:/tmp/AstroPPLibsqfJKd$ ls libiconv.so.2.6.1 libRawConverter.so libraw.so.22.0.0
Then after this has been loaded, jogl initialises OpenGL and we crash...
Any clue what is happening from this output?
This is what JOGL accomplished before crashing:
mabula@mabula-virtual-machine:/tmp/jogamp_0000/file_cache$ tree /tmp/jogamp_0000/file_cache/ /tmp/jogamp_0000/file_cache/ ├── jln6835728288635718214 │ ├── jln8087643468882149036 │ └── jln8087643468882149036.tmp ├── jln6835728288635718214.lck └── jln6835728288635718214.tmp
@AstroPixelProcessor found the solution which was discussed on JOGL forum so I copy paste here
After more testing and manipulating permissions of the files in my application, it turns out that the DEB packager that I used is to blame... apparently, the packager sets permissions in the files of my application in such a way that the error occurs. If I don't use the DEB packager, JOGL will run on Linux Mint 20 and also on Ubuntu 20 I can confirm with OpenJDK 17 (Temurin in my case). ...
The DEB packager that I used did NOT set the correct permissions on the jre/lib/jspanwhelper. After installation the permissions were 644 (RW,R,R). A chmod 755 /jre/lib/jspanwhelper fixed the JOGL native lib loading issue completely.
Sorry to have bothered you with this ;-) At least it is again a valuable lesson learnt, at least for me.
So that fully explains the issue I was experiencing. The Java jspawnhelper packaged in my app simply was not allowed to execute the JOGL native libs script.
@jzy3d , excellent, sorry for not having posted it here as well. It was in the back of my mind that I still needed to do that...
It is good to know that the permission denied error code indicated a file permission issue in my installed package.
I would suggest to close this issue since it is solved now.
Reported by @AstroPixelProcessor on Jogamp forum :