Skip to content

Commit

Permalink
cares.sh: try workaround for hiding symbols 14
Browse files Browse the repository at this point in the history
  • Loading branch information
vszakats committed Jan 26, 2025
1 parent 69756c5 commit dd60875
Showing 1 changed file with 6 additions and 24 deletions.
30 changes: 6 additions & 24 deletions cares.patch
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
diff --git a/include/ares.h b/include/ares.h
index 7fe3ec78..dd0bf3e4 100644
index 7fe3ec78..ac417245 100644
--- a/include/ares.h
+++ b/include/ares.h
@@ -116,7 +116,7 @@ extern "C" {
# endif
@@ -117,7 +117,7 @@ extern "C" {
# endif
#else
-# if defined(__GNUC__) && __GNUC__ >= 4
+# if (defined(__GNUC__) && __GNUC__ >= 4) || defined(__clang__)
# define CARES_EXTERN __attribute__((visibility("default")))
# if defined(__GNUC__) && __GNUC__ >= 4
-# define CARES_EXTERN __attribute__((visibility("default")))
+# define CARES_EXTERN
# elif defined(__INTEL_COMPILER) && __INTEL_COMPILER >= 900
# define CARES_EXTERN __attribute__((visibility("default")))
# elif defined(__SUNPRO_C)
diff --git a/src/lib/event/ares_event_configchg.c b/src/lib/event/ares_event_configchg.c
index 4dd6df8d..77335728 100644
--- a/src/lib/event/ares_event_configchg.c
Expand All @@ -23,21 +23,3 @@ index 4dd6df8d..77335728 100644
# include <sys/types.h>
# include <unistd.h>
# include <notify.h>
diff --git a/src/lib/CMakeLists.txt b/src/lib/CMakeLists.txt
index 9d4e1092..395342c3 100644
--- a/src/lib/CMakeLists.txt
+++ b/src/lib/CMakeLists.txt
@@ -40,13 +40,6 @@ IF (CARES_SHARED)
SET_TARGET_PROPERTIES (${PROJECT_NAME} PROPERTIES C_STANDARD 99)
ENDIF ()

- IF (CARES_SYMBOL_HIDING)
- SET_TARGET_PROPERTIES (${PROJECT_NAME} PROPERTIES
- C_VISIBILITY_PRESET hidden
- VISIBILITY_INLINES_HIDDEN YES
- )
- ENDIF ()
-
TARGET_INCLUDE_DIRECTORIES (${PROJECT_NAME}
PUBLIC "$<BUILD_INTERFACE:${PROJECT_BINARY_DIR}>"
"$<BUILD_INTERFACE:${PROJECT_SOURCE_DIR}>"

0 comments on commit dd60875

Please sign in to comment.