From 621f71afff62cccd0f777e72d326bb9d2d23dbbc Mon Sep 17 00:00:00 2001 From: Jaromir Capik Date: Tue, 26 Jul 2011 15:38:15 +0200 Subject: [PATCH] Initial import (#725504). --- .gitignore | 1 + jsoup.spec | 92 ++++++++++++++++++++++++++++++++++++++++++++++++++++++ sources | 1 + 3 files changed, 94 insertions(+) create mode 100644 jsoup.spec diff --git a/.gitignore b/.gitignore index e69de29..c3af04a 100644 --- a/.gitignore +++ b/.gitignore @@ -0,0 +1 @@ +/jsoup-1.6.1.tar.xz diff --git a/jsoup.spec b/jsoup.spec new file mode 100644 index 0000000..7e2887c --- /dev/null +++ b/jsoup.spec @@ -0,0 +1,92 @@ +Name: jsoup +Version: 1.6.1 +Release: 2%{?dist} +Summary: Java library for working with real-world HTML + +Group: Development/Libraries +License: MIT + +URL: http://%{name}.org/ + +# git clone git://github.com/jhy/jsoup +# git archive --prefix="jsoup-1.6.1/" --format=tar jsoup-1.6.1 | xz > jsoup-1.6.1.tar.xz +Source0: %{name}-%{version}.tar.xz + +BuildArch: noarch + +BuildRequires: java-devel >= 1:1.6.0 +BuildRequires: maven +BuildRequires: maven-compiler-plugin +BuildRequires: maven-source-plugin +BuildRequires: maven-javadoc-plugin +BuildRequires: maven-plugin-plugin +BuildRequires: maven-jar-plugin +BuildRequires: maven-surefire-provider-junit4 +Requires: maven +Requires: jpackage-utils +Requires: java + + +%description +jsoup is a Java library for working with real-world HTML. +It provides a very convenient API for extracting and manipulating data, +using the best of DOM, CSS, and jquery-like methods. + +jsoup implements the WHATWG HTML5 specification, +and parses HTML to the same DOM as modern browsers do. + + - scrape and parse HTML from a URL, file, or string + - find and extract data, using DOM traversal or CSS selectors + - manipulate the HTML elements, attributes, and text + - clean user-submitted content against a safe white-list, + to prevent XSS attacks + - output tidy HTML + +jsoup is designed to deal with all varieties of HTML found in the wild; +from pristine and validating, to invalid tag-soup; +jsoup will create a sensible parse tree. + + +%package javadoc +Group: Documentation +Summary: Javadoc for %{name} +Requires: jpackage-utils + +%description javadoc +API documentation for %{name}. + +%prep +%setup -q + +%build +mvn-rpmbuild install javadoc:aggregate + +%install +# jars +install -Dpm 644 target/%{name}-%{version}.jar %{buildroot}%{_javadir}/%{name}.jar + +# poms +install -Dpm 644 pom.xml %{buildroot}%{_mavenpomdir}/JPP-%{name}.pom + +%add_maven_depmap JPP-%{name}.pom %{name}.jar + +# javadoc +install -dm 755 %{buildroot}%{_javadocdir}/%{name} +cp -pr target/site/apidocs/* %{buildroot}%{_javadocdir}/%{name} + +%files +%doc LICENSE README CHANGES +%{_javadir}/%{name}.jar +%{_mavenpomdir}/JPP-%{name}.pom +%{_mavendepmapfragdir}/%{name} + +%files javadoc +%doc LICENSE +%doc %{_javadocdir}/%{name} + +%changelog +* Fri Jul 22 2011 Jaromir Capik - 1.6.1-2 +- Switching to sources from github + +* Fri Jul 22 2011 Jaromir Capik - 1.6.1-1 +- Initial package diff --git a/sources b/sources index e69de29..04088c5 100644 --- a/sources +++ b/sources @@ -0,0 +1 @@ +0e3a0bbf7a810fad91fb561846e27792 jsoup-1.6.1.tar.xz