mirror of
https://github.com/nigels-com/glew.git
synced 2024-11-15 18:44:42 +00:00
25 lines
807 B
Python
25 lines
807 B
Python
|
from conans import ConanFile, CMake
|
||
|
import os
|
||
|
|
||
|
channel = os.getenv("CONAN_CHANNEL", "testing")
|
||
|
username = os.getenv("CONAN_USERNAME", "dimi309")
|
||
|
|
||
|
class TestGlew(ConanFile):
|
||
|
settings = "os", "compiler", "build_type", "arch"
|
||
|
requires = "glew/2.0.0@%s/%s" % (username, channel)
|
||
|
generators = "cmake"
|
||
|
|
||
|
def build(self):
|
||
|
cmake = CMake(self)
|
||
|
self.run('cmake "%s" %s' % (self.conanfile_directory, cmake.command_line))
|
||
|
self.run("cmake --build . %s" % cmake.build_config)
|
||
|
|
||
|
def test(self):
|
||
|
self.run(os.sep.join([".","bin", "testGlew"]))
|
||
|
|
||
|
def imports(self):
|
||
|
if self.settings.os == "Windows":
|
||
|
self.copy(pattern="*.dll", dst="bin", src="bin")
|
||
|
if self.settings.os == "Macos":
|
||
|
self.copy(pattern="*.dylib", dst="bin", src="lib")
|