From 4b6fefb2ac8cd2cd82ff492ee91710f127580211 Mon Sep 17 00:00:00 2001 From: Egor Pugin Date: Tue, 23 Jan 2018 21:57:52 +0300 Subject: [PATCH] Add openmp support for Visual Studio builds. --- CMakeLists.txt | 2 +- cppan.yml | 7 +++++++ 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 86874c7915..014cf515a2 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -82,7 +82,7 @@ if (WIN32) if (MSVC) add_definitions(-D_CRT_SECURE_NO_WARNINGS) - set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /MP") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /MP /openmp") endif() set(LIB_Ws2_32 Ws2_32) diff --git a/cppan.yml b/cppan.yml index 46edd7f39c..68865d4028 100644 --- a/cppan.yml +++ b/cppan.yml @@ -21,6 +21,13 @@ root_project: pvt.cppan.demo.google.tesseract common_settings: c++: 11 + options: + any: + compiler_options: + msvc: + private: + - /openmp + projects: libtesseract: type: lib