SWDEV-310152 - ldconfig should be run from each components providing shared library, since rpath will be removed from binaries and libraries
Revert "SWDEV-310152 - Remove ldconfig from rocm-ocl-icd package"
This reverts commit 0f5c2f0ba8.
Change-Id: Id07f4c8b2915c4ed7937094087ddba8402444da9
This commit is contained in:
@@ -2,12 +2,19 @@
|
|||||||
|
|
||||||
set -e
|
set -e
|
||||||
|
|
||||||
|
INSTALL_PATH=@CPACK_PACKAGING_INSTALL_PREFIX@
|
||||||
|
|
||||||
|
do_ldconfig() {
|
||||||
|
echo ${INSTALL_PATH}/@CMAKE_INSTALL_LIBDIR@ > /@CMAKE_INSTALL_SYSCONFDIR@/ld.so.conf.d/10-rocm-opencl.conf && ldconfig
|
||||||
|
mkdir -p /@CMAKE_INSTALL_SYSCONFDIR@/OpenCL/vendors && (echo libamdocl64.so > /@CMAKE_INSTALL_SYSCONFDIR@/OpenCL/vendors/@OPENCL_AMD_ICD_FILE@)
|
||||||
|
}
|
||||||
|
|
||||||
case "$1" in
|
case "$1" in
|
||||||
abort-deconfigure|abort-remove|abort-upgrade)
|
abort-deconfigure|abort-remove|abort-upgrade)
|
||||||
echo "$1"
|
echo "$1"
|
||||||
;;
|
;;
|
||||||
configure)
|
configure)
|
||||||
mkdir -p /etc/OpenCL/vendors && (echo libamdocl64.so > /etc/OpenCL/vendors/@OPENCL_AMD_ICD_FILE@)
|
do_ldconfig
|
||||||
;;
|
;;
|
||||||
*)
|
*)
|
||||||
exit 0
|
exit 0
|
||||||
|
|||||||
@@ -2,11 +2,16 @@
|
|||||||
|
|
||||||
set -e
|
set -e
|
||||||
|
|
||||||
|
rm_ldconfig() {
|
||||||
|
rm -f /@CMAKE_INSTALL_SYSCONFDIR@/ld.so.conf.d/10-rocm-opencl.conf && ldconfig
|
||||||
|
rm -f /@CMAKE_INSTALL_SYSCONFDIR@/OpenCL/vendors/@OPENCL_AMD_ICD_FILE@
|
||||||
|
}
|
||||||
|
|
||||||
case "$1" in
|
case "$1" in
|
||||||
purge)
|
purge)
|
||||||
;;
|
;;
|
||||||
remove | upgrade )
|
remove | upgrade )
|
||||||
rm -f /etc/OpenCL/vendors/@OPENCL_AMD_ICD_FILE@
|
rm_ldconfig
|
||||||
;;
|
;;
|
||||||
*)
|
*)
|
||||||
exit 0
|
exit 0
|
||||||
|
|||||||
@@ -1 +1,4 @@
|
|||||||
mkdir -p /etc/OpenCL/vendors && (echo libamdocl64.so > /etc/OpenCL/vendors/@OPENCL_AMD_ICD_FILE@)
|
INSTALL_PATH=@CPACK_PACKAGING_INSTALL_PREFIX@
|
||||||
|
|
||||||
|
echo ${INSTALL_PATH}/@CMAKE_INSTALL_LIBDIR@ > /@CMAKE_INSTALL_SYSCONFDIR@/ld.so.conf.d/10-rocm-opencl.conf && ldconfig
|
||||||
|
mkdir -p /@CMAKE_INSTALL_SYSCONFDIR@/OpenCL/vendors && (echo libamdocl64.so > /@CMAKE_INSTALL_SYSCONFDIR@/OpenCL/vendors/@OPENCL_AMD_ICD_FILE@)
|
||||||
|
|||||||
@@ -1,4 +1,8 @@
|
|||||||
|
if [ $1 -eq 0 ]; then
|
||||||
|
# Remove rocm-opencl.conf during remove/uninstall operation
|
||||||
|
rm -f /@CMAKE_INSTALL_SYSCONFDIR@/ld.so.conf.d/10-rocm-opencl.conf && ldconfig
|
||||||
|
fi
|
||||||
# Remove icd file for uninstall and upgrade operation
|
# Remove icd file for uninstall and upgrade operation
|
||||||
rm -f /etc/OpenCL/vendors/@OPENCL_AMD_ICD_FILE@
|
rm -f /@CMAKE_INSTALL_SYSCONFDIR@/OpenCL/vendors/@OPENCL_AMD_ICD_FILE@
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user