@@ -397,16 +397,12 @@ foreach file : fundamental_source_paths + common_sources + systemd_boot_sources
397397 endif
398398endforeach
399399
400- systemd_boot_efi_name = ' systemd-boot@0@.efi' .format(efi_arch[0 ])
401- stub_elf_name = ' linux@0@.elf.stub' .format(efi_arch[0 ])
402- stub_efi_name = ' linux@0@.efi.stub' .format(efi_arch[0 ])
403-
404- foreach tuple : [[' systemd_boot.so' , systemd_boot_efi_name, systemd_boot_objects, false ],
405- [stub_elf_name, stub_efi_name, stub_objects, true ]]
406- so = custom_target (
407- tuple[0 ],
408- input : tuple[2 ],
409- output : tuple[0 ],
400+ foreach tuple : [[' systemd-boot@0@.@1@' , systemd_boot_objects, false ],
401+ [' linux@0@.@1@.stub' , stub_objects, true ]]
402+ elf = custom_target (
403+ tuple[0 ].format(efi_arch[0 ], ' elf' ),
404+ input : tuple[1 ],
405+ output : tuple[0 ].format(efi_arch[0 ], ' elf' ),
410406 command : [cc.cmd_array(),
411407 ' -o' , ' @OUTPUT@' ,
412408 efi_cflags,
@@ -415,13 +411,13 @@ foreach tuple : [['systemd_boot.so', systemd_boot_efi_name, systemd_boot_objects
415411 ' -lefi' ,
416412 ' -lgnuefi' ,
417413 ' -lgcc' ],
418- install : tuple[3 ],
414+ install : tuple[2 ],
419415 install_dir : bootlibdir)
420416
421417 custom_target (
422- tuple[1 ] ,
423- input : so ,
424- output : tuple[1 ] ,
418+ tuple[0 ].format(efi_arch[ 0 ], ' efi ' ) ,
419+ input : elf ,
420+ output : tuple[0 ].format(efi_arch[ 0 ], ' efi ' ) ,
425421 command : [objcopy,
426422 ' -j' , ' .bss*' ,
427423 ' -j' , ' .data' ,
0 commit comments