Is there a free implementation of Ada? - ada

I looked at the AdaCore site, as well as for A# (which now appears to be owned by AdaCore) and neither appear to be free (although I could have misread something). Any recommendations?

GNAT is available for download here: https://libre.adacore.com/
Look for "GNAT GPL Edition". Not sure why it is so well hidden on that little known site.

Here's a big list of Ada compilers from Open Directory.
The GNU Ada compiler seems to be a more popular one.

GNAT, the GNU Ada implementation: http://www.gnu.org/software/gnat/gnat.html

In the past the ada front end was not packaged with the gcc compiler, but now
the gnat ada compiler is bundled with the gcc compiler when you install most linux distributions. Of course there may be various development libraries that you may need for
your own projects, but the ada front end is there. At least that has been my experience with
debian and ubuntu over the last couple of years.
As for AdaCore, they hide the libre/free version of the gnat ada compiler because they
want to you to buy support; which they can leagally do. However, the gcc compiler is
GPL and is considered open source, which means you can use it for free.

Thomas, you can find the GPL edition of GNAT Adacore Ada framework in http://libre.adacore.com/libre/ and download it from http://libre.adacore.com/libre/download/. Just select Free Software or Academic Development and Build Download Package. The compiler is the option gnat-gpl-2011-i686-pc-mingw32-bin.exe, but there are several additional libraries in the list.

Related

Ada/SPARK: should I be using GNATprove? Where can I find it?

On chapter 22.1 of this Learning Ada, trying to build the examples.
It expects GNATprove to be installed. I am using Ubuntu 18.04 LTS, and I don't see any package that provides it. When I tried to find the main repo, all I found was something at Open Do, and when I click the download button, it appears to be a broken link. Google has little to offer about GNATprove, which is a bit worrying.
I'm new to Ada so I don't really know what I should be using, so if GNATprove is not the right thing, then let me know. I'm also generally expecting a free software toolchain -- is that a reasonable expectation or should I expect to need the "pro" version to see what Ada/SPARK are all about?
GNATprove is the tool used for the formal verification of SPARK, i.e. the provable subset of Ada. If you want to build reliable software and be sure that it does the right thing, it's certainly worth looking at SPARK!
The easiest way to get you hands on SPARK it is to download the GNAT Community Edition from https://www.adacore.com/download which includes GNATprove. The community edition has everything you need to get started wit Ada and SPARK. The main difference of "Pro" is the commercial support.

FreeRTOS + GNAT Ada compiled library

I have a running ARM CortexA9 board with FreeRTOS and I need to add a old and large library written in ADA. I have successfully generated the library and implemented it in the code but I'm struggling with some problems;
First off, what RTS profile are permitted with FreeRTOS between the following ?
zfp
Ravenscar_sfp
Ravenscar_full
You’re proposing to use the GNAT CE 2019 arm-elf compiler to compile the Ada source (-mcpu=cortex-a9 is OK) & link the result with your non-ada code.
I don’t think you could use the AdaCore Ravenscar runtimes that come with that compiler, because they assume they are in charge of the board and run their own tasking/interrupt handling code, not FreeRTOS.
I’ve been maintaining a FreeRTOS-based runtime for some lower-end Cortex-M boards, which does support the Ravenscar profile, quite like the AdaCore sfp runtimes. I don’t think it’d be a huge amount of work to adapt it for your use case.
On the other hand, if your Ada code (and the Ada code it depends on) don’t involve tasking or rely on finalization or exceptions, you may well not need much in the way of runtime support; the zfp runtimes would act as a basis.

How do I install earlier versions of Haskell Platform and switch between them?

I have installed this https://www.haskell.org/platform/#linux-generic Haskell Platform. The problem is it comes with ghc version 8.2.1.
How do I install an earlier version of Haskell Platform so that I can use older, bug-free ghc if I need it?
I can see prior versions available.
https://www.haskell.org/platform/prior.html
So the question remains, how do I make them peacefully coexist on my system?
activate-hs doesn't seem to work, so please tell me how do I switch defferent Haskell Platforms?
Just installing the Haskell platform has updated the links in /usr/local/bin.
So I guess my question is almost solved.
activate-hs should work for the most recent releases of the platform. If it does not, it would be good to know why.
Additionally, you can specify the -w or --with-compiler= in either cabal new-build or cabal configure to give a path to a different ghc to use. That lets you sidestep moving symlinks around (the activate-hs solution) and just pick a ghc to use directly.

Can Julia run on SPARC Solaris?

I like Linux but I have spare capacity on an enterprise class SPARC Solaris platform. I'm just wondering if anyone has tried running Julia there before as it doesn't seem to be a supported OS.
No Julia does not run SPARC Solaris. Supported platforms are x86 (Linux+windows+mac+FreeBSD), ARM and Power8-LE. A SPARC port would not be too difficult, but would need to be done by someone who cares about that platform, and has access to relevant hardware. Unfortunately, that does not describe most of the current developers and contributors.
Not yet but future interest might also come from wanting to use Julia on FPGAs, in combination with open softcores such as Leon -- a SPARC architecture already supported by LLVM.

MPICH2 Installation

Given the availability of a new workstation (Intell Xeon X5690, Windows 7 Professional, 64-bit) for numerical analysis of fluid dynamics models, I find it a shame not engage in parallel computing. So far, I have had no or little experience in this field.
What's the difference between MS-MPI and the latest release of MPICH suitable for Windows? I installed MPICH 1.4.1, but I cannot get a test program to work on Ifort. How am I supposed to compile the program? Do I have to change Ifort configurations somehow to add the libraries of MPICH? Isn't there any good manual available online that could meet my needs?
There's lots of questions in this one question, but it all boils down to one basic question: How do I install MPI on Windows?
MPICH has long since worked on Windows. The last version that supported it was 1.4.1p1 as you've found, but it doesn't have any support anymore from the MPICH developers so if you have trouble, you probably won't find much help. I haven't seen anyone on here step up to help with those questions so far.
MS-MPI is a good option if you want to use Windows. It's free to use and still has support directly from Microsoft. You'll have to read their documentation about how to set everything up correctly, but it's probably the right place to start if you want to use MPI on Windows.
Intel MPI also works on Windows, but it isn't free so you might not want to look at that right now.

Resources