Skip to content

Commit

Permalink
xrtdeps : fix and update Fedora package list
Browse files Browse the repository at this point in the history
- Added logic to detect Fedora version from /etc/os-release.
- Introduced conditional inclusion of openssl-static, protobuf-static, and python2-sphinx based on Fedora version:
 - openssl-static for Fedora ≤ 35
 - protobuf-static for Fedora ≤ 38
 - python2-sphinx for Fedora < 32, otherwise python3-sphinx for Fedora ≥ 32
- Cleaned up redundant entries in the package list (FD_LIST).
- Improved error handling for unavailable packages with --skip-broken option in dnf.
- Ensured compatibility with Fedora's evolving package ecosystem by addressing deprecated packages.

Signed-off-by: Marco Dos Santos Oliveira <[email protected]>
  • Loading branch information
Byvirven committed Nov 30, 2024
1 parent 342cbee commit dba89d9
Showing 1 changed file with 78 additions and 63 deletions.
141 changes: 78 additions & 63 deletions src/runtime_src/tools/scripts/xrtdeps.sh
Original file line number Diff line number Diff line change
Expand Up @@ -247,69 +247,84 @@ ub_package_list()

fd_package_list()
{
FD_LIST=(\
boost-devel \
boost-filesystem \
boost-program-options \
boost-static \
cmake \
cppcheck \
curl \
dkms \
dmidecode \
elfutils-devel \
elfutils-libs \
gcc \
gcc-c++ \
gdb \
git \
glibc-static \
gnuplot \
gnutls-devel \
gtest-devel \
json-glib-devel \
kernel-devel-$(uname -r) \
kernel-headers-$(uname -r) \
libcurl-devel \
libdrm-devel \
libffi-devel \
libjpeg-turbo-devel \
libpng12-devel \
libstdc++-static \
libtiff-devel \
libudev-devel \
libuuid-devel \
libyaml-devel \
lm_sensors \
make \
ncurses-devel \
ocl-icd \
ocl-icd-devel \
opencl-headers \
opencv \
openssl-devel \
openssl-static \
pciutils \
perl \
pkgconfig \
protobuf-compiler \
protobuf-devel \
protobuf-static \
python \
python-pip \
python2-sphinx \
python3 \
python3-pip \
redhat-lsb \
rapidjson-devel \
rpm-build \
strace \
systemd-devel \
systemd-devel \
systemtap-sdt-devel \
unzip \
zlib-static \
)
FD_LIST=(\
boost-devel \
boost-filesystem \
boost-program-options \
cmake \
cppcheck \
curl \
dkms \
dmidecode \
elfutils-devel \
elfutils-libs \
gcc \
gcc-c++ \
gdb \
git \
glibc-static \
gnuplot \
gnutls-devel \
gtest-devel \
json-glib-devel \
kernel-devel-$(uname -r) \
kernel-headers-$(uname -r) \
libcurl-devel \
libdrm-devel \
libffi-devel \
libjpeg-turbo-devel \
libpng12-devel \
libstdc++-static \
libtiff-devel \
libudev-devel \
libuuid-devel \
libyaml-devel \
lm_sensors \
make \
ncurses-devel \
ocl-icd \
ocl-icd-devel \
opencl-headers \
opencv \
openssl-devel \
pciutils \
perl \
pkgconfig \
protobuf-compiler \
protobuf-devel \
python \
python-pip \
python3 \
python3-pip \
redhat-lsb \
rapidjson-devel \
rpm-build \
strace \
systemd-devel \
systemtap-sdt-devel \
unzip \
zlib-static \
)

# Detect Fedora version
FEDORA_VERSION=$(grep "^VERSION_ID=" /etc/os-release | cut -d'=' -f2 | tr -d '"')

# Add openssl-static if Fedora <= 35
if (( FEDORA_VERSION <= 35 )); then
FD_LIST+=("openssl-static")
fi

# Add protobuf-static if Fedora <= 38
if (( FEDORA_VERSION <= 38 )); then
FD_LIST+=("protobuf-static")
fi

# Add python2-sphinx if Fedora < 32, else python3-sphinx
if (( FEDORA_VERSION < 32 )); then
FD_LIST+=("python2-sphinx")
else
FD_LIST+=("python3-sphinx")
fi
}


Expand Down

0 comments on commit dba89d9

Please sign in to comment.