I am debugging a C application running with a dynamically linked shared library. The program runs well on Ubuntu 14.04 64 bit. But it generates segmentation fault on Ubuntu 16.04 when Linux terminates the shared objects upon exiting the application.
Inside gdb, I set a breakpoint right before the segmentation fault happens. Then I use info source
to check the source file information:
Thread 1 "test" hit Breakpoint 3, _dl_fini () at dl-fini.c:201
(gdb) info source
Current source file is dl-fini.c
Compilation directory is /build/glibc-bfm8X4/glibc-2.23/elf
Located in /build/glibc-bfm8X4/glibc-2.23/elf/dl-fini.c
Source language is c.
Producer is GNU C11 5.4.0 20160609 -mno-mmx -mtune=generic -march=x86-64 -g -O2 -O3 -std=gnu11 -fgnu89-inline -fno-stack-protector -fmerge-all-constants -frounding-math -fPIC -ftls-model=initial-exec.
Compiled with DWARF 2 debugging format.
Does not include preprocessor macro info.
I am not able to find the indicated Compilation directory and the location of the source file.
Directory /build/glibc-bfm8X4/glibc-2.23/elf doesn't exist. Anyone has any idea of this situation?
Thanks in advance.