From a7f89980e5b3f4b9a74c70dbc5ffe8aabd28be28 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B6rg=20Frings-F=C3=BCrst?= Date: Sun, 6 Jul 2014 18:04:32 +0200 Subject: Imported Upstream version 2.9.3 --- scripts/setlib.sh | 38 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 38 insertions(+) create mode 100755 scripts/setlib.sh (limited to 'scripts/setlib.sh') diff --git a/scripts/setlib.sh b/scripts/setlib.sh new file mode 100755 index 0000000..eca184e --- /dev/null +++ b/scripts/setlib.sh @@ -0,0 +1,38 @@ +#!/bin/sh +# setup sequence for ipmiutil +# +# Resolve whatever libcrypto.so is present to the one that ipmiutil +# was built to reference. +# The default build on RHEL4.4 references libcrypto.so.4 +libver=4 +found=0 + +# check where the libcrypto.so is located +dirs="/usr/lib64 /lib64 /usr/lib /lib" +for d in $dirs +do + libt=`ls $d/libcrypto.so.0.* 2>/dev/null |tail -n1` + if [ "x$libt" != "x" ]; then + # Found a libcrypto.so + libcry=$libt + libdir=$d + found=1 + libnew=$libdir/libcrypto.so.$libver + echo "libcry=$libcry libdir=$libdir libnew=$libnew" + if [ ! -f $libnew ]; then + # Need a sym-link to resolve it + echo "ln -s $libcry $libnew" + ln -s $libcry $libnew + ldconfig + fi + fi +done + +if [ $found -eq 0 ]; then + echo "libcrypto.so not found, install openssl rpm" + rv=1 +else + rv=0 +fi +exit $rv + -- cgit v1.2.3