1
0
mirror of https://git.FreeBSD.org/ports.git synced 2024-12-31 05:41:08 +00:00

archivers/snappy-java: support build with OpenJDK 21

In Java 21 compiler removed support for source and target 1.7 (7).

PR:		280316
Approved by:	Angelo Polo <language.devel@gmail.com>
Obtained from:	https://github.com/xerial/snappy-java/issues/532
This commit is contained in:
Vladimir Druzenko 2024-07-26 20:54:22 +03:00
parent 8fc02254f2
commit e4f0d70750

View File

@ -1,6 +1,6 @@
--- Makefile.orig 2023-10-08 13:55:19 UTC
--- Makefile.orig 2023-09-27 02:22:20 UTC
+++ Makefile
@@ -4,7 +4,7 @@ include Makefile.common
@@ -4,7 +4,7 @@ MVN:=mvn
$(info OS_NAME:$(OS_NAME), OS_ARCH:$(OS_ARCH))
MVN:=mvn
@ -9,7 +9,7 @@
all: snappy
@@ -17,7 +17,6 @@ SNAPPY_GIT_REPO_URL:=https://github.com/google/snappy
@@ -17,7 +17,6 @@ SNAPPY_UNPACKED:=$(TARGET)/snappy-extracted.log
# Change this variable to use a specific git commit
SNAPPY_GIT_REV:=$(SNAPPY_VERSION)
SNAPPY_UNPACKED:=$(TARGET)/snappy-extracted.log
@ -17,7 +17,7 @@
SNAPPY_CMAKE_CACHE=$(SNAPPY_OUT)/CMakeCache.txt
BITSHUFFLE_ARCHIVE:=$(TARGET)/bitshuffle-$(BITSHUFFLE_VERSION).tar.gz
@@ -74,21 +73,12 @@ $(SNAPPY_UNPACKED): $(SNAPPY_ARCHIVE)
@@ -74,37 +73,28 @@ $(SNAPPY_UNPACKED): $(SNAPPY_ARCHIVE)
$(TAR) xvfz $< -C $(TARGET)
touch $@
@ -41,7 +41,17 @@
snappy-header: $(SNAPPY_CMAKE_CACHE)
@@ -104,7 +94,7 @@ $(TARGET)/jni-classes/org/xerial/snappy/BitShuffleNati
$(TARGET)/jni-classes/org/xerial/snappy/SnappyNative.class: $(SRC)/org/xerial/snappy/SnappyNative.java
@mkdir -p $(TARGET)/jni-classes
- $(JAVAC) -source 1.7 -target 1.7 -h $(SRC)/org/xerial/snappy/ -d $(TARGET)/jni-classes -sourcepath $(SRC) $<
+ $(JAVAC) -source 8 -target 8 -h $(SRC)/org/xerial/snappy/ -d $(TARGET)/jni-classes -sourcepath $(SRC) $<
$(SRC)/org/xerial/snappy/SnappyNative.h: $(TARGET)/jni-classes/org/xerial/snappy/SnappyNative.class
$(TARGET)/jni-classes/org/xerial/snappy/BitShuffleNative.class: $(SRC)/org/xerial/snappy/BitShuffleNative.java
@mkdir -p $(TARGET)/jni-classes
- $(JAVAC) -source 1.7 -target 1.7 -h $(SRC)/org/xerial/snappy/ -d $(TARGET)/jni-classes -sourcepath $(SRC) $<
+ $(JAVAC) -source 8 -target 8 -h $(SRC)/org/xerial/snappy/ -d $(TARGET)/jni-classes -sourcepath $(SRC) $<
$(SRC)/org/xerial/snappy/BitShuffleNative.h: $(TARGET)/jni-classes/org/xerial/snappy/BitShuffleNative.class