|
View:
New views
6 Messages
—
Rating Filter:
Alert me
|
|
|
segfault (memory leak?) in GNU Make 3.82.90 (CVS HEAD)Hi,
I am getting a segmentation fault with GNU Make 3.82.90 (CVS HEAD as of earlier today). To obtain more information, I have run it in valgrind. The report is quite long, here is an excerpt: ... ==6816== Invalid write of size 8 ==6816== at 0x40B428: pattern_search (implicit.c:688) ==6816== by 0x40BA3E: pattern_search (implicit.c:755) ==6816== by 0x40BA3E: pattern_search (implicit.c:755) ==6816== by 0x40C1A0: try_implicit_rule (implicit.c:45) ==6816== by 0x418FB5: update_file (remake.c:491) ==6816== by 0x419C15: update_goal_chain (remake.c:155) ==6816== by 0x411C25: main (main.c:2337) ==6816== Address 0x5405530 is 0 bytes after a block of size 64 alloc'd ==6816== at 0x4A0776F: malloc (vg_replace_malloc.c:263) ==6816== by 0x4125A8: xmalloc (misc.c:374) ==6816== by 0x40ABB2: pattern_search (implicit.c:221) ==6816== by 0x40BA3E: pattern_search (implicit.c:755) ==6816== by 0x40BA3E: pattern_search (implicit.c:755) ==6816== by 0x40C1A0: try_implicit_rule (implicit.c:45) ==6816== by 0x418FB5: update_file (remake.c:491) ==6816== by 0x419C15: update_goal_chain (remake.c:155) ==6816== by 0x411C25: main (main.c:2337) ... ==6816== Process terminating with default action of signal 11 (SIGSEGV) ==6816== Access not within mapped region at address 0x0 ==6816== at 0x4A08862: strlen (mc_replace_strmem.c:390) ==6816== by 0x41B428: strcache_add (strcache.c:191) ==6816== by 0x40BC08: pattern_search (implicit.c:883) ==6816== by 0x40BA3E: pattern_search (implicit.c:755) ==6816== by 0x40BA3E: pattern_search (implicit.c:755) ==6816== by 0x40C1A0: try_implicit_rule (implicit.c:45) ==6816== by 0x418FB5: update_file (remake.c:491) ==6816== by 0x419C15: update_goal_chain (remake.c:155) ==6816== by 0x411C25: main (main.c:2337) ... ==6816== LEAK SUMMARY: ==6816== definitely lost: 85 bytes in 4 blocks ==6816== indirectly lost: 0 bytes in 0 blocks ==6816== possibly lost: 3 bytes in 1 blocks ==6816== still reachable: 672,520 bytes in 3,700 blocks ==6816== suppressed: 0 bytes in 0 blocks ... I don't know how to narrow my makefile down to find the culprit. Thanks in advance, Martin _______________________________________________ Help-make mailing list Help-make@... https://lists.gnu.org/mailman/listinfo/help-make |
|
|
|
|
|
|
|
|
Re: segfault (memory leak?) in GNU Make 3.82.90 (CVS HEAD)Hi,
Rereading this post, I see that I did not show what command lead to the segfault problem. Here it is again. Should I file a bug? .SECONDEXPANSION: gen_default_Test_f := \ file1 \ file2 gen_default_Test_bar := bar_foo gen_%.f: $${gen_$$*_f} @echo "f $@" gen_%: \ $$(if $$(gen_$$*_f),gen_%.f) \ $$(if $$(gen_$$*_bar),$$(gen_$$*_bar).ext) @echo "$@" $ touch file1 $ touch file2 $ make gen_default_Test When I use GNU Make 3.81, this works as expected, when I use GNU Make 3.82, it segfaults. Regards, Martin _______________________________________________ Help-make mailing list Help-make@... https://lists.gnu.org/mailman/listinfo/help-make |
|
|
Re: segfault (memory leak?) in GNU Make 3.82.90 (CVS HEAD)On Wed, 2012-04-18 at 20:52 -0400, Martin d'Anjou wrote:
> .SECONDEXPANSION: > gen_default_Test_f := \ > file1 \ > file2 > gen_default_Test_bar := bar_foo > > gen_%.f: $${gen_$$*_f} > @echo "f $@" > > gen_%: \ > $$(if $$(gen_$$*_f),gen_%.f) \ > $$(if $$(gen_$$*_bar),$$(gen_$$*_bar).ext) > @echo "$@" > > $ touch file1 > $ touch file2 > $ make gen_default_Test I've tried the above and in all versions (3.81, 3.82, latest CVS) I get the same result: make: *** No rule to make target 'gen_default_Test'. Stop. Are you sure there's not more needed here? -- ------------------------------------------------------------------------------- Paul D. Smith <psmith@...> Find some GNU make tips at: http://www.gnu.org http://make.mad-scientist.net "Please remain calm...I may be mad, but I am a professional." --Mad Scientist _______________________________________________ Help-make mailing list Help-make@... https://lists.gnu.org/mailman/listinfo/help-make |
|
|
Re: segfault (memory leak?) in GNU Make 3.82.90 (CVS HEAD)> I've tried the above and in all versions (3.81, 3.82, latest CVS) I get > the same result: > > make: *** No rule to make target 'gen_default_Test'. Stop. > > Are you sure there's not more needed here? > I just tried again too. On RedHat Entreprise 5, it does not work, but on a more recent distro (Mint 11), it works. Must be a bug in one of the older libraries. Thanks for checking. Martin _______________________________________________ Help-make mailing list Help-make@... https://lists.gnu.org/mailman/listinfo/help-make |
| Free embeddable forum powered by Nabble | Forum Help |