From 880d56d52cc0fe6937128562a72fcd795f74e7b4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fabian=20Bl=C3=A4se?= Date: Tue, 29 Mar 2022 19:32:39 +0200 Subject: [PATCH] buildscript: Keep target name for x86 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The x86 OpenWrt target does not have device names, as x86 images are generic for various hardware. Therefore, removing the target and subtarget from the image name results in an indistiguishable image name. Keep the target name for x86 images, so the resulting images are distinguishable. Fixes: #229 Signed-off-by: Fabian Bläse --- buildscript | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/buildscript b/buildscript index b2b3fd93..69c8f610 100755 --- a/buildscript +++ b/buildscript @@ -280,8 +280,13 @@ cp_firmware() { filename_build=${f##*/} filename_build=${filename_build//openwrt/fff-${version}} filename_build=${filename_build//squashfs-/} - filename_build=${filename_build//${chipset}-/} - filename_build=${filename_build//${subtarget}-/} + + # The x86 OpenWrt target does not have a device name, + # so keep the target and subtarget for identification. + if [ "$chipset" != "x86" ]; then + filename_build=${filename_build//${chipset}-/} + filename_build=${filename_build//${subtarget}-/} + fi cp "$f" "$imagedestpath/$filename_build" done done