10-24-2023 03:43 AM
On Linux system (Ubuntu20.04) I loaded a library, I can select the correct function after selecting the library path, but when I click OK, it says that I can't find the loaded library, asking me to make sure that the library path is correct, but the library path is correct, I don't know why this error occurred;
I made a series of attempts:(I will package all images, source code and libraries into attachments)
1. The operation performed to load the library is shown in the image:
2.A strange phenomenon
Trying to repeat step 1, I successfully loaded the compiled library, sometimes with a different name, but the cpp was the same; But after a while, like when I took a nap and my computer wasn't turned off, I went to load the library again and found that the error from step 1 was coming up again, which made me crash😤
3.Remove a library of dds
So I found that libraries compiled from cpp files that don't rely on dds libraries can be loaded no matter how much time has passed; But now I don't know what is the incompatibility of the dds library I compiled that caused the loading failure, because I used the source code to compile the DLL under the window. This makes me feel very frustrated and I don't know how to solve it😢
Solved! Go to Solution.
10-24-2023 04:12 AM
10-24-2023 05:12 AM
All Environment is 64 bit;
10-24-2023 05:31 AM
Thanks guys,I found the answer to the question:
this link: How does LabVIEW's call library function node search for the path to the shared library? - NI
So I copied all the dependencies to /usr/lib and commented out the shared variables to load the libraries.
At this time, I went to load the library has been stable and will not report errors.But when I loaded the full functionality library, it had another error, but it should be related to other problems, I would be very grateful if anyone knew how to fix it.
10-24-2023 08:03 AM
Looks like the API is using mangled function names.
Typical for C++ functions.
The C++ function names contain prototype info, but they're compiler specific.
There (several) compiler options to prevent the export of mangled file names, but google will probably serve you better than me.
10-24-2023 08:09 PM
Thanks for your reply.
I'll look it up.