#!/bin/sh

# 
# Sample script to accept licenses for the IBM xlf compilers
# For Linux:
#    Assumes all compiler software has been installed

OS=`uname`
if [ $OS != "AIX" ]; then
    cd $installroot/
    xlf_script=`find opt/ibmcmp/xlf -name new_install -print`

    if [ -n $installroot ]; then
        #  Being run from a stateful install postscript or stateless postbootscript.
        if [ -n "$xlf_script" ] ; then
            echo 1 | chroot $installroot /$xlf_script
        fi
    else
        #  Being run from a stateful install postscript postbootscript.
        if [ -n "$xlf_script" ] ; then
           echo 1 | $xlf_script
        fi
    fi
fi  


