blob: e64488be461f510b421ff1cbad6c82c41b3f2589 [file] [log] [blame]
William A. Kennington IIIc5966302020-03-20 13:04:31 -07001From ee638fd4a299bfc53a2238e9f71ae310c8d97460 Mon Sep 17 00:00:00 2001
Brad Bishop19323692019-04-05 15:28:33 -04002From: Ross Burton <ross.burton@intel.com>
3Date: Tue, 3 Jul 2018 13:59:09 +0100
4Subject: [PATCH] Make CPU family warnings fatal
5
6Upstream-Status: Inappropriate [OE specific]
7Signed-off-by: Ross Burton <ross.burton@intel.com>
8
9---
Brad Bishopc342db32019-05-15 21:57:59 -040010 mesonbuild/envconfig.py | 2 +-
11 mesonbuild/environment.py | 4 +---
12 2 files changed, 2 insertions(+), 4 deletions(-)
Brad Bishop19323692019-04-05 15:28:33 -040013
Brad Bishopc342db32019-05-15 21:57:59 -040014diff --git a/mesonbuild/envconfig.py b/mesonbuild/envconfig.py
William A. Kennington IIIc5966302020-03-20 13:04:31 -070015index 0f277a7..24578ea 100644
Brad Bishopc342db32019-05-15 21:57:59 -040016--- a/mesonbuild/envconfig.py
17+++ b/mesonbuild/envconfig.py
William A. Kennington IIIc5966302020-03-20 13:04:31 -070018@@ -192,7 +192,7 @@ class MachineInfo:
Andrew Geissler82c905d2020-04-13 13:39:40 -050019
Brad Bishopc342db32019-05-15 21:57:59 -040020 cpu_family = literal['cpu_family']
21 if cpu_family not in known_cpu_families:
22- mlog.warning('Unknown CPU family %s, please report this at https://github.com/mesonbuild/meson/issues/new' % cpu_family)
23+ raise EnvironmentException('Unknown CPU family %s, see https://wiki.yoctoproject.org/wiki/Meson/UnknownCPU for directions.' % cpu_family)
Andrew Geissler82c905d2020-04-13 13:39:40 -050024
Brad Bishopc342db32019-05-15 21:57:59 -040025 endian = literal['endian']
26 if endian not in ('little', 'big'):
Brad Bishop19323692019-04-05 15:28:33 -040027diff --git a/mesonbuild/environment.py b/mesonbuild/environment.py
William A. Kennington IIIc5966302020-03-20 13:04:31 -070028index dc8b14f..3aab71e 100644
Brad Bishop19323692019-04-05 15:28:33 -040029--- a/mesonbuild/environment.py
30+++ b/mesonbuild/environment.py
William A. Kennington IIIc5966302020-03-20 13:04:31 -070031@@ -354,9 +354,7 @@ def detect_cpu_family(compilers: CompilersDict) -> str:
Brad Bishopc342db32019-05-15 21:57:59 -040032 trial = 'parisc'
Andrew Geissler82c905d2020-04-13 13:39:40 -050033
Brad Bishop19323692019-04-05 15:28:33 -040034 if trial not in known_cpu_families:
35- mlog.warning('Unknown CPU family {!r}, please report this at '
William A. Kennington IIIc5966302020-03-20 13:04:31 -070036- 'https://github.com/mesonbuild/meson/issues/new with the '
Brad Bishop19323692019-04-05 15:28:33 -040037- 'output of `uname -a` and `cat /proc/cpuinfo`'.format(trial))
38+ raise EnvironmentException('Unknown CPU family %s, see https://wiki.yoctoproject.org/wiki/Meson/UnknownCPU for directions.' % trial)
Andrew Geissler82c905d2020-04-13 13:39:40 -050039
Brad Bishop19323692019-04-05 15:28:33 -040040 return trial
Andrew Geissler82c905d2020-04-13 13:39:40 -050041