Skip to content

Commit

Permalink
ci,build: add helper to check CentOS min version
Browse files Browse the repository at this point in the history
Some things are different in version 8 and we need to check for that
version.
We typically use 'lsb_release' to that, since the tool is pretty robust.
So, we need to install 'redhat-lsb-core' to get it.

Signed-off-by: Alexandru Ardelean <[email protected]>
  • Loading branch information
commodo committed Apr 6, 2020
1 parent 1b5bae4 commit 7567322
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
2 changes: 1 addition & 1 deletion CI/travis/before_install_linux
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ handle_centos() {
# FIXME: see about adding `libserialport-dev` from EPEL ; maybe libusb-1.0.0-devel...
yum -y groupinstall 'Development Tools'
yum -y install cmake libxml2-devel libusb1-devel doxygen libaio-devel \
avahi-devel bzip2 gzip rpm rpm-build
avahi-devel bzip2 gzip rpm rpm-build redhat-lsb-core
}

handle_centos_docker() {
Expand Down
5 changes: 5 additions & 0 deletions CI/travis/lib.sh
Original file line number Diff line number Diff line change
Expand Up @@ -342,6 +342,11 @@ is_ubuntu_at_least_ver() {
version_ge "$(get_version)" "$1"
}

is_centos_at_least_ver() {
[ "$(get_dist_id)" = "CentOS" ] || return 1
version_ge "$(get_version)" "$1"
}

print_github_api_rate_limits() {
# See https://developer.github.com/v3/rate_limit/
# Note: Accessing this endpoint does not count against your REST API rate limit.
Expand Down

0 comments on commit 7567322

Please sign in to comment.