Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Linking error to advapi32 when using BOOST_AUTO_LINK_SYSTEM #54

Open
rlpires opened this issue Apr 4, 2019 · 0 comments
Open

Linking error to advapi32 when using BOOST_AUTO_LINK_SYSTEM #54

rlpires opened this issue Apr 4, 2019 · 0 comments

Comments

@rlpires
Copy link

rlpires commented Apr 4, 2019

Under Windows, the code in random_device.cpp automatically links to the library advapi32.lib.
This uses the auto_link.hpp header combined with the macro BOOST_AUTO_LINK_NOMANGLE to produce the correct library file name to link.

As of version 1.69, it is also possible to use the macro BOOST_AUTO_LINK_SYSTEM, which is exclusive with the NOMANGLE macro.
Using the former causes a link error as the library file name added by auto_link is incorrect.
I would suggest undefining the BOOST_AUTO_LINK_SYSTEM before including the auto_link header in random_device.cpp.

#define BOOST_LIB_NAME "Advapi32"

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant