-
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathconanfile.py
More file actions
33 lines (26 loc) · 1.03 KB
/
conanfile.py
File metadata and controls
33 lines (26 loc) · 1.03 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
from conan import ConanFile
from conan.tools.cmake import CMake, cmake_layout
class AxidevIoRecipe(ConanFile):
name = "axidev-io"
version = "0.4.0"
package_type = "library"
# Paramètres de base
settings = "os", "compiler", "build_type", "arch"
generators = "CMakeDeps", "CMakeToolchain"
def layout(self):
cmake_layout(self)
def build(self):
cmake = CMake(self)
cmake.configure()
cmake.build()
def package(self):
cmake = CMake(self)
cmake.install()
def package_info(self):
# The CMake target uses an underscore in the actual library target name
# (CMake target `axidev::io` is an alias for the target `axidev_io`).
# Ensure the packaged library name matches the built artifact.
self.cpp_info.libs = ["axidev_io"]
self.cpp_info.set_property("cmake_target_name", "axidev::io")
# Make the expected CMake config file name explicit for modern Conan
self.cpp_info.set_property("cmake_file_name", "axidev-io")