Thread: ./configure doesn't work in

  1. #1
    Registered User
    Join Date
    Sep 2010
    Posts
    8

    ./configure doesn't work in

    I get the following error when I try to run my program using "sudo ./configure"
    configure: error: C++ compiler cannot create executables

    The log file (renames to config.txt) is attached.

    Any help would be greatly appreciated!

  2. #2
    Nasal Demon Xupicor's Avatar
    Join Date
    Sep 2010
    Location
    Poland
    Posts
    179
    ./configure: line 1759: g++: command not found
    Is everything all right with your GCC installation?

  3. #3
    Registered User
    Join Date
    Sep 2010
    Posts
    8
    How do I check that?

  4. #4
    Registered User
    Join Date
    Sep 2004
    Location
    California
    Posts
    3,268
    Quote Originally Posted by joey2264 View Post
    How do I check that?
    What happens when you run "g++" from the command line?

    Also, you shouldn't run configure as root.
    bit∙hub [bit-huhb] n. A source and destination for information.

  5. #5
    &TH of undefined behavior Fordy's Avatar
    Join Date
    Aug 2001
    Posts
    5,793
    Looks like you have ubuntu. Have you tried "sudo apt-get install build-essential" ?

  6. #6
    Registered User
    Join Date
    Jun 2005
    Posts
    6,815
    Either type "which g++" or "g++ -v" at the command line.

    If either give a message to the effect of "command not found", it means either that gcc is not installed, or - if it is installed - your settings (path, etc) are incorrect so you can't execute it. Since you're getting the message when using sudo to execute the configure script, you need to check those settings are correct for the superuser (root).

    If "g++ -v" gives a few lines describing versions of g++ and (maybe) libraries, then the setup is probably working.
    Right 98% of the time, and don't care about the other 3%.

    If I seem grumpy or unhelpful in reply to you, or tell you you need to demonstrate more effort before you can expect help, it is likely you deserve it. Suck it up, Buttercup, and read this, this, and this before posting again.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. strcmp returning 1...
    By Axel in forum C Programming
    Replies: 12
    Last Post: 09-08-2006, 07:48 PM
  2. getline() don't want to work anymore...
    By mikahell in forum C++ Programming
    Replies: 7
    Last Post: 07-31-2006, 10:50 AM
  3. Why don't the tutorials on this site work on my computer?
    By jsrig88 in forum C++ Programming
    Replies: 3
    Last Post: 05-15-2006, 10:39 PM
  4. fopen();
    By GanglyLamb in forum C Programming
    Replies: 8
    Last Post: 11-03-2002, 12:39 PM
  5. DLL __cdecl doesnt seem to work?
    By Xei in forum C++ Programming
    Replies: 6
    Last Post: 08-21-2002, 04:36 PM