summarylogtreecommitdiffstats
path: root/intel-tbb.install
blob: 4d31f8f652eb9d4fe448a97ffd6fba6aa7b42efe (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36

post_install() {

  echo "-----------------------------------------------------------------------------------"
  echo "The dynamic links to the irml libs istalled with openmp are replaced with the" ;
  echo " links to the irml libs contained in the package: intel-tbb" ;
  echo " If you want to use the openmp libs edit by hand the files:" ;
  echo " /etc/ld.so.conf.d/intel-openmp.conf"
  echo " /etc/ld.so.conf.d/intel-tbb.conf"
  echo "-----------------------------------------------------------------------------------"

  if [ -e /etc/ld.so.conf.d/intel-openmp.conf ] ; then
    mv /etc/ld.so.conf.d/intel-openmp.conf /etc/ld.so.conf.d/intel-openmp.backup
    touch /etc/ld.so.conf.d/intel-openmp.conf
  fi ;
  
  ldconfig ;
}

post_upgrade() {
   ldconfig ;
}

post_remove() {
  if [ -e /etc/ld.so.conf.d/intel-openmp.backup ] ; then
    if [ -e /etc/ld.so.conf.d/intel-openmp.conf ] ; then
      rm /etc/ld.so.conf.d/intel-openmp.conf
    fi ;

    mv /etc/ld.so.conf.d/intel-openmp.backup /etc/ld.so.conf.d/intel-openmp.conf
  fi ;

  ldconfig ;
}