SHA256
1
0
forked from pool/opa-fmgui

Accepting request 969200 from home:fstrba:branches:science:HPC

fix build in Factory + don't build with gradle + use non-vulnerable reload4j instead of log4j

OBS-URL: https://build.opensuse.org/request/show/969200
OBS-URL: https://build.opensuse.org/package/show/science:HPC/opa-fmgui?expand=0&rev=45
This commit is contained in:
Nicolas Morey-Chaisemartin 2022-04-11 16:30:24 +00:00 committed by Git OBS Bridge
parent 33c8d54365
commit 09bffafab1
10 changed files with 90 additions and 105 deletions

View File

@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:b49c6da1b2cb67a0caf6c7480630b51c70a11ca2016ff2f555eaeda863143a29
size 78420037

View File

@ -1,15 +0,0 @@
diff --git a/build.gradle b/build.gradle
index 78d2c13..a50b106 100644
--- a/build.gradle
+++ b/build.gradle
@@ -7,7 +7,9 @@ allprojects {
sourceCompatibility = 1.7
repositories {
- mavenCentral()
+ flatDir {
+ dirs System.env.GRADLE_LIB_DIR
+ }
}
configurations{

BIN
javax.activation-api-1.2.0.jar (Stored with Git LFS) Normal file

Binary file not shown.

BIN
jaxb-api-2.3.1.jar (Stored with Git LFS) Normal file

Binary file not shown.

View File

@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:e3bff9ab64a09b1ac2800f3b5fb1e3d99728064acb6dd3924938507638a404fb
size 367444

View File

@ -1,22 +0,0 @@
commit 3ed6b221531f961706f15ec7582eb0716addd94b
Author: Nicolas Morey-Chaisemartin <nmoreychaisemartin@suse.com>
Date: Fri Apr 27 15:15:57 2018 +0200
opa-fmgui: force loading java.xml.bind for JDK9
Signed-off-by: Nicolas Morey-Chaisemartin <nmoreychaisemartin@suse.com>
diff --git install/opa-fmgui.sh install/opa-fmgui.sh
index c2283850c919..cc2f00995207 100644
--- install/opa-fmgui.sh
+++ install/opa-fmgui.sh
@@ -98,6 +98,9 @@ if [ "$JAVA" == "nojava" ]; then
read -p 'Press [Enter] key to continue...'
else
if [ -a $JAR ]; then
+ # Force loading java.xml.bind for JDK9+
+ export JDK_JAVA_OPTIONS="--add-modules java.xml.bind"
+
# run the JVM and pass the jar name
if [ $DEBUG -eq 1 ]; then
echo

View File

@ -1,3 +1,30 @@
-------------------------------------------------------------------
Mon Apr 11 13:00:04 UTC 2022 - Fridrich Strba <fstrba@suse.com>
- Do not use the vulnerable log4j-1.2.14, but use the maintained
fork reaload4j-1.2.20 that receives security updates
-------------------------------------------------------------------
Mon Apr 11 12:46:41 UTC 2022 - Fridrich Strba <fstrba@suse.com>
- Fix building with JDK17
* This fixes build in Factory and still allows building on other
distributions
* Do not use gradle for build, but build gritty using simple
javac/jar combo and the rest using the ant build.xml file
* Add jaxb-api-2.3.1.jar and javax.activation-api-1.2.0.jar
to allow building with JDK versions that do not include the
JavaEE modules
* Remove swingx-testsupport-1.6.5.jar, since that one is only
meant to be used for testing the swingx itself and not for
distribution
- Removed patches:
* gradle-use_local_repo.patch
+ not needed when gradle is not used for building
* opa-fmgui-force-loading-java.xml.bind-for-JDK9.patch
+ not needed since the relevant JavaEE modules are on the
classpath
-------------------------------------------------------------------
Wed Oct 10 07:56:00 UTC 2018 - nmoreychaisemartin@suse.com
@ -24,7 +51,7 @@ Mon Nov 13 10:14:30 UTC 2017 - nmoreychaisemartin@suse.com
Mon Sep 25 14:41:13 UTC 2017 - nmoreychaisemartin@suse.com
- Update embedded gradle binaries to 3.2 to support JDK9
- Add opa-fmgui-fix-build-for-JDK9-Gradle-3.2.patch to fix
- Add opa-fmgui-fix-build-for-JDK9-Gradle-3.2.patch to fix
compilation with JDK9
-------------------------------------------------------------------

View File

@ -1,7 +1,7 @@
#
# spec file for package opa-fmgui
#
# Copyright (c) 2018 SUSE LINUX GmbH, Nuernberg, Germany.
# Copyright (c) 2022 SUSE LLC
# Copyright (c) 2015 Intel Corporation
#
# All modifications and additions to the file contributed by third parties
@ -13,84 +13,76 @@
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via http://bugs.opensuse.org/
# Please submit bugfixes or comments via https://bugs.opensuse.org/
#
%define git_ver %{nil}
%define name opa-fmgui
%define appdir .
%define appfolder opa-fmgui
%define appjar opa-fmgui.jar
%define _binary_payload w9.gzdio
%define gradle_version 4.10.2
Name: opa-fmgui
Version: 10.1.0.0.115
Release: 0
Summary: Fabric Manager Graphical User Interface
License: BSD-3-Clause AND LGPL-2.0-or-later
Group: Productivity/Clustering/Computing
Url: http://www.intel.com/
URL: https://www.intel.com/
Source0: %{name}-%{version}%{git_ver}.tar.gz
Source1: antlr-2.7.7.jar
Source2: dom4j-1.6.1.jar
# Source3: gritty.jar
Source4: hibernate-commons-annotations-4.0.4.Final.jar
Source5: hibernate-core-4.3.5.Final.jar
Source6: hibernate-entitymanager-4.3.5.Final.jar
Source7: hibernate-jpa-2.1-api-1.0.0.Final.jar
Source8: hsqldb-2.3.2.jar
Source9: jandex-1.1.0.Final.jar
Source10: javahelp-2.0.05.jar
Source11: javassist-3.18.1-GA.jar
Source3: hibernate-commons-annotations-4.0.4.Final.jar
Source4: hibernate-core-4.3.5.Final.jar
Source5: hibernate-entitymanager-4.3.5.Final.jar
Source6: hibernate-jpa-2.1-api-1.0.0.Final.jar
Source7: hsqldb-2.3.2.jar
Source8: jandex-1.1.0.Final.jar
Source9: javahelp-2.0.05.jar
Source10: javassist-3.18.1-GA.jar
Source11: javax.activation-api-1.2.0.jar
Source12: javax.mail-1.5.2.jar
Source13: jboss-logging-3.1.3.GA.jar
Source14: jboss-logging-annotations-1.2.0.Beta1.jar
Source15: jboss-transaction-api_1.2_spec-1.0.0.Final.jar
Source16: jcommon-1.0.21.jar
Source17: jfreechart-1.0.17.jar
Source18: jgraphx-3.6.0.0.jar
Source19: jsch-0.1.53.jar
Source20: log4j-1.2.14.jar
Source13: jaxb-api-2.3.1.jar
Source14: jboss-logging-3.1.3.GA.jar
Source15: jboss-logging-annotations-1.2.0.Beta1.jar
Source16: jboss-transaction-api_1.2_spec-1.0.0.Final.jar
Source17: jcommon-1.0.21.jar
Source18: jfreechart-1.0.17.jar
Source19: jgraphx-3.6.0.0.jar
Source20: jsch-0.1.53.jar
Source21: log4j-over-slf4j-1.7.7.jar
Source22: logback-classic-1.1.2.jar
Source23: logback-core-1.1.2.jar
Source24: mbassador-1.2.4.2.jar
Source25: slf4j-api-1.7.7.jar
Source26: swingx-all-1.6.5.jar
Source27: swingx-action-1.6.5.jar
Source28: swingx-autocomplete-1.6.5.jar
Source29: swingx-beaninfo-1.6.5.jar
Source30: swingx-common-1.6.5.jar
Source31: swingx-core-1.6.5.jar
Source32: swingx-graphics-1.6.5.jar
Source33: swingx-mavensupport-1.6.5.jar
Source34: swingx-painters-1.6.5.jar
Source35: swingx-plaf-1.6.5.jar
Source36: swingx-testsupport-1.6.5.jar
Source37: gradle-%{gradle_version}-bin.zip
Patch1: gradle-use_local_repo.patch
Patch3: opa-fmgui-intel-manifest-license.patch
Source25: reload4j-1.2.20.jar
Source26: slf4j-api-1.7.7.jar
Source27: swingx-all-1.6.5.jar
Source28: swingx-action-1.6.5.jar
Source29: swingx-autocomplete-1.6.5.jar
Source30: swingx-beaninfo-1.6.5.jar
Source31: swingx-common-1.6.5.jar
Source32: swingx-core-1.6.5.jar
Source33: swingx-graphics-1.6.5.jar
Source34: swingx-mavensupport-1.6.5.jar
Source35: swingx-painters-1.6.5.jar
Source36: swingx-plaf-1.6.5.jar
Patch0: opa-fmgui-intel-manifest-license.patch
# Patch auto extracted by service
Patch5: stl-14927-jgraphx-update.patch
Patch6: manifest-version.patch
Patch7: opa-fmgui-fix-build-for-JDK9-Gradle-3.2.patch
Patch8: opa-fmgui-force-loading-java.xml.bind-for-JDK9.patch
Patch1: stl-14927-jgraphx-update.patch
Patch2: manifest-version.patch
Patch3: opa-fmgui-fix-build-for-JDK9-Gradle-3.2.patch
BuildRequires: ant
BuildRequires: jre >= 1.7
Requires: jre >= 1.7
Requires: mlocate
BuildRequires: hicolor-icon-theme
BuildRequires: java-devel >= 1.7
BuildRequires: openssl
BuildRequires: unzip
BuildRequires: update-desktop-files
BuildRequires: wget
Requires: jre >= 1.7
Requires: mlocate
# BuildRequires: gradle
BuildRoot: %{_tmppath}/%{name}-%{version}-build
BuildArch: noarch
%description
@ -98,19 +90,23 @@ FMGUI is the Fabric Manager Graphical User Interface. It can be run by invoking
script fmgui.
%prep
%setup -q -n %{name}-%{version}%{git_ver}
%setup -q -n %{name}-%{version}%{git_ver}
%patch0 -p1
%patch1 -p1
%patch3 -p1
%patch5 -p1
%patch6 -p1
%patch7
%patch8
%patch2 -p1
%patch3
%build
(cd %{_tmppath}; rm -Rf gradle-%{gradle_version}; unzip %{_sourcedir}/gradle-%{gradle_version}-bin.zip)
GRADLE_LIB_DIR=%{_sourcedir}
export GRADLE_LIB_DIR
%{_tmppath}/gradle-%{gradle_version}/bin/gradle copyDeps buildOPA --info
mkdir -p lib
cp %{_sourcedir}/*.jar lib/
pushd gritty
mkdir -p classes
javac -d classes -source 8 -target 8 -cp %{SOURCE20}:%{SOURCE25} $(find . -name \*.java | xargs)
jar -cf ../lib/gritty.jar -C classes .
popd
%{ant}
%install
mkdir -p %{buildroot}%{_javadir}/%{appfolder}
@ -163,7 +159,6 @@ rm %{buildroot}/fmgui.desktop
%icon_theme_cache_postun
%files
%defattr(-,root,root,-)
%doc README THIRD-PARTY-README Third_Party_Copyright_Notices_and_Licenses
%license LICENSE gritty/gritty_license.txt
%dir %{_sysconfdir}/xdg/menus

BIN
reload4j-1.2.20.jar (Stored with Git LFS) Normal file

Binary file not shown.

View File

@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:b27447a35b4ef2aac002e7cb63020f7dc54c253f39bf1893a9e6aa4b825e9e70
size 14366