lain-bootleg-bootleg
lain-bootleg-bootleg copied to clipboard
install & asset finding logic
Currently there are no CMake install rules for the binary & assets, I think that would be a good addition.
For that, some more sophisticated logic for finding the assets at runtime would be needed, so Unixoid-style FHS (or Darwin-style bundles ig) can work without cding to some weird directories. For example
- Maybe search in a path passed via an envvar or switch first in case the normal mechanism needs to be overridden
- Then in
$CWD/resso Windows-style packaging (exe in a dir, assets next to it) works as expected - Then in a user-specific path (somewhere under
$XDG_DATA_HOMEmaybe, related to #3) - Then in a system path - CMake has a
CMAKE_INSTALL_DATADIR/CMAKE_INSTALL_FULL_DATADIRfor that sort of stuff when usingGNUInstallDirsto specify install paths (dunno if it handles bundles on Darwin ottomh though) (or some other path configured at build-time) - Also, some graceful error handling would help so missing assets don't lead to a SIGSEGV.