summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEWouters <6179932+EWouters@users.noreply.github.com>2021-11-01 15:52:20 +0100
committerAndreas Kling <kling@serenityos.org>2021-11-03 11:22:50 +0100
commit617c06e82ed28f5c1c3c27373a07dae38e539d3c (patch)
treef598db5e9ca3c28fa219c16267e97e3ddde94223
parent3a8c423447b391873e206ba2185a0ea0189a6ef4 (diff)
downloadserenity-617c06e82ed28f5c1c3c27373a07dae38e539d3c.zip
Ports: Patch Makefile to use normal soname flags on Mac
Remove if statement altogether, as suggested by timschumi.
-rw-r--r--Ports/zstd/patches/fix_soname_flags.patch24
1 files changed, 24 insertions, 0 deletions
diff --git a/Ports/zstd/patches/fix_soname_flags.patch b/Ports/zstd/patches/fix_soname_flags.patch
new file mode 100644
index 0000000000..1839f3ef0b
--- /dev/null
+++ b/Ports/zstd/patches/fix_soname_flags.patch
@@ -0,0 +1,24 @@
+--- zstd-1.5.0/lib/Makefile.orig 2021-05-14 16:59:34.000000000 +0200
++++ zstd-1.5.0/lib/Makefile 2021-11-01 16:24:07.000000000 +0100
+@@ -206,17 +206,10 @@
+
+ # macOS linker doesn't support -soname, and use different extension
+ # see : https://developer.apple.com/library/mac/documentation/DeveloperTools/Conceptual/DynamicLibraries/100-Articles/DynamicLibraryDesignGuidelines.html
+-ifeq ($(UNAME), Darwin)
+- SHARED_EXT = dylib
+- SHARED_EXT_MAJOR = $(LIBVER_MAJOR).$(SHARED_EXT)
+- SHARED_EXT_VER = $(LIBVER).$(SHARED_EXT)
+- SONAME_FLAGS = -install_name $(LIBDIR)/libzstd.$(SHARED_EXT_MAJOR) -compatibility_version $(LIBVER_MAJOR) -current_version $(LIBVER)
+-else
+- SONAME_FLAGS = -Wl,-soname=libzstd.$(SHARED_EXT).$(LIBVER_MAJOR)
+- SHARED_EXT = so
+- SHARED_EXT_MAJOR = $(SHARED_EXT).$(LIBVER_MAJOR)
+- SHARED_EXT_VER = $(SHARED_EXT).$(LIBVER)
+-endif
++SONAME_FLAGS = -Wl,-soname=libzstd.$(SHARED_EXT).$(LIBVER_MAJOR)
++SHARED_EXT = so
++SHARED_EXT_MAJOR = $(SHARED_EXT).$(LIBVER_MAJOR)
++SHARED_EXT_VER = $(SHARED_EXT).$(LIBVER)
+
+ SET_CACHE_DIRECTORY = \
+ +$(MAKE) --no-print-directory $@ \