Package: charls / 1.1.0+dfsg-2

add_visibility.patch Patch series | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
Description: Use GCC Visibility
Author: Mathieu Malaterre <malat@debian.org>
Forwarded: no

--- charls-1.1.0+dfsg.orig/src/interface.cpp
+++ charls-1.1.0+dfsg/src/interface.cpp
@@ -7,7 +7,7 @@
 #if defined(WIN32) && defined(CHARLS_DLL)
 #define CHARLS_IMEXPORT(returntype) __declspec(dllexport) returntype __stdcall
 #else
-#define CHARLS_IMEXPORT(returntype) returntype
+#define CHARLS_IMEXPORT(returntype) __attribute__ ((visibility ("default"))) returntype
 #endif
 
 #include "config.h"
--- charls-1.1.0+dfsg.orig/src/interface.h
+++ charls-1.1.0+dfsg/src/interface.h
@@ -20,7 +20,7 @@
 
 /* windows dll */
 #if !defined(CHARLS_IMEXPORT) && defined(CHARLS_DLL)
-#  define CHARLS_IMEXPORT(returntype) __declspec(dllimport) returntype __stdcall
+#define CHARLS_IMEXPORT(returntype) __attribute__ ((visibility ("default"))) returntype
 #endif
 
 #if !defined(CHARLS_IMEXPORT)