summaryrefslogtreecommitdiff
path: root/package/lz4/patches/patch-Makefile
blob: 56d9ae37c342853b3b7c1e2f4d45c73b234f03c4 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
--- lz4-r118.orig/Makefile	2014-06-26 11:36:13.000000000 +0200
+++ lz4-r118/Makefile	2014-06-30 07:42:30.000000000 +0200
@@ -39,8 +39,8 @@ LIBVER=$(LIBVER_MAJOR).$(LIBVER_MINOR).$
 
 DESTDIR=
 PREFIX = /usr
-CC    := $(CC)
-CFLAGS+= -I. -std=c99 -O3 -Wall -W -Wundef -DLZ4_VERSION=\"$(RELEASE)\"
+CC    ?= $(CC)
+CFLAGS+= -I. -std=c99 -Wall -W -Wundef -DLZ4_VERSION=\"$(RELEASE)\"
 
 LIBDIR?= $(PREFIX)/lib
 INCLUDEDIR=$(PREFIX)/include
@@ -55,19 +55,10 @@ else
 EXT =
 endif
 
-# OS X 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 ($(shell uname), Darwin)
-	SONAME_FLAGS =
-	SHARED_EXT = dylib
-	SHARED_EXT_MAJOR = $(LIBVER_MAJOR).$(SHARED_EXT)
-	SHARED_EXT_VER = $(LIBVER).$(SHARED_EXT)
-else
-	SONAME_FLAGS = -Wl,-soname=liblz4.$(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=liblz4.$(SHARED_EXT).$(LIBVER_MAJOR)
+SHARED_EXT = so
+SHARED_EXT_MAJOR = $(SHARED_EXT).$(LIBVER_MAJOR)
+SHARED_EXT_VER = $(SHARED_EXT).$(LIBVER)
 
 TEXT = lz4.c lz4.h lz4hc.c lz4hc.h \
 	lz4_format_description.txt Makefile NEWS LICENSE README.md \