Subject: Re: [Fwd: Re: compiling php5 out of memory problem]
To: None <port-sparc@NetBSD.org>
From: Valeriy E. Ushakov <uwe@ptc.spbu.ru>
List: port-sparc
Date: 09/25/2006 17:51:45
On Mon, Sep 25, 2006 at 08:22:36 -0400, Heitzso wrote:
> Ah ... the wonders of the simple ulimit! That was all that was needed.
> The default data size limit was 64M, so the gcc memory allocation
> request of 64M on top of the prior 2M broke and gcc halted. The hard
> limit was 512M or something on that order. So bumping up the current to
> the hard limit was all that was necessary.
[...]
> I don't know if anyone wants to mess with this, but adding this
> explanation to the doc re pkgsrc would be useful. Something along the
> lines of ...
> "
> If a package make stops with an error message stating that a memory
> allocation failed, then you should try rerunning the make after
> increasing the current virtual memory data size to the maximum data
> limit size (also known as the hard limit) using the command sequence:
> ulimit -d # show current data size limit
> ulimit -dH # show maximum data size limit (hard limit)
> ulimit -d `ulimit -dH`; make # run make with maximum data size limit
> "
pkgsrc already have UNLIMIT_RESOURCES variable that packages can set.
E.g. clisp build needs a lot of stack for bootstrapping.
PS: Given what memory hog gcc4 is we might bump memory limit defaults.
SY, Uwe
--
uwe@ptc.spbu.ru | Zu Grunde kommen
http://snark.ptc.spbu.ru/~uwe/ | Ist zu Grunde gehen