From 3132c68c141d6d5869de5b5bf16d01061c76797d Mon Sep 17 00:00:00 2001 From: mbooth Date: Mon, 13 Dec 2010 21:10:20 +0000 Subject: [PATCH] Install maven pom and depmap --- xerces-j2-pom.xml | 48 ++++++++++++++++ xerces-j2.spec | 142 ++++++++++------------------------------------ 2 files changed, 79 insertions(+), 111 deletions(-) create mode 100644 xerces-j2-pom.xml diff --git a/xerces-j2-pom.xml b/xerces-j2-pom.xml new file mode 100644 index 0000000..e4a3c72 --- /dev/null +++ b/xerces-j2-pom.xml @@ -0,0 +1,48 @@ + + + + 4.0.0 + + org.apache + apache + 4 + + + xerces + xercesImpl + 2.11.0 + Xerces2 Java Parser + + Xerces2 is the next generation of high performance, fully compliant XML parsers in the + Apache Xerces family. This new version of Xerces introduces the Xerces Native Interface (XNI), + a complete framework for building parser components and configurations that is extremely + modular and easy to program. + + + http://xerces.apache.org/xerces2-j + + + + xml-apis + xml-apis + 1.4.01 + + + + xml-resolver + xml-resolver + 1.2 + true + + + + + + + src + + + \ No newline at end of file diff --git a/xerces-j2.spec b/xerces-j2.spec index 6cb245c..ce2a891 100644 --- a/xerces-j2.spec +++ b/xerces-j2.spec @@ -2,7 +2,7 @@ Name: xerces-j2 Version: 2.11.0 -Release: 1%{?dist} +Release: 2%{?dist} Summary: Java XML parser Group: Development/Libraries License: ASL 2.0 @@ -19,6 +19,8 @@ Source3: https://svn.apache.org/repos/asf/xerces/java/tags/Xerces-J_%{cvs_ Source5: https://svn.apache.org/repos/asf/xerces/java/tags/Xerces-J_%{cvs_version}/tools/src/ExperimentalTaglet.java Source6: https://svn.apache.org/repos/asf/xerces/java/tags/Xerces-J_%{cvs_version}/tools/src/InternalTaglet.java +Source7: %{name}-pom.xml + # Patch the build so that it doesn't try to use bundled xml-commons source Patch0: %{name}-build.patch @@ -32,8 +34,8 @@ BuildArch: noarch BuildRequires: java-devel >= 1:1.6.0 BuildRequires: jpackage-utils BuildRequires: xalan-j2 >= 2.7.1 -BuildRequires: xml-commons-apis >= 1.4 -BuildRequires: xml-commons-resolver >= 1.1 +BuildRequires: xml-commons-apis >= 1.4.01 +BuildRequires: xml-commons-resolver >= 1.2 BuildRequires: ant BuildRequires: xml-stylebook BuildRequires: jaxp_parser_impl @@ -41,12 +43,15 @@ BuildRequires: dejavu-sans-fonts Requires: java Requires: jpackage-utils Requires: xalan-j2 >= 2.7.1 -Requires: xml-commons-apis >= 1.4 -Requires: xml-commons-resolver >= 1.1 +Requires: xml-commons-apis >= 1.4.01 +Requires: xml-commons-resolver >= 1.2 Provides: jaxp_parser_impl = 1.4 + Requires(post): chkconfig jaxp_parser_impl Requires(preun): chkconfig jaxp_parser_impl +Requires(post): jpackage-utils +Requires(postun): jpackage-utils # This documentation is provided by xml-commons-apis Obsoletes: %{name}-javadoc-apis < %{version}-%{release} @@ -161,20 +166,16 @@ jar cf bin/xjavac.jar org/apache/xerces/util/XJavac.class javac -classpath /usr/lib/jvm/java/lib/tools.jar org/apache/xerces/util/*Taglet.java jar cf bin/xerces2taglets.jar org/apache/xerces/util/*Taglet.class -ln -sf $(build-classpath xalan-j2) . -ln -sf $(build-classpath xml-commons-apis) . -ln -sf $(build-classpath xml-commons-resolver) . -ln -sf $(build-classpath xml-stylebook) . +ln -sf $(build-classpath xalan-j2) serializer.jar +ln -sf $(build-classpath xml-commons-apis) xml-apis.jar +ln -sf $(build-classpath xml-commons-resolver) resolver.jar +ln -sf $(build-classpath xml-stylebook) stylebook-1.0-b2.jar popd # Build everything export ANT_OPTS="-Xmx256m -Djava.endorsed.dirs=$(pwd)/tools -Djava.awt.headless=true -Dbuild.sysclasspath=first -Ddisconnected=true" ant -Djavac.source=1.5 -Djavac.target=1.5 \ -Dbuild.compiler=modern \ - -Djar.serializer=xalan-j2.jar \ - -Djar.apis=xml-commons-apis.jar \ - -Djar.resolver=xml-commons-resolver.jar \ - -Ddoc.generator.package=tools/xml-stylebook.jar \ clean jars javadocs docs # Fix line endings in generated docs @@ -226,6 +227,14 @@ install -pD -m755 -T %{SOURCE2} %{buildroot}%{_bindir}/%{name}-constants install -pD -T build/xercesSamples.jar %{buildroot}%{_datadir}/%{name}/%{name}-samples.jar cp -pr data %{buildroot}%{_datadir}/%{name} +# Pom +install -pD -T -m 644 %{SOURCE7} %{buildroot}%{_mavenpomdir}/JPP-%{name}.pom +%add_to_maven_depmap xerces xercesImpl %{version} JPP %{name} + +# Legacy depmaps for compatability +%add_to_maven_depmap xerces xerces %{version} JPP %{name} +%add_to_maven_depmap xerces xmlParserAPIs %{version} JPP %{name} + # jaxp_parser_impl ghost symlink ln -s %{_sysconfdir}/alternatives \ %{buildroot}%{_javadir}/jaxp_parser_impl.jar @@ -234,9 +243,13 @@ ln -s %{_sysconfdir}/alternatives \ rm -rf %{buildroot} %post +%update_maven_depmap update-alternatives --install %{_javadir}/jaxp_parser_impl.jar \ jaxp_parser_impl %{_javadir}/%{name}.jar 40 +%postun +%update_maven_depmap + %preun { [ $1 = 0 ] || exit 0 @@ -249,6 +262,8 @@ update-alternatives --install %{_javadir}/jaxp_parser_impl.jar \ %doc %{_docdir}/%{name}-%{version}/LICENSE %doc %{_docdir}/%{name}-%{version}/NOTICE %doc %{_docdir}/%{name}-%{version}/README +%{_mavendepmapfragdir}/* +%{_mavenpomdir}/* %{_javadir}/%{name}* %ghost %{_javadir}/jaxp_parser_impl.jar @@ -286,6 +301,9 @@ update-alternatives --install %{_javadir}/jaxp_parser_impl.jar \ %{_bindir}/* %changelog +* Mon Dec 13 2010 Mat Booth 2.11.0-2 +- Install maven pom and depmap. + * Sat Dec 11 2010 Mat Booth - 2.11.0-1 - Update to latest upstream version. - Provide JAXP 1.4. @@ -480,101 +498,3 @@ update-alternatives --install %{_javadir}/jaxp_parser_impl.jar \ - RH vacuuming - remove jikes dependency - add nonjikes-cast.patch - -* Sun Feb 08 2004 David Walluck 0:2.6.1-1jpp -- 2.6.1 -- update Source0 URL -- now requires xml-commons-resolver - -* Fri Jan 9 2004 Kaj J. Niemi - 0:2.6.0-1jpp -- Update to 2.6.0 -- Patch #1 (xerces-j2-manifest.patch) is unnecessary (upstream) - -* Tue Oct 21 2003 Ville Skyttä - 0:2.5.0-1jpp -- Update to 2.5.0. -- Clean up versionless javadoc dir symlinking, own (ghost) the symlinks. -- Mark javadocs as %%doc. - -* Wed Jun 4 2003 Ville Skyttä - 0:2.4.0-3jpp -- Own (ghost) %%{_javadir}/jaxp_parser_impl.jar. -- Remove alternatives in preun instead of postun. - -* Mon May 12 2003 David Walluck 0:2.4.0-2jpp -- bug #17325 fixed upstream - -* Mon May 12 2003 David Walluck 0:2.4.0-1jpp -- 2.4.0 -- BuildRequires: jikes -- update for JPackage 1.5 -- re-diff'ed build patch for 2.4.0 -- bug #17325 handled by perl now -- scripts: s|find-jar|build-classpath| and don't test for java-functions - -* Wed Mar 26 2003 Nicolas Mailhot - 2.3.0-2jpp -- For jpackage-utils 1.5 -- zapped manual, since it doesn't want to build -- as a consequence, removed uneeded dependencies - -* Mon Feb 24 2003 Ville Skyttä - 2.3.0-1jpp -- Update to 2.3.0. -- Add a crude patch to work around invalid XML in doc sources, see - . -- Built with IBM's 1.3.1 SR3. - -* Sat Dec 28 2002 Ville Skyttä - 2.2.1-2jpp -- Add upstream patch which fixes problems with Tomcat's webapps. - - -- Separate scripts subpackage. - -* Fri Nov 15 2002 Ville Skyttä - 2.2.1-1jpp -- Update to 2.2.1. -- Change alternative to point to non-versioned jar. -- Don't remove alternative on upgrade. -- Fix Group tag for demo, javadoc and manual subpackages. -- Add version and constants scripts. -- Some spec file cleanup. - -* Sun Oct 6 2002 Ville Skyttä 2.2.0-2jpp -- Fix bad permissions for main jar. - -* Sun Sep 29 2002 Ville Skyttä 2.1.0-1jpp -- Update to 2.2.0. - -* Tue Sep 10 2002 Ville Skyttä 2.1.0-2jpp -- Rebuild with -Dcompiler=modern, not a Jikes bug this time, but sloppy code - that is tolerated by javac. See for details. - -* Tue Sep 10 2002 Ville Skyttä 2.1.0-1jpp -- 2.1.0. -- Updated description. -- Changed javadoc and manual group to Documentation. -- Spec file cleanups. - -* Fri Jul 12 2002 Henri Gomez 2.0.2-4jpp -- add BuildRequires xerces-j1 and xalan-j2 -- removed BuildRequires xml-commons-api since ant require jaxp_parser_impl - which in turn require xml-commons-api ;) - -* Mon Jul 01 2002 Guillaume Rousse 2.0.2-3jpp -- vendor, distribution, group tags -- provides jaxp_parser_impl -- dropped api jar -- renamed lone jar to %%{name}.jar -- priority bumped to 40 -- fixed stylebook build (add xerces-j1 in classpath) - -* Wed Jun 26 2002 Guillaume Rousse 2.0.2-2jpp -- rebuild for missing symlinks -- use sed instead of bash 2.x extension in link area to make spec compatible with distro using bash 1.1x - -* Mon Jun 24 2002 Henri Gomez 2.0.2-1jpp -- 2.0.2 - -* Sun Mar 10 2002 Guillaume Rousse 2.0.1-1jpp -- 2.0.1 -- provides jaxp_parser2 virtual resource -- drop wrapper - -* Sun Feb 03 2002 Guillaume Rousse 2.0.0-1jpp -- first JPackage release