首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >使用cmake:未能找到OpenImageIO (缺失: OPENIMAGEIO_LIBRARY OPENIMAGEIO_INCLUDE_DIR)编译周期问题

使用cmake:未能找到OpenImageIO (缺失: OPENIMAGEIO_LIBRARY OPENIMAGEIO_INCLUDE_DIR)编译周期问题
EN

Stack Overflow用户
提问于 2019-12-26 15:06:09
回答 1查看 3.5K关注 0票数 1

我想在我的Ubuntu18.04上构建和运行循环渲染引擎。我确保安装了循环存储库页(https://developer.blender.org/diffusion/C/)中提到的所有关键依赖项。

问题是,当我运行cmake时,我得到了以下输出:

代码语言:javascript
复制
sebastian@sebastian-N551JX:~$ cd Program\ Files/cycles/
sebastian@sebastian-N551JX:~/Program Files/cycles$ cd build
sebastian@sebastian-N551JX:~/Program Files/cycles/build$ cmake ..
CMake Deprecation Warning at CMakeLists.txt:36 (cmake_policy):
  The OLD behavior for policy CMP0043 will be removed from a future version
  of CMake.

  The cmake-policies(7) manual explains that the OLD behaviors of all
  policies are deprecated and that a policy should be set to OLD only under
  specific short-term circumstances.  Projects should be ported to the NEW
  behavior and not rely on setting a policy to OLD.


-- The C compiler identification is GNU 7.4.0
-- The CXX compiler identification is GNU 7.4.0
-- Check for working C compiler: /usr/bin/cc
-- Check for working C compiler: /usr/bin/cc -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Detecting C compile features
-- Detecting C compile features - done
-- Check for working CXX compiler: /usr/bin/c++
-- Check for working CXX compiler: /usr/bin/c++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Found GLUT: /usr/lib/x86_64-linux-gnu/libglut.so  
-- GLUT_FOUND=TRUE
-- Looking for pthread.h
-- Looking for pthread.h - found
-- Performing Test CMAKE_HAVE_LIBC_PTHREAD
-- Performing Test CMAKE_HAVE_LIBC_PTHREAD - Failed
-- Looking for pthread_create in pthreads
-- Looking for pthread_create in pthreads - not found
-- Looking for pthread_create in pthread
-- Looking for pthread_create in pthread - found
-- Found Threads: TRUE  
CMake Warning (dev) at /usr/local/share/cmake-3.15/Modules/FindOpenGL.cmake:275 (message):
  Policy CMP0072 is not set: FindOpenGL prefers GLVND by default when
  available.  Run "cmake --help-policy CMP0072" for policy details.  Use the
  cmake_policy command to set the policy and suppress this warning.

  FindOpenGL found both a legacy GL library:

    OPENGL_gl_LIBRARY: /usr/lib/x86_64-linux-gnu/libGL.so

  and GLVND libraries for OpenGL and GLX:

    OPENGL_opengl_LIBRARY: /usr/lib/x86_64-linux-gnu/libOpenGL.so
    OPENGL_glx_LIBRARY: /usr/lib/x86_64-linux-gnu/libGLX.so

  OpenGL_GL_PREFERENCE has not been set to "GLVND" or "LEGACY", so for
  compatibility with CMake 3.10 and below the legacy GL library will be used.
Call Stack (most recent call first):
  src/cmake/external_libs.cmake:71 (find_package)
  src/CMakeLists.txt:18 (include)
This warning is for project developers.  Use -Wno-dev to suppress it.

-- Found OpenGL: /usr/lib/x86_64-linux-gnu/libOpenGL.so   
-- Found Glew: /usr/lib/x86_64-linux-gnu/libGLEW.so  
CMake Error at /usr/local/share/cmake-3.15/Modules/FindPackageHandleStandardArgs.cmake:137 (message):
  Could NOT find OpenImageIO (missing: OPENIMAGEIO_LIBRARY
  OPENIMAGEIO_INCLUDE_DIR)
Call Stack (most recent call first):
  /usr/local/share/cmake-3.15/Modules/FindPackageHandleStandardArgs.cmake:378 (_FPHSA_FAILURE_MESSAGE)
  src/cmake/Modules/FindOpenImageIO.cmake:61 (FIND_PACKAGE_HANDLE_STANDARD_ARGS)
  src/cmake/external_libs.cmake:81 (find_package)
  src/CMakeLists.txt:18 (include)


-- Configuring incomplete, errors occurred!
See also "/home/sebastian/Program Files/cycles/build/CMakeFiles/CMakeOutput.log".
See also "/home/sebastian/Program Files/cycles/build/CMakeFiles/CMakeError.log".

cmake告诉我它找不到OpenImageIO (失踪: OPENIMAGEIO_LIBRARY OPENIMAGEIO_INCLUDE_DIR)

我可能应该说,我最近刚从Windows 10转到Ubuntu,我对cmake和make仍然很陌生,老实说,我不知道在这种情况下发生了什么……我浏览了互联网和StackOverflow,但在那里提出的解决方案对我无效。我想我需要告诉cmake在哪里找到丢失的文件夹(我知道它们已经安装了),但是我不知道怎么做。

如果你知道这个问题,你能给我指明正确的方向吗?如果你能给我任何建议,我将不胜感激。

提前感谢!

编辑:到目前为止,我所做的是通过以下命令安装OpenImageIO:

代码语言:javascript
复制
sudo apt-get update 
sudo apt-get install openimageio-tools

这似乎不起作用,因为cmake仍然找不到文件夹。之后,我将文件从OpenImageIO存储库(https://github.com/OpenImageIO/oiio)克隆到

代码语言:javascript
复制
sebastian@sebastian-N551JX:~/Program Files/oiio$

然后,根据安装指南(https://github.com/OpenImageIO/oiio/blob/master/INSTALL.md),我执行了以下命令

代码语言:javascript
复制
mkdir build
cd build
cmake ..

当我这样做的时候,出现了一些新的问题。这里有个片段:

代码语言:javascript
复制
Field3D library not found 
--     Try setting Field3D_ROOT ? 
-- GIF library not found 
--     Try setting GIF_ROOT ? 
-- Libheif library not found 
--     Try setting Libheif_ROOT ? 

当我试图“制造”时,我得到了以下错误:

代码语言:javascript
复制
[ 75%] Linking CXX shared library libOpenImageIO.so
c++: error: Files/oiio/src/build-scripts/hidesymbols.map: No such file or directory

我会尽力克服这些问题,如果有人有想法,请随时通知我。提前感谢!

EN

回答 1

Stack Overflow用户

回答已采纳

发布于 2020-09-23 19:31:53

sudo apt install libopenimageio-dev

( Ubuntu 20.04 LTS)

票数 5
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/59490146

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档