Commit 4bd6c75e authored by Andoni Morales Alastruey's avatar Andoni Morales Alastruey
Browse files

cmake: fix build on windows x86_64

parent a3d91b48
...@@ -16,3 +16,20 @@ class Recipe(recipe.Recipe): ...@@ -16,3 +16,20 @@ class Recipe(recipe.Recipe):
can_use_configure_cache = False can_use_configure_cache = False
files_bin = ['bin/cmake', 'bin/ccmake'] files_bin = ['bin/cmake', 'bin/ccmake']
def prepare(self):
if self.config.target_platform == Platform.WINDOWS:
if self.config.target_arch == Architecture.X86_64:
# Setting SYSTEM_NAME sets CMAKE_CROSSCOMPILING and the
# binutils such as ar and ranlib are prefixed correctly
self.configure_tpl += ' -- -DCMAKE_SYSTEM_NAME="Windows"'
def configure(self):
if self.config.target_platform == Platform.WINDOWS:
if self.config.target_arch == Architecture.X86_64:
# Bootstrap needs to be run twice for some dark reason
try:
super(recipe.Recipe, self).configure()
except:
pass
super(recipe.Recipe, self).configure()
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment