From 7c4736d27f4c5d7844a44addc0305e4354440074 Mon Sep 17 00:00:00 2001 From: Xavier Claessens Date: Sun, 13 May 2018 10:36:58 -0400 Subject: Convert args.projectoptions into a dict This simplifies a lot of code, and centralize "key=value" parsing in a single place. Unknown command line options becomes an hard error instead of merely printing warning message. It has been warning it would become an hard error for a while now. This has exceptions though, any unknown option starting with "_" or "b_" are ignored because they depend on which languages gets added and which compiler gets selected. Also any option for unknown subproject are ignored because they depend on which subproject actually gets built. Also write more command line parsing tests. "19 bad command line options" is removed because bad cmd line option became hard error and it's covered with new tests in "30 command line". --- mesonbuild/environment.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'mesonbuild/environment.py') diff --git a/mesonbuild/environment.py b/mesonbuild/environment.py index 9b252a2..074bd75 100644 --- a/mesonbuild/environment.py +++ b/mesonbuild/environment.py @@ -288,7 +288,7 @@ class Environment: self.cross_info = CrossBuildInfo(self.coredata.cross_file) else: self.cross_info = None - self.cmd_line_options = options + self.cmd_line_options = options.cmd_line_options # List of potential compilers. if mesonlib.is_windows(): -- cgit v1.1