Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum. |
Notices |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
|
|
|
04-06-2006, 10:49 PM
|
#1
|
Senior Member
Registered: Feb 2003
Location: Washington D.C
Posts: 2,190
Rep:
|
c++ compilers
I currently am taking a class in C++ and object oriented programming. my class requires borland C++ compiler but I heard that linux has compilers like GCC. Can I use GNU's GCC instead of Borland C++ compilers and be able to pass the class?I am new to programming and would appriciate any comments
|
|
|
04-06-2006, 11:21 PM
|
#2
|
LQ Guru
Registered: Jan 2002
Posts: 6,042
Rep:
|
Yes, you can use gcc compiler. After you install the gcc compiler, install mingw. mingw makes binary files that can run on Windows while only using Linux.
|
|
|
04-06-2006, 11:52 PM
|
#3
|
Senior Member
Registered: Nov 2003
Location: Perth, Western Australia
Distribution: Ubuntu, Debian, Various using VMWare
Posts: 2,088
Rep:
|
There may be some differences between the Borland compiler and g++. However, since you are taking a beginning programming class, you should only be doing the basics, and only ANSI C++, so you shouldnt have any problems.
I hope this helps
--Ian
|
|
|
04-07-2006, 02:32 AM
|
#4
|
LQ Newbie
Registered: Apr 2006
Posts: 10
Rep:
|
Though U can use GCC for using C its better for u to go thro the differences between GCC and Borland by surfing the net
|
|
|
04-07-2006, 03:31 AM
|
#5
|
Senior Member
Registered: Nov 2005
Location: Belgium
Distribution: Red Hat, Fedora
Posts: 1,515
Rep:
|
Gcc and Borland are 2 different compilers, so they may use different options. Compiling on Windows may also be different from compiling on Linux (ie different system libraries) or cross-compiling (like using Mingw to compile Windows stuff on a Linux box).
|
|
|
04-07-2006, 09:53 AM
|
#6
|
Senior Member
Registered: Feb 2003
Location: Washington D.C
Posts: 2,190
Original Poster
Rep:
|
do you have any decent links for programming?
|
|
|
04-10-2006, 03:07 AM
|
#7
|
Senior Member
Registered: Nov 2005
Location: Belgium
Distribution: Red Hat, Fedora
Posts: 1,515
Rep:
|
For C++, Bjarne Stroustrup's book is the considered as "must have".
What do you want to know about programming in C++?
|
|
|
04-10-2006, 03:28 AM
|
#8
|
Member
Registered: Apr 2006
Posts: 39
Rep:
|
metallica, I know in a lot of those first programming classes, you're programming inside of a GUI-based system, and you're not even writing make files and junk (those come in the second round of classes). If you don't really want to fiddle around with VIM or EMACS or something, writing out C++ in what's basically a fancy Windows Notepad, then writing makefiles and compiling like that, then maybe you should stick with the Borland stuff (if it is in fact the graphical, easy to use stuff)
|
|
|
04-10-2006, 03:32 AM
|
#9
|
Member
Registered: Feb 2003
Location: Poole, Dorset, England
Distribution: Fedora Core 5
Posts: 80
Rep:
|
By the sounds of it, he'd be using the Free Borland Compilers to which there is no GUI anyway!?
|
|
|
04-10-2006, 03:53 AM
|
#10
|
Member
Registered: Apr 2006
Posts: 39
Rep:
|
Maybe, but I was started out with Borland JBuilder (for Java), and I didn't really understand what a compiler was. =)
I was thinking thay maybe he had Borland C++ Builder, or whatever they may call it.
|
|
|
04-10-2006, 10:36 AM
|
#11
|
Senior Member
Registered: Feb 2003
Location: Washington D.C
Posts: 2,190
Original Poster
Rep:
|
actually I read the cdrom readme.txt and it is just *.cpp examples. This is my first week in class so I guess of buying a Borland C++ I would prefer to use GCU GCC and take it from there and use mingw to compile stuff for windows. Here is a really stupid question, I just want to get a jump on the class so how would be able to open up a *.cpp file and begin to play with it? I know that I will learn this real soon in the book (online class) but I just wanted to through this out there.
|
|
|
04-10-2006, 11:11 AM
|
#12
|
Member
Registered: Apr 2006
Posts: 39
Rep:
|
what OS are you using?
Regardless, just open it with a text editor, like VIM, or Notepad
|
|
|
04-10-2006, 03:19 PM
|
#13
|
Senior Member
Registered: Feb 2003
Location: Washington D.C
Posts: 2,190
Original Poster
Rep:
|
The instructor has told me that I need to use Visual C++ so I guess I am going to have to use a windows machine unless there is an alternative in linux.
|
|
|
04-10-2006, 03:30 PM
|
#14
|
Member
Registered: Aug 2004
Location: Belgium
Distribution: debian 5.02
Posts: 73
Rep:
|
Hello Metallica,
One important remark : call the compiler with gpp instead of gcc or u will have plenty of mysterious error messages. If u want a library to program in X, consider Qt4 from Trolltech later on. For now it's too complicated, unless classes are making X programs from the beginning. I have Borland C++ version5 for use in Windows : very good stuff indeed !!!
Greetings,
Ronald
|
|
|
04-11-2006, 12:18 AM
|
#15
|
LQ Guru
Registered: Jan 2002
Posts: 6,042
Rep:
|
No need to buy Borland compiler because they give it out for free. Programs compiled with Borland depends on Windows even though it runs in DOS. Visual C++ is a bloated IDE because for a simple "Hello World" program takes up about a megabyte. You do not need Visual C++ for a beginning programming class.
If you use MinGW, the programs will run in DOS or Windows.
A beginning programming C/C++ class will not even touch GUI junk. I have taken a beginning programming C class. All what my instructor/teacher what me to learn is the syntax of the langauge.
|
|
|
All times are GMT -5. The time now is 11:09 PM.
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|