#/bin/bash

set -e

do_ldconfig() {
    echo /opt/rocm/hsa/lib > /etc/ld.so.conf.d/hsa-ext-rocr-dev.conf && ldconfig
}

case "$1" in
   configure)
       do_ldconfig
   ;;
   abort-upgrade|abort-remove|abort-deconfigure)
       echo "$1"
   ;;
   *)
       exit 0
   ;;
esac
