can't use assimp library

2019-07-18 23:46发布

问题:

I installed the assimp library using these commands:

sudo apt-get install libassimp-dev assimp-utils
sudo apt-get install libxmu-dev libxi-dev

I downloaded the c++ source code from the assimp website, but it shows errors that I am not able to resolve

CMake Error at CMakeLists.txt:42 (INSTALL):


install TARGETS given no RUNTIME DESTINATION for executable target
  "assimp_simpleogl".

CMake Warning (dev) in CMakeLists.txt:
  No cmake_minimum_required command is present.  A line of code such as

    cmake_minimum_required(VERSION 2.8)

  should be added at the top of the file.  The version specified may be lower
  if you wish to support older CMake versions for this project.  For more
  information run "cmake --help-policy CMP0000".
This warning is for project developers.  Use -Wno-dev to suppress it.

-- Configuring incomplete, errors occurred!
See also "/home/playroom/Desktop/assimp/CMakeFiles/CMakeOutput.log".

What should I do to remove this error ?

回答1:

just go at line 42, and replace the environment variable "${ASSIMP_BIN_INSTALL_DIR}"
with the destination of your choice. (like "./" or "./build")

then make and it should work.