33 lines
1.1 KiB
Python
33 lines
1.1 KiB
Python
|
from conans import ConanFile, CMake
|
||
|
|
||
|
|
||
|
class PkmnLibConan(ConanFile):
|
||
|
name = "PkmnLib"
|
||
|
license = "TODO"
|
||
|
url = "https://git.p-epsilon.com/Deukhoofd/CreatureLib"
|
||
|
description = "The core implementation for turn based battling using creatures."
|
||
|
settings = "compiler"
|
||
|
options = {"shared": [True, False]}
|
||
|
default_options = {"shared": True}
|
||
|
generators = "cmake"
|
||
|
exports_sources = "*"
|
||
|
compiler = "clang"
|
||
|
requires = "CreatureLib/d26670082260d3eaab2126dc02c5e2fe674e0076@creaturelib/master"
|
||
|
|
||
|
def build(self):
|
||
|
cmake = CMake(self)
|
||
|
cmake.configure()
|
||
|
cmake.build()
|
||
|
|
||
|
# Explicit way:
|
||
|
# self.run('cmake "%s/src" %s' % (self.source_folder, cmake.command_line))
|
||
|
# self.run("cmake --build . %s" % cmake.build_config)
|
||
|
|
||
|
def package(self):
|
||
|
self.copy("*.hpp", 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)
|