This is the mail archive of the
gcc-help@gcc.gnu.org
mailing list for the GCC project.
Re: Learning C language
- From: Andrew Haley <aph at redhat dot com>
- To: deraustin at waitrose dot com
- Cc: gcc-help at gcc dot gnu dot org
- Date: Mon, 29 Dec 2008 20:52:48 +0000
- Subject: Re: Learning C language
- References: <847E4B79-427A-4336-BF57-9CE01CF6D57A@waitrose.com>
deraustin@waitrose.com wrote:
> Some twenty-five or more years ago I studied C language for a brief
> period using Hisoft's Lattice C on an Atari ST computer. Now, retired,
> with time available and with an Intel Apple iMac computer, I am keen to
> renew this study.
>
> From recent reading my best course would seem to be to use GCC and,
> towards this end, I have acquired Brian Gough's book 'An Introduction to
> GCC' and, to refresh my memory, Kerninghan and Ritchie's 'The C
> Programming Language (ANSI edition)', having lost the copy of the
> earlier edition I once had.
>
> Lattice C came complete with compiler and all necessary system
> libraries and header files etc and, using the Lattice C manual and K
> and R, I was able to start writing what were to me quite complicated
> programs fairly quickly; to my regret most of this is now lost and
> forgotten. My problem is that with the C language compilers, libraries
> etc that are available now by downloads and otherwise, I am not at all
> sure which I should acquire in order to, first, begin my studies with
> GCC, and then to gradually progress to more advanced levels.
>
> I would be grateful for any help you can give me on how, and from
> whence, I can acquire the appropriate compiler program, system files and
> the standard and other libraries, indeed all I need to start building
> and running C programs.
>
> At 86 and with three young grandsons, all knowledgeable about
> computers (although not yet into programming) my aim is to learn enough
> to surprise them by sending them stand-alone, executable programs on
> disk for them to run on their PCs.
That's great.
> Any advice you can give me towards this end, including guides,
> tutorials, books etc, which might be of help would be much appreciated.
First, you need to install Xcode. According to http://developer.apple.com/TOOLS/xcode/,
Xcode is packaged on the DVD with every copy of Mac OS X.
Xcode includes GCC. Install that first, and see how you get on.
I'm not a Mac developer so I won't be able much to help you with
Mac-specific issues -- for that you might be better off asking a
Mac forum. But by all means ask.
Andrew.