From 3ce48db90dce97ab2c7bd3c6003daa32cd8fc55d Mon Sep 17 00:00:00 2001 From: Vincent Fu Date: Mon, 23 Sep 2024 16:50:31 +0000 Subject: [PATCH] ci: only remove libunwind-14-dev if installed Some containers no longer have libunwind-14-dev in their repositories. Remove this package only if it is installed. Signed-off-by: Vincent Fu --- ci/actions-install.sh | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/ci/actions-install.sh b/ci/actions-install.sh index e7ba8443..a2d0922c 100755 --- a/ci/actions-install.sh +++ b/ci/actions-install.sh @@ -60,8 +60,10 @@ DPKGCFG librdmacm-dev pkg-config ) - echo "Removing libunwind-14-dev because of conflicts with libunwind-dev" - sudo apt remove -y libunwind-14-dev + if apt list --installed | grep -c "libunwind-14-dev"; then + echo "Removing libunwind-14-dev because of conflicts with libunwind-dev" + sudo apt remove -y libunwind-14-dev + fi if [ "${CI_TARGET_OS}" == "linux" ] || [ "${CI_TARGET_OS}" == "ubuntu" ]; then # Only for Ubuntu pkgs+=( -- 2.25.1