All 17 module CMakeLists repeated the same prologue: language standards, the PS5 SDK header paths, a clang check, the cross-compile triple, the output directory layout and an objcopy strip step. The triple appeared 17 times and the strip block 6 times, each needing manual sync. Add source/cmake/OnionTarget.cmake with onion_module_prologue, onion_output_dirs and onion_strip_debug. Language standards stay opt-in arguments because the loader-side C modules are C17 while the rest are C11, and a shared default would silently downgrade them. Per-module compiler flags are left alone since the modules genuinely differ. Drop IS_SUBPROJECT and IS_CLANG, which were assigned in 11 and 6 modules respectively and never read anywhere. Add CONFIGURE_DEPENDS to the seven source-listing globs that lacked it, so a newly added source file triggers a re-configure instead of being silently omitted from the build. Hoist -DDEBUG onto the shared C flags in the five modules that only passed it to C++, so both languages in a target see the same macros. No .c file keys off DEBUG today, so this changes no behaviour. Compile and link flags were captured from build.ninja before and after: all 132 compile edges and 17 link edges are unchanged except for the intended -DDEBUG addition. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
OnionHEN — source tree
This directory is the CMake project for OnionHEN, a community continuation of etaHEN (LightningMods), licensed under GPLv3.
OnionHEN is based on etaHEN’s open-source release. See the root README for project goals, credits to GoldHEN and etaHEN, and full documentation.
Layout
| Path | Description |
|---|---|
bootstrapper/ |
Main payload bootstrapper |
daemon/ |
Main daemon |
util/ |
Utility daemon (cheats, IPC, …) |
shellui/ |
Toolbox / ShellUI hooks |
unpacker/ |
Payload unpacker |
libhijacker/, libNineS/, libNidResolver/ |
Internal static libs |
include/ |
Shared headers |
common/ |
Shared low-level implementations |
platform/ps5/stubs/ |
PS5 system-library link stubs |
External source and prebuilt dependencies live in the repository-level
third_party/ directory. Downloaded dependency blobs are
cached under .cache/dependencies/; they are never stored in source/.
Repository-side generators and build helpers live in ../tools/.
Build
Requires a Prospero / PS5 payload SDK (PS5_PAYLOAD_SDK) and clang targeting x86_64-sie-ps5.
Full pipeline (preferred) from the repo root:
export PS5_PAYLOAD_SDK=/path/to/ps5-payload-sdk
./scripts/build.sh
Stages external embeds, then shellui → daemon/util → bootstrapper → unpacker.
See ../third_party/README.md and
./scripts/build.sh --help.
Manual CMake:
./scripts/ps5_cmake.sh -S source -B build -G Ninja -DV_FW=0x3000000
cmake --build build
Build products go under build/bin/ and build/lib/ (repo root; gitignored).
Further reading
- Project overview & credits:
../README.md - Writeups:
../docs/ - Upstream lineage: etaHEN · GoldHEN