On Wed, Apr 20, 2011 at 9:43 AM, David Doria <daviddo...@gmail.com> wrote:

> On Wed, Apr 20, 2011 at 9:04 AM, David Cole <david.c...@kitware.com>
> wrote:
> > If you are setting the CXX compiler, you should also probably be setting
> the
> > C compiler.
> >
> > I always use environment variables to do this:
> >
> >   export CC=/home/doriad/src/gcc-4.5.2/bin/gcc/gcc
> >   export CXX=/home/doriad/src/gcc-4.5.2/bin/gcc/g++
> >   ccmake ../../src/ITK
> >
> > If that still doesn't work, then inspect the contents of the file
> > CMakeFiles/CMakeError.log to see what the actual errors are, and post
> them
> > here. (CMakeFiles/CMakeOutput.log may also have relevant results in
> it...)
> >
> >
> > HTH,
> > David C.
>
> Hm, so there is no 'gcc' executable after I built gcc. Gcc's configure
> says: "The following languages will be built:
> c,c++,fortran,java,objc". So I'm assuming it should be there? I tried
> setting the ITK C compiler to g++ as well, but no dice.
>
> In CMakeFiles/CMakeError.log
>
> of course it says:
>
> CMakeCCompilerId.c:2:3: error: #error "A C++ compiler has been selected for
> C."
>
> The executables that were built are:
>
> [doriad@daviddesktop gcc]$ find . -executable -type f
> ./as
> ./cc1-dummy
> ./jcf-dump
> ./cc1
> ./jvgenmain
> ./gcj
> ./config.status
> ./lto-wrapper
> ./cc1plus-dummy
> ./cc1plus
> ./cc1obj-dummy
> ./gcov
> ./nm
> ./cpp
> ./f951
> ./xgcc
> ./cc1obj
> ./gfortran
> ./collect2
> ./collect-ld
> ./jc1
> ./g++
> ./gcov-dump
>
> Any thoughts?
>
> Thanks,
>
> David
>


Sounds like you must have gotten errors when you built gcc...

Pore through the log of what happened during the gcc build maybe?

Are you building gcc from source, or using some package manager to build it
for you? (MacPorts, something else?)
_______________________________________________
Powered by www.kitware.com

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Follow this link to subscribe/unsubscribe:
http://www.cmake.org/mailman/listinfo/cmake

Reply via email to