2019-12-29 14:29:52 +00:00
|
|
|
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."
|
2020-01-01 18:59:47 +00:00
|
|
|
settings = "os", "compiler"
|
2019-12-29 14:29:52 +00:00
|
|
|
options = {"shared": [True, False]}
|
|
|
|
default_options = {"shared": True}
|
|
|
|
generators = "cmake"
|
|
|
|
exports_sources = "*"
|
|
|
|
compiler = "clang"
|
2020-01-09 13:44:11 +00:00
|
|
|
requires = \
|
2020-01-11 21:30:23 +00:00
|
|
|
"CreatureLib/779f0b08cfc7d2b19ee0bd27c61a28807172bc1f@creaturelib/master", \
|
2020-01-09 13:44:11 +00:00
|
|
|
"AngelScript/2.34@AngelScript/Deukhoofd"
|
2019-12-29 14:29:52 +00:00
|
|
|
|
|
|
|
def build(self):
|
|
|
|
cmake = CMake(self)
|
|
|
|
cmake.configure()
|
|
|
|
cmake.build()
|
|
|
|
|
|
|
|
def package(self):
|
|
|
|
self.copy("*.hpp", dst="include", src="src")
|
2020-01-09 18:03:38 +00:00
|
|
|
self.copy("*.h", dst="include", src="src")
|
2019-12-29 14:29:52 +00:00
|
|
|
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)
|
2020-01-01 18:59:47 +00:00
|
|
|
|
|
|
|
def imports(self):
|
|
|
|
if self.settings.os == "Windows":
|
|
|
|
self.copy("*.dll", "bin", "bin")
|