LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 04-11-2006, 11:29 AM   #1
Uh-Oh...Problems
LQ Newbie
 
Registered: Apr 2006
Posts: 16

Rep: Reputation: 0
Compiling Problems


How do you compile a c++ file? i can type it but can't compile
 
Old 04-11-2006, 11:30 AM   #2
nx5000
Senior Member
 
Registered: Sep 2005
Location: Out
Posts: 3,307

Rep: Reputation: 57
Code:
g++ -o file file.cpp
This will compile and link file.cpp
 
Old 04-11-2006, 11:36 AM   #3
Uh-Oh...Problems
LQ Newbie
 
Registered: Apr 2006
Posts: 16

Original Poster
Rep: Reputation: 0
bash:g++: comand not found

what do i do to fix this
 
Old 04-11-2006, 11:39 AM   #4
Nylex
LQ Addict
 
Registered: Jul 2003
Location: London, UK
Distribution: Slackware
Posts: 7,464

Rep: Reputation: Disabled
Install the gcc-g++ package for your distro.
 
Old 04-11-2006, 11:45 AM   #5
reddazz
LQ Guru
 
Registered: Nov 2003
Location: N. E. England
Distribution: Fedora, CentOS, Debian
Posts: 16,298

Rep: Reputation: 77
Quote:
Originally Posted by Nylex
Install the gcc-g++ package for your distro.
gcc-c++ on some distros.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Compiling problems jwilcox09 Linux - Software 7 03-19-2005 07:11 PM
Problems compiling in g++ tsubasa Red Hat 2 03-11-2005 05:53 PM
problems compiling alaios Linux - General 3 02-10-2005 06:00 AM
Problems Compiling Problems With GCC And C++ phnxbn Linux - Software 0 11-02-2004 05:49 PM
Problems installing amsn (TK compiling problems) JNewton Linux - Software 0 05-24-2004 12:07 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 01:47 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration