简体   繁体   中英

Can't use make and cmake on windows

I am trying to compile ogre on windows 7 x64. It's only the sample tutorial.

The environnement var are:

BOOST_INCLUDEDIR=C:\OgreSDK\boost
BOOST_LIBRARYDIR=C:\OgreSDK\boost\lib
BOOST_ROOT=C:\OgreSDK\boost
OGRE_HOME=C:/OgreSDK
Path=...C:\Python34\;C:\Python34\Scripts...C:\Program Files (x86)\Git\cmd;C:\Program Files (x86)\Git\bin;C:\Program Files (x86)\GnuWin32\bin;C:\MinGW\bin;C:\Python34\;C:\Python34\Scripts...;C:/OgreSDK/bin/;C:\MinGW\bin

You can see the full ones here https://gist.github.com/vinz243/bf1a2465215c0fb906b0

The repo is here https://github.com/vinz243/ogre-test

So the output was:

Compiling the C compiler identification source file "CMakeCCompilerId.c" failed.
Compiler: C:/MinGW/bin/gcc.exe 
Build flags: 
Id flags: -c

The output was:
1

Multiple times https://github.com/vinz243/ogre-test/blob/master/CMakeFiles/CMakeError.log

Note that I must append

//CXX compiler.

CMAKE_CXX_COMPILER:FILEPATH=C:/MinGW/bin/g++.exe

//C compiler.

CMAKE_C_COMPILER:FILEPATH=C:/MinGW/bin/gcc.exe

// Make program
CMAKE_MAKE_PROGRAM:FILEPATH=C:/MinGW/bin/make.exe

On each build b/c each build throws an error otherwise

There were several problems

  • In the PATH, the Git bin/ folder was set, and it was conflicting w/ cmake
  • CmdEr was making trouble, too. Stock cmd worked
  • Cmd must be ran as admin

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM