(21.06.2010, 08:48)routeconverter Wrote: (20.06.2010, 17:14)hvdwolf Wrote: The only point is that the built-in gpsbabel currently doesn't work.
Since it's 32 bit on Mac OS X and since it's too old on Linux?
The packed gpsbabel inside the macosx jar as such is fine. When I extracted it (via jar -xf ..) and set the execute bit correctly, it worked fine when specifying it as an external gpsbabel. Please note that this universal 32bit gpsbabel will run on any macosx even if the macosx is 64bit. It will simply run the 32bit version against a separate 32bit kernel extension in a separate 32bit memory space. It functions diffferently for C-programs as for java jars/classes.
The linux version should be 100% statically compiled. A dynamically linked version will most certainly fail as soon as it is run on another version as the distribution version it was compiled on.
It will definitely fail on another distribution no matter the version.
As mentioned: A completely statically built version might run on all linux versions as long as the kernel (file and memory) calls haven't changed too much, but I wouldn't worry about that. I will see if I can compile such a statically linked version.
(21.06.2010, 08:48)routeconverter Wrote: (20.06.2010, 17:14)hvdwolf Wrote: As long as it doesn't work I think a notification in the FAQs or on the download page would be welcome to new users to tell them to download/install gpsbabel.
Did it: http://www.routeconverter.de/faqs/gpsbabel/en
Nice, but for OSX it is not correct (Sorry, OSX differs on this point).
When using "linux ported" binaries you do that either from MacPorts or from Fink or you download the source and compile it yourself in which case it is installed in /usr/local/bin (default prefix). In case you use MacPorts, binaries are installed in /opt/local/bin. In case you use Fink, binaries are installed in /sw/bin.
Note that both MacPorts and Fink will set the binary paths in the PATH environment upon installation.
Linux might differ as well. Some distributions install "foreign" programs in /usr/local/bin. If you compile yourself it will definitely be installed in /usr/local/bin.
(That's why I mentioned some posts ago: "If you need info please let me know..")
To my humble opinion, the most "fail safe" way for linux would be (I think):
- the binary defined within the options dialog
- try to find the binary via the PATH, so without a path specified (/usr/bin, /usr/sbin, /usr/local/bin are
always in the PATH statement)
- run the internal gpsbabel
The most "fail safe" way for macosx would be (I think):
- the binary defined within the options dialog
- try to find the binary via the PATH, so without a path specified (/usr/bin, /usr/sbin, /opt/local/bin, /sw/bin are
always in the PATH statement. /usr/local/bin should be in the PATH.)
- run the internal gpsbabel
This would be a more "universal" approach for all possible configurations on osx and linux.
Off course, you could make it even more "fail safe" by testing all the mentioned paths after the "- try to find the binary via the PATH ..", but that would be more work on your side trying to compensate for users who messed up their environment (don't touch it if you don't know what you do).