diff --git a/geronimo-specs.build.xml b/geronimo-specs.build.xml
index 574fac3..4c93311 100644
--- a/geronimo-specs.build.xml
+++ b/geronimo-specs.build.xml
@@ -204,7 +204,7 @@
-
+
diff --git a/geronimo-specs.spec b/geronimo-specs.spec
index cd02ac4..0719193 100644
--- a/geronimo-specs.spec
+++ b/geronimo-specs.spec
@@ -25,6 +25,7 @@ License: Apache-2.0
Group: Development/Languages/Java
URL: https://geronimo.apache.org
Source0: %{name}-%{version}-src.tar.bz2
+Patch0: sun-security-provider.patch
# STEPS TO CREATE THE SOURCE FILE
# mkdir geronimo-specs-1.2
# cd geronimo-specs-1.2
@@ -627,6 +628,7 @@ package are deprecated and will disapear in future releases.
%prep
%setup -q
+%patch0 -p1
chmod -R go=u-w *
mkdir etc
cp LICENSE.txt etc
@@ -637,8 +639,7 @@ cp %{SOURCE1000} build.xml
%pom_xpath_set pom:project/pom:version 1.1.1 geronimo-spec-j2ee
%build
-ant -Dant.build.javac.source=8 -Dant.build.javac.target=8 \
- -Didlj=%{java_home}/bin/idlj
+%ant -Dant.build.javac.source=8 -Dant.build.javac.target=8
%install
set +x
diff --git a/sun-security-provider.patch b/sun-security-provider.patch
new file mode 100644
index 0000000..50e4956
--- /dev/null
+++ b/sun-security-provider.patch
@@ -0,0 +1,24 @@
+diff -urEbwB geronimo-specs-1.2.orig/geronimo-javamail_1.3.1_spec-1.3/src/main/java/javax/mail/internet/NewsAddress.java geronimo-specs-1.2/geronimo-javamail_1.3.1_spec-1.3/src/main/java/javax/mail/internet/NewsAddress.java
+--- geronimo-specs-1.2.orig/geronimo-javamail_1.3.1_spec-1.3/src/main/java/javax/mail/internet/NewsAddress.java 2023-10-16 15:51:42.237871542 +0200
++++ geronimo-specs-1.2/geronimo-javamail_1.3.1_spec-1.3/src/main/java/javax/mail/internet/NewsAddress.java 2023-10-16 15:51:58.961315753 +0200
+@@ -25,8 +25,6 @@
+
+ import javax.mail.Address;
+
+-import sun.security.provider.Sun;
+-
+ /**
+ * A representation of an RFC1036 Internet newsgroup address.
+ *
+diff -urEbwB geronimo-specs-1.2.orig/geronimo-javamail_1.4_spec-1.1/src/main/java/javax/mail/internet/NewsAddress.java geronimo-specs-1.2/geronimo-javamail_1.4_spec-1.1/src/main/java/javax/mail/internet/NewsAddress.java
+--- geronimo-specs-1.2.orig/geronimo-javamail_1.4_spec-1.1/src/main/java/javax/mail/internet/NewsAddress.java 2023-10-16 15:51:42.244538252 +0200
++++ geronimo-specs-1.2/geronimo-javamail_1.4_spec-1.1/src/main/java/javax/mail/internet/NewsAddress.java 2023-10-16 15:52:20.221456718 +0200
+@@ -25,8 +25,6 @@
+
+ import javax.mail.Address;
+
+-import sun.security.provider.Sun;
+-
+ /**
+ * A representation of an RFC1036 Internet newsgroup address.
+ *