Welcome Guest ( Log In | Register )



 
Reply to this topicStart new topic
> Programming C In Windows, 2 questions
FirefoxRocks
post Feb 2 2008, 07:58 PM
Post #1


Super Member
Group Icon

Group: [HOSTED]
Posts: 582
Joined: 12-July 06
From: Ontario, Canada
Member No.: 14,464



Ok I usually would use Linux to program because there is a compiler (gcc), but I need to use Windows to program for now because of a few unexplained reasons.

I need to find a compiler for Windows that will compile the C language. I have tried Microsoft Visual C++ Express 2008 but I find it to be way too bulky and hard to use. The command-line compiler is similar to gcc I guess, and it creates executable files for Windows, but the compiler in the actual program compiles C++ but not C for some reason. And it will only compile files in projects, not standalone files. In my opinion, this is not such a great product.

Where can I find a free C compiler for Windows?

Second question: How do you program a GUI? It would be nice to have a GUI to run the program, not just command line stuff.
Go to the top of the page
 
+Quote Post
yordan
post Feb 2 2008, 08:35 PM
Post #2


Way Out Of Control - You need a life :)
Group Icon

Group: [MODERATOR]
Posts: 1,885
Joined: 16-August 05
Member No.: 7,896



the gcc for windows page : http://sourceforge.net/projects/gcw/
Look also here : http://www.delorie.com/djgpp/
and also here : http://gcc.gnu.org/install/binaries.html
and of course http://www.google.fr/search?hl=fr&q=%2...nload&meta=
Go to the top of the page
 
+Quote Post
docduke
post Feb 2 2008, 08:49 PM
Post #3


Member - Active Contributor
Group Icon

Group: [MODERATOR]
Posts: 99
Joined: 8-January 08
Member No.: 27,477



QUOTE(FirefoxRocks @ Feb 2 2008, 12:58 PM) *
I need to find a compiler for Windows that will compile the C language. ...
Second question: How do you program a GUI? It would be nice to have a GUI to run the program, not just command line stuff.
Maybe it's time to consider another language. When Kernighan and Ritchie originally developed C in 1978, it was considered functional, but low level. Now, it is the primary alternative to assembly language. Writing a GUI in it is very error-prone. That is why languages like C++ were developed, but they have complex syntax and a number of "gotchas" that make minor errors very hard to find.

I do almost all my programming in Python. It is free, open source and exceptionally easy to learn. It is also licensed so that you can develop software and sell it commercially -- it is not GPLed. It has many GUI Frameworks that will run on Windows and Linux as well. Install the appropriate Python compiler and extensions on your favorite system, and the code you develop on one system will run on others.

As an illustration of how Python has major advantages, consider the market application TeleChart. It has a "Developer's Kit" which is intended to be accessed from Visual Basic or Visual C++. I am calling it from Python. My program also spawns GUI subwindows using Tkinter and Python megawidgets. Programming a GUI system in Windows (or Linux for that matter) is very complex, because there are literally thousands of system calls, and mastering them is best avoided by using a toolkit that is adapted to your application. Just mastering the toolkit will require days, if not weeks.

Hope this helps! cool.gif


Go to the top of the page
 
+Quote Post
FirefoxRocks
post Feb 2 2008, 09:38 PM
Post #4


Super Member
Group Icon

Group: [HOSTED]
Posts: 582
Joined: 12-July 06
From: Ontario, Canada
Member No.: 14,464



Ok I've heard of Python before but do end-users need to download some software before running the software (something like the .NET Framework)? Also, is it possible to develop FREE software with Python, not just commercial software?

As for C++, don't you need to learn C before learning C++?
Go to the top of the page
 
+Quote Post
docduke
post Feb 3 2008, 03:44 AM
Post #5


Member - Active Contributor
Group Icon

Group: [MODERATOR]
Posts: 99
Joined: 8-January 08
Member No.: 27,477



