Subject: pkg/18087: Support for SunOS "ulimit" command in bsd.pkg.mk
To: None <gnats-bugs@gnats.netbsd.org>
From: Jonathan Perkin <sketch@rd.bbc.co.uk>
List: netbsd-bugs
Date: 08/27/2002 14:55:03
>Number:         18087
>Category:       pkg
>Synopsis:       bsd.pkg.mk doesn't cater for SunOS "ulimit" command
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    pkg-manager
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Tue Aug 27 08:04:00 PDT 2002
>Closed-Date:
>Last-Modified:
>Originator:     Jonathan Perkin
>Release:        NetBSD 1.6F
>Organization:
British Broadcasting Corporation
>Environment:
System: NetBSD batfink.intra.nut 1.6F NetBSD 1.6F (GENERIC) #0: Tue Aug 13 14:37:11 BST 2002 sketch@batfink.intra.nut:/usr/src/sys/arch/i386/compile/GENERIC i386
Architecture: i386
Machine: i386
>Description:
	Solaris 8's (and probably earlier versions too) ulimit command doesn't
	support the "-m" option used in bsd.pkg.mk, preferring the -v option
	for setting amount of (virtual) memory to allocate.
>How-To-Repeat:
	Build pkgsrc/www/mozilla on zoularis and watch it break.
>Fix:
Index: bsd.pkg.mk
===================================================================
RCS file: /cache/ncvs/pkgsrc/mk/bsd.pkg.mk,v
retrieving revision 1.1034
diff -u -r1.1034 bsd.pkg.mk
--- bsd.pkg.mk  2002/08/25 18:52:05     1.1034
+++ bsd.pkg.mk  2002/08/27 12:56:43
@@ -318,7 +318,11 @@
 _ULIMIT_CMD+=  ulimit -s `ulimit -H -s`;
 .  endif
 .  if ${UNLIMIT_RESOURCES:Mmemorysize} != ""
+.    if ${OPSYS} == "SunOS"
+_ULIMIT_CMD+=  ulimit -v `ulimit -H -v`;
+.    else
 _ULIMIT_CMD+=  ulimit -m `ulimit -H -m`;
+.    endif
 .  endif
 .endif
>Release-Note:
>Audit-Trail:
>Unformatted: