Fully embrace profiles
This commit is contained in:
14
conanfile.py
14
conanfile.py
@@ -5,13 +5,14 @@ import os
|
||||
|
||||
required_conan_version = ">=1.33.0"
|
||||
|
||||
class Bigfoot(ConanFile):
|
||||
name = "bin2cpp"
|
||||
class Bin2CPP(ConanFile):
|
||||
name = "Bin2CPP"
|
||||
homepage = "https://git.romainboullard.com/rboullard/Bin2CPP"
|
||||
description = "A utility that converts files to CPP headers"
|
||||
topics = ("utility")
|
||||
license = "MIT"
|
||||
version = "0.1.0"
|
||||
version = "1.0.0"
|
||||
package_type = "application"
|
||||
|
||||
# Binary configuration
|
||||
settings = "os", "compiler", "build_type", "arch"
|
||||
@@ -19,11 +20,13 @@ class Bigfoot(ConanFile):
|
||||
"shared": [True, False],
|
||||
"fPIC": [True, False],
|
||||
"build_tests": [True, False],
|
||||
"asan": [True, False]
|
||||
}
|
||||
default_options = {
|
||||
"shared": False,
|
||||
"fPIC": True,
|
||||
"build_tests": False,
|
||||
"asan": False
|
||||
}
|
||||
|
||||
generators = "CMakeDeps"
|
||||
@@ -35,7 +38,7 @@ class Bigfoot(ConanFile):
|
||||
if self.settings.os == "Windows":
|
||||
del self.options.fPIC
|
||||
|
||||
if(self.settings.build_type == "RelWithDebInfo" or self.settings.build_type == "Debug"):
|
||||
if(self.options.asan and (self.settings.build_type == "RelWithDebInfo" or self.settings.build_type == "Debug")):
|
||||
self.options["mimalloc"].asan = True
|
||||
|
||||
def requirements(self):
|
||||
@@ -52,8 +55,9 @@ class Bigfoot(ConanFile):
|
||||
|
||||
def generate(self):
|
||||
tc = CMakeToolchain(self)
|
||||
|
||||
|
||||
tc.variables["BUILD_TESTS"] = self.options.build_tests
|
||||
tc.variables["ASAN"] = self.options.asan
|
||||
|
||||
tc.generate()
|
||||
|
||||
|
||||
Reference in New Issue
Block a user