comp.lang.ada
 help / color / mirror / Atom feed
From: jrmarino <dragonlace.cla@marino.st>
Subject: Re: Ada on Android and iOS?
Date: Wed, 22 Jan 2014 15:07:00 -0800 (PST)
Date: 2014-01-22T15:07:00-08:00	[thread overview]
Message-ID: <af418e24-74ea-497b-9be9-ab838a285f34@googlegroups.com> (raw)
In-Reply-To: <d42aabb3-1723-4511-ab46-9b02bece447f@googlegroups.com>

On Wednesday, January 22, 2014 10:35:00 PM UTC+1, coding...@gmail.com wrote:
> 1) How were you able to figure out that you needed to patch GCC? Was it like the build would fail and you had to dig into the GCC code and figure out what the offending code was trying to do? Or was it more like the cross compiler built successfully but the ACATS failed and you dug into the assembler to figure out why it failed? I've never patched a compiler before, nor have I ever taken a compiler course in college.

I decided to try to build an Android cross-compiler after I already had experience "porting" GNAT to FreeBSD, DragonFly, OpenBSD, and NetBSD.  In theory, GNAT was already ported to FreeBSD, but it didn't work (didn't pass a big chunk of ACATS) and certainty x86-64 was a non-starter.  There was no unwind implemented, so zero cost exceptions didn't work.  I had to update targets and change GNAT codes on a per target basis.  It took several iterations and yes, ACATS failures gives a hint what is broken.  By the time I had GNAT working on *BSD, creating an Android target was a logical progression.


> 2) What did you mean when you said "I had to implement the target and some functionality"? Did you have to implement something in the GNAT run time to use an Android sub-system?

With 4.6, there was no android target at all.  With 4.7, it seems like linux-eabi and some flavor of android-eabi was supported, but I don't think that extended to GNAT.  So at the very minimum the android target had to be defined.  But that's not all.  Temp files are handled differently, threading has to be tweaked now, signals needed dedicated code, etc.



> 3) For the target header files, did you use the NDK header files and combined them with newer Linux headers from somewhere else like I did?

see lang/gnatdroid-sysroot
Should be whatever the latest android kit was at the time (2.3, API v9)
http://www.freshports.org/lang/gnatdroid-sysroot/


> I'll take a look at the GNATDroid make files as you suggested. BTW, is there a mailing list or something that you and anyone else involved with GNATDroid
> collaborate on? I think it would be interesting to find out what goes behind the scene of maintaining GNATDroid.

Not anymore.  www.dragonlace.net is occasionally updated.
GNATDroid has been static.  I was hoping somebody would recreate a java interface to all the standard android tools.

You'd probably be interested in Rob Veenker's work: 
http://rveenker.home.xs4all.nl/Ada%20on%20Android.html


John


  reply	other threads:[~2014-01-22 23:07 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-01-22 11:39 Ada on Android and iOS? coding.rascal
2014-01-22 15:43 ` Ludovic Brenta
2014-01-22 16:55 ` jrmarino
2014-01-22 21:35   ` coding.rascal
2014-01-22 23:07     ` jrmarino [this message]
2014-01-23 19:20 ` Dan'l Miller
2014-01-23 20:19   ` Micronian Coder
2014-01-23 23:48 ` Lucretia
2023-06-20 13:31   ` Guillermo Hazebrouck
2023-06-20 17:43     ` Luke A. Guest
2023-06-20 18:08       ` Luke A. Guest
2023-06-20 18:45         ` Luke A. Guest
2023-06-20 19:17       ` Simon Wright
2023-06-20 19:29         ` Luke A. Guest
2023-06-20 19:35         ` Luke A. Guest
2023-06-20 21:27     ` Luke A. Guest
2023-06-21  7:01       ` Guillermo Hazebrouck
2023-06-21  9:06         ` Luke A. Guest
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox