Subject: pkg_create coredumps resulting in empty +CONTENTS
To: None <tech-pkg@NetBSD.org>
From: Lars Nordlund <email@example.com>
Date: 10/25/2005 00:02:24
On my NetBSD i386-current with pkgsrc-current I see this:
===> lars@glengoyne:/usr/pkgsrc/net/openslp %make install
===> do-shlib-handling [openslp-1.2.1] ===> [Automatic ELF shared object handling]
===> register-pkg [openslp-1.2.1] ===> Registering installation for openslp-1.2.1
 Segmentation fault (core dumped) /home/lars/tmp/p...
===> check-wrkref [openslp-1.2.1] ===> Checking for work-directory references in openslp-1.2.1
===> lars@glengoyne:/usr/pkgsrc/net/openslp %echo $?
===> lars@glengoyne:/usr/pkgsrc/net/openslp %ls -la work.glengoyne/.pkgdb/+CONTENTS
-rw-r--r-- 1 root wheel 0 Oct 24 21:47 work.glengoyne/.pkgdb/+CONTENTS
===> lars@glengoyne:/usr/pkgsrc/net/openslp %
i.e. 'make install' silently fails leaving the package with an empty
+CONTENTS file. This causes problems for other packages because they
can't be properly buildlinked (or something like that?).
Debugging gives this:
Program received signal SIGSEGV, Segmentation fault.
0xbbbbf10e in memmove () from /usr/lib/libc.so.12
#0 0xbbbbf10e in memmove () from /usr/lib/libc.so.12
#1 0x5ab8afd4 in ?? ()
#2 0xbbbb73f0 in __bt_split () from /usr/lib/libc.so.12
#3 0xbbbb6bb3 in __bt_split () from /usr/lib/libc.so.12
#4 0xbbbb2eaa in __bt_put () from /usr/lib/libc.so.12
#5 0x0804dd3a in pkgdb_store (
val=0x805b019 "openslp-1.2.1") at pkgdb.c:126
#6 0x0804b56c in check_list (home=0x0, pkg=0xbfbfdf78,
PkgName=0x805b019 "openslp-1.2.1") at pl.c:167
#7 0x0804ab60 in pkg_perform (pkgs=0xbfbfdfc8) at perform.c:317
#8 0x08049ff2 in main (argc=1, argv=0xbfbfe090) at main.c:228
#9 0x08049a9a in ___start ()
I have yet to understand why it bombs in pkgdb_store(). I found
#29894 which could perhaps be the same problem, even though I have
not seen any failing fprintf()'s here.
Anyone else seeing this? I have considered wiping my usr/pkg and
start over from scratch with freshly built packages, but I thought
it could be good to get to the bottom with this problem first, now
that I have it easily reproducible.