Rejigger lib path
[WebThing.git] / WebThing
index 7d14c4b..25cddfd 100755 (executable)
--- a/WebThing
+++ b/WebThing
@@ -1,7 +1,11 @@
 #!/bin/sh
 
-export LD_LIBRARY_PATH=plugins:$LD_LIBRARY_PATH
+export WEBTHING_HOME=`dirname "$0"`
 
-echo $LD_LIBRARY_PATH
+# We change directories because we don't have a proper configuration
+# architecture, yet.
+cd "$WEBTHING_HOME"
 
-exec mono main.exe
+export LD_LIBRARY_PATH=$WEBTHING_HOME/lib:$WEBTHING_HOME/plugins:$LD_LIBRARY_PATH
+
+exec mono $WEBTHING_HOME/WebThingMain.exe "$@" >/dev/null 2>&1