diff options
author | 2021-06-23 16:01:20 +0000 | |
---|---|---|
committer | 2021-07-02 13:00:15 +0000 | |
commit | b9d2c34d8a9ff343e3ef2fab7381501682bc6c35 (patch) | |
tree | 6947607bfb1f4d73faabcbd642ac4a59609c39df /ci/install_dependencies.sh | |
parent | 08fd79b551dde788da6974705df9c9d3e8de01d5 (diff) |
[ci] Update build_rpm scripts
* Update to collectd-5.12
* Use systems/$os/$version/build_base_machine.sh to install requirements
* Add patch for updating collectd/contrib/redhat/collectd.spec instead of using sed
Change-Id: I4be4f5ef116d2e61ef1468b4009fcc7a52d9593a
Signed-off-by: Emma Foley <efoley@redhat.com>
(cherry picked from commit 5aa077b485d7d96c47d8757d31904b38596249f6)
Diffstat (limited to 'ci/install_dependencies.sh')
-rwxr-xr-x | ci/install_dependencies.sh | 33 |
1 files changed, 13 insertions, 20 deletions
diff --git a/ci/install_dependencies.sh b/ci/install_dependencies.sh index d131429f..40437804 100755 --- a/ci/install_dependencies.sh +++ b/ci/install_dependencies.sh @@ -1,5 +1,5 @@ #!/bin/bash -# Copyright 2017 Intel Corporation +# Copyright 2017-21 Anuket, Intel Corporation and others # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -16,25 +16,18 @@ DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" source $DIR/utility/package-list.sh -# For collectd -sudo yum install -y yum-utils -sudo yum install -y epel-release -sudo yum-builddep -y collectd - -sudo yum -y install autoconf automake flex bison libtool pkg-config - -sudo yum -y install git - -sudo yum -y install rpm-build \ - libcap-devel xfsprogs-devel iptables-devel \ - libmemcached-devel gtk2-devel libvirt-devel \ - ganglia-devel mysql-devel qpid-proton-c-devel - -# For DMA component -sudo yum -y install hiredis-devel - -# For intel-cmt-cat -sudo yum -y install wget +# Reuse build_base_machine.sh for this distro, to install the required packages +# Detect OS name and version from systemd based os-release file +. /etc/os-release +distro_dir="$DIR/../systems/$ID/$VERSION_ID" + +# build base system using OS specific scripts +if [ -d "$distro_dir" ] && [ -e "$distro_dir/build_base_machine.sh" ]; then + sudo $distro_dir/build_base_machine.sh || ( echo "$distro_dir/build_base_machine.sh failed" && exit 1 ) +else + "$distro_dir is not supported" + exit 1 +fi # For RPM build mkdir -p $RPM_WORKDIR/{BUILD,RPMS,SOURCES,SPECS,SRPMS} |