[Bug 281310] sysutils/avfs - Core dump when used in x11-fm/worker, strips debug symbols

From: <bugzilla-noreply_at_freebsd.org>
Date: Fri, 06 Sep 2024 09:27:19 UTC
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=281310

            Bug ID: 281310
           Summary: sysutils/avfs - Core dump when used in x11-fm/worker,
                    strips debug symbols
           Product: Ports & Packages
           Version: Latest
          Hardware: Any
                OS: Any
            Status: New
          Severity: Affects Only Me
          Priority: ---
         Component: Individual Port(s)
          Assignee: ports-bugs@FreeBSD.org
          Reporter: ax61@disroot.org
                CC: mp39590@gmail.com
             Flags: maintainer-feedback?(mp39590@gmail.com)
                CC: mp39590@gmail.com

FreeBSD provided package, for v14.1, of x11-fm/worker died just after starting
with segmentation fault. By default (per default port options), worker is
compiled with avfs port.

worker worked without any issues after compiling it WITHOUT avfs.

I had tried to compile sysutils/avfs with debug symbols but they were removed
anyway during installation of the port.

Let me known if there is some other option that I could twiddle for the debug
symbols not be removed, or after the port has been fixed to install without
symbol removal in case that could help with core dump. Then I will try again.

# cd sysutils/avfs
# make showconfig
===> The following configuration options are available for avfs-1.1.4:
     DAV=off: Build the DAV module (requires libneon)
     DEBUG=on: Build with debugging support
     FUSE=off: FUSE (Filesystem in Userspace) support
     ZSTD=off: Zstandard compression support
===> Use 'make config' to modify these settings

# make build && make install
...
checking whether to build shared library and/or fuse daemon... shared
checking whether debugging is enabled... yes
...
libtool: install: /usr/bin/install -c .libs/libavfs.lai
/aux-build/ports/freebsd/ports/sysutils/avfs/work/stage/usr/local/lib/libavfs.la
libtool: install: /usr/bin/install -c .libs/libavfs.a
/aux-build/ports/freebsd/ports/sysutils/avfs/work/stage/usr/local/lib/libavfs.a
libtool: install: strip --strip-debug
/aux-build/ports/freebsd/ports/sysutils/avfs/work/stage/usr/local/lib/libavfs.a
libtool: install: chmod 644
/aux-build/ports/freebsd/ports/sysutils/avfs/work/stage/usr/local/lib/libavfs.a
libtool: install: ranlib
/aux-build/ports/freebsd/ports/sysutils/avfs/work/stage/usr/local/lib/libavfs.a
...

# file /usr/local/lib/libavfs.a /usr/local/lib/libavfs.so*
/usr/local/lib/libavfs.a:        current ar archive
/usr/local/lib/libavfs.so:       symbolic link to libavfs.so.0.0.2
/usr/local/lib/libavfs.so.0:     symbolic link to libavfs.so.0.0.2
/usr/local/lib/libavfs.so.0.0.2: ELF 64-bit LSB shared object, x86-64, version
1 (FreeBSD), dynamically linked, for FreeBSD 14.1 (1401502), stripped


I tried to build worker with DEBUG option, did not seem to have helped ...

# make build -DDEBUG && make install -DDEBUG


Below is the output of "bt all" for the worker core dump FWTW ...

(lldb) target create "/usr/local/bin/worker" --core "worker.core"
Core file '/home/<user>/worker.core' (x86_64) was loaded.
(lldb) bt all
* thread #1, name = 'worker', stop reason = signal SIGSEGV
  * frame #0: 0x000000082b2f486b libc.so.7`___lldb_unnamed_symbol6293 at
strlen.S:95
    frame #1: 0x0000000822df07a9 libavfs.so.0`___lldb_unnamed_symbol272 + 281
    frame #2: 0x0000000822dff704 libavfs.so.0`___lldb_unnamed_symbol577 + 68
    frame #3: 0x0000000822e15a78 libavfs.so.0`___lldb_unnamed_symbol814 + 152
    frame #4: 0x0000000822e16070 libavfs.so.0`___lldb_unnamed_symbol823 + 144
    frame #5: 0x0000000822df379f libavfs.so.0`___lldb_unnamed_symbol327 + 591
    frame #6: 0x0000000822df9320 libavfs.so.0`___lldb_unnamed_symbol467 + 80
    frame #7: 0x00000000003c97c8 worker`___lldb_unnamed_symbol3755 + 184
    frame #8: 0x000000000039230b worker`___lldb_unnamed_symbol3065 + 667
    frame #9: 0x0000000000392962 worker`___lldb_unnamed_symbol3073 + 98
    frame #10: 0x0000000000390dc1 worker`___lldb_unnamed_symbol3001 + 97
    frame #11: 0x0000000000398968 worker`___lldb_unnamed_symbol3174 + 88
    frame #12: 0x00000000004f6b46 worker`___lldb_unnamed_symbol7383 + 342
    frame #13: 0x0000000000507c4d worker`___lldb_unnamed_symbol7433 + 1277
    frame #14: 0x000000082b213916 libc.so.7`__libc_start1(argc=1,
argv=0x00000008207382a8, env=0x000000>
    frame #15: 0x00000000002f87c0 worker`___lldb_unnamed_symbol920 + 48

-- 
You are receiving this mail because:
You are the assignee for the bug.