URL: <http://savannah.gnu.org/bugs/?48009>
Summary: Increased stack rlimit is inherited by the subprocesses to make when make restarts Project: make Submitted by: jeremyd Submitted on: Wed 25 May 2016 12:00:19 PM GMT Severity: 3 - Normal Item Group: Bug Status: None Privacy: Public Assigned to: None Open/Closed: Open Discussion Lock: Any Component Version: SCM Operating System: POSIX-Based Fixed Release: None Triage Status: None _______________________________________________________ Details: The fix for https://savannah.gnu.org/bugs/?22010 is incomplete. When make restarts itself due to an updated makefile it re-exec's itself inheriting the increased stack rlimit but without remembering the original saved values so the re-exec'd make will run its subprocesses with the increased stack limit. This sequence of commands demonstrates the bug: $ ulimit -H -s 32768 $ ulimit -s 4096 $ cat Makefile include foo.inc foo.inc: bar.txt touch $@ show-stack-rlimit: ulimit -s $ echo > foo.inc $ echo > bar.txt $ make show-stack-rlimit touch foo.inc ulimit -s 32768 <-- inherited the stack increase to the hard limit $ make show-stack-rlimit ulimit -s 4096 The attached patch resolves the issue for me. _______________________________________________________ File Attachments: ------------------------------------------------------- Date: Wed 25 May 2016 12:00:19 PM GMT Name: stack-rlimit-make-restart.patch Size: 856B By: jeremyd <http://savannah.gnu.org/bugs/download.php?file_id=37259> _______________________________________________________ Reply to this item at: <http://savannah.gnu.org/bugs/?48009> _______________________________________________ Message sent via/by Savannah http://savannah.gnu.org/ _______________________________________________ Bug-make mailing list Bug-make@gnu.org https://lists.gnu.org/mailman/listinfo/bug-make