-
Notifications
You must be signed in to change notification settings - Fork 0
/
conanfile.py
55 lines (38 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
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
#!/usr/bin/env python3
from conans import ConanFile, CMake
class ScopeConan(ConanFile):
# Package Info
name = "Scope"
version = "1.0.0"
description = "An RAII scope-guard library"
url = "https://github.com/bitwizeshift/Scope"
author = "Matthew Rodusek <[email protected]>"
license = "BSL-1.0"
# Sources
exports = ( "LICENSE" )
exports_sources = ( "CMakeLists.txt",
"cmake/*",
"include/*",
"LICENSE" )
# Settings
options = {}
default_options = {}
generators = "cmake"
# Dependencies
build_requires = ("Catch2/2.7.1@catchorg/stable")
def configure_cmake(self):
cmake = CMake(self)
# Features
cmake.definitions["SCOPE_ENABLE_UNIT_TESTS"] = "OFF"
cmake.configure()
return cmake
def build(self):
cmake = self.configure_cmake()
cmake.build()
# cmake.test()
def package(self):
cmake = self.configure_cmake()
cmake.install()
self.copy(pattern="LICENSE", dst="licenses")
def package_id(self):
self.info.header_only()