summaryrefslogtreecommitdiff
path: root/emulators/freebsd_lib/Makefile
diff options
context:
space:
mode:
authortv <tv@pkgsrc.org>1999-05-22 19:31:07 +0000
committertv <tv@pkgsrc.org>1999-05-22 19:31:07 +0000
commitf62bec75b30eab073376e20f3f5a4e043b1c1497 (patch)
treeadb66a3a9bfe7a9cd21e93ab28d58795ec74474e /emulators/freebsd_lib/Makefile
parent50265bfb0c9ac46c65a4a51f011867937cc159a0 (diff)
downloadpkgsrc-f62bec75b30eab073376e20f3f5a4e043b1c1497.tar.gz
Clean this up a bit:
- actually extract to ${WRKDIR} and use find, xargs, and ${INSTALL_DATA{,_DIR}} to get the permissions right - add a "smart-/emul" script that will automatically add a symlink from /emul/freebsd (adding /emul directory as necessary) only in the cases where this will not clobber something; otherwise print a message at install time that the user must do this. Note that this still works if /emul is a symlink to ${LOCALBASE}/emul, though that is no longer required. - issue a message at install time reminding the user to add COMPAT_FREEBSD to the kernel configuration.
Diffstat (limited to 'emulators/freebsd_lib/Makefile')
-rw-r--r--emulators/freebsd_lib/Makefile26
1 files changed, 9 insertions, 17 deletions
diff --git a/emulators/freebsd_lib/Makefile b/emulators/freebsd_lib/Makefile
index a081e908a49..6a927309ac0 100644
--- a/emulators/freebsd_lib/Makefile
+++ b/emulators/freebsd_lib/Makefile
@@ -1,10 +1,11 @@
-# $NetBSD: Makefile,v 1.3 1998/12/12 18:10:31 frueauf Exp $
+# $NetBSD: Makefile,v 1.4 1999/05/22 19:31:07 tv Exp $
#
DISTNAME= freebsd_lib-2.2.7
CATEGORIES= emulators
MASTER_SITES= http://www.flame.org/NetBSD/
ONLY_FOR_ARCHS= i386
+ONLY_FOR_OPSYS= NetBSD
MAINTAINER= packages@netbsd.org
@@ -19,24 +20,15 @@ MAINTAINER= packages@netbsd.org
MIRROR_DISTFILE= no
NO_BUILD= yes
-EXTRACT_ONLY= # empty
NO_WRKSUBDIR= yes
-EMUL_DIR= ${PREFIX}/emul
-FREEBSD_DIR= ${EMUL_DIR}/freebsd
-
-pre-install:
- @[ -d ${EMUL_DIR} ] || ${MKDIR} ${EMUL_DIR}
- @if [ ! -e /emul ] || \
- [ "`ls -i /emul/.`" != "`ls -i ${EMUL_DIR}`" ]; \
- then \
- ${ECHO} -n "You must create a link \"/emul\" "; \
- ${ECHO} "pointing to \"${EMUL_DIR}\"."; \
- exit 1; \
- fi
-
do-install:
- ${MKDIR} ${FREEBSD_DIR}
- (cd ${FREEBSD_DIR}; pax -rzf ${DISTDIR}/${DISTNAME}.tar.gz)
+ @${INSTALL_DATA_DIR} ${PREFIX}/emul/freebsd
+ @(cd ${WRKSRC} && find usr -type d -print) | \
+ (cd ${PREFIX}/emul/freebsd && xargs ${INSTALL_DATA_DIR})
+ @cd ${WRKSRC} && for file in `find usr -name '*.*' -print`; do \
+ ${INSTALL_DATA} $$file ${PREFIX}/emul/freebsd/$$file; \
+ done
+ @${SETENV} PKG_PREFIX="${PREFIX}" ${SH} ${INSTALL_FILE} - POST-INSTALL
.include "../../mk/bsd.pkg.mk"