from Hacker News

Gnat 2021 GPL Community Edition Ada 202x compiler released

by berkeleynerd on 5/28/21, 9:22 AM with 81 comments

  • by onox on 5/28/21, 4:47 PM

    To anyone who has a Linux distro and wants to try Ada (2012 on some):

    Debian/Ubuntu: sudo apt install gnat gprbuild

    Arch Linux: sudo pacman -S gcc-ada (get gprbuild from the AUR)

    NixOS: https://github.com/fluffynukeit/adaspark/

    I think it's also available on Fedora IIRC.

    And then go to https://learn.adacore.com/ :)

  • by wiremoons on 5/28/21, 12:56 PM

    Such a shame there is no macOS support for the new '2021 Community Edition', for either x64 or the newer Apple silicon (M1). As ARM is supported for other platforms (even as a cross compiler only) - not sure why the whole Apple community is being missed out in this update, for both x64 and ARM. Guess AdaCore customers don't use Apple products any more, so hence no availability for the Community Edition either..? One of the benefits of using Ada was the great cross platform support for Linux, Window, and previously macOS.
  • by bdavis__ on 5/28/21, 1:06 PM

    to add to the ada saga, RHEL has dropped providing FSF gnat since redhat 6.

    very big loss to not have ada on one of the big linux distributions.

    (build your own! yes, it can be done...)

    edit. fixed wrong word

  • by jeff-davis on 5/28/21, 4:17 PM

    I'm half-obsessed with C interoperability in a variety of languages. I know Ada (or GNAT) has a C FFI, and I've done a little investigation/experimentation but not much.

    Here are a few questions, which probably don't have an answer in the Ada standard but might in specific implementations:

    * Is there a way to declare data layouts to have compatibility with C, similar to #[repr(C)] in rust?

    * Is there a way to catch C++ exceptions?

    * Is there a way to catch C longjmps()?

    * Is there a way to have some kind of custom control over ABI issues, e.g. define custom FFIs to langauges with a different ABI? Or anything close to this? For that matter, does any language have something like this or does it not make sense?

  • by systems on 5/28/21, 1:04 PM

    This is more of a general question With the availability of free languages such as Rust, Clojure, F#, Go, Typescript, Idris, Raku You have a solid option that cover ever possible paradigm and style of programming you may fathom

    Why would any one invest time or effort in a commercial language such as Ada, Eiffel or even Xojo and LispWorks, that require you to pay for Automated test support and what is considered by most standards now basic libraries

    And not only that, the communities are usually tiny and support is probably very limited to the commercial support they provide, and when it comes to languages, languages with big communities, provide infinitely better support than commercial support for proprietary languages or implementations

    The cost of AdaCore is not just the compiler license, its the total ecosystem cost

  • by kitd on 5/28/21, 6:32 PM

    Anyone know why the linux x86 binary is >3 times the size of the Risc or Arm ones?
  • by 13415 on 5/28/21, 10:16 AM

    Just remember that all software you compile with it will be under the GPL.
  • by badhombres on 5/28/21, 12:33 PM

    What’s different?