From ea184c8f99b1940058c84a51fb38357f9d013d0c Mon Sep 17 00:00:00 2001 From: jlam Date: Mon, 19 Jun 2006 23:20:59 +0000 Subject: Cleanup fallout from {DE,}INSTALL_SRC removal: rewrite the INSTALL script to be of the format expected by the pkginstall framework. Also, split out the important text from the INSTALL script and put it into a MESSAGE file. --- emulators/freebsd_lib/INSTALL | 48 ++++++++++++++++++++----------------------- emulators/freebsd_lib/MESSAGE | 8 ++++++++ 2 files changed, 30 insertions(+), 26 deletions(-) create mode 100644 emulators/freebsd_lib/MESSAGE (limited to 'emulators/freebsd_lib') diff --git a/emulators/freebsd_lib/INSTALL b/emulators/freebsd_lib/INSTALL index 975aeb7b90e..da11b01b1f5 100644 --- a/emulators/freebsd_lib/INSTALL +++ b/emulators/freebsd_lib/INSTALL @@ -1,34 +1,30 @@ -#!/bin/sh -# $NetBSD: INSTALL,v 1.1 2001/10/31 23:52:39 zuntum Exp $ +# $NetBSD: INSTALL,v 1.2 2006/06/19 23:20:59 jlam Exp $ -emul=freebsd -if [ "$2" != "POST-INSTALL" ]; then exit 0; fi +case "${STAGE}" in +POST-INSTALL) + emulsubdir=freebsd -cat </dev/null && pwd -P`" != \ - "`cd / && cd /emul/$emul 2>/dev/null && pwd -P`" ]; then - if [ -e /emul/$emul -o -L /emul/$emul ] || \ - [ \( -e /emul -o -L /emul \) -a ! -d /emul ]; then - cat <<-EOF + emuldir_pwd=`cd $emulsubdir 2>/dev/null && ${PWD_CMD}` + pkgemuldir_pwd=`cd $pkgemulsubdir 2>/dev/null && ${PWD_CMD}` - IMPORTANT: You must create a symbolic link from /emul/$emul to - ${PKG_PREFIX}/emul/$emul in order for this package to work properly. - (It seems there is something else located at /emul/$emul.) - EOF - else - mkdir -p /emul - ln -sf ${PKG_PREFIX}/emul/$emul /emul/$emul - fi -fi + if ${TEST} "$emuldir_pwd" != "$pkgemuldir_pwd"; then + if ${TEST} -e $emuldir -o -L $emuldir; then + ${CAT} << EOF +============================================================================== +You must create a symbolic link for ${PKGNAME} to work properly: -cat < $emuldir +It seems there is something else located at $emuldir. ============================================================================== EOF + else + ${MKDIR} -p `${DIRNAME} $emuldir` && + ${LN} -fs $pkgemuldir $emuldir + fi + fi + ;; +esac diff --git a/emulators/freebsd_lib/MESSAGE b/emulators/freebsd_lib/MESSAGE new file mode 100644 index 00000000000..30cc236404c --- /dev/null +++ b/emulators/freebsd_lib/MESSAGE @@ -0,0 +1,8 @@ +============================================================================== +$NetBSD: MESSAGE,v 1.1 2006/06/19 23:20:59 jlam Exp $ + +Do not forget to include COMPAT_FREEBSD in your kernel configuration +file. FreeBSD binaries require this option in order to work. + +Note that FreeBSD ELF binaries are not yet supported with this package. +============================================================================== -- cgit v1.2.3