On 01/08/19 4:08 AM, tim Rowledge wrote:
I know that part of this is the result of the rather varied rules different unixes have for storing loaded applications. I don't know very much about those rules - and I really, really, don't want to have to care - so maybe somebody has ideas that might help have a decent shared location for the sources file that would fit? Could we just use vmPath/../ for 'normal' installs?
The *.sources is a read-only file, so it is first searched in VM path where it is protected from accidental modifications and caters to the case when the same VM is used to run images located in multiple directories. It is part of the image, so it could also be placed in the image directory if VM path is not writable (multi-user case). This will get the beginners started quickly with minimum fuss.
For more advanced uses, we could change the image to look for an override, say $SQUEAK_SOURCES, to override these hard-coded paths.
Or, we could place sources file in $HOME/.squeak/ and symlink it from different image directories. This can be added to the launch script.
SQUEAK_SOURCES=.... IMAGE_DIR=... VM_DIR=...
ensure_sources() { test -f $VM_DIR/$1 || \ test -f $IMAGE_DIR/$1 || \ ln -s "$HOME/.squeak/$1" "$IMAGE_DIR/$1" }
ensure_sources $SQUEAK_SOURCES
Regards .. Subbu