Skip to content

Commit

Permalink
Move libmodbus+yum fixes to install_libmodbus.
Browse files Browse the repository at this point in the history
  • Loading branch information
lhartmann committed Sep 7, 2023
1 parent 2406e06 commit 9dab3cf
Showing 1 changed file with 6 additions and 7 deletions.
13 changes: 6 additions & 7 deletions background_installer.sh
Original file line number Diff line number Diff line change
Expand Up @@ -160,6 +160,12 @@ function install_libmodbus {
fi
$1 ldconfig
cd "$OPENPLC_DIR"

# Fix for RPM-based distros
if [ -x /bin/yum ]; then
sudo cp /usr/local/lib/pkgconfig/libmodbus.pc /usr/share/pkgconfig/
sudo cp /usr/local/lib/lib*.* /lib64/
fi
}

function install_systemd_service() {
Expand Down Expand Up @@ -286,13 +292,6 @@ elif [ "$1" == "linux" ]; then

install_all_libs sudo
install_systemd_service sudo

# Fix for RPM-based distros
if [ -x /bin/yum ]; then
sudo cp /usr/local/lib/pkgconfig/libmodbus.pc /usr/share/pkgconfig/
sudo cp /usr/local/lib/lib*.* /lib64/
fi

finalize_install

elif [ "$1" == "docker" ]; then
Expand Down

0 comments on commit 9dab3cf

Please sign in to comment.