[CMake] mingw crosscompile error: invalid option `macosx-version-min=10.5' ?

Claus Klein claus.klein at arcormail.de
Sat Jan 2 21:30:52 EST 2010


I have problems to crosscompile on MAC-OS for MinGW.
How kann I prevent this strange compiler flag on a Darwin Plattform?

Thanks

Claus
-----------------------------------------

cmake -DCMAKE_C_COMPILER=i386-mingw32-gcc -DCMAKE_CXX_COMPILER=i386- 
mingw32-g++ --debug-trycompile --debug-output - 
DCMAKE_SYSTEM_NAME=Windows-gcc ..
debug trycompile on
Running with debug output on.
-- The C compiler identification is GNU
    Called from: [2]	/opt/local/share/cmake-2.8/Modules/ 
CMakeDetermineCCompiler.cmake
                 [1]	/Users/clausklein/Workspace/cmake/GNU_style/ 
CMakeLists.txt
-- The CXX compiler identification is GNU
    Called from: [2]	/opt/local/share/cmake-2.8/Modules/ 
CMakeDetermineCXXCompiler.cmake
                 [1]	/Users/clausklein/Workspace/cmake/GNU_style/ 
CMakeLists.txt
-- Checking whether C compiler has -isysroot
    Called from: [3]	/opt/local/share/cmake-2.8/Modules/Platform/ 
Darwin-GNU-C.cmake
                 [2]	/opt/local/share/cmake-2.8/Modules/ 
CMakeCInformation.cmake
                 [1]	/Users/clausklein/Workspace/cmake/GNU_style/ 
CMakeLists.txt
-- Checking whether C compiler has -isysroot - yes
    Called from: [3]	/opt/local/share/cmake-2.8/Modules/Platform/ 
Darwin-GNU-C.cmake
                 [2]	/opt/local/share/cmake-2.8/Modules/ 
CMakeCInformation.cmake
                 [1]	/Users/clausklein/Workspace/cmake/GNU_style/ 
CMakeLists.txt
-- Check for working C compiler: /opt/local/bin/i386-mingw32-gcc
    Called from: [2]	/opt/local/share/cmake-2.8/Modules/ 
CMakeTestCCompiler.cmake
                 [1]	/Users/clausklein/Workspace/cmake/GNU_style/ 
CMakeLists.txt
-- Check for working C compiler: /opt/local/bin/i386-mingw32-gcc --  
broken
    Called from: [2]	/opt/local/share/cmake-2.8/Modules/ 
CMakeTestCCompiler.cmake
                 [1]	/Users/clausklein/Workspace/cmake/GNU_style/ 
CMakeLists.txt
CMake Error at /opt/local/share/cmake-2.8/Modules/ 
CMakeTestCCompiler.cmake:50 (MESSAGE):
   The C compiler "/opt/local/bin/i386-mingw32-gcc" is not able to  
compile a
   simple test program.

   It fails with the following output:

    Change Dir: /Users/clausklein/Workspace/cmake/GNU_style/build/ 
CMakeFiles/CMakeTmp



   Run Build Command:/opt/local/bin/gmake "cmTryCompileExec/fast"

   /opt/local/bin/gmake -f CMakeFiles/cmTryCompileExec.dir/build.make
   CMakeFiles/cmTryCompileExec.dir/build

   gmake[1]: Entering directory
   `/Users/clausklein/Workspace/cmake/GNU_style/build/CMakeFiles/ 
CMakeTmp'

   /opt/local/bin/cmake -E cmake_progress_report
   /Users/clausklein/Workspace/cmake/GNU_style/build/CMakeFiles/ 
CMakeTmp/CMakeFiles
   1

   Building C object CMakeFiles/cmTryCompileExec.dir/testCCompiler.c.o

   /opt/local/bin/i386-mingw32-gcc -mmacosx-version-min=10.5 -o
   CMakeFiles/cmTryCompileExec.dir/testCCompiler.c.o -c
   /Users/clausklein/Workspace/cmake/GNU_style/build/CMakeFiles/ 
CMakeTmp/testCCompiler.c


   cc1: error: invalid option `macosx-version-min=10.5'

   gmake[1]: *** [CMakeFiles/cmTryCompileExec.dir/testCCompiler.c.o]  
Fehler 1

   gmake[1]: Leaving directory
   `/Users/clausklein/Workspace/cmake/GNU_style/build/CMakeFiles/ 
CMakeTmp'

   gmake: *** [cmTryCompileExec/fast] Fehler 2





   CMake will not be able to correctly generate this project.
Call Stack (most recent call first):
   CMakeLists.txt:4 (PROJECT)


    Called from: [2]	/opt/local/share/cmake-2.8/Modules/ 
CMakeTestCCompiler.cmake
                 [1]	/Users/clausklein/Workspace/cmake/GNU_style/ 
CMakeLists.txt
-- Configuring incomplete, errors occurred!
macbook-pro:build clausklein$



More information about the CMake mailing list