31 lines
1.5 KiB
Plaintext
31 lines
1.5 KiB
Plaintext
The main goal of this investigation is to organize shared data and code across
|
|
multiple binary files. This is especially important for something like a base
|
|
layer that will be used in a program that supports hot-reloading or plugins.
|
|
|
|
Each isolated example in this repository explores a way to set up the base
|
|
layer, plugin, and main program.
|
|
|
|
The examples:
|
|
|
|
*_linking - Concrete examples for each operating system showing how to
|
|
setup and use various types of dynamic linking. In these
|
|
the "base" layer uses load-time linking, the "plugin" layer uses
|
|
run-time linking, and the "main" layer acts as the executable that
|
|
binds it all together into a process.
|
|
|
|
*_before_main - Concrete examples for each operating system showing how to
|
|
create a function that runs before main.
|
|
|
|
clang - Build scripts that build the concrete examples with clang instead of
|
|
cl or gcc. In each case clang can build the same source. In some cases
|
|
clang on windows can even build the linux source. The build lines for
|
|
clang that replace cl require some modification. The build lines for
|
|
clang that replace gcc have the exact same flags and inputs.
|
|
|
|
xlist - My prefered solution to the problem posed in the investigation which
|
|
relies only on run-time linking & before-main execution. It uses an
|
|
xlist to manage the maintenance burden of run-time linking, and a
|
|
basic outline of the abstracted form of the base layer.
|
|
|
|
|