From 1400b612c16ede885d53b4bade53f226d0fe5935 Mon Sep 17 00:00:00 2001 From: Balazs Benics Date: Sun, 28 Jul 2019 15:37:11 +0200 Subject: [PATCH] fix cross building --- conanfile.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/conanfile.py b/conanfile.py index b86f289..0fb7c2f 100644 --- a/conanfile.py +++ b/conanfile.py @@ -1,7 +1,7 @@ #!/usr/bin/env python # -*- coding: utf-8 -*- -from conans import ConanFile, CMake +from conans import ConanFile, tools, CMake from conans.model.version import Version from conans.errors import ConanException @@ -76,7 +76,7 @@ class NameofConan(ConanFile): def build(self): cmake = self.configure_cmake() cmake.build() - if self.options.build_tests: + if self.options.build_tests and not tools.cross_building(self.settings): cmake.test() def package(self):