Files
haikuports/app-arch/lz4/patches/lz4-1.8.0.patchset
2017-08-27 21:32:13 +02:00

80 lines
3.4 KiB
Plaintext

From a5412e8c0b0223ac84aca3707f77b86b8b9bd89d Mon Sep 17 00:00:00 2001
From: Jerome Duval <jerome.duval@gmail.com>
Date: Tue, 5 Aug 2014 17:14:07 +0000
Subject: haiku patch
diff --git a/Makefile b/Makefile
index da485a1..42440b6 100644
--- a/Makefile
+++ b/Makefile
@@ -90,7 +90,7 @@ clean:
#-----------------------------------------------------------------------------
# make install is validated only for Linux, OSX, BSD, Hurd and Solaris targets
#-----------------------------------------------------------------------------
-ifneq (,$(filter $(shell uname),Linux Darwin GNU/kFreeBSD GNU OpenBSD FreeBSD NetBSD DragonFly SunOS))
+ifneq (,$(filter $(shell uname),Linux Darwin GNU/kFreeBSD GNU OpenBSD FreeBSD NetBSD DragonFly SunOS Haiku))
HOST_OS = POSIX
.PHONY: install uninstall
diff --git a/lib/Makefile b/lib/Makefile
index 9abb699..f44d999 100644
--- a/lib/Makefile
+++ b/lib/Makefile
@@ -46,9 +46,7 @@ BUILD_STATIC:=yes
CPPFLAGS+= -DXXH_NAMESPACE=LZ4_
CFLAGS ?= -O3
-DEBUGFLAGS:= -Wall -Wextra -Wcast-qual -Wcast-align -Wshadow \
- -Wswitch-enum -Wdeclaration-after-statement -Wstrict-prototypes -Wundef \
- -Wpointer-arith -Wstrict-aliasing=1
+DEBUGFLAGS:= -Wall -Wshadow -Wstrict-prototypes -Wundef
CFLAGS += $(DEBUGFLAGS) $(MOREFLAGS)
FLAGS = $(CPPFLAGS) $(CFLAGS) $(LDFLAGS)
@@ -96,7 +94,7 @@ ifneq (,$(filter Windows%,$(OS)))
@$(CC) $(FLAGS) -DLZ4_DLL_EXPORT=1 -shared $^ -o dll\$@.dll
dlltool -D dll\liblz4.dll -d dll\liblz4.def -l dll\liblz4.lib
else
- @$(CC) $(FLAGS) -shared $^ -fPIC -fvisibility=hidden $(SONAME_FLAGS) -o $@
+ @$(CC) $(FLAGS) -shared $^ -fPIC $(SONAME_FLAGS) -o $@
@echo creating versioned links
@ln -sf $@ liblz4.$(SHARED_EXT_MAJOR)
@ln -sf $@ liblz4.$(SHARED_EXT)
@@ -113,7 +111,7 @@ clean:
#-----------------------------------------------------------------------------
# make install is validated only for Linux, OSX, BSD, Hurd and Solaris targets
#-----------------------------------------------------------------------------
-ifneq (,$(filter $(shell uname),Linux Darwin GNU/kFreeBSD GNU OpenBSD FreeBSD NetBSD DragonFly SunOS))
+ifneq (,$(filter $(shell uname),Linux Darwin GNU/kFreeBSD GNU OpenBSD FreeBSD NetBSD DragonFly SunOS Haiku))
DESTDIR ?=
# directory variables : GNU convention prefers lowercase
diff --git a/programs/Makefile b/programs/Makefile
index c7ef6d1..d1cabb0 100644
--- a/programs/Makefile
+++ b/programs/Makefile
@@ -46,9 +46,7 @@ OBJFILES := $(patsubst %.c,%.o,$(SRCFILES))
CPPFLAGS += -I$(LZ4DIR) -DXXH_NAMESPACE=LZ4_
CFLAGS ?= -O3
-DEBUGFLAGS:=-Wall -Wextra -Wundef -Wcast-qual -Wcast-align -Wshadow \
- -Wswitch-enum -Wdeclaration-after-statement -Wstrict-prototypes \
- -Wpointer-arith -Wstrict-aliasing=1
+DEBUGFLAGS:=-Wall -Wundef -Wshadow -Wstrict-prototypes
CFLAGS += $(DEBUGFLAGS) $(MOREFLAGS)
FLAGS = $(CFLAGS) $(CPPFLAGS) $(LDFLAGS)
@@ -109,7 +107,7 @@ clean:
#-----------------------------------------------------------------------------
# make install is validated only for Linux, OSX, BSD, Hurd and Solaris targets
#-----------------------------------------------------------------------------
-ifneq (,$(filter $(shell uname),Linux Darwin GNU/kFreeBSD GNU OpenBSD FreeBSD NetBSD DragonFly SunOS))
+ifneq (,$(filter $(shell uname),Linux Darwin GNU/kFreeBSD GNU OpenBSD FreeBSD NetBSD DragonFly SunOS Haiku))
unlz4: lz4
ln -s lz4 unlz4
--
2.7.0