diff --git a/src/js_native_api.h b/src/js_native_api.h index acb7316d2d2972..9d0fa811cfa3af 100644 --- a/src/js_native_api.h +++ b/src/js_native_api.h @@ -22,7 +22,7 @@ #ifdef _WIN32 #define NAPI_EXTERN __declspec(dllexport) #else - #define NAPI_EXTERN /* nothing */ + #define NAPI_EXTERN __attribute__((visibility("default"))) #endif #endif diff --git a/src/node.h b/src/node.h index 72911d7982b72f..c260d172c01ebf 100644 --- a/src/node.h +++ b/src/node.h @@ -29,7 +29,7 @@ # define NODE_EXTERN __declspec(dllimport) # endif #else -# define NODE_EXTERN /* nothing */ +# define NODE_EXTERN __attribute__((visibility("default"))) #endif #ifdef BUILDING_NODE_EXTENSION