Can not double click to open executable file when using Pylon Basler Camera SDK C++
-
Hi every body, my english not well so i'm using google translator write this post.
I have a project with QtQuick - QML which use Basler SDK C++. The application have done. I want to run this executable file by double click ( not ./myapplication on terminal) but the application don't open.
I develop application on Ubuntu 18.04, Qt 5.9.5, Pylon SDK 5.0.12
I'm sure that i can run my application in terminal without meet any error ( like miss .so, miss libary) and i have add QMAKE_LFLAGS += -no-pie in .pro file too.
Why i know the reason because Basler Libary. Because if i comment (don't use but still include header file) all function or class related to Basler, I can run my app by double click.
Anyone who meet this same problem can suggest me about situation? I'm newbie in desgined app on linux. So i have less experience.
~Thanks all for reading. -
Hi and welcome to devnet,
Did you modify your LD_LIBRARY_PATH environment variable ?
Did you check with ldd where the libraries are loaded from ? -
Yes, I using ldd ./myapplication and i don't see any file .so missing linking.
I have too modify LD_LIBRARY_PATH in ~/.bashrc. So that i can run my app in terminal without error.
I think there are different between run ./ in terminal and double click on excecutable file.
Something i discovery in past 4 days: when i run in terminal, i think this mean bash shell auto setup my environment by read .bashrc. But when i double click direct into executable, another bash shell have active to run. Because this shell is not been activated by terminal, the environment not auto setup for me. So can not open my application and i can't see any error (no terminal show to debug )
Do you have idea for that? . I know in window os have systems environment. So in linux os (ubuntu) have systems environment? The ~/.bashrc only setup when i using terminal default (GNOME, GUI). -
Where did you store these librairies ?
-
Actually, I build pylon (basler libary) from source and i have two location for this. One in ~/Download/pylon-5.0.12-SDK...../pylon5/lib64. This folder have exists when i donwload from their web site. The second in /opt/pylon5/lib64 . This folder appear when i install pylon in to my computer.
Addtion, i have use some libary:- TensorRT in ~/TensorRT/lib/
- OpenCV in /usr/local/lib/
-
Which desktop environment are you using ?
-
One way is to add .conf files in
/etc/ld.so.conf.d/
with the paths to your custom libraries. Then you have to call ldconfig as root. -
@SGaist Thanks you, last week i was verry busy. I already created .conf file in /etc/ld.so.conf.d/ and run ldconfig commanded as root. But i still can't open my app with double click. I have a question about file config. What should be name of the file? Any name i set or specifical name.
-
Can you show your conf file content ?
-
How did you name the file ?
-
Might be a silly question but does /etc/ld.so.conf load the content of the /etc/ld.so.conf.d folder ?