Skip to content

Commit 04496ae

Browse files
committed
Add default visibility attribute to non-windows platforms
Signed-off-by: Martynas Gurskas <[email protected]>
1 parent 62cfaa5 commit 04496ae

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

CHANGELOG.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
----
44

5-
- Scaffolding: Decorate public functions with `__declspec(dllexport)` under Windows
5+
- Scaffolding: Decorate public functions with `__declspec(dllexport)` under Windows and `__attribute__((visibility("default")))` on other platforms
66

77
#### v0.4.0+v0.25.0
88

bindgen/src/bindings/cpp/templates/cpp_scaffolding.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
#if defined(_WIN32) || defined(_WIN64)
1010
#define UNIFFI_EXPORT __declspec(dllexport)
1111
#else
12-
#define UNIFFI_EXPORT
12+
#define UNIFFI_EXPORT __attribute__((visibility("default")))
1313
#endif
1414

1515
#include <stdio.h>

0 commit comments

Comments
 (0)