Route all module interaction through dispatch
A module is addressed by name and command string, and nothing else. Typed API access handed a caller a pointer into the callee's function table, which meant compiling against that module's struct layout — a build-time dependency between modules that the design does not permit. Removing it also removes the manifest, the table magic constant, and the table size field, which existed only to describe and validate those tables. Load validation is now three steps: reserved contract symbols resolve, the minimum-version handshake passes, and the version and description probes return well-formed values. The contract is four reserved symbols, and a module's interface is the command vocabulary it documents. Documentation is brought in line, and artifacts are named exactly: libdpm-core.so for the library, <dpm/core.h> for the header, the dpm binary for the command-line tool.
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
# Building libdpm-core and the dpm binary
|
||||
# Building libdpm-core.so and the dpm binary
|
||||
|
||||
## Prerequisites
|
||||
|
||||
@@ -22,7 +22,7 @@ cmake --build <build-dir>
|
||||
Artifacts land in:
|
||||
|
||||
```
|
||||
<build-dir>/bin/dpm the CLI
|
||||
<build-dir>/bin/dpm the dpm binary
|
||||
<build-dir>/lib/libdpm-core.so the library
|
||||
<build-dir>/modules/info.so the bundled info module
|
||||
```
|
||||
@@ -39,7 +39,7 @@ This runs the API test binary (which exercises the full load-time validation mat
|
||||
|
||||
### Manual Execution
|
||||
|
||||
The build tree plus the test fixtures form a complete self-contained environment; no installation is required. Point the CLI at local paths with its override flags:
|
||||
The build tree plus the test fixtures form a complete self-contained environment; no installation is required. Point the `dpm` binary at local paths with its override flags:
|
||||
|
||||
```
|
||||
<build-dir>/bin/dpm --config-dir ./tests/fixtures/conf --module-path <build-dir>/modules info version
|
||||
@@ -79,10 +79,10 @@ cmake --install <build-dir>
|
||||
Omit `-DCMAKE_INSTALL_PREFIX=/usr` at configure time for a `/usr/local` install. Under the install prefix this installs:
|
||||
|
||||
```
|
||||
bin/dpm the CLI
|
||||
bin/dpm the dpm binary
|
||||
lib/libdpm-core.so the library
|
||||
lib/dpm/modules/info.so the bundled info module
|
||||
include/dpm/ the public header
|
||||
```
|
||||
|
||||
The libdpm-core configuration installs to `/etc/dpm/conf.d/core.conf` regardless of prefix.
|
||||
The library's own configuration installs to `/etc/dpm/conf.d/core.conf` regardless of prefix.
|
||||
|
||||
Reference in New Issue
Block a user