QUOTE(FirefoxRocks @ Feb 2 2008, 02:38 PM) *
Ok I've heard of Python before but do end-users need to download some software before running the software ...?
Also, is it possible to develop FREE software with Python, not just commercial software?
As for C++, don't you need to learn C before learning C++?
Nothing except what comes with the python installer. It is fully functional as a standalone package. (Of course it requires an operating system.) I just took a look at my Python 2.5 installation. It includes several add-ons, and occupies 49.1 MB on my hard drive. The .msi (compressed) installer of Python 2.5 is just 10.2 MB. If you want one that talks with .NET, IronPython is available. As another alternative, if you want it to generate pure Java code, try Jython.

Of course, you can develop free software. Most of the apps are. But you are not forced to. Python used to have a lot of testimonials from people in various businesses. I just did a search and found one: Industrial Light and Magic. There were so many more, including Google, that the Python website has buried them. The original inspiration behind Python was Guido van Rossum. Python is so important to Google that they have currently employed him to extend the development of Py 2.5 to Py 3.0, including extensions that matter very much to them.

C++ is a "wrapper" for C. Technically, the C++ engine is a macro processor that takes C++ source code as input, and generates C code, which makes use of a lot of functions from libraries that are used specifically to facilitate higher-level operations for which C++ is intended.
Go to the top of the page
 
+Quote Post
yordan
post Feb 3 2008, 12:00 PM
Post #6


Way Out Of Control - You need a life :)
Group Icon

Group: [MODERATOR]
Posts: 1,885
Joined: 16-August 05
Member No.: 7,896



The topic starter post was a question about C programming.
And I think that C programming is sometimes a must for serviceability purposes.
If you write down a program for somebody else, it can be maintained by any guy who learned C programming at school, and there are lots around the world.
So, the first step in a self-training plan should really, in my opinion, starting with C on any hardware you have, Windows if it's your current Operating system.
When talking with other people in your profession life, first say "I propose you to start developping the thing programming in C", and then you add "a nice alternative would be using Python but I must warn you that I will be the only guy able to help you for future software evolution".
Go to the top of the page
 
+Quote Post
docduke
post Feb 3 2008, 07:22 PM
Post #7


Member - Active Contributor
Group Icon

Group: [MODERATOR]
Posts: 99
Joined: 8-January 08
Member No.: 27,477



QUOTE(yordan @ Feb 3 2008, 05:00 AM) *
The topic starter post was a question about C programming.
Point granted. And you provided him with multiple links for compilers, which was his first request. Maybe I should have left it at that...

But the initial post continued with "Second question: How do you program a GUI?..." Have you ever tried constructing a GUI in C? I actually have, but the effort didn't last very long. Many too many misunderstood structures, incorrect pointers, and other things that are very difficult to find in C, unless you're using and IDE with a debugger, and I haven't found one of those that doesn't cost real money.

Have you found a good IDE C system? Your link to DJGPP looks like a possibility, but I've never seen DJGPP before. Is it usable for GUI development?

Another possible choice for C is MinGW. I haven't used it for a decade, but it turned up in the google search you posted, and it certainly has a lot of development behind it.
Go to the top of the page
 
+Quote Post
yordan
post Feb 3 2008, 08:04 PM
Post #8


Way Out Of Control - You need a life :)
Group Icon

Group: [MODERATOR]
Posts: 1,885
Joined: 16-August 05
Member No.: 7,896



QUOTE
Maybe I should have left it at that...

No, no, please no. And, yes, I muss confess, I just wanted to have fun with polemics. However, your way of thinking is very interesting, I thing it's the best way, looking at the future and looking if things are useful instead of seeing if they are used.
and, no, I did not test the C compilers by myself, because I am currently working under AIX so I use gcc or the manufacter's C compiler.
Go to the top of the page
 
+Quote Post
rockarolla
post Feb 5 2008, 08:44 AM
Post #9


Member [ Level 1 ]
Group Icon

Group: Members
Posts: 44
Joined: 5-February 08
Member No.: 28,155



Well under windows the best is to use the old BCC (Borland) C and C++ compiler...I still have a copy of it - it is compact and proved.

Go to the top of the page
 
+Quote Post

Reply to this topicStart new topic

Collapse

> Similar Topics

Topics Topics
  1. How Long Have You Been Programming ?(99)
  2. What Books/e-books/articles Would You Guys Recommend For Beginners To Programming?(1)
  3. A Few Thoughts On Freelance Programming(9)


 



- Lo-Fi Version Time is now: 4th July 2008 - 04:11 PM