Our project (in C ++) should reference boost regex , so we just find the correct compiled libboost_regex_1.45.0 and say g ++ to link it. The compilation was successful, and we just get the correct executable, as expected. The problem is that every time we try to run an executable file, it crashes before entering the main() procedure.
Attaching the generated core file with gdb , the backtrace command shows a segmentation error during __bultin_strlen , which is resolved to strlen@ @GLBC_2.2.5 .
Since our executable is linked to several dynamic libraries, readelf -s used to identify the problematic character, and it boils down to libboost_regex . However, the aforementioned symbol is already present in the RHEL6 system folder /lib64/libc.so .
The question is, how can we work with regex correctly?
- OS: RHEL6.2
- GCC: 4.3.2 /
libstdc++6.0.13 - Boost libraries are built with exactly the same toolbox -
user-config.bjam configured
Static communication is not a good choice for us for various reasons.
Symbol information and ldd information are tied to https://gist.github.com/skyscribe/5184622
source share