A restartable process can be compiled using any of the following standard Imakefile macros:
UserprocessTarget
SupprocessTarget
CXXUserprocessTarget
CXXSupprocessTarget
Processes that use dynamic or shared libraries (compiled with Imake macros of the type Dynamic...Target or Shared...Target) are not hot restartable.
Use the following table to link processes that use the API exported by the hot restart feature. Note that all ChorusOS processes are automatically linked with the libc.a library.
API Function |
Library |
---|---|
hrfexec() HR_EXIT_HDL() hrKillGroup() hrGetprocessGroup() |
libc.a |
pmmAllocate() pmmFree() pmmFreeAll() |
pmmlib.a |
The following is an example Imakefile for a restartable process that uses the Persistent Memory Manager API:
SRCS = HR_process.c UserprocessTarget(HR_process_s, HR_process.o, $(NUCLEUS_DIR)/lib/pmm/pmmlib.a) Depend($(SRCS))