Chapter 5. Preparing Dynamic Software Updates

Preparing dynamic software updates requires the complete source code of the original, updateable program, and the complete source code of the newer version of program. Using the original and new versions, a dynamic software update patch can be prepared using the hcu_build_patch.sh patch generator.

The next sections describe in detail how a dynamic software update patch can be prepared. Both the original and newer source code of a program need to be first compiled as if they were being prepared to be updateable (Section 5.1, Section 5.2). This will result in producing whole-program merged versions of the source code, which are needed by the patch generator. A file describing possible execution continuation mappings (Section 5.3.2) from the old version to the new version must also be prepared by the user. The patch generator (Section 5.4) produces the dynamic software update patch in source code, and the patch is then compiled (Section 5.5) to a dynamically loadable shared object.

5.1. Preparing An Updateable Original Version

The original version of the program is prepared as described in Chapter 4. In this example, preparing an updateable vsFTPd version 2.0.4 produces the file vsftpd-2.0.4/vsftpd_comb.c.