Closed apolukhin closed 7 years ago
You can see in https://github.com/boostorg/winapi/blob/develop/include/boost/detail/winapi/dll.hpp#L145 that GetModuleFileNameA
is provided but conditioned on BOOST_NO_ANSI_APIS
, which is a Boost.Config macro defined on some Windows versions. I don't see how it could have been defined for Cygwin, other that it was defined by user or some code, but I think that's the problem.
In general though, you should either check for BOOST_NO_ANSI_APIS
as well and use A or W functions accordingly or just always use W functions. I think there are a few exceptions, but most of the Windows API is universally available in W variant.
Also, make sure you included boost/detail/winapi/dll.hpp
.
However users complain, that it is not available from Boost.WinAPI:
Phil Bouchard:
Currently that line looks like this https://github.com/boostorg/stacktrace/blob/1614e8ff7d79c091bc9216f4f138670db3db8a33/include/boost/stacktrace/detail/location_from_symbol.hpp#L58 , so Phil dropped the
boost::detail::winapi::
to use the global function