Update to latest upstream release

This commit is contained in:
Mat Booth 2021-12-06 10:44:36 +00:00
parent 41d3ee08cd
commit 1835620f29
4 changed files with 14 additions and 49 deletions

View File

@ -1,31 +0,0 @@
From f0d18d7027330806097b6f6c221c0a6008f8c503 Mon Sep 17 00:00:00 2001
From: Mat Booth <mat.booth@gmail.com>
Date: Wed, 15 Sep 2021 10:15:08 +0100
Subject: [PATCH 2/2] Fix build from source
---
build.xml | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/build.xml b/build.xml
index 229bec2..797f7fa 100644
--- a/build.xml
+++ b/build.xml
@@ -24,10 +24,10 @@
<mkdir dir="${output}" />
<javac srcdir="${basedir}" destdir="${output}"
- debuglevel="lines,source"
- source="1.8"
- target="1.8">
- <compilerarg line="-Xlint:none"/>
+ debuglevel="lines,vars,source"
+ debug="true"
+ release="11">
+ <compilerarg line="-Xlint:none -encoding cp1252 --patch-module java.compiler=${javaapi}"/>
</javac>
<delete file="${basedir}/META-INF/MANIFEST.MF" failonerror="false"/>
--
2.31.1

View File

@ -1,11 +1,11 @@
Manifest-Version: 1.0
Created-By: Maven Archiver 3.5.0
Created-By: Maven Archiver 3.5.1
Build-Jdk-Spec: 11
Main-Class: org.eclipse.jdt.internal.compiler.batch.Main
Bundle-ManifestVersion: 2
Bundle-Name: Eclipse Compiler for Java(TM)
Bundle-SymbolicName: org.eclipse.jdt.core.compiler.batch
Bundle-Version: 3.27.0.v20210823-1758
Bundle-Version: 3.28.0.v20211117-1416
Bundle-ClassPath: .
Bundle-Vendor: Eclipse.org
Export-Package: org.eclipse.jdt.core,org.eclipse.jdt.core.compiler,org.e

View File

@ -1,9 +1,9 @@
Epoch: 1
%global eclipse_ver 4.21
%global bundle_ver 3.27.0
%global jar_ver %{eclipse_ver}RC2a
%global drop S-%{jar_ver}-202109060500
%global eclipse_ver 4.22
%global bundle_ver 3.28.0
%global jar_ver %{eclipse_ver}RC2
%global drop S-%{jar_ver}-202111241800
Summary: Eclipse Compiler for Java
Name: ecj
@ -17,16 +17,10 @@ Source1: https://repo1.maven.org/maven2/org/eclipse/jdt/ecj/%{bundle_ver}/ecj-%{
# The ecj build does not generate a proper manifest, so use the one from the binary distribution
# Extracted from: https://download.eclipse.org/eclipse/downloads/drops4/%%{drop}/ecj-%%{jar_ver}.jar
Source2: MANIFEST.MF
# Provide API stubs for newer JDKs to allow us to build on the system default JDK where those APIs are not present
# Fetched from: https://git.eclipse.org/c/jdt/eclipse.jdt.core.git/plain/org.eclipse.jdt.compiler.tool/lib/javax16api.jar?h=S4_21_0_RC2a
Source3: javax16api.jar
# Always generate debug info when building RPMs (Andrew Haley)
Patch0: 0001-Always-generate-bytecode-debuginfo.patch
# Include java API stubs in build and fix misc other incorrect build flags
Patch1: 0002-Fix-build-from-source.patch
BuildArch: noarch
BuildRequires: ant
@ -40,12 +34,12 @@ the JDT Core batch compiler.
%prep
%autosetup -p1 -c -n %{name}-%{eclipse_ver}
sed -i -e 's|debuglevel=\"lines,source\"|debug=\"yes\"|g' build.xml
# Specify encoding
sed -i -e '/compilerarg/s/Xlint:none/Xlint:none -encoding cp1252/' build.xml
cp %{SOURCE1} pom.xml
mkdir -p scripts/binary/META-INF/
cp %{SOURCE2} scripts/binary/META-INF/MANIFEST.MF
rm ./META-INF/ECLIPSE_.{SF,RSA}
# Aliases
%mvn_alias org.eclipse.jdt:ecj org.eclipse.jdt:core org.eclipse.jdt.core.compiler:ecj \
@ -53,7 +47,7 @@ rm ./META-INF/ECLIPSE_.{SF,RSA}
%build
export JAVA_HOME=/usr/lib/jvm/java-11
ant -Djavaapi=%{SOURCE3}
ant
%install
%mvn_artifact pom.xml ecj.jar
@ -72,6 +66,9 @@ install -m 644 -p ecj.1 $RPM_BUILD_ROOT%{_mandir}/man1/ecj.1
%{_mandir}/man1/ecj*
%changelog
* Mon Dec 06 2021 Mat Booth <mat.booth@gmail.com> - 1:4.22-1
- Update to latest upstream release
* Wed Sep 15 2021 Mat Booth <mat.booth@gmail.com> - 1:4.21-1
- Update to latest upstream release
- Drop build requirement on Java 8, ecj now requires Java 11

View File

@ -1,3 +1,2 @@
SHA512 (ecj-3.27.0.pom) = 675ab0f5f9a5bb7cc7feb47d98de4623d19a57a89b89d8191e6f7f0e524aae423a7f7fead380b0a58bafab439295ce01eeb442823033d415ac890f6b3ea070a2
SHA512 (ecjsrc-4.21RC2a.jar) = ab940d18f1d5fcbeef3b903a7d719ce6b1dd900d87be08f7a916d6a7d65d8b83b44332dea1642c8d75e2baac3ba8dc27faef659e365cee5f500db99aa9675ce7
SHA512 (javax16api.jar) = 20bed38ea93b7cb91783333dce0023ce86e4d82a8b88950e3abced0ff6c3e086f3b13c25d6ae1674c8ddb8099be3925c7636ef262171b65e035088f61f5306b0
SHA512 (ecj-3.28.0.pom) = 3a3d35abe326323dc76228bcc198c9efbe77ef8f1e233a1d7f051a9fe5f3e619781ddbbf1ca22c180d006a32f9a6ea9c0bffc6f9cb984b911a16dbeb6af7e7c7
SHA512 (ecjsrc-4.22RC2.jar) = cd52a72aecded032625ee83581ac565e1e96f8d26ecfc76e982274fd3d6238f1e7f22576855589b021e9a5ef67686b9b75e010c4e2033a8b7f6e7c9b1ff7eb4c