Skip to content

Commit

Permalink
(#14075) Fixed psyinf-gmtl cmake setup
Browse files Browse the repository at this point in the history
* fixed gmtl cmake setup

* updated package using CMake namespace and corrected version in CMakeLists

* updated source ref
  • Loading branch information
psyinf authored Nov 8, 2022
1 parent c71c8fa commit 9e8866a
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 6 deletions.
2 changes: 1 addition & 1 deletion recipes/psyinf-gmtl/all/conandata.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
sources:
"0.7.1":
url: "https://github.com/psyinf/gmtl/archive/refs/tags/0.7.1.tar.gz"
sha256: "64e36b8c41b1829933921cd5a2f2825111840010b6d0e3aaa82c023c8fd7ebd5"
sha256: "e7fbc98d8714251655c1f2ab60d35500ca6c1c57e4887419c99ffb4a49fc5030"
7 changes: 5 additions & 2 deletions recipes/psyinf-gmtl/all/conanfile.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
import os


required_conan_version = ">=1.52.0"
required_conan_version = ">=1.50.0"


class PackageConan(ConanFile):
Expand Down Expand Up @@ -39,8 +39,11 @@ def package(self):
def package_info(self):
self.cpp_info.bindirs = []
self.cpp_info.libdirs = []
self.cpp_info.names["cmake_find_package"] = "gmtl"
self.cpp_info.names["cmake_find_package_multi"] = "gmtl"

self.cpp_info.set_property("cmake_file_name", "gmtl")
self.cpp_info.set_property("cmake_target_name", "gmtl")
self.cpp_info.set_property("cmake_target_name", "gmtl::gmtl")
self.cpp_info.set_property("pkg_config_name", "gmtl")


2 changes: 1 addition & 1 deletion recipes/psyinf-gmtl/all/test_package/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -5,4 +5,4 @@ project(test_package CXX)
find_package(gmtl REQUIRED CONFIG)

add_executable(${PROJECT_NAME} test_package.cpp)
target_link_libraries(${PROJECT_NAME} PRIVATE gmtl)
target_link_libraries(${PROJECT_NAME} PRIVATE gmtl::gmtl)
4 changes: 2 additions & 2 deletions recipes/psyinf-gmtl/all/test_v1_package/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ project(test_package CXX)
include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake)
conan_basic_setup(TARGETS)

find_package(psyinf-gmtl REQUIRED CONFIG)
find_package(gmtl REQUIRED CONFIG)

add_executable(${PROJECT_NAME} ../test_package/test_package.cpp)
target_link_libraries(${PROJECT_NAME} PRIVATE psyinf-gmtl::psyinf-gmtl)
target_link_libraries(${PROJECT_NAME} PRIVATE gmtl::gmtl)

0 comments on commit 9e8866a

Please sign in to comment.