From 6e60a91fae0ff0719715acb0a10e3814c0229adb Mon Sep 17 00:00:00 2001 From: Lars Erik Wik Date: Thu, 2 Oct 2025 09:00:25 +0200 Subject: [PATCH] build-environment-check: deleted script The list of wanted/unwanted packages is outdated. It only handles redhat and debian based systems. Nowadays we use the cfengine-build-host-setup.cf as the single source of truth. It does exactly what we want, it promises that the build host is setup correctly. Hence, it's time we let this script go. Ticket: ENT-12598 Signed-off-by: Lars Erik Wik --- README.md | 1 - build-remote | 1 - build-scripts/build-environment-check | 71 --------------------------- ci/build.sh | 1 - package-nova-hub.sh | 1 - 5 files changed, 75 deletions(-) delete mode 100755 build-scripts/build-environment-check diff --git a/README.md b/README.md index b11495027..9b60dae78 100644 --- a/README.md +++ b/README.md @@ -44,7 +44,6 @@ Execute the build steps and see that packages are generated: ``` ./buildscripts/build-scripts/autogen ./buildscripts/build-scripts/clean-buildmachine -./buildscripts/build-scripts/build-environment-check ./buildscripts/build-scripts/install-dependencies ./buildscripts/build-scripts/configure ./buildscripts/build-scripts/compile diff --git a/build-remote b/build-remote index 041777212..8a6afdcb4 100755 --- a/build-remote +++ b/build-remote @@ -304,7 +304,6 @@ common_build() { local_script autogen local_script transfer-to-buildmachine - remote_script build-environment-check remote_script clean-buildmachine remote_script install-dependencies diff --git a/build-scripts/build-environment-check b/build-scripts/build-environment-check deleted file mode 100755 index 490181f25..000000000 --- a/build-scripts/build-environment-check +++ /dev/null @@ -1,71 +0,0 @@ -#!/bin/sh - -. "$(dirname "$0")"/functions -. detect-environment -. compile-options - -# WARNING we alter the buildslave: we remove UNWANTED_DEPS - -### SYSTEM PACKAGE DEPENDENCIES ### -# Libtool is unwanted because "libltdl" polutes our package dependencies. -# The rest are wanted only on the machine doing "autogen.sh", -# aka buildmaster, which is *different* from the buildslaves -### TODO add to the unwanted list: bison byacc flex -### TODO unfortunately autoconf is installed by autobuild policy - -case "$OS" in -rhel | centos) - DEP_LIST="gcc-c++ ncurses ncurses-devel pkgconfig pam-devel" - UNWANTED_DEPS="libtool-ltdl libtool-ltdl-devel" - ;; -debian | ubuntu) - DEP_LIST="dpkg-dev debhelper g++ pkg-config build-essential libpam0g-dev" - UNWANTED_DEPS="libltdl-dev libltdl7" - ;; - -# SKIP IN UNKNOWN OS -*) - echo "$0: not implemented for OS $OS, skipping" - exit 0 - ;; -esac - -case "$OS-$OS_VERSION" in -rhel-6* | centos-6*) - DEP_LIST="$DEP_LIST rpm-build" - ;; -rhel-* | centos-*) - DEP_LIST="$DEP_LIST rpm-build-libs" - ;; -*) DEP_LIST="$DEP_LIST fakeroot" ;; -esac - -DEP_LIST="$DEP_LIST rsync gcc make sudo wget" -#UNWANTED_DEPS="$UNWANTED_DEPS libtool" # TODO automake autoconf bison byacc flex - -RET=0 -for unwanted in $UNWANTED_DEPS; do - if query_pkg "$unwanted"; then - echo "ERROR Found unwanted package: $unwanted" - RET=1 - fi -done - -for dep in $DEP_LIST; do - if query_pkg "$dep"; then - true - else - echo "ERROR Missing system package: $dep" - RET=1 - fi -done - -# Exit with the right exit code -if [ $RET = 0 ]; then - echo "$0: SUCCESS buildslave is correctly setup" - exit 0 -else - echo "$0: FAILURE buildslave is NOT correctly setup" - echo "You should edit the policy in autobuild to fix the issues" - exit 1 -fi diff --git a/ci/build.sh b/ci/build.sh index f6dce32d2..384aa9ef8 100755 --- a/ci/build.sh +++ b/ci/build.sh @@ -23,7 +23,6 @@ fi ssh-add -l set -x # stop hiding secrets -time ./buildscripts/build-scripts/build-environment-check time ./buildscripts/build-scripts/install-dependencies time ./buildscripts/build-scripts/configure # 3 minutes locally time ./buildscripts/build-scripts/generate-source-tarballs # 1m49 diff --git a/package-nova-hub.sh b/package-nova-hub.sh index 650286ddc..fed9f162d 100644 --- a/package-nova-hub.sh +++ b/package-nova-hub.sh @@ -13,7 +13,6 @@ export EXPLICIT_ROLE=hub #./buildscripts/build-scripts/autogen #./buildscripts/build-scripts/clean-buildmachine -#./buildscripts/build-scripts/build-environment-check #./buildscripts/build-scripts/install-dependencies #./buildscripts/build-scripts/configure #./buildscripts/build-scripts/compile