ci(linux): add option to check all architectures [skip ci]

This commit is contained in:
Baptiste Augrain 2024-04-13 01:32:40 +02:00
parent ab01a1aa00
commit a1f3d6ff6c
3 changed files with 150 additions and 142 deletions

View File

@ -61,6 +61,7 @@ jobs:
- name: Check existing VSCodium tags/releases
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
CHECK_ALL: 'yes'
run: ./check_tags.sh
compile:
@ -241,8 +242,8 @@ jobs:
npm_arch: arm64
- vscode_arch: armhf
npm_arch: arm
# - vscode_arch: ppc64le
# npm_arch: ppc64
- vscode_arch: ppc64le
npm_arch: ppc64
- vscode_arch: riscv64
npm_arch: riscv64
env:

View File

@ -60,6 +60,7 @@ jobs:
- name: Check existing VSCodium tags/releases
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
CHECK_ALL: 'yes'
run: ./check_tags.sh
compile:

View File

@ -219,154 +219,160 @@ elif [[ "${ASSETS}" != "null" ]]; then
echo "Already have the Linux REH ${VSCODE_ARCH} archive"
export SHOULD_BUILD_REH="no"
fi
# linux-arm64
elif [[ "${VSCODE_ARCH}" == "arm64" ]]; then
if [[ -z $( contains "arm64.deb" ) ]]; then
echo "Building on Linux arm64 because we have no DEB"
export SHOULD_BUILD="yes"
else
export SHOULD_BUILD_DEB="no"
fi
if [[ -z $( contains "aarch64.rpm" ) ]]; then
echo "Building on Linux arm64 because we have no RPM"
export SHOULD_BUILD="yes"
else
export SHOULD_BUILD_RPM="no"
fi
if [[ -z $( contains "${APP_NAME}-linux-arm64-${RELEASE_VERSION}.tar.gz" ) ]]; then
echo "Building on Linux arm64 because we have no TAR"
export SHOULD_BUILD="yes"
else
export SHOULD_BUILD_TAR="no"
fi
if [[ "${CHECK_REH}" != "no" && -z $( contains "${APP_NAME_LC}-reh-linux-arm64-${RELEASE_VERSION}.tar.gz" ) ]]; then
echo "Building on Linux arm64 because we have no REH archive"
export SHOULD_BUILD="yes"
else
export SHOULD_BUILD_REH="no"
fi
export SHOULD_BUILD_APPIMAGE="no"
if [[ "${SHOULD_BUILD}" != "yes" ]]; then
echo "Already have all the Linux arm64 builds"
fi
# linux-armhf
elif [[ "${VSCODE_ARCH}" == "armhf" ]]; then
if [[ -z $( contains "armhf.deb" ) ]]; then
echo "Building on Linux arm because we have no DEB"
export SHOULD_BUILD="yes"
else
export SHOULD_BUILD_DEB="no"
fi
if [[ -z $( contains "armv7hl.rpm" ) ]]; then
echo "Building on Linux arm because we have no RPM"
export SHOULD_BUILD="yes"
else
export SHOULD_BUILD_RPM="no"
fi
if [[ -z $( contains "${APP_NAME}-linux-armhf-${RELEASE_VERSION}.tar.gz" ) ]]; then
echo "Building on Linux arm because we have no TAR"
export SHOULD_BUILD="yes"
else
export SHOULD_BUILD_TAR="no"
fi
if [[ "${CHECK_REH}" != "no" && -z $( contains "${APP_NAME_LC}-reh-linux-armhf-${RELEASE_VERSION}.tar.gz" ) ]]; then
echo "Building on Linux arm because we have no REH archive"
export SHOULD_BUILD="yes"
else
export SHOULD_BUILD_REH="no"
fi
export SHOULD_BUILD_APPIMAGE="no"
if [[ "${SHOULD_BUILD}" != "yes" ]]; then
echo "Already have all the Linux arm builds"
fi
# linux-ppc64le
elif [[ "${VSCODE_ARCH}" == "ppc64le" ]]; then
SHOULD_BUILD_APPIMAGE="no"
SHOULD_BUILD_DEB="no"
SHOULD_BUILD_RPM="no"
SHOULD_BUILD_TAR="no"
if [[ -z $( contains "${APP_NAME_LC}-reh-linux-ppc64le-${RELEASE_VERSION}.tar.gz" ) ]]; then
echo "Building on Linux PowerPC64LE because we have no REH archive"
export SHOULD_BUILD="yes"
else
export SHOULD_BUILD_REH="no"
fi
if [[ "${SHOULD_BUILD}" != "yes" ]]; then
echo "Already have all the Linux PowerPC64LE builds"
fi
# linux-riscv64
elif [[ "${VSCODE_ARCH}" == "riscv64" ]]; then
SHOULD_BUILD_APPIMAGE="no"
SHOULD_BUILD_DEB="no"
SHOULD_BUILD_RPM="no"
SHOULD_BUILD_TAR="no"
if [[ -z $( contains "${APP_NAME_LC}-reh-linux-riscv64-${RELEASE_VERSION}.tar.gz" ) ]]; then
echo "Building on Linux RISC-V64 because we have no REH archive"
export SHOULD_BUILD="yes"
else
export SHOULD_BUILD_REH="no"
fi
if [[ "${SHOULD_BUILD}" != "yes" ]]; then
echo "Already have all the Linux PowerPC64LE builds"
fi
# linux-x64
else
if [[ -z $( contains "amd64.deb" ) ]]; then
echo "Building on Linux x64 because we have no DEB"
export SHOULD_BUILD="yes"
else
export SHOULD_BUILD_DEB="no"
fi
if [[ -z $( contains "x86_64.rpm" ) ]]; then
echo "Building on Linux x64 because we have no RPM"
export SHOULD_BUILD="yes"
else
export SHOULD_BUILD_RPM="no"
fi
# linux-arm64
if [[ "${VSCODE_ARCH}" == "arm64" || "${CHECK_ALL}" == "yes" ]]; then
if [[ -z $( contains "arm64.deb" ) ]]; then
echo "Building on Linux arm64 because we have no DEB"
export SHOULD_BUILD="yes"
else
export SHOULD_BUILD_DEB="no"
fi
if [[ -z $( contains "${APP_NAME}-linux-x64-${RELEASE_VERSION}.tar.gz" ) ]]; then
echo "Building on Linux x64 because we have no TAR"
export SHOULD_BUILD="yes"
else
export SHOULD_BUILD_TAR="no"
fi
if [[ -z $( contains "aarch64.rpm" ) ]]; then
echo "Building on Linux arm64 because we have no RPM"
export SHOULD_BUILD="yes"
else
export SHOULD_BUILD_RPM="no"
fi
if [[ -z $( contains "${APP_NAME}-linux-arm64-${RELEASE_VERSION}.tar.gz" ) ]]; then
echo "Building on Linux arm64 because we have no TAR"
export SHOULD_BUILD="yes"
else
export SHOULD_BUILD_TAR="no"
fi
if [[ "${CHECK_REH}" != "no" && -z $( contains "${APP_NAME_LC}-reh-linux-arm64-${RELEASE_VERSION}.tar.gz" ) ]]; then
echo "Building on Linux arm64 because we have no REH archive"
export SHOULD_BUILD="yes"
else
export SHOULD_BUILD_REH="no"
fi
if [[ -z $( contains "x86_64.AppImage" ) ]]; then
echo "Building on Linux x64 because we have no AppImage"
export SHOULD_BUILD="yes"
else
export SHOULD_BUILD_APPIMAGE="no"
if [[ "${SHOULD_BUILD}" != "yes" ]]; then
echo "Already have all the Linux arm64 builds"
fi
fi
if [[ "${CHECK_REH}" != "no" && -z $( contains "${APP_NAME_LC}-reh-linux-x64-${RELEASE_VERSION}.tar.gz" ) ]]; then
echo "Building on Linux x64 because we have no REH archive"
export SHOULD_BUILD="yes"
else
export SHOULD_BUILD_REH="no"
# linux-armhf
if [[ "${VSCODE_ARCH}" == "armhf" || "${CHECK_ALL}" == "yes" ]]; then
if [[ -z $( contains "armhf.deb" ) ]]; then
echo "Building on Linux arm because we have no DEB"
export SHOULD_BUILD="yes"
else
export SHOULD_BUILD_DEB="no"
fi
if [[ -z $( contains "armv7hl.rpm" ) ]]; then
echo "Building on Linux arm because we have no RPM"
export SHOULD_BUILD="yes"
else
export SHOULD_BUILD_RPM="no"
fi
if [[ -z $( contains "${APP_NAME}-linux-armhf-${RELEASE_VERSION}.tar.gz" ) ]]; then
echo "Building on Linux arm because we have no TAR"
export SHOULD_BUILD="yes"
else
export SHOULD_BUILD_TAR="no"
fi
if [[ "${CHECK_REH}" != "no" && -z $( contains "${APP_NAME_LC}-reh-linux-armhf-${RELEASE_VERSION}.tar.gz" ) ]]; then
echo "Building on Linux arm because we have no REH archive"
export SHOULD_BUILD="yes"
else
export SHOULD_BUILD_REH="no"
fi
export SHOULD_BUILD_APPIMAGE="no"
if [[ "${SHOULD_BUILD}" != "yes" ]]; then
echo "Already have all the Linux arm builds"
fi
fi
if [[ "${SHOULD_BUILD}" != "yes" ]]; then
echo "Already have all the Linux x64 builds"
# linux-ppc64le
if [[ "${VSCODE_ARCH}" == "ppc64le" || "${CHECK_ALL}" == "yes" ]]; then
SHOULD_BUILD_APPIMAGE="no"
SHOULD_BUILD_DEB="no"
SHOULD_BUILD_RPM="no"
SHOULD_BUILD_TAR="no"
if [[ -z $( contains "${APP_NAME_LC}-reh-linux-ppc64le-${RELEASE_VERSION}.tar.gz" ) ]]; then
echo "Building on Linux PowerPC64LE because we have no REH archive"
export SHOULD_BUILD="yes"
else
export SHOULD_BUILD_REH="no"
fi
if [[ "${SHOULD_BUILD}" != "yes" ]]; then
echo "Already have all the Linux PowerPC64LE builds"
fi
fi
# linux-riscv64
if [[ "${VSCODE_ARCH}" == "riscv64" || "${CHECK_ALL}" == "yes" ]]; then
SHOULD_BUILD_APPIMAGE="no"
SHOULD_BUILD_DEB="no"
SHOULD_BUILD_RPM="no"
SHOULD_BUILD_TAR="no"
if [[ -z $( contains "${APP_NAME_LC}-reh-linux-riscv64-${RELEASE_VERSION}.tar.gz" ) ]]; then
echo "Building on Linux RISC-V64 because we have no REH archive"
export SHOULD_BUILD="yes"
else
export SHOULD_BUILD_REH="no"
fi
if [[ "${SHOULD_BUILD}" != "yes" ]]; then
echo "Already have all the Linux PowerPC64LE builds"
fi
fi
# linux-x64
if [[ "${VSCODE_ARCH}" == "x64" || "${CHECK_ALL}" == "yes" ]]; then
if [[ -z $( contains "amd64.deb" ) ]]; then
echo "Building on Linux x64 because we have no DEB"
export SHOULD_BUILD="yes"
else
export SHOULD_BUILD_DEB="no"
fi
if [[ -z $( contains "x86_64.rpm" ) ]]; then
echo "Building on Linux x64 because we have no RPM"
export SHOULD_BUILD="yes"
else
export SHOULD_BUILD_RPM="no"
fi
if [[ -z $( contains "${APP_NAME}-linux-x64-${RELEASE_VERSION}.tar.gz" ) ]]; then
echo "Building on Linux x64 because we have no TAR"
export SHOULD_BUILD="yes"
else
export SHOULD_BUILD_TAR="no"
fi
if [[ -z $( contains "x86_64.AppImage" ) ]]; then
echo "Building on Linux x64 because we have no AppImage"
export SHOULD_BUILD="yes"
else
export SHOULD_BUILD_APPIMAGE="no"
fi
if [[ "${CHECK_REH}" != "no" && -z $( contains "${APP_NAME_LC}-reh-linux-x64-${RELEASE_VERSION}.tar.gz" ) ]]; then
echo "Building on Linux x64 because we have no REH archive"
export SHOULD_BUILD="yes"
else
export SHOULD_BUILD_REH="no"
fi
if [[ "${SHOULD_BUILD}" != "yes" ]]; then
echo "Already have all the Linux x64 builds"
fi
fi
fi
fi
@ -374,7 +380,7 @@ else
if [[ "${IS_SPEARHEAD}" == "yes" ]]; then
export SHOULD_BUILD_SRC="yes"
elif [[ "${OS_NAME}" == "linux" ]]; then
if [[ "${VSCODE_ARCH}" == "ppc64le" ]]; then
if [[ "${VSCODE_ARCH}" == "ppc64le" || "${VSCODE_ARCH}" == "riscv64" ]]; then
SHOULD_BUILD_DEB="no"
SHOULD_BUILD_RPM="no"
SHOULD_BUILD_TAR="no"