#!/bin/sh # # Installs PanicConf.hs in correct location # this_path="`pwd`/$0" this_dir=`dirname $this_path` panic_dir=$this_dir/.. source $this_dir/../configure.lib # # These constants you may wish to change later (if Cabal changes) # PANIC=Panic PANIC_CONF=PanicConf.hs PANIC_CONF_API=PanicConfAPI.hi PANIC_CABAL=$panic_dir/Panic.cabal SETUP_CONFIG=$panic_dir/dist/setup-config INSTALL_SH=$this_dir/install-sh if test ! -x $INSTALL_SH; then echo "ERROR: install-sh must be present in directory" echo " \``pwd`'" echo " for `basename $0` to run" exit 1 fi install_dir=$prefix/lib/$name-$ver install_dir=`get_install_dir $SETUP_CONFIG $PANIC_CABAL` src_dir=`get_cabal_value hs-source-dirs $PANIC_CABAL` PROJECT=`get_cabal_value executable $PANIC_CABAL` build_dir=`get_config_value buildDir $SETUP_CONFIG` echo "Installing: $PANIC_CONF in $install_dir" $INSTALL_SH -d $install_dir $INSTALL_SH -c $panic_dir/$src_dir/$PANIC_CONF $install_dir $INSTALL_SH -c $panic_dir/$build_dir/$PROJECT/$PROJECT-tmp/PanicConfAPI.hi \ $install_dir $INSTALL_SH -c $panic_dir/$build_dir/$PROJECT/$PROJECT-tmp/PanicConfAPI.o \ $install_dir