diff options
author | Psy-Kai <psykai1993@googlemail.com> | 2020-08-10 11:34:05 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-08-10 11:34:05 +0300 |
commit | e1f55a8f818a2b0abb2d121a9cffb0a584af2880 (patch) | |
tree | 42b8fae4e6b6b9578f76f0ac304f0d1776dc312f /conanfile.py | |
parent | ddda911ff101d1e0db864743ed4d342ead9d5dc2 (diff) |
Update conanfile.py (#568)
settings.os represent the target system not the build system (https://docs.conan.io/en/latest/systems_cross_building/cross_building.html#gnu-triplet-convention).
Thus we need to check the `settings_os_build` variable not the `os` variable.
This will fix the problem that CMake tries to check if the compiler works with wrong parameter (which results in using -`rdynamic` which may not be supported on mcu compilers)
Diffstat (limited to 'conanfile.py')
-rw-r--r-- | conanfile.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/conanfile.py b/conanfile.py index d709236..d23d823 100644 --- a/conanfile.py +++ b/conanfile.py @@ -7,7 +7,7 @@ class NanoPbConan(ConanFile): license = "zlib" url = "https://jpa.kapsi.fi/nanopb/" description = "Protocol Buffers with small code size" - settings = "os", "compiler", "build_type", "arch" + settings = "os_build", "compiler", "build_type", "arch" generators = "cmake" exports = '*' options = { @@ -18,7 +18,7 @@ class NanoPbConan(ConanFile): } def configure(self): - if self.settings.os == "Windows" and self.settings.compiler == "Visual Studio": + if self.settings.os_build == "Windows" and self.settings.compiler == "Visual Studio": del self.options.fPIC def build(self): |