libs/split
is a library required to build split applications. When building a split application you must include libs/split
in your loader and your application
Split applications allow the user to build the application content separate from the library content by splitting an application into two pieces:
See split image architecture for the details of split image design.
libs/split
contains the following components
Your split application and loader must initialize the library by calling
#include "split/split.h" void split_app_init(void);
This registers the configuration and commands for split applications.
Your loader can call
int split_app_go(void **entry, int toBoot);
to check whether the split application can be run. A example is shown below
#include "split/split.h" #include "bootutil/bootutil.h" { void *entry; rc = split_app_go(&entry, true); if(rc == 0) { system_start(entry); } }