diff --git a/picofly_build_local.sh b/picofly_build_local.sh index dc40b59..3634a24 100644 --- a/picofly_build_local.sh +++ b/picofly_build_local.sh @@ -19,7 +19,7 @@ fi # detect distribution if [ -f /etc/os-release ]; then . /etc/os-release - DISTRO=$ID + DISTRO=${ID-LIKE:-$ID} else echo -e "${RED}Error: Cannot detect distribution${NC}" exit 1 @@ -128,4 +128,4 @@ echo -e " - update.bin: ${WORKSPACE}/build/usk/update.bin" USK_VERSION_LO=$(sed -n 's/#define VER_LO \([0-9]*\)/\1/p' "$USK_DIR/config.h") USK_VERSION_HI=$(sed -n 's/#define VER_HI \([0-9]*\)/\1/p' "$USK_DIR/config.h") USK_VERSION="${USK_VERSION_HI}.${USK_VERSION_LO}" -echo -e "${GREEN}Version: Picofly ${USK_VERSION}${NC}\n" \ No newline at end of file +echo -e "${GREEN}Version: Picofly ${USK_VERSION}${NC}\n" diff --git a/picofly_build_remote.sh b/picofly_build_remote.sh index 273720b..c3c9feb 100644 --- a/picofly_build_remote.sh +++ b/picofly_build_remote.sh @@ -12,7 +12,7 @@ echo -e "${GREEN}=== Picofly build script (multi-distro) ===${NC}\n" # detect distribution if [ -f /etc/os-release ]; then . /etc/os-release - DISTRO=$ID + DISTRO=${ID_LIKE:-$ID} else echo -e "${RED}Error: Cannot detect distribution${NC}" exit 1 @@ -127,4 +127,4 @@ echo -e " - update.bin: ${WORKSPACE}/build/usk/update.bin" USK_VERSION_LO=$(sed -n 's/#define VER_LO \([0-9]*\)/\1/p' "$WORKSPACE/usk/config.h") USK_VERSION_HI=$(sed -n 's/#define VER_HI \([0-9]*\)/\1/p' "$WORKSPACE/usk/config.h") USK_VERSION="${USK_VERSION_HI}.${USK_VERSION_LO}" -echo -e "${GREEN}Version: Picofly ${USK_VERSION}${NC}\n" \ No newline at end of file +echo -e "${GREEN}Version: Picofly ${USK_VERSION}${NC}\n"