Building GNAT on MUSL, now with ARM 64-bit support

30/04/18, modified 17/09/18

An update on the previous version. I thought that version already supported ARM 64-bit processors1, but unfortunately it did not.

So another debug cycle ensued. As it turned out the code that is used to generate aarch64 instructions had a wrong #ifdef line. Once this bug was fixed, the next bug cropped up and with a mean time between a possible fix and the correct fix taking days, the whole exercise took weeks2. After a week or so, the cross-compiler seemed to work. Next, I wanted to compile a native compiler for the target platform with the help of the cross-compiler. Again, time was spent, and fortunately a compiler could be build and after some more work3 it can build the FFA code on aarch64 systems.

Some small things are left to do; the scripts can do with some clean-up and the native compilers are not tarred to a file, finally, I want to try little-endian ppc.

Update:The native compilers do not contain the gprbuild tool, this is still on the todo list.

  1. Build scripts designate these processors with 'aarch64'. []
  2. Try the fix, start a rebuild which will take an hour if unsuccessful and 3 if successful, look at it after half a day or more, see that it failed, try something else, etc. etc. []
  3. It also needs an assembler and a C library []

3 Responses to “Building GNAT on MUSL, now with ARM 64-bit support”

  1. This appears to be namewise and bitwise- identical to the previously-posted tarball!

  2. ave1 says:

    Thank you for the observation!, I seem to have copy-pasted a bit too quickly (I checked the links but did not read)

    I updated the post

  3. [...] Ave1's GNAT version 2018-04-30 adding support for ARM architectures. [...]

Leave a Reply