2014-09-06 135 views
3

我在使用cmake ../../ogre_src_v1-8-1在我的build目录中构建OGRE源。我已经研究过很多类似的错误,但没有任何解决方法。Cmake在创建OGRE时出错

CMake的命令上面提到的输出提供了以下的输出:

-- Configuring OGRE 1.8.1 
-- Detected g++ 4.8 

-- Enabling GCC visibility flags 
-- Search path: /home/kamal/Documents/ogre_src_v1-8-1/build/Dependencies;/home/kamal/Documents/ogre_src_v1-8-1/Dependencies;/home/kamal/Documents/ogre_src_v1-8-1/build/../Dependencies;/home/kamal/Documents/ogre_src_v1-8-1/../Dependencies 
-- Looking for ZLIB... 
-- Found ZLIB: optimized;/usr/lib/x86_64-linux-gnu/libz.so;debug;/usr/lib/x86_64-linux-gnu/libz.so 
-- Looking for ZZip... 
-- Found ZZip: optimized;/usr/lib/x86_64-linux-gnu/libzzip.so;debug;/usr/lib/x86_64-linux-gnu/libzzip.so 
-- Looking for FreeImage... 
-- checking for module 'freeimage' 
-- package 'freeimage' not found 
-- Found FreeImage: optimized;/usr/lib/libfreeimage.so;debug;/usr/lib/libfreeimage.so 
-- Looking for FREETYPE... 
-- CMAKE_PREFIX_PATH: /home/kamal/Documents/ogre_src_v1-8-1/build/Dependencies;/home/kamal/Documents/ogre_src_v1-8-1/Dependencies;/home/kamal/Documents/ogre_src_v1-8-1/build/../Dependencies;/home/kamal/Documents/ogre_src_v1-8-1/../Dependencies;/usr/local;/usr/lib/x86_64-linux-gnu 
-- CMAKE_PREFIX_PATH: /home/kamal/Documents/ogre_src_v1-8-1/build/Dependencies;/home/kamal/Documents/ogre_src_v1-8-1/Dependencies;/home/kamal/Documents/ogre_src_v1-8-1/build/../Dependencies;/home/kamal/Documents/ogre_src_v1-8-1/../Dependencies;/usr/local;/usr/lib/x86_64-linux-gnu 
-- Could not locate FREETYPE 
-- Looking for Cg... 
-- checking for module 'Cg' 
-- package 'Cg' not found 
-- Found Cg: optimized;/usr/lib/x86_64-linux-gnu/libCg.so;debug;/usr/lib/x86_64-linux-gnu/libCg.so 
-- Looking for POCO... 
-- checking for module 'POCO' 
-- package 'POCO' not found 
-- Could not locate POCO 
-- Looking for TBB... 
-- Found TBB: optimized;/usr/lib/libtbb.so;debug;/usr/lib/libtbb.so 
-- Looking for TBB_MALLOC... 
-- Found TBB_MALLOC: optimized;/usr/lib/libtbbmalloc.so;debug;/usr/lib/libtbbmalloc.so 
-- Looking for TBB_MALLOC_PROXY... 
-- Found TBB_MALLOC_PROXY: optimized;/usr/lib/libtbbmalloc_proxy.so;debug;/usr/lib/libtbbmalloc_proxy.so 
-- Looking for GLSL_Optimizer... 
-- checking for module 'GLSL_Optimizer' 
-- package 'GLSL_Optimizer' not found 
-- Could not locate GLSL_Optimizer 
-- Looking for HLSL2GLSL... 
-- checking for module 'HLSL2GLSL' 
-- package 'HLSL2GLSL' not found 
-- Could not locate HLSL2GLSL 
-- Looking for OIS... 
-- Found OIS: optimized;/usr/lib/x86_64-linux-gnu/libOIS.so;debug;/usr/lib/x86_64-linux-gnu/libOIS.so 
-- Looking for Softimage... 
-- Could not locate Softimage 
-- Looking for CppUnit... 
-- checking for module 'cppunit' 
-- package 'cppunit' not found 
-- Could not locate CppUnit 
CMake Error at CMake/Utils/MacroLogFeature.cmake:100 (MESSAGE): 

----------------------------------------------------------------------------- 

-- The following REQUIRED packages could NOT be located on your system. 

-- Please install them before continuing this software installation. 

-- If you are in Windows, try passing -DOGRE_DEPENDENCIES_DIR=<path to dependencies> 

----------------------------------------------------------------------------- 

+ freetype: Portable font engine <http://www.freetype.org> 

----------------------------------------------------------------------------- 
Call Stack (most recent call first): 
CMake/Dependencies.cmake:234 (MACRO_DISPLAY_FEATURE_LOG) 
CMakeLists.txt:194 (include) 

-- Configuring incomplete, errors occurred! 

如何解决这个问题?任何帮助将不胜感激!

回答

4

它缺少构建OGRE所需的freetype库。确保系统上安装了lib本身和开发包。 这可能会有所帮助,OGRE wiki页面提供各种linux发行版的先决条件安装说明Install OGRE Prerequisite

+2

我的系统上安装了'libfreetype6'和'libfreetype6-dev'。 – 2014-09-06 14:06:30

+0

好,但CMake没有找到它。你可以手动为libs和include目录设置变量,我发现通过'cmake-gui'这样做会更快,尤其是在你摆弄的时候。 – lazycoder 2014-09-06 16:28:21

+0

谢谢。使用'cmake-gui'帮助更具体地理解它。 – 2014-09-06 16:37:19