Annettest 0 Light Poster

Hello all.

I am having problems with compiling code on my Mac (OS X, 10.6.5).

This started happening suddenly when I tried to (1) install f2c using g++, and then (2) compile code including f2c. Now I'm having problems compiling ALL code!

I don't understand the error, and would really appreciate any help. From searching online, I suspect there may be a problem with my gcc compiler. Just in case, I reinstalled Xcode (twice), which installs a new compiler. But I still get the same error.

Here's the error:

cc1plus: error: /include: not a directory
cc1plus: error: /lib: not a directory
make: *** [Task1.o] Error 1

Someone told me to try executing:

gcc -v

to see what directories the gcc I'm using has by default. I got this:

Target: i686-apple-darwin10 Configured with: /var/tmp/gcc/gcc-5659~1/src/configure --disable-checking --enable-werror --prefix=/usr --mandir=/share/man --enable-languages=c,objc,c++,obj-c++ --program-transform-name=/^[cg][^.-]*$/s/$/-4.2/ --with-slibdir=/usr/lib --build=i686-apple-darwin10 --program-prefix=i686-apple-darwin10- --host=x86_64-apple-darwin10 --target=i686-apple-darwin10 --with-gxx-include-dir=/include/c++/4.2.1 Thread model: posix gcc version 4.2.1 (Apple Inc. build 5659)

This person said that my problem is shown by this piece of output:

--with-gxx-include-dir=/include/c++/4.2.1

He said it should read:

--with-gxx-include-dir=/usr/include/c++/4.2.1

and that there must therefore be a problem with the g++ installation on my system.

Is this right? I have reinstalled Xcode twice and don't know what else to do! I would really appreciate any help!

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.