good easy to use Free C compiler!!

A

Albert

Interrupt said:
Can someone please point me in the direction of a good easy to use
free C compiler, I’m using Code Blocks now but it crashes all the time
and I’m beginning to lose the plot with it, got enough problems trying
to learn C without having to fight the compiler to!!!

Install Cygwin with gcc, gdb and vim. Use printf statements to
*selectively* print out values of variables and gdb to debug seg
faults/get a stack trace.

According to Dave Taylor in Teach Yourself Unix in 24 Hours, First
Edition, "...you will need two hours to learn to use vi." I myself don't
know all the commands of vi let alone vim, but I'm already editing much
quicker than in Notepad, Code::Blocks, Dev-cpp, nano or Kate. That was
just going through usr_01 to usr03.txt in the vimtutor.
 
J

jaysome

Not supporting C89 either doesn't help.

Simon,

Using the "/Za" option with a Microsoft compiler should disable
language extensions and result in compliance with the ANSI C89
standard. Have you found otherwise? If so, please tell.
 
F

Flash Gordon

Keith said:
I thought they had pretty good support for C89.

You are right, it does, with the same caveats as all other compilers. To
get it to follow the standard you have to tell it to follow the standard
(as with all the other compilers), and there may be some bugs (as with
all the other compilers).
 
I

Interrupt

I’ve spent the last few days downloading and trying all to IDE’s
recommended, I’ve settled on Open Watcom which for me as a beginner is
the most intuitive! Also doesn’t crash constantly!
Thanks for the input!!!
 
B

bartc

Simon Connah said:
That is an IDE not a compiler. It uses the GCC compiler.

I'm not entirely sure why people find it so hard to distinguish between an
IDE and a compiler.

I don't think a compiler need be a standalone program, even if they are
frequently designed that way.

So if an IDE can compile programs (however it does so), then I guess it can
be considered a compiler, with some extra facilities.
 
C

Conor

Reviving this thread somewhat, I'd just like to ask a few questions
about the available free C compilers for C development under Windows.
Yes, it's a little Windows specific all of a sudden but at least it's
still C programming!

I do like the command line BTW. The last IDE I used was Turbo C 2.01,
but that 10 years of Unix for you. Type "make", go get coffee/sleep.
Computers are too fast now, can't sleep during compiles any more :-(

Ok, there's the free Borland 5.5 compiler, which is a little dated
perhaps, especially in regards to the Windows API. However, nothing
prevents me from writing my own header files, copying from the Win
SDK! It has the distinct advantage of being standalone, with no
install (just a 8MB zip file). Set your PATH and off you go. You do
end up doing a static link against Borland CRT.

Visual C++ 2005/2008 Express is free but you need to download the
Windows SDK to do anything useful like Win32 programming. Ruddy great
big install. Looks like you can dynamically link with a sole
dependency on msvcrt.dll, but you can't. There's MSVCR70.DLL,
MSVCR80.DLL and MSVCR90.DLL and they can sod off if they think I'm
distributing them. So static link again. Sigh.

{
Note Visual C++ 2008 creates an unnecessary dependency by calling
GetSystemWindowsDirectoryW. So compiled executables will not run on
Windows 98SE or ME. Now, I don't worry too much about 98SE given its
age but I'll be damned to hell if I'll let Microsoft dictate to me
what markets I may not access. It's one thing if I'm knowingly using
calls that 98SE didn't have but it's quite another to have MS
arbitrarily remove that market (however big it is). Rant over.
Sorry :)
}

The earlier free Visual C++ compilers were non-optimising. Which I
thought was rather mean.

Erm. I'm not all that sure about Borland's CRT library and threading.
MS no longer has a single threaded CRT anymore, just libcmt.... I
worry about things like errno biting me in the ass some day. Someone
somewhere mentioned that everything is threaded on WinXP and the CRT
should be written to assume that (or maybe I'm losing it.)

I haven't used Watcom C or MinGW, but maybe those are better. I guess
I have a irrational liking for Borland given my love of Turbo C all
those years ago! I keep feeling it would be nice to dynamic link
against msvcrt.dll, given that it is always there, but perhaps I'm
being irrational and static linking is just fine. If Sysinternals can
produce single 100KB executables that do magic and don't need a
massive redistributable, then so can I. Maybe...

Cheers,

Conor.
 
C

Conor

Have a look at Pelles C - fairly full implementation of C99 and a good,
lightweight IDE.

Ah yes, based on the LCC compiler. A friend picked bits out of it at
some point when he needed a resource editor. I think he still ended up
compiling with Borland 5.5 though. Hard to change habits!

At least there are choices out there which is a good thing.
 
J

jamm

Well If you're talking free IDE + compiler, I like CodeBlocks.
VisualStudio/Express is a pretty nice tool though.

--
*From the 1966 TV series:*
Robin: You can't get away from Batman that easy!
Batman: Easily.
Robin: Easily.
Batman: Good grammar is essential, Robin.
 
C

Conor

Well, you can always write your own version of crt ;)
Or you don;t have to use crt at all ;)

It has been done by developers, presumably those with a lot of time on
their hands! I won't be rushing to the top of that particular queue
though! You need to write startup code at the very minimum.
VC++ can read typelibs like headers, which is good, too.
Win SDK you have to download if you want 64 bit compiler
and useful tools.

Yes, like MIDL and the typelib stuff if you want to do COM development
(IDispatch). Which I might at some point so I should go get the SDK
anyway I guess.

Conor.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,995
Messages
2,570,225
Members
46,815
Latest member
treekmostly22

Latest Threads

Top