diff options
author | Jan Janssen <medhefgo@web.de> | 2022-01-26 10:20:46 +0100 |
---|---|---|
committer | Jan Janssen <medhefgo@web.de> | 2022-01-26 14:40:55 +0100 |
commit | b6167d96117fcb3f737c9b3534e858dcdcaa5aa0 (patch) | |
tree | e75829c0210515fbb6fca35784d9b8dfd7d5a6b4 | |
parent | meson: Remove test-efi-create-disk.sh (diff) | |
download | systemd-b6167d96117fcb3f737c9b3534e858dcdcaa5aa0.tar.xz systemd-b6167d96117fcb3f737c9b3534e858dcdcaa5aa0.zip |
meson: Use same name format for efi binary intermediates
-rw-r--r-- | src/boot/efi/meson.build | 24 | ||||
-rwxr-xr-x | tools/debug-sd-boot.sh | 4 |
2 files changed, 12 insertions, 16 deletions
diff --git a/src/boot/efi/meson.build b/src/boot/efi/meson.build index 20b0c4bf7c..84021c3f36 100644 --- a/src/boot/efi/meson.build +++ b/src/boot/efi/meson.build @@ -397,16 +397,12 @@ foreach file : fundamental_source_paths + common_sources + systemd_boot_sources endif endforeach -systemd_boot_efi_name = 'systemd-boot@0@.efi'.format(efi_arch[0]) -stub_elf_name = 'linux@0@.elf.stub'.format(efi_arch[0]) -stub_efi_name = 'linux@0@.efi.stub'.format(efi_arch[0]) - -foreach tuple : [['systemd_boot.so', systemd_boot_efi_name, systemd_boot_objects, false], - [stub_elf_name, stub_efi_name, stub_objects, true]] - so = custom_target( - tuple[0], - input : tuple[2], - output : tuple[0], +foreach tuple : [['systemd-boot@0@.@1@', systemd_boot_objects, false], + ['linux@0@.@1@.stub', stub_objects, true]] + elf = custom_target( + tuple[0].format(efi_arch[0], 'elf'), + input : tuple[1], + output : tuple[0].format(efi_arch[0], 'elf'), command : [cc.cmd_array(), '-o', '@OUTPUT@', efi_cflags, @@ -415,13 +411,13 @@ foreach tuple : [['systemd_boot.so', systemd_boot_efi_name, systemd_boot_objects '-lefi', '-lgnuefi', '-lgcc'], - install : tuple[3], + install : tuple[2], install_dir : bootlibdir) custom_target( - tuple[1], - input : so, - output : tuple[1], + tuple[0].format(efi_arch[0], 'efi'), + input : elf, + output : tuple[0].format(efi_arch[0], 'efi'), command : [objcopy, '-j', '.bss*', '-j', '.data', diff --git a/tools/debug-sd-boot.sh b/tools/debug-sd-boot.sh index 816eead22d..1bd2cc406d 100755 --- a/tools/debug-sd-boot.sh +++ b/tools/debug-sd-boot.sh @@ -32,10 +32,10 @@ fi binary=$(realpath "${1}") if [[ "${1}" =~ systemd-boot([[:alnum:]]+).efi ]]; then target="systemd-boot" - symbols=$(realpath "$(dirname "${1}")/systemd_boot.so") + symbols=$(realpath "${1%efi}elf") elif [[ "${1}" =~ linux([[:alnum:]]+).efi.stub ]]; then target="systemd-stub" - symbols=$(realpath "$(dirname "${1}")/linux${BASH_REMATCH[1]}.elf.stub") + symbols=$(realpath "${1%efi.stub}elf.stub") else echo "Cannot detect EFI binary '${1}'." exit 1 |