Find the answer to your Linux question:
Results 1 to 4 of 4
Hi I have recently bought an eee PC for the purposes of doing C and C++ programming in Linux. I am a novice Linux user and the information I have ...
  1. #1
    Just Joined!
    Join Date
    Mar 2009
    Posts
    2

    New eee PC - compiler issues

    Hi

    I have recently bought an eee PC for the purposes of doing C and C++ programming in Linux. I am a novice Linux user and the information I have found on the net so far has been over my head.

    I cannot get any programs to compile and was hoping for some help in finding out why. Whenever I try to compile a C++ program I get an error message "cpp: error trying to exec 'cc1plus': execvp: No such file or directory'.

    I have also tried to compile C programs using commands cc, gcc, g++ and cpp. The only output I get is when I use the cpp command and the only thing that happens is that the code is printed to the screen (like a cat command) but the file is not compiled.

    Attached is a screen shot of my version info for my new machine.
    Attached Images Attached Images

  2. #2
    Linux Guru waterhead's Avatar
    Join Date
    Jul 2004
    Location
    Franklin, Wisconsin
    Posts
    4,577
    Do you have gcc and g++ installed? You can install them with apt.
    Paul

    Please do not send Private Messages to me with requests for help. I will not reply.

  3. #3
    Just Joined!
    Join Date
    Mar 2009
    Posts
    2
    Hi Paul,

    I am assuming that it was installed, but how do i check if it is installed. I am new to Linux, what is an apt?

  4. #4
    Linux Guru waterhead's Avatar
    Join Date
    Jul 2004
    Location
    Franklin, Wisconsin
    Posts
    4,577
    Developmental programs usually are not installed by default. You can install them if you select them during the initial installation of Linux.

    Apt is the install/update utility program. It is run through terminal commands. For more info, enter these commands
    Code:
    apt --help
    Code:
    man apt
    You can install these programs individually, with these commands. You have to have root privileges to do this, so use the su command. The root password will remain hidden.
    Code:
    su
    Password: <enter root password>
    Code:
    apt-get install gcc
    Code:
    apt-get install g++
    Paul

    Please do not send Private Messages to me with requests for help. I will not reply.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •