openbsd-ports/devel/libtai/pkg/INSTALL
lebel f4a0279a0b initial import of libtai-0.60:
--
libtai is a library for storing and manipulating dates and times.
 
libtai supports two time scales: (1) TAI64, covering a few hundred
billion years with 1-second precision; (2) TAI64NA, covering the
same period with 1-attosecond precision. Both scales are defined
in terms of TAI, the current international real time standard.

Submitted by Brian J. Kifiak <bk@rt.fm>

checked by wilfried@ (thanks!)
2001-04-16 20:14:24 +00:00

65 lines
1.3 KiB
Plaintext

#!/bin/sh
# $OpenBSD: INSTALL,v 1.1.1.1 2001/04/16 20:14:24 lebel Exp $
#
# Pre/post-installation setup of libtai
# exit on errors, use a sane path and install prefix
#
set -e
PATH=/bin:/usr/bin:/sbin:/usr/sbin
PREFIX=${PKG_PREFIX:-/usr/local}
CONFIG_FILE=${SYSCONFDIR}/leapsecs.dat
SAMPLE_CONFIG_FILE=$PREFIX/share/libtai/leapsecs.dat
do_notice()
{
echo
echo "+---------------"
echo "| The existing $1 configuration file, $CONFIG_FILE,"
echo "| has NOT been changed. You may want to compare it to the"
echo "| current file, $SAMPLE_CONFIG_FILE,"
echo "| and update your configuration as needed."
echo "+---------------"
echo
}
do_install()
{
install -o root -g wheel -m 644 $SAMPLE_CONFIG_FILE $CONFIG_FILE
echo
echo "+---------------"
echo "| The $1 configuration file, $CONFIG_FILE,"
echo "| has been installed. "
echo "+---------------"
echo
}
# verify proper execution
#
if [ $# -ne 2 ]; then
echo "usage: $0 distname { PRE-INSTALL | POST-INSTALL }" >&2
exit 1
fi
# Verify/process the command
#
case $2 in
PRE-INSTALL)
: nothing to pre-install for this port
;;
POST-INSTALL)
if [ -f $CONFIG_FILE ]; then
do_notice $1
else
do_install $1
fi
;;
*)
echo "usage: $0 distname { PRE-INSTALL | POST-INSTALL }" >&2
exit 1
;;
esac
exit 0