diff --git a/0000-source-target-1.8.patch b/0000-source-target-1.8.patch
index 87cbb32..5fb7dfd 100644
--- a/0000-source-target-1.8.patch
+++ b/0000-source-target-1.8.patch
@@ -2,6 +2,17 @@ diff --git a/build.xml b/build.xml
index 8542245..6179cfa 100644
--- a/build.xml
+++ b/build.xml
+@@ -16,8 +16,8 @@
+
+
+
+-
+-
++
++
+
+
+
@@ -178,8 +178,8 @@
debug="on"
includes="**/*.java"
@@ -9,6 +20,17 @@ index 8542245..6179cfa 100644
- source="1.6"
- target="1.6"
+ source="1.8"
++ target="1.8"
+ >
+
+
+@@ -213,8 +213,8 @@
+ debug="on"
+ includes="**/*.java"
+ excludes="${excludes},**/bak/**"
+- source="1.6"
+- target="1.6"
++ source="1.8"
+ target="1.8"
>
@@ -22,3 +44,14 @@ index 8542245..6179cfa 100644
use="true"
windowtitle="BeanShell ${version}"
doctitle="<h1>BeanShell ${version}<h1>"
+@@ -680,8 +680,8 @@
+ destdir="${build-dir}"
+ debug="on"
+ debuglevel="lines,vars,source"
+- source="1.6"
+- target="1.6"
++ source="1.8"
++ target="1.8"
+ >
+
+
diff --git a/bsh.spec b/bsh.spec
index 9b753b8..3cc46eb 100644
--- a/bsh.spec
+++ b/bsh.spec
@@ -30,7 +30,7 @@
Name: bsh
Version: 2.1.0
-Release: 2%{?dist}
+Release: 3%{?dist}
Epoch: 0
Summary: Lightweight Scripting for Java
URL: http://www.beanshell.org/
@@ -160,6 +160,9 @@ cat scripts/bshdoc.bsh >> %{buildroot}%{_bindir}/bshdoc
%license LICENSE NOTICE
%changelog
+* Thu Dec 2 2021 Hans de Goede - 0:2.1.0-3
+- Fix building with Java 17
+
* Wed Jul 21 2021 Fedora Release Engineering - 0:2.1.0-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild