[Mono-list] Cross platform app on usb drive
Sun, 17 Oct 2004 20:18:36 +0300
I have tried something similar, but on Windows only. It worked.
For quick testing you can make use of SUBST'ed drives in Windows.
e.g. You create a drive as
> mkdir D:\env1
> subst S: D:\env
and install Mono onto it.
Now you can 'hide' installed mono by
> Subst S: /D
Let's pretend you make a distribution onto drive Z:
You clean drive Z:
Install mono into Z:\mono
Fix the .BAT files and remove all references to Z: from them.
Now mono works on Z: only by starting \Mono\mono
Copy you application into Z:\YourApp
Put .bat file into root:
To test whether installation is drive-independent (on Windows) you can
use different substed drive letters.
Under Linux it should be easy too:
Let's pretend, that your mountpoint it /mnt/flash (which is the same as
Z:\ under Windows).
Package mono-linux into /mnt/flash/mono-linux.
Put startup .sh script into /mnt/flash
# WD is rooted path to working directory/mount point
if [ -z "$WD" ] ; then WD=`which $0`; fi
if [ "$WD" = "./" ]; then WD=$PWD; fi
$WD/mono-linux/bin/mono $WD/YourApp/YourApp.exe $*