diff options
author | Adrian Freihofer <adrian.freihofer@gmail.com> | 2024-02-25 21:47:00 +0100 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2024-02-27 11:38:46 +0000 |
commit | 4c6f3bbc773f10bbfc9c45a7468c0f18d384ac16 (patch) | |
tree | a716a54f9724cf9d49e3f5a5c99e132760636d94 /scripts | |
parent | be57fda5423eae49133fa0fdecaa30e4d9f57026 (diff) | |
download | poky-4c6f3bbc773f10bbfc9c45a7468c0f18d384ac16.tar.gz |
devtool: ide-sdk launch.json per recipe only
If multiple recipes are processed at once, the launch.json and the
tasks.json of the second recipe contains also the configurations for the
binaries of the first recipe.
Example:
devtool ide-sdk powertop cmake-example oe-selftest-image
generated a launch and a tasks configuration for the cmake-example
recipe which also offers debugging the powertop binary.
(From OE-Core rev: 63986b2c40d90fe96cdc6a46aa649efcf17f6ac2)
Signed-off-by: Adrian Freihofer <adrian.freihofer@siemens.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'scripts')
-rw-r--r-- | scripts/lib/devtool/ide_plugins/ide_code.py | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/scripts/lib/devtool/ide_plugins/ide_code.py b/scripts/lib/devtool/ide_plugins/ide_code.py index d5e3a4f421..d58d0bdc53 100644 --- a/scripts/lib/devtool/ide_plugins/ide_code.py +++ b/scripts/lib/devtool/ide_plugins/ide_code.py | |||
@@ -255,8 +255,10 @@ class IdeVSCode(IdeBase): | |||
255 | def vscode_launch(self, modified_recipe): | 255 | def vscode_launch(self, modified_recipe): |
256 | """GDB Launch configuration for binaries (elf files)""" | 256 | """GDB Launch configuration for binaries (elf files)""" |
257 | 257 | ||
258 | configurations = [self.vscode_launch_bin_dbg( | 258 | configurations = [] |
259 | gdb_cross_config) for gdb_cross_config in self.gdb_cross_configs] | 259 | for gdb_cross_config in self.gdb_cross_configs: |
260 | if gdb_cross_config.modified_recipe is modified_recipe: | ||
261 | configurations.append(self.vscode_launch_bin_dbg(gdb_cross_config)) | ||
260 | launch_dict = { | 262 | launch_dict = { |
261 | "version": "0.2.0", | 263 | "version": "0.2.0", |
262 | "configurations": configurations | 264 | "configurations": configurations |
@@ -280,6 +282,8 @@ class IdeVSCode(IdeBase): | |||
280 | ] | 282 | ] |
281 | } | 283 | } |
282 | for gdb_cross_config in self.gdb_cross_configs: | 284 | for gdb_cross_config in self.gdb_cross_configs: |
285 | if gdb_cross_config.modified_recipe is not modified_recipe: | ||
286 | continue | ||
283 | tasks_dict['tasks'].append( | 287 | tasks_dict['tasks'].append( |
284 | { | 288 | { |
285 | "label": gdb_cross_config.id_pretty, | 289 | "label": gdb_cross_config.id_pretty, |
@@ -394,6 +398,8 @@ class IdeVSCode(IdeBase): | |||
394 | } | 398 | } |
395 | if modified_recipe.gdb_cross: | 399 | if modified_recipe.gdb_cross: |
396 | for gdb_cross_config in self.gdb_cross_configs: | 400 | for gdb_cross_config in self.gdb_cross_configs: |
401 | if gdb_cross_config.modified_recipe is not modified_recipe: | ||
402 | continue | ||
397 | tasks_dict['tasks'].append( | 403 | tasks_dict['tasks'].append( |
398 | { | 404 | { |
399 | "label": gdb_cross_config.id_pretty, | 405 | "label": gdb_cross_config.id_pretty, |