taviso / 123elf

A native port of Lotus 1-2-3 to Linux.
1.17k stars 59 forks source link

Search for runtime files in shared directory, to support system-wide installation #68

Closed vrza closed 2 years ago

vrza commented 2 years ago

Check directories relative to the directory the executable is run from.

If runtime files dir is not found under ${exedir}/root/lotus, try searching in ${exedir}/../share/lotus.

This should help support system-wide installation and packaging.

Related to issue #66

vrza commented 2 years ago

@taviso what do you think about this approach?

The location for the default config file can admittedly be nicer, e.g. $PREFIX/share/lotus/123.v10/etc/l123set.cf

vrza commented 2 years ago

Thinking about this further, another approach could be:

Then either:

or:

vrza commented 2 years ago

Discussion related to https://github.com/taviso/123elf/pull/20

taviso commented 2 years ago

Sorry for the slow response - I was focused on the keymap issue. This looks good to me, I rolled back the extract script temporarily because of bug reports, as soon as that returns I think this is good to merge.

vrza commented 2 years ago

No rush. I can create a new branch with the fixed extract file and with the unified filesystem approach described above:

${PREFIX}/bin/123
${PREFIX}/share/lotus/123.v10/
${PREFIX}/etc/l123set.cf
vrza commented 2 years ago

@taviso Created a new PR based on current main branch for your convenience:

https://github.com/taviso/123elf/pull/70

Some files have been moved around (most notably binary is now built as bin/123) so please test on whatever setup you can. I tested on Linux, works for me in both git directory as well as installed system-wide in /usr/local.

taviso commented 2 years ago

Thank you, closing as #70 has now been merged instead.