Shared Libraries 

It can happen that an exe file integrated in the app container, such as a Command Line Tool, brings its own Shared Libraries with it and needs them for its execution. Such Shared Libraries can be integrated into the app container and made known to the Linux system when the app is installed/started.

Note: Libraries of (new) components are dynamically loaded by specifying their full path when loading the component into the firmware. Therefore, they do not have to be specified as "sharedlibs" in the app description.

Necessary additions in the app description file

If the optional JSON object "sharedlibs" is present in the app description file, the AppManager knows that Shared Libraries are in the app.

The "sharedlibs" entry is structured as follows:

"sharedlibs":
   [
       {
           "libpath" : "<path to shared lib 1 object file>"
       },
       {
           "libpath" : "<path to shared lib 2 object file>"
       },
       {
           "libpath" : "<path to shared lib [N] object file>"  
       }
   ]

"libpath":

Specifies the local path to the Shared Library in the app container.

Steps to create and integrate Shared Libraries

If own developed Shared Libraries are needed, create the Shared Libraries:

  • Program your Shared Libraries (or Library).
  • If necessary, license your Shared Libraries.
  • Build your Shared Libraries using the PLCnext Software Development Kit.
  • Test your Shared Libraries.

Integrate the Shared Libraries to your app:

  • The files you are going to need are the binary files of your Shared Libraries. If they are on your PC, it is easiest to copy them with an SFTP client into your app folder on the controller.
  • Add the app part "sharedlibs" (“Necessary additions in the app description file”) for the Shared Libraries in your app description file.

Specifications and restrictions

  • An app container can optionally contain several Shared Libraries.
  • The names of the activated Shared Libraries within a container or within all activated apps must not occur more than once.
  • Shared Libraries are activated/deactivated when you start/stop the app.
  • The activation/deactivation of a Shared Library app part does not require a restart of the firmware.

Demo Shared Libraries App

(currently not available)

Support in the firmware

The Shared Libraries app part type is supported in the firmware from version 19.3.0.

 

 

 


•  Web browser recommendation: Chrome/Edge 88 or newer, Firefox ESR 90 or neweror Safari  • 
• Published/reviewed: 2023-11-17 • Revision 14 •