problems when building

5 views
Skip to first unread message

Luca Pireddu

unread,
Mar 30, 2010, 6:45:29 PM3/30/10
to mobile-tra...@googlegroups.com
Hello all.

I've built MTE for the first time, using ant and the instructions to
build MTE in Eclipse as a starting point. Several files generated
errors when building because of their encodings, some of which are
incompatible with the encoding used on my system (UTF-8). The
encodings I found where

* ASCII
* ISO-8859
* "Non-ISO extended-ASCII" (not sure what this is, but it's what the
"file" utility spit out)

I'm wondering, does it seem reasonable to adopt a standard encoding
for all project files? How about UTF-8, which is backwards compatible
with ASCII?

Here's a sample error:

[wtk] /home/luca/Projects/bzr-repo/mte/src/com/substanceofcode/tracker/view/InformationCanvas.java:116:
warning: unmappable character for encoding UTF8
[wtk] course = position.course + "�";

Similar errors were generated by:
src/com/substanceofcode/map/MapProvider.java (ISO-8859)
src/com/substanceofcode/tracker/view/InformationCanvas.java (ISO-8859)
src/com/substanceofcode/tracker/view/SplashAndUpdateCanvas.java (ISO-8859)
src/com/substanceofcode/util/Float11.java (Non-ISO extended-ASCII)

I resolved by converting the ISO-8859 files to UTF-8 with iconv, and
eliminating the offending characters in Float11.java.

I also had to add mmapi.jar to the jsr variable in build-eclipse.xml
(as mentioned in this thread:
http://groups.google.com/group/mobile-trail-explorer/browse_thread/thread/5aad7d8cc46c419d/063d62c485d58e3b?lnk=gst&q=mmapi#063d62c485d58e3b).
Finally, I had to remove the .exe extensions on the WTK binaries to
which the build file refers. In the future I will probably submit a
patch for build-eclipse.xml to detect the platform and decide whether
or not to use the .exe extension automatically.

Now ant -f build-eclipse.xml builds the project and starts the WTK emulator.

Luca

Reply all
Reply to author
Forward
0 new messages