-
Notifications
You must be signed in to change notification settings - Fork 0
/
conanfile.py
33 lines (28 loc) · 1.15 KB
/
conanfile.py
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 conans import ConanFile, CMake
class DiConan(ConanFile):
name = "di"
version = "1.0"
license = "Apache-2.0"
author = "Lukasz Laszko [email protected]"
url = "https://github.com/lukaszlaszko/di"
description = "Compile and runtime dependency injection for C++ 14"
topics = ("dependency injection", "di", "c++", "cpp", "", "cxx")
settings = "os", "compiler", "build_type", "arch"
options = {"shared": [True, False]}
default_options = "shared=False"
generators = "cmake"
exports_sources = ["CMakeLists.txt", "src/*", "external/*", "tests/*"]
def build(self):
cmake = CMake(self)
cmake.configure()
cmake.build(target="di")
def package(self):
self.copy("*.hpp", dst="include", src="src")
self.copy("*.ipp", dst="include", src="src")
self.copy("*.lib", dst="lib", keep_path=False)
self.copy("*.dll", dst="bin", keep_path=False)
self.copy("*.dylib*", dst="lib", keep_path=False)
self.copy("*.so", dst="lib", keep_path=False)
self.copy("*.a", dst="lib", keep_path=False)
def package_info(self):
self.cpp_info.libs = ["di"]