This content has moved to a new space on the Internet.

Go to new location

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 a 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 start/stop of a Shared Library app component does not require a restart of the firmware.
  • The names of the activated Shared Libraries within a container or within all activated apps must not occur more than once.

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.

 

 

 


 • Published/reviewed: 2020-06-11 • Revision 35 •