From a21377ce6c1ca34f45fce487514847dc2efc6e8c Mon Sep 17 00:00:00 2001 From: Dan Paulat Date: Mon, 5 Jun 2023 22:11:36 -0500 Subject: [PATCH] Add oneTBB to Linux build for PSTL --- conanfile.py | 33 +++++++++++++++++++++++++++++++++ conanfile.txt | 30 ------------------------------ wxdata/wxdata.cmake | 7 ++++++- 3 files changed, 39 insertions(+), 31 deletions(-) create mode 100644 conanfile.py delete mode 100644 conanfile.txt diff --git a/conanfile.py b/conanfile.py new file mode 100644 index 00000000..c6fe1dc1 --- /dev/null +++ b/conanfile.py @@ -0,0 +1,33 @@ +from conans import ConanFile + +class SupercellWxConan(ConanFile): + settings = ("os", "compiler", "build_type", "arch") + requires = ("boost/1.81.0", + "cpr/1.9.3", + "freetype/2.12.1", + "geographiclib/1.52", + "glew/2.2.0", + "glm/cci.20220420", + "gtest/cci.20210126", + "libcurl/7.86.0", + "libxml2/2.10.3", + "openssl/3.1.0", + "spdlog/1.11.0", + "sqlite3/3.40.1", + "vulkan-loader/1.3.236.0", + "zlib/1.2.13") + generators = ("cmake", + "cmake_find_package", + "cmake_paths") + default_options = {"libiconv:shared" : True, + "openssl:no_module": True, + "openssl:shared" : True} + + def requirements(self): + if self.settings.os == "Linux": + self.requires("onetbb/2021.9.0") + + def imports(self): + self.copy("*.dll", dst="bin", src="bin") + self.copy("*.dylib", dst="bin", src="lib") + self.copy("license*", dst="licenses", src=".", folder=True, ignore_case=True) diff --git a/conanfile.txt b/conanfile.txt deleted file mode 100644 index 95e79404..00000000 --- a/conanfile.txt +++ /dev/null @@ -1,30 +0,0 @@ -[requires] -boost/1.81.0 -cpr/1.9.3 -freetype/2.12.1 -geographiclib/1.52 -glew/2.2.0 -glm/cci.20220420 -gtest/cci.20210126 -libcurl/7.86.0 -libxml2/2.10.3 -openssl/3.1.0 -spdlog/1.11.0 -sqlite3/3.40.1 -vulkan-loader/1.3.236.0 -zlib/1.2.13 - -[generators] -cmake -cmake_find_package -cmake_paths - -[options] -libiconv:shared=True -openssl:no_module=True -openssl:shared=True - -[imports] -bin, *.dll -> ./bin -lib, *.dylib -> ./bin -., license* -> ./licenses @ folder=True, ignore_case=True diff --git a/wxdata/wxdata.cmake b/wxdata/wxdata.cmake index e2ee86f9..a61a1c8f 100644 --- a/wxdata/wxdata.cmake +++ b/wxdata/wxdata.cmake @@ -7,6 +7,10 @@ find_package(cpr) find_package(LibXml2) find_package(spdlog) +if (NOT MSVC) + find_package(TBB) +endif() + set(HDR_AWIPS include/scwx/awips/coded_location.hpp include/scwx/awips/coded_time_motion_location.hpp include/scwx/awips/message.hpp @@ -252,7 +256,8 @@ if (WIN32) endif() if (NOT MSVC) - target_link_libraries(wxdata PUBLIC date::date-tz) + target_link_libraries(wxdata PUBLIC date::date-tz + TBB::tbb) endif() set_target_properties(wxdata PROPERTIES CXX_STANDARD 20