LoginSignup
5
6

More than 5 years have passed since last update.

ClionでOpenCVを使う場合のCMakeListsの書き方

Posted at

忘れないようにメモ。

CMakeLists.txt
cmake_minimum_required(VERSION 2.8.4)
project(test)

find_package(OpenCV REQUIRED)
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11")

set(SOURCE_FILES main.cpp)
add_executable(test ${SOURCE_FILES})
target_link_libraries(test ${OpenCV_LIBS})
5
6
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
5
6