As discussed in a previous article, i’m actually working on a project written in Ada about concurrent and distributed systems. My focus is to analyze and expand a working example with a few requirements like GTK+, XML and distribution support.
Since i feel more comfortable using my mac, i tried (and succeded) in getting a working environment using X11 and the latest GNAT distribution. Now i’m going to explain how to add XML support to Ada and how to install PolyOrb.
XMLAda
First, get the XMLAda package from the AdaCore website in the x86_64-darwin section. Then, untar the package with:
$ tar xf AdaCore.tar
$ cd XMLAda/
$ tar xf xmlada-gpl-3.2.1-src.tgz
$ cd xmlada-3.2.1-src/
After this, it’s the usual way:
$ ./configure --prefix=/usr/local/xmlada
$ make
$ sudo make install
The prefix option points to the directory where the library will be installed.
When you add XMLAda to your Ada project dependencies you will notice that at link time Gps won’t find the library because it searches for it inside /usr/local/lib.
To solve this problem, you can either change the path in Gps or add a symbolic link to point to the correct place with:
$ ln -s /usr/local/xmlada/lib/xmlada /usr/local/lib/xmlada
PolyOrb
As stated by the OW2 Consortium, “PolyORB aims at providing a uniform solution to build distributed applications; relying either on industrial-strength middleware standards such as CORBA, the Distributed System Annex of Ada 95, distribution programming paradigms such as Web Services, Message Oriented Middleware (MOM), or to implement application-specific middleware.”
To get it to work on mac you have to download the x86_64-linux version from the GNAT 2010 distribution at AdaCore and untar the package with:
$ tar xf AdaCore.tar
$ cd PolyORB/
$ tar xf polyorb-gpl-2010-src.tgz
$ cd polyorb-gpl-2010-src
And build it with usual procedure:
$ ./configure
$ make
$ sudo make install
Note: the compilation of PolyOrb takes a lot of time, around 25 minutes on my MacBook Dual Core 2Ghz.
That’s it!

Par brutto in italiano, eh?!
bravo Andrea!
Non può non essere in inglese per un informatico
e sono troppo pigro per mantenerlo in due lingue..