#!/bin/sh # $OpenBSD: INSTALL,v 1.3 2003/04/24 23:48:48 todd Exp $ # # Pre/post-installation setup of LAM PATH=/bin:/usr/bin:/sbin:/usr/sbin PREFIX=${PKG_PREFIX:-/usr/local} DB_DIR=${DB_DIR} do_post_install() { for f in bhost.def bhost.lam conf.lam conf.otb helpfile; do file=${SYSCONFDIR}/lam-$f if [ -f $file ]; then existing="$existing lam-$f" else install="$install lam-$f" cp ${PREFIX}/share/examples/lam/lam-$f $file fi done echo echo "+---------------" if ! [ X"${install}" = X"" ]; then echo "| The following files have been copied from the" echo "| ${PREFIX}/share/examples/lam directory to ${SYSCONFDIR}" echo "| $install" fi if ! [ X"${existing}" = X"" ]; then echo "| Current examples for this package are found in:" echo "| ${PREFIX}/share/examples/lam" echo "| The following files were already present:" echo "| $existing" fi echo "+---------------" echo } # Verify/process the command # case $2 in PRE-INSTALL) ;; POST-INSTALL) do_post_install ;; *) echo "usage: $0 distname { PRE-INSTALL | POST-INSTALL }" >&2 exit 1 ;; esac exit 0