Skip to content

Commit 3eef736

Browse files
committed
Revert "build: Drop no longer needed -fvisibility=hidden compiler option"
This reverts commit d147876. Hidden visiblity is still useful for builders including a static libsecp.
1 parent c5f2b46 commit 3eef736

File tree

2 files changed

+3
-0
lines changed

2 files changed

+3
-0
lines changed

CMakeLists.txt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -271,6 +271,8 @@ else()
271271
try_append_c_flags(-Wundef)
272272
endif()
273273

274+
set(CMAKE_C_VISIBILITY_PRESET hidden)
275+
274276
set(print_msan_notice)
275277
if(SECP256K1_BUILD_CTIME_TESTS)
276278
include(CheckMemorySanitizer)

configure.ac

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -112,6 +112,7 @@ AC_DEFUN([SECP_TRY_APPEND_DEFAULT_CFLAGS], [
112112
SECP_TRY_APPEND_CFLAGS([-Wcast-align=strict], $1) # GCC >= 8.0
113113
SECP_TRY_APPEND_CFLAGS([-Wconditional-uninitialized], $1) # Clang >= 3.0 only
114114
SECP_TRY_APPEND_CFLAGS([-Wreserved-identifier], $1) # Clang >= 13.0 only
115+
SECP_TRY_APPEND_CFLAGS([-fvisibility=hidden], $1) # GCC >= 4.0
115116
116117
CFLAGS="$SECP_TRY_APPEND_DEFAULT_CFLAGS_saved_CFLAGS"
117118
fi

0 commit comments

Comments
 (0)