Index: README ================================================================== --- README +++ README @@ -52,10 +52,16 @@ specify the directory containing the documentation files. Before using it, you must create a file called .heromeshrc in your home directory; you may use default.heromeshrc to start with, and then customize it as you wish. + +If compiled with "./compile p" then it is installed as "bin/heromesh" +(relative to the current directory, which should be the directory where +the source files are) and installs "bin/current.heromeshrc" as well (if it +does not already exist; it won't overwrite an existing file). In this case, +it can be used as a "portable app" mode. === Documentation === Free Hero Mesh includes the following documentation files (plain text): Index: compile ================================================================== --- compile +++ compile @@ -1,11 +1,17 @@ #!/bin/bash -- set -e +if test "$1" = "p"; then + echo 'Using portable mode.' + test -d bin || mkdir bin + export EXE=bin/heromesh + test -e bin/current.heromeshrc || cp default.heromeshrc bin/current.heromeshrc +fi test -f CFLAGS || echo xxx > CFLAGS test "xx$CFLAGS" = "x`cat CFLAGS`" || rm bindings.o class.o picture.o function.o exec.o game.o edit.o picedit.o || true echo "x$CFLAGS" > CFLAGS -test "x$EXE" = "x" && EXE=~/bin/heromesh +test "x$EXE" = "x" && export EXE=~/bin/heromesh echo 'Flags: ' "$CFLAGS" echo 'Target filename: ' "$EXE" test instruc -nt instruc.h && node instruc.js > instruc.h test instruc.js -nt instruc.h && node instruc.js > instruc.h test names.js -nt names.h && node names.js > names.h