1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
|
diff --git a/mesonbuild/msetup.py b/mesonbuild/msetup.py
index 8d7dd0bbf756..f1fa777d179a 100644
--- a/mesonbuild/msetup.py
+++ b/mesonbuild/msetup.py
@@ -16,6 +16,7 @@
if T.TYPE_CHECKING:
from typing_extensions import Protocol
from .coredata import SharedCMDOptions
+ from .interpreter import SubprojectHolder
class CMDOptions(SharedCMDOptions, Protocol):
@@ -192,9 +193,9 @@ def generate(self, capture: bool = False, vslite_ctx: T.Optional[dict] = None) -
'Some other Meson process is already using this build directory. Exiting.'):
return self._generate(env, capture, vslite_ctx)
- def check_unused_options(self, coredata: 'coredata.CoreData', cmd_line_options: T.Dict[OptionKey, str], all_subprojects: T.Mapping[str, object]) -> None:
+ def check_unused_options(self, coredata: 'coredata.CoreData', cmd_line_options: T.Dict[OptionKey, str], all_subprojects: T.Mapping[str, SubprojectHolder]) -> None:
errlist: T.List[str] = []
- known_subprojects = all_subprojects.keys()
+ known_subprojects = [name for name, obj in all_subprojects.items() if obj.found()]
for opt in cmd_line_options:
# Accept options that exist or could appear in subsequent reconfigurations,
# including options for subprojects that were not used
|