diff --git a/.gitignore b/.gitignore
index 031b81a..0437187 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1 +1,6 @@
-plexus-classworlds-2.2.3.tar.xz
+target/
+.project
+.classpath
+.settings/
+bin
+/plexus-classworlds-2.4.tar.gz
diff --git a/plexus-classworlds-1.2-jpp-depmap.xml b/plexus-classworlds-1.2-jpp-depmap.xml
deleted file mode 100644
index 14cb08e..0000000
--- a/plexus-classworlds-1.2-jpp-depmap.xml
+++ /dev/null
@@ -1,27 +0,0 @@
-
-
-
- junit
- junit
- 3.8.1
-
-
- JPP
- junit
- 3.8.2
-
-
-
-
- org.codehaus.plexus
- plexus-utils
- 1.0.4
-
-
- JPP/plexus
- utils
- 1.4.5
-
-
-
-
diff --git a/plexus-classworlds-settings.xml b/plexus-classworlds-settings.xml
deleted file mode 100644
index efe7bd7..0000000
--- a/plexus-classworlds-settings.xml
+++ /dev/null
@@ -1,47 +0,0 @@
-
-
-
- JPP
-
-
- internal
- jpp
- __JPP_URL_PLACEHOLDER__
-
-
- external
- jpp
- __JAVADIR_PLACEHOLDER__
-
-
- local
- jpp
- __MAVENREPO_DIR_PLACEHOLDER__
-
-
-
-
- plugins-internal
- plugins-internal
- jpp
- __JPP_URL_PLACEHOLDER__
-
-
- plugins-external
- plugins-external
- jpp
- __JAVADIR_PLACEHOLDER__
-
-
- plugins-maven
- plugins-maven
- jpp
- __MAVENDIR_PLUGIN_PLACEHOLDER__
-
-
-
-
-
- JPP
-
-
diff --git a/plexus-classworlds.depmap b/plexus-classworlds.depmap
deleted file mode 100644
index d8e5151..0000000
--- a/plexus-classworlds.depmap
+++ /dev/null
@@ -1,26 +0,0 @@
-
-
-
- asm
- asm
- 3.0
-
-
- JPP/objectweb-asm
- asm
- 3.2
-
-
-
-
- ant
- ant
- 1.6.5
-
-
- JPP
- ant
- 1.6.5
-
-
-
diff --git a/plexus-classworlds.spec b/plexus-classworlds.spec
index 0f2205a..9c6d8da 100644
--- a/plexus-classworlds.spec
+++ b/plexus-classworlds.spec
@@ -28,38 +28,26 @@
# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#
-%global with_maven 1
%global parent plexus
%global subname classworlds
Name: %{parent}-%{subname}
-Version: 2.2.3
-Release: 2%{?dist}
+Version: 2.4
+Release: 1%{?dist}
Summary: Plexus Classworlds Classloader Framework
License: ASL 2.0 and Plexus
Group: Development/Libraries
URL: http://plexus.codehaus.org/
-# svn export http://svn.codehaus.org/plexus/plexus-classworlds/tags/plexus-classworlds-2.2.3 plexus-classworlds-2.2.3
-# tar caf plexus-classworlds-2.2.3.tar.xz plexus-classworlds-2.2.3
-Source0: %{name}-%{version}.tar.xz
+# git clone git://github.com/sonatype/plexus-classworlds.git
+# git archive --prefix="plexus-classworlds/" --format=tar plexus-classworlds-2.4 > plexus-classworlds-2.4.tar.gz
+Source0: %{name}-%{version}.tar.gz
-# Generated with mvn ant:ant
-Source1: plexus-classworlds-1.2-build.xml
-# Fedora-specific maven bits
-Source3: plexus-classworlds-settings.xml
-
-# workaround objectweb-asm depmap
-Source5: %{name}.depmap
-
-BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
BuildArch: noarch
BuildRequires: jpackage-utils
-BuildRequires: ant
BuildRequires: apache-commons-logging
BuildRequires: xml-commons-jaxp-1.3-apis
-%if %{with_maven}
BuildRequires: maven2
BuildRequires: maven-compiler-plugin
BuildRequires: maven-install-plugin
@@ -74,7 +62,6 @@ BuildRequires: maven-shared-reporting-impl
BuildRequires: maven-dependency-plugin
BuildRequires: maven-surefire-maven-plugin
BuildRequires: maven-surefire-provider-junit
-%endif
BuildRequires: plexus-utils
Requires(post): jpackage-utils
@@ -99,59 +86,41 @@ Requires: jpackage-utils
API documentation for %{name}.
%prep
-%setup -q -n %{name}-%{version}
+%setup -q -n %{name}
for j in $(find . -name "*.jar" | grep -v /test-data/ | grep -v /test-jars/); do
- mv $j $j.no
+ rm $j
done
-cp %{SOURCE1} build.xml
-cp %{SOURCE3} settings.xml
-mkdir -p lib
-ln -sf $(build-classpath xml-commons-jaxp-1.3-apis) lib/xml-apis-1.3.02.jar
-ln -sf $(build-classpath ant) lib/ant-1.6.5.jar
-ln -sf $(build-classpath commons-logging) lib/commons-logging-1.0.3.jar
+# fix ant groupId
+sed -i 's:ant:org.apache.ant:' pom.xml
%build
export MAVEN_REPO_LOCAL=$(pwd)/.m2/repository
mkdir -p $MAVEN_REPO_LOCAL
-# tests skipped because of old commons-cli package these fail
-
-%if %{with_maven}
-mvn-jpp \
- -e \
- -Dmaven.test.skip=true \
+mvn-jpp -e \
-Dmaven.repo.local=$MAVEN_REPO_LOCAL \
- -Dmaven2.jpp.depmap.file=%{SOURCE5} \
install javadoc:javadoc
-%else
-export CLASSPATH=
-CLASSPATH=$CLASSPATH:target/classes:target/test-classes
-
-ant -Dbuild.sysclasspath=only jar javadoc
-%endif
%install
-rm -rf $RPM_BUILD_ROOT
# jars
install -Dpm 644 target/%{name}-%{version}.jar \
- $RPM_BUILD_ROOT%{_javadir}/plexus/%{subname}-%{version}.jar
+ $RPM_BUILD_ROOT%{_javadir}/plexus/%{subname}.jar
%add_to_maven_depmap org.codehaus.plexus %{name} %{version} JPP/%{parent} %{subname}
-(cd $RPM_BUILD_ROOT%{_javadir}/%{parent} && for jar in *-%{version}*; do ln -sf ${jar} `echo $jar| sed "s|-%{version}||g"`; done)
-
# pom
install -Dpm 644 pom.xml $RPM_BUILD_ROOT%{_mavenpomdir}/JPP.%{parent}-%{subname}.pom
# javadoc
-install -d -m 755 $RPM_BUILD_ROOT%{_javadocdir}/%{name}-%{version}
-cp -pr target/site/apidocs/* $RPM_BUILD_ROOT%{_javadocdir}/%{name}-%{version}
-ln -s %{name}-%{version} $RPM_BUILD_ROOT%{_javadocdir}/%{name}
+install -d -m 755 $RPM_BUILD_ROOT%{_javadocdir}/%{name}
+cp -pr target/site/apidocs/* $RPM_BUILD_ROOT%{_javadocdir}/%{name}
-%clean
-rm -rf $RPM_BUILD_ROOT
+%pre javadoc
+# workaround for rpm bug, can be removed in F-17
+[ $1 -gt 1 ] && [ -L %{_javadocdir}/%{name} ] && \
+rm -rf $(readlink -f %{_javadocdir}/%{name}) %{_javadocdir}/%{name} || :
%post
%update_maven_depmap
@@ -168,9 +137,16 @@ rm -rf $RPM_BUILD_ROOT
%files javadoc
%defattr(-,root,root,-)
-%doc %{_javadocdir}/*
+%doc LICENSE.txt
+%doc %{_javadocdir}/%{name}
%changelog
+* Wed Feb 2 2011 Stanislav Ochotnicky - 2.4-1
+- Update to latest upstream version
+- Drop ant build parts
+- Versionless jars & javadocs
+- Enable tests again
+
* Tue Dec 21 2010 Alexander Kurtakov 2.2.3-2
- Fix FTBFS.
diff --git a/sources b/sources
index cba41ba..0bc77f0 100644
--- a/sources
+++ b/sources
@@ -1 +1 @@
-4fe07489f26593b2ca1166cf101b3629 plexus-classworlds-2.2.3.tar.xz
+9bd9b4aa3bb05e627b1f1af8d1417884 plexus-classworlds-2.4.tar.gz