[CMake] No +DD64 compiler option for HP-UX on IA64
Won Kim
wondawg3 at gmail.com
Sun Jun 27 21:37:02 EDT 2010
Hello,
I've been trying to set up CMake on different build machines.
Everything went perfectly on Linux machines (32/64bit),
however, CMake gave me the following error message during configuration on
HP IA64.
-- The C compiler identification is GNU
-- Check for working C compiler: /usr/local/bin/gcc
-- Check for working C compiler: /usr/local/bin/gcc -- broken
CMake Error at
.../cmake-2.8.1-HP-UX-9000_785/share/cmake-2.8/Modules/CMakeTestCCompiler.cmake:52
(MESSAGE):
The C compiler "/usr/local/bin/gcc" is not able to compile a simple test
program.
It fails with the following output:
Change Dir: /data5/obmtp4/tmp/ofsrc5_build/CMakeFiles/CMakeTmp
Run Build Command:/usr/local/bin/gmake "cmTryCompileExec/fast"
/usr/local/bin/gmake -f CMakeFiles/cmTryCompileExec.dir/build.make
CMakeFiles/cmTryCompileExec.dir/build
gmake[1]: Entering directory
`/data5/obmtp4/tmp/ofsrc5_build/CMakeFiles/CMakeTmp'
/data5/obmtp4/cmake-2.8.1-HP-UX-9000_785/bin/cmake -E
cmake_progress_report
/data5/obmtp4/tmp/ofsrc5_build/CMakeFiles/CMakeTmp/CMakeFiles 1
Building C object CMakeFiles/cmTryCompileExec.dir/testCCompiler.c.o
/usr/local/bin/gcc -o CMakeFiles/cmTryCompileExec.dir/testCCompiler.c.o -c
/data5/obmtp4/tmp/ofsrc5_build/CMakeFiles/CMakeTmp/testCCompiler.c
Linking C executable cmTryCompileExec
/data5/obmtp4/cmake-2.8.1-HP-UX-9000_785/bin/cmake -E cmake_link_script
CMakeFiles/cmTryCompileExec.dir/link.txt --verbose=1
/usr/local/bin/gcc CMakeFiles/cmTryCompileExec.dir/testCCompiler.c.o -o
cmTryCompileExec -Wl,+s,-E,+nodefaultrpath -Wl,+b/usr/lib
* ld: Can't find library or mismatched ABI for -lc*
Fatal error.
So, I added the following two lines in HP-UX.cmake file to solve the
problem:
SET(CMAKE_C_COMPILER /usr/bin/cc) ==> Replace C compiler
SET(CMAKE_C_FLAGS "+DD64") ==> Added +DD64 compiler option for
IA64.
After inserting these lines, CMake could compile the sample C source file.
To compare with other HP machine I tried the same in HP RISC machine, and it
compiled fine without those lines.
Is there anything that I need to set up before compiling on HP IA64 machine?
Also, I wonder why CMake would not add "+DD64" compile option automatically.
If possible, I would prefer the way that CMake add necessary compile options
by itself.
Thank you very much,
Won
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.cmake.org/pipermail/cmake/attachments/20100628/277400b5/attachment.htm>
More information about the CMake
mailing list