Hey folks,
any comments on this issue? I looked a bit further and on OSX, it seems
the JavaApplicationStub always changes the current directory, no matter
what. See also:
http://lists.apple.com/archives/java-dev/2007/Mar/msg00125.html
Given this, I propose to add a wrapper shell script for OSX too. The
idea is that:
1. The wrapper script adds --curdir to the commandline
2. Then calls the JavaApplicationStub
3. The regular startup through the GUI can still use the
JavaApplicationStub directly.
So the wrapper script is only minimal (unlike the Linux version, which
also handles the directory changing and setting up the java
environment). Alternatively, we could remove the JavaApplicationStub
altogether and use a more featured wrapper script like on Linux, but I'm
not sure what JavaApplicationStub does exactly.
On the Windows side, Arduino is started through launch4j. Looking at the
docs, it seems it has a "chdir" configuration that Arduino sets to ".",
meaning change to the directory containing arduino.exe.
http://launch4j.sourceforge.net/docs.html
We could remove the "chdir" from the configuration, which I _think_ will
leave the directory unchanged. However, I suspect that then there is no
longer any way to find out where arduino.exe (and thus find out where
the data files are).
So, I'd propose _also_ adding a wrapper script (.bat?) for Windows,
which essentially does the same thing as the OSX version I just
suggested.
If this sounds ok to people, I might have a go at implementing this
(though I'd have to find someone to test the OSX stuff, since I don't
have that).
Gr.
Matthijs