INTELLIGENT WORK FORUMS
FOR COMPUTER PROFESSIONALS

Log In

Come Join Us!

Are you a
Computer / IT professional?
Join Tek-Tips Forums!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!

*Tek-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

Posting Guidelines

Promoting, selling, recruiting, coursework and thesis posting is forbidden.

Jobs

Getting Started

Getting Started

(OP)
Hi,

This is my first post here. I'm a fairly experienced programmer but I've never used Ada and I'm interested in learning. What low cost or no cost compilers, IDEs, or other tools would you recommend for getting started using a windows pc? Also what Ada books would you guys recommend?

Thanks,

Mike

RE: Getting Started

Try http://www.gnu.org/software/gnat/gnat.html

It has an IDE and and a free compiler.  I'm still trying to get used to Ada after having left it for 30 years.  There are two common versions: 83 and 95.  I'd stick to 95 since it has a C interface and can therefore map to windows routines.

RE: Getting Started

Quote (xwb):


It has an IDE and a free compiler
An IDE? Sure? On the link you posted I didn't see any IDE.

I have installed Ada as a part of my MingW installation. But this is command line version only.

The following commands are available

CODE

$ gnat
GNAT 3.4.5 (mingw-vista special r3) Copyright 1996-2004 Free Software Foundation, Inc.

List of available commands

GNAT BIND               gnatbind
GNAT CHOP               gnatchop
GNAT CLEAN              gnatclean
GNAT COMPILE            gnatmake -f -u -c
GNAT ELIM               gnatelim
GNAT FIND               gnatfind
GNAT KRUNCH             gnatkr
GNAT LINK               gnatlink
GNAT LIST               gnatls
GNAT MAKE               gnatmake
GNAT NAME               gnatname
GNAT PREPROCESS         gnatprep
GNAT PRETTY             gnatpp
GNAT STUB               gnatstub
GNAT XREF               gnatxref

Commands FIND, LIST, PRETTY, STUB and XREF accept project file switches -vPx, -Pprj and -Xnam=val

If you want start with the compiler, then to create an executable from this example program
hello.adb

CODE

-- Hello World in Ada

with Text_IO;
procedure Hello is

begin
  Text_IO.Put_Line("Hello World!");
end Hello;
you need to:

1. Compile

CODE

gnat compile hello.adb
2. Bind

CODE

gnat bind hello
3. Link

CODE

gnat link hello
or simply make all in one step

CODE

gnat make hello.adb

I started to play with Ada some years ago, but I never done something more advanced and I left it.
smile

RE: Getting Started

Yup - it is called GPS (Gnat Programming Studio) and it comes with the Ada 2005 manual.

RE: Getting Started

I normally drop back to command line for compiling and linking. Somehow I find it easier to press up-arrow than click on a button.  Note that your path variable has to be set up correctly otherwise GPS will not work.

RE: Getting Started

(OP)
Thanks guys, I haven't had alot of time to play around with it yet but I downloaded GPS and you're right it looks like there's lots of nice features to the IDE.

Thanks for your help,

Mike

RE: Getting Started

Hi,

just returned myself to have a dabble with Ada.

one of the things that put me off last time was the whole business of wanting an IDE and specifically for me - wanting sensible graphical output - not just text.

I've just found that there is a version 'a#' - which like c# is designed to hook into .NET runtime. which means , i'm hoping, bieng able to generate all the usuall windowsy stuff.... yay...

also, contains and installation to enable visual studio IDE to be used for a# development

see....

http://asharp.martincarlisle.com/

I've only just found this last week - installed and managed to build the examples...... so it works..... but struggled to set a project up from scratch.

so if you can find any tutorials on it I'd be grateful!!

 

RE: Getting Started

It is better if you put the A# stuff as a new thread.

RE: Getting Started

well, i was actually putting it as a reply to the original one that seemed to be asking about suitable environments for developing.

ie. i was suggesting if he was looking for an IDE he might want to try this

RE: Getting Started

Quote (Toe):


i was suggesting if he was looking for an IDE he might want to try this
But, if you want to use A# with IDE you need VS, or isn't it so?  

RE: Getting Started

(OP)
Thanks for the additional info guys. Actually I had heard something about A# and I do have a copy of visual studio. However, the main reason I'm looking into this is because I'm currently prototyping some artificial intelligence stuff in vb.net. Unfortunately that's basically limited to windows and I'm looking around a little at what else is out there if I try to turn this into a real product that might be used for non-windows or embedded type of applications. I'm guessing A# is probably not portable since it probably needs the .net runtime like vb.net does.

I do know c/c++ pretty well but I would rather not use that language because among other things the error checking and array features are terrible. So I've been looking around a little to see if there was something better out there and Ada sounded interesting.

Thanks,

Mike

RE: Getting Started

Quote (MMM3Mike):


...I'm currently prototyping some artificial intelligence stuff in vb.net...
I thought that the AI things will be programmed mostly in LISP smile
But seriously, I would rather use Python or Ruby, or any other similar language, which is multiplatform.

I wonder if you know C++, why you want to use Ada? Do you think, that Ada has something what C++ doesn't have?
It would be easier for you to use Java or C#, than learn the complete different language.

RE: Getting Started

(OP)

Quote:

I thought that the AI things will be programmed mostly in LISP But seriously, I would rather use Python or Ruby, or any other similar language, which is multiplatform.

Those languages may be fine for prototyping but speed will matter if this is going to be turned into a viable program some day and I doubt those languages would up to the task in that regard so I would still have to rewrite the program in something faster anyways. But anyways I know VB.NET better than any of those languages and it pretty much has most of what I need for this.


Quote:

I wonder if you know C++, why you want to use Ada? Do you think, that Ada has something what C++ doesn't have? It would be easier for you to use Java or C#, than learn the complete different language.


I would say the most important feature in a language for this application is good error checking because the algorithms and data structures are extremely complicated to write. In my opinion C++ is total crap in this category. Basically C++ have no overflow checks so if you overrun an array or put a number that is too large into an integer for instance it doesn't complain and keeps running which increases the chances that the error won't be found or the program crashes later on and the source of the error is harder to find.

From what I've read Ada has the most elaborate error checking features of any language. Not only does it do these checks but has other unusual error checking features. Such as you can put range limits on variables and create your own primative and incompatable data types. To be honest I don't know why every statically typed language doesn't copy this capability.

Also C++ doesn't support dynamic arrays directly (about 90% of arrays in my program are dynamic) and you can't set the lower bounds to anything other than zero. Ada does support these things.

I could mention a bunch of other smaller reasons I'm looking into Ada as opposed to C++ but I think you get the idea. Java is probably too slow and consumes too much memory for this. C# = VB.NET in C syntax and neither is crossplatform.

Red Flag This Post

Please let us know here why this post is inappropriate. Reasons such as off-topic, duplicates, flames, illegal, vulgar, or students posting their homework.

Red Flag Submitted

Thank you for helping keep Tek-Tips Forums free from inappropriate posts.
The Tek-Tips staff will check this out and take appropriate action.

Reply To This Thread

Posting in the Tek-Tips forums is a member-only feature.

Click Here to join Tek-Tips and talk with other members!

Resources

Close Box

Join Tek-Tips® Today!

Join your peers on the Internet's largest technical computer professional community.
It's easy to join and it's free.

Here's Why Members Love Tek-Tips Forums:

Register now while it's still free!

Already a member? Close this window and log in.

Join Us             Close