Repack tarball without bundled jars, fix license tag
This commit is contained in:
parent
313c1e79f5
commit
ac6ae447f5
1
.gitignore
vendored
1
.gitignore
vendored
@ -1,2 +1,3 @@
|
||||
/JDOM-2.0.5.tar.gz
|
||||
/JDOM-2.0.6.tar.gz
|
||||
/jdom2-2.0.6.tar.gz
|
||||
|
@ -1,6 +1,6 @@
|
||||
From 7fcf41703a428b255a7d7f9b1424e825dd7e1788 Mon Sep 17 00:00:00 2001
|
||||
From 05a8a2fa49e92ad36a86d5d73588a2e46bf9ff95 Mon Sep 17 00:00:00 2001
|
||||
From: Michael Simacek <msimacek@redhat.com>
|
||||
Date: Wed, 31 May 2017 13:13:48 +0200
|
||||
Date: Mon, 23 Jul 2018 14:30:14 +0200
|
||||
Subject: [PATCH] Adapt build
|
||||
|
||||
---
|
||||
@ -8,7 +8,7 @@ Subject: [PATCH] Adapt build
|
||||
1 file changed, 25 insertions(+), 15 deletions(-)
|
||||
|
||||
diff --git a/build.xml b/build.xml
|
||||
index 8067c61..13f88d4 100644
|
||||
index cd7c2ed..10d8df6 100644
|
||||
--- a/build.xml
|
||||
+++ b/build.xml
|
||||
@@ -112,17 +112,7 @@ For instructions on how to build JDOM, please view the README.txt file.
|
||||
@ -43,12 +43,12 @@ index 8067c61..13f88d4 100644
|
||||
<target name="package" depends="coverage, jars"
|
||||
description="Creates the class package">
|
||||
- <zip destfile="${package}/${jarbase}.zip">
|
||||
+ <!--zip destfile="${package}/${jarbase}.zip">
|
||||
+ <!--<zip destfile="${package}/${jarbase}.zip">
|
||||
<fileset dir="${package}" includes="${jarbase}*.jar" />
|
||||
<fileset dir="${basedir}" includes="lib/xerces* lib/jaxen* lib/xml*" />
|
||||
<fileset dir="${basedir}" includes="lib/xerces* lib/jaxen* lib/xml* lib/xalan/**" />
|
||||
<fileset dir="${basedir}" includes="LICENSE.txt README.txt" />
|
||||
- </zip>
|
||||
+ </zip-->
|
||||
+ </zip>-->
|
||||
</target>
|
||||
|
||||
<!-- =================================================================== -->
|
||||
@ -97,5 +97,5 @@ index 8067c61..13f88d4 100644
|
||||
<jar destfile="${mavendir}/${mavenbase}-maven-bundle.jar"
|
||||
basedir="${mavendir}/core"
|
||||
--
|
||||
2.9.4
|
||||
2.17.1
|
||||
|
22
generate-tarball.sh
Executable file
22
generate-tarball.sh
Executable file
@ -0,0 +1,22 @@
|
||||
#!/bin/bash
|
||||
set -e
|
||||
|
||||
name=jdom2
|
||||
version="$(sed -n 's/Version:\s*//p' *.spec)"
|
||||
|
||||
# RETRIEVE
|
||||
wget "https://github.com/hunterhacker/jdom/archive/JDOM-${version}.tar.gz" -O "${name}-${version}.orig.tar.gz"
|
||||
|
||||
rm -rf tarball-tmp
|
||||
mkdir tarball-tmp
|
||||
cd tarball-tmp
|
||||
tar xf "../${name}-${version}.orig.tar.gz"
|
||||
|
||||
# CLEAN TARBALL
|
||||
rm -r */lib */*/lib
|
||||
find -name '*.jar' -delete
|
||||
find -name '*.class' -delete
|
||||
|
||||
tar cf "../${name}-${version}.tar.gz" *
|
||||
cd ..
|
||||
rm -r tarball-tmp "${name}-${version}.orig.tar.gz"
|
19
jdom2.spec
19
jdom2.spec
@ -1,19 +1,22 @@
|
||||
Name: jdom2
|
||||
Version: 2.0.6
|
||||
Release: 11%{?dist}
|
||||
Release: 12%{?dist}
|
||||
Summary: Java manipulation of XML made easy
|
||||
License: ASL 1.1 or BSD
|
||||
License: Saxpath
|
||||
URL: http://www.jdom.org/
|
||||
Source0: https://github.com/hunterhacker/jdom/archive/JDOM-%{version}.tar.gz
|
||||
# ./generate-tarball.sh
|
||||
Source0: %{name}-%{version}.tar.gz
|
||||
# originally taken from http://repo1.maven.org/maven2/org/jdom/jdom-contrib/1.1.3/jdom-contrib-1.1.3.pom
|
||||
Source1: jdom-contrib-template.pom
|
||||
Source2: jdom-junit-template.pom
|
||||
# Bnd tool configuration
|
||||
Source3: bnd.properties
|
||||
# Remove bundled jars that might not have clear licensing
|
||||
Source4: generate-tarball.sh
|
||||
# Use system libraries
|
||||
# Disable gpg signatures
|
||||
# Process contrib and junit pom files
|
||||
Patch0: jdom-2.0.5-build.patch
|
||||
Patch0: 0001-Adapt-build.patch
|
||||
|
||||
BuildRequires: javapackages-local
|
||||
BuildRequires: ant
|
||||
@ -47,8 +50,6 @@ This package contains javadoc for %{name}.
|
||||
|
||||
%prep
|
||||
%setup -q -n jdom-JDOM-%{version}
|
||||
find . -name "*.class" -print -delete
|
||||
find . -name "*.jar" -print -delete
|
||||
|
||||
%patch0 -p1
|
||||
|
||||
@ -60,6 +61,7 @@ sed -i 's/\r//' LICENSE.txt README.txt
|
||||
# Unable to run coverage: use log4j12 but switch to log4j 2.x
|
||||
sed -i.coverage "s|coverage, jars|jars|" build.xml
|
||||
|
||||
mkdir lib
|
||||
build-jar-repository lib xerces-j2 xml-commons-apis jaxen junit isorelax xalan-j2 xalan-j2-serializer
|
||||
|
||||
%build
|
||||
@ -84,6 +86,11 @@ mv build/package/jdom-%{version}.bar build/package/jdom-%{version}.jar
|
||||
%license LICENSE.txt
|
||||
|
||||
%changelog
|
||||
* Mon Jul 23 2018 Michael Simacek <msimacek@redhat.com> - 2.0.6-12
|
||||
- Repack tarball without bundled jars
|
||||
- The repacked jar contains slightly different source (force push by upstream?)
|
||||
- Correct license tag
|
||||
|
||||
* Tue Jul 17 2018 Mikolaj Izdebski <mizdebsk@redhat.com> - 2.0.6-11
|
||||
- Remove unneeded buildrequires
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user