From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00 autolearn=ham autolearn_force=no version=3.4.4 X-Google-Thread: a07f3367d7,4cb1f8d1c17d39a8 X-Google-Attributes: gida07f3367d7,public,usenet X-Google-NewGroupId: yes X-Google-Language: ENGLISH,ASCII-7-bit Received: by 10.68.39.100 with SMTP id o4mr28183952pbk.0.1322519794078; Mon, 28 Nov 2011 14:36:34 -0800 (PST) Path: lh20ni32950pbb.0!nntp.google.com!news1.google.com!npeer01.iad.highwinds-media.com!news.highwinds-media.com!feed-me.highwinds-media.com!post02.iad.highwinds-media.com!news.flashnewsgroups.com-b7.4zTQh5tI3A!not-for-mail From: Stephen Leake Newsgroups: comp.lang.ada Subject: Re: Ada 'hello world' for Android; success! (but music player failure) References: <8239efcjuw.fsf@stephe-leake.org> <27491240.406.1322407095677.JavaMail.geo-discussion-forums@yqf20> Date: Mon, 28 Nov 2011 17:35:26 -0500 Message-ID: <82r50ran9t.fsf_-_@stephe-leake.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.2 (windows-nt) Cancel-Lock: sha1:xQSFKb6uEiID73uchc5qcPksmGk= MIME-Version: 1.0 X-Complaints-To: abuse@flashnewsgroups.com Organization: FlashNewsgroups.com X-Trace: 76f004ed40cade029e66118701 Xref: news1.google.com comp.lang.ada:19222 Content-Type: text/plain; charset=us-ascii Date: 2011-11-28T17:35:26-05:00 List-Id: mockturtle writes: > Your post is almost one month old (I did not check the group for a > while), but I wanted to add my congratulations to the thread. Thanks. However, I have now finished writing a first draft of a (very small) music player app, and it does not work. I encountered more bugs, both in jvm2ada and jvm-gnat. I fixed a few, found workarounds for more, and finally got the thing to compile, install, and get past the first "can't find the main class name" error. Now it can't find many methods, so this is _not_ a case of "if it compiles, it will run". Which is a good reason to give up. Another reason to give up; I could not use Ada.Containers (due to more jgnat bugs). So I had to use java.util.LinkedLists. Which is generic, but jgnat doesn't support Java generics, so the linked list just contains java.Lang.Object, and we lose type safety. Another reason to give up; Java interfaces don't map to Ada interfaces (because jgnat was initially designed before Ada interfaces were invented), so using Java interfaces is awkward. At this point, my opinion of GNAT for JVM is: 1) it probably works well if you are writing a stand-alone Ada program that is compiled for the JVM target. 2) it is _not_ good enough when trying to import large amounts of Java code, and export the Ada main programs (as is the case for a real Android app). So I'm giving up, and going back to Java. We need a major player to decide they need secure, reliable apps on Android, so they will pay to fix jgnat. Here's a scenario; convert President Obama to Android (he currently uses a Blackberry), so the Pentagon has to get secure apps for him. :). -- -- Stephe