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

Fix export define for Windows #765

Merged
merged 5 commits into from
Dec 6, 2022
Merged

Fix export define for Windows #765

merged 5 commits into from
Dec 6, 2022

Conversation

paullouisageneau
Copy link
Owner

This PR fixes the export define for Windows, as previously it would lead to incorrect behavior, for instance re-exported symbols when used as a static library in a dynamic library.

@Nemirtingas
Copy link
Contributor

Nemirtingas commented Dec 1, 2022

Should apply the same to

#ifdef _WIN32
#define RTC_CPP_EXPORT __declspec(dllexport)
#ifndef _WIN32_WINNT
#define _WIN32_WINNT 0x0602 // Windows 8
#endif
#ifdef _MSC_VER
#pragma warning(disable : 4251) // disable "X needs to have dll-interface..."
#endif
#else
#define RTC_CPP_EXPORT
#endif

@paullouisageneau
Copy link
Owner Author

@Nemirtingas I fixed the C++ exports too.

@Nemirtingas
Copy link
Contributor

Nemirtingas commented Dec 2, 2022

LGTM, thanks.

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

Successfully merging this pull request may close these issues.

2 participants