[boost] [stacktrace] Not working on Cygwin

43 views
Skip to first unread message

Phil Bouchard via Boost

unread,
Sep 3, 2017, 1:52:38 PM9/3/17
to bo...@lists.boost.org, Phil Bouchard
Hi,

I tried stacktrace on Cygwin and after tweaking some local and system
headers I was able to compile libboost_stacktrace_windbg.a and
libboost_stacktrace_addr2line.a but when I run my application calls to
boost::stacktrace::stacktrace(1, 1) doesn't output anything.

It works fine under Linux using libboost_stacktrace_backtrace.a.


Thanks in advance for your help,
-Phil


_______________________________________________
Unsubscribe & other changes: http://lists.boost.org/mailman/listinfo.cgi/boost

Antony Polukhin via Boost

unread,
Sep 6, 2017, 1:37:14 AM9/6/17
to boost@lists.boost.org List, Antony Polukhin, Phil Bouchard
2017-09-03 20:52 GMT+03:00 Phil Bouchard via Boost <bo...@lists.boost.org>:
> Hi,
>
> I tried stacktrace on Cygwin and after tweaking some local and system
> headers I was able to compile libboost_stacktrace_windbg.a and
> libboost_stacktrace_addr2line.a but when I run my application calls to
> boost::stacktrace::stacktrace(1, 1) doesn't output anything.
>
> It works fine under Linux using libboost_stacktrace_backtrace.a.

Thanks for the issue report!

What headers have you changed in what manner? What version of Cygwin
do you have and were did you downloaded it?


--
Best regards,
Antony Polukhin

Phil Bouchard via Boost

unread,
Sep 6, 2017, 8:27:40 AM9/6/17
to bo...@lists.boost.org, Phil Bouchard
On 09/06/2017 01:36 AM, Antony Polukhin via Boost wrote:
> 2017-09-03 20:52 GMT+03:00 Phil Bouchard via Boost <bo...@lists.boost.org>:
>> Hi,
>>
>> I tried stacktrace on Cygwin and after tweaking some local and system
>> headers I was able to compile libboost_stacktrace_windbg.a and
>> libboost_stacktrace_addr2line.a but when I run my application calls to
>> boost::stacktrace::stacktrace(1, 1) doesn't output anything.
>>
>> It works fine under Linux using libboost_stacktrace_backtrace.a.
>
> Thanks for the issue report!
>
> What headers have you changed in what manner? What version of Cygwin
> do you have and were did you downloaded it?

Basically I have installed the latest Cygwin and:

- There is a missing boost/stacktrace/detail/push_options.pp

- There is a missing boost/stacktrace/detail/pop_options.pp

- I had to change the scope of GetModuleFileNameA in:
stacktrace/detail/location_from_symbol.hpp:
if (!GetModuleFileNameA(handle, file_name_, DEFAULT_PATH_SIZE_))

- I had to change some __POSIX_VISIBLE macros in the system header files
to enable some functions:
/usr/include/stdio.h:337:#if 1//__POSIX_VISIBLE
/usr/include/sys/signal.h:177:#if 1//__POSIX_VISIBLE
/cygwin64/usr/include/sys/unistd.h:292:#if 1//__BSD_VISIBLE ||
__POSIX_VISIBLE >= 200112 || __XSI_VISIBLE >= 4


Thanks,
-Phil
Reply all
Reply to author
Forward
0 new messages