Results 1 to 2 of 2

Thread: Error with gcc compiler

  1. #1
    Join Date
    Jul 2010
    Beans
    1

    Error with gcc compiler

    hey folks,

    I had some serious problems with my ubuntu 10.4 partitions yesterday and fixed them using gparted - check partition.

    But since then I cannot use gcc anymore (?):

    name@machine:~/$ gcc
    gcc: no input files
    name@machine:~/$ gcc test.c
    gcc: error trying to exec 'cc1': execvp: No such file or directory

    I searched the forum and people suggested to reinstall multiple packages: cpp, gcc, build-essential, cpp-4.4

    I reinstalled them but the error stays...

    Thx for your reply, the tree stump

  2. #2
    Join Date
    Sep 2011
    Beans
    2

    Smile Re: Error with gcc compiler

    Hi

    This seems to happen for people once in a while... For me purging and reinstalling didn't help... However I used:

    Code:
    gcc -print-search-dirs
    -which showed me that gcc only searched for cc1 in:
    Code:
    /usr/lib/i386-linux-gnu/gcc/i686-linux-gnu/4.5.2/
    and not in:
    Code:
    /usr/lib/i386-linux-gnu/gcc/i686-linux-gnu/4.5/
    This could easily be solved by a nice symlink:
    Code:
    cd /usr/lib/i386-linux-gnu/gcc/i686-linux-gnu/
    sudo ln -s 4.5/ 4.5.2
    -and everything worked again!
    Last edited by LinuxMorten; September 20th, 2011 at 10:33 AM. Reason: correction

Bookmarks

Posting Permissions

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