Skip to content

Commit

Permalink
archivers/snappy-java: support build with OpenJDK 21
Browse files Browse the repository at this point in the history
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:	xerial/snappy-java#532
  • Loading branch information
VVD committed Jul 26, 2024
1 parent 8fc0225 commit e4f0d70
Showing 1 changed file with 15 additions and 5 deletions.
20 changes: 15 additions & 5 deletions archivers/snappy-java/files/patch-Makefile
Original file line number Diff line number Diff line change
@@ -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
Expand All @@ -9,15 +9,15 @@

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
-SNAPPY_GIT_UNPACKED:=$(TARGET)/snappy-git-extracted.log
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 $@

Expand All @@ -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

Expand Down

0 comments on commit e4f0d70

Please sign in to comment.