Do not export internal symbols from a unix shared library.
This commit is contained in:
parent
7ecd2eb53b
commit
93f4effd2b
@ -77,6 +77,9 @@ endif()
|
|||||||
#--------------------------------------------------------------------
|
#--------------------------------------------------------------------
|
||||||
if (BUILD_SHARED_LIBS)
|
if (BUILD_SHARED_LIBS)
|
||||||
set(_GLFW_BUILD_DLL 1)
|
set(_GLFW_BUILD_DLL 1)
|
||||||
|
if (UNIX OR APPLE)
|
||||||
|
add_definitions(-fvisibility=hidden)
|
||||||
|
endif()
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
#--------------------------------------------------------------------
|
#--------------------------------------------------------------------
|
||||||
|
@ -157,6 +157,10 @@ extern "C" {
|
|||||||
#define GLFWAPI __declspec(dllimport)
|
#define GLFWAPI __declspec(dllimport)
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#elif defined(__GNUC__) && defined(_GLFW_BUILD_DLL)
|
||||||
|
|
||||||
|
#define GLFWAPI __attribute__((visibility("default")))
|
||||||
|
|
||||||
#else
|
#else
|
||||||
|
|
||||||
/* We are either building/calling a static lib or we are non-win32 */
|
/* We are either building/calling a static lib or we are non-win32 */
|
||||||
|
Loading…
Reference in New Issue
Block a user