diff --git a/0001-Crosslink-javadoc.patch b/0001-Crosslink-javadoc.patch new file mode 100644 index 0000000..77a1f95 --- /dev/null +++ b/0001-Crosslink-javadoc.patch @@ -0,0 +1,45 @@ +From 085262f5d43cc9541480392910f29091ef678217 Mon Sep 17 00:00:00 2001 +From: Michael Simacek +Date: Tue, 14 Jul 2015 11:20:41 +0200 +Subject: [PATCH 1/3] Crosslink javadoc + +--- + build.xml | 15 ++++++++++++--- + 1 file changed, 12 insertions(+), 3 deletions(-) + +diff --git a/build.xml b/build.xml +index 8cbab8e..d36f42b 100644 +--- a/build.xml ++++ b/build.xml +@@ -41,7 +41,12 @@ + + + +- ++ ++ ++ ++ ++ ++ + + + +@@ -178,8 +183,12 @@ + author='true' version='true' use='true' + windowtitle="${Name} Implementation" + doctitle="${Name}" encoding="ISO-8859-1" +- bottom="${copyright}" +- /> ++ bottom="${copyright}"> ++ ++ ++ ++ ++ + + + +-- +2.1.0 + diff --git a/0002-Jar-paths.patch b/0002-Jar-paths.patch new file mode 100644 index 0000000..f99d535 --- /dev/null +++ b/0002-Jar-paths.patch @@ -0,0 +1,111 @@ +From 03b255b50250861a630cd72cb3fae30c7f0f5987 Mon Sep 17 00:00:00 2001 +From: Michael Simacek +Date: Tue, 14 Jul 2015 11:20:59 +0200 +Subject: [PATCH 2/3] Jar paths + +--- + build.xml | 20 +++++++++++--------- + 1 file changed, 11 insertions(+), 9 deletions(-) + +diff --git a/build.xml b/build.xml +index d36f42b..1f00059 100644 +--- a/build.xml ++++ b/build.xml +@@ -54,7 +54,7 @@ + + + +- ++ + + + +@@ -83,7 +83,7 @@ + source='${compile.source}' target='${compile.target}' + includeAntRuntime='false'> + +- ++ + + + +@@ -94,7 +94,7 @@ + source='${compile.source}' target='${compile.target}' + includeAntRuntime='false'> + +- ++ + + + +@@ -108,12 +108,14 @@ + unless="compile.skip"> + + ++ + + + +@@ -236,7 +238,7 @@ public class Version { + + + +- ++ + + + +@@ -277,7 +279,7 @@ public class Version { + source='${compile.source}' target='${compile.target}' + includeAntRuntime='true'> + +- ++ + + + +@@ -298,8 +300,8 @@ public class Version { + + + +- +- ++ ++ + + + +@@ -318,13 +320,13 @@ public class Version { + + + ++ +@@ -397,7 +399,7 @@ public class Version { + + + +- ++ + + +-- +2.1.0 + diff --git a/0003-Add-OSGi-attributes.patch b/0003-Add-OSGi-attributes.patch new file mode 100644 index 0000000..fad0aae --- /dev/null +++ b/0003-Add-OSGi-attributes.patch @@ -0,0 +1,27 @@ +From 1cbc54dc98b762c4ba3b1daffc2cf5a1116732ef Mon Sep 17 00:00:00 2001 +From: Michael Simacek +Date: Tue, 14 Jul 2015 11:21:21 +0200 +Subject: [PATCH 3/3] Add OSGi attributes + +--- + build.xml | 4 ++++ + 1 file changed, 4 insertions(+) + +diff --git a/build.xml b/build.xml +index 1f00059..194b0bf 100644 +--- a/build.xml ++++ b/build.xml +@@ -129,6 +129,10 @@ + + + ++ ++ ++ ++ +
+ + +-- +2.1.0 + diff --git a/README.en.md b/README.en.md deleted file mode 100644 index 0da3bc6..0000000 --- a/README.en.md +++ /dev/null @@ -1,36 +0,0 @@ -# nekohtml - -#### Description -{**When you're done, you can delete the content in this README and update the file with details for others getting started with your repository**} - -#### Software Architecture -Software architecture description - -#### Installation - -1. xxxx -2. xxxx -3. xxxx - -#### Instructions - -1. xxxx -2. xxxx -3. xxxx - -#### Contribution - -1. Fork the repository -2. Create Feat_xxx branch -3. Commit your code -4. Create Pull Request - - -#### Gitee Feature - -1. You can use Readme\_XXX.md to support different languages, such as Readme\_en.md, Readme\_zh.md -2. Gitee blog [blog.gitee.com](https://blog.gitee.com) -3. Explore open source project [https://gitee.com/explore](https://gitee.com/explore) -4. The most valuable open source project [GVP](https://gitee.com/gvp) -5. The manual of Gitee [https://gitee.com/help](https://gitee.com/help) -6. The most popular members [https://gitee.com/gitee-stars/](https://gitee.com/gitee-stars/) diff --git a/README.md b/README.md deleted file mode 100644 index b63718c..0000000 --- a/README.md +++ /dev/null @@ -1,39 +0,0 @@ -# nekohtml - -#### 介绍 -{**以下是码云平台说明,您可以替换此简介** -码云是 OSCHINA 推出的基于 Git 的代码托管平台(同时支持 SVN)。专为开发者提供稳定、高效、安全的云端软件开发协作平台 -无论是个人、团队、或是企业,都能够用码云实现代码托管、项目管理、协作开发。企业项目请看 [https://gitee.com/enterprises](https://gitee.com/enterprises)} - -#### 软件架构 -软件架构说明 - - -#### 安装教程 - -1. xxxx -2. xxxx -3. xxxx - -#### 使用说明 - -1. xxxx -2. xxxx -3. xxxx - -#### 参与贡献 - -1. Fork 本仓库 -2. 新建 Feat_xxx 分支 -3. 提交代码 -4. 新建 Pull Request - - -#### 码云特技 - -1. 使用 Readme\_XXX.md 来支持不同的语言,例如 Readme\_en.md, Readme\_zh.md -2. 码云官方博客 [blog.gitee.com](https://blog.gitee.com) -3. 你可以 [https://gitee.com/explore](https://gitee.com/explore) 这个地址来了解码云上的优秀开源项目 -4. [GVP](https://gitee.com/gvp) 全称是码云最有价值开源项目,是码云综合评定出的优秀开源项目 -5. 码云官方提供的使用手册 [https://gitee.com/help](https://gitee.com/help) -6. 码云封面人物是一档用来展示码云会员风采的栏目 [https://gitee.com/gitee-stars/](https://gitee.com/gitee-stars/) diff --git a/nekohtml-1.9.22.pom b/nekohtml-1.9.22.pom new file mode 100644 index 0000000..dbdd505 --- /dev/null +++ b/nekohtml-1.9.22.pom @@ -0,0 +1,45 @@ + + 4.0.0 + net.sourceforge.nekohtml + nekohtml + Neko HTML + An HTML parser and tag balancer. + 1.9.22 + http://nekohtml.sourceforge.net/ + + + The Apache Software License, Version 2.0 + http://www.apache.org/licenses/LICENSE-2.0.txt + repo + + + + http://nekohtml.svn.sourceforge.net/viewvc/nekohtml/ + + + + xerces + xercesImpl + 2.10.0 + + + + + Andy Clark + + + Marc Guillemot + mguillem + mguillem@users.sourceforge.net + http://mguillem.wordpress.com/ + +1 + + + + + nexus-releases + Nexus Release Repository + http://oss.sonatype.org/service/local/staging/deploy/maven2/ + + + diff --git a/nekohtml-1.9.22.tar.gz b/nekohtml-1.9.22.tar.gz new file mode 100644 index 0000000..42cbb97 Binary files /dev/null and b/nekohtml-1.9.22.tar.gz differ diff --git a/nekohtml.spec b/nekohtml.spec new file mode 100644 index 0000000..8b8a3a3 --- /dev/null +++ b/nekohtml.spec @@ -0,0 +1,66 @@ +Name: nekohtml +Version: 1.9.22 +Release: 8 +Summary: HTML scanner and tag balancer +License: ASL 2.0 +URL: http://nekohtml.sourceforge.net/ +Source0: nekohtml-%{version}.tar.gz +Source1: http://central.maven.org/maven2/net/sourceforge/nekohtml/nekohtml/%{version}/nekohtml-%{version}.pom +Patch0: 0001-Crosslink-javadoc.patch +Patch1: 0002-Jar-paths.patch +Patch2: 0003-Add-OSGi-attributes.patch +Requires: bcel xerces-j2 >= 0:2.7.1 xml-commons-apis +BuildRequires: javapackages-local ant ant-junit bcel xerces-j2 >= 0:2.7.1 xerces-j2-javadoc xml-commons-apis +BuildArch: noarch +Obsoletes: nekohtml-javadoc < %{version}-%{release} +Obsoletes: nekohtml-demo < %{version}-%{release} +Provides: nekohtml-javadoc = %{version}-%{release} +Provides: nekohtml-demo = %{version}-%{release} + +%description +NekoHTML is a simple HTML scanner and tag balancer that enables application programmers +to parse HTML documents and access the information using standard XML interfaces. + +%prep +%autosetup -p1 +find -name "*.jar" -delete +rm data/meta/test-meta-encoding3.html +%mvn_alias net.sourceforge.nekohtml:nekohtml nekohtml:nekohtml +%mvn_package net.sourceforge.nekohtml:nekohtml-samples demo +%mvn_file ':{*}' @1 + +%build +export CLASSPATH=$(build-classpath bcel xerces-j2 xml-commons-apis) +%{ant} \ + -Dbuild.sysclasspath=first \ + -Dlib.dir=%{_javadir} \ + -Djar.file=nekohtml.jar \ + -Djar.xni.file=nekohtml-xni.jar \ + -Djar.samples.file=nekohtml-samples.jar \ + -Dbcel.javadoc=%{_javadocdir}/bcel \ + -Dj2se.javadoc=%{_javadocdir}/java \ + -Dxni.javadoc=%{_javadocdir}/xerces-j2-xni \ + -Dxerces.javadoc=%{_javadocdir}/xerces-j2-impl \ + clean jar jar-xni doc +%mvn_artifact %{SOURCE1} nekohtml.jar +%mvn_artifact net.sourceforge.nekohtml:nekohtml-xni:%{version} nekohtml-xni.jar +%mvn_artifact net.sourceforge.nekohtml:nekohtml-samples:%{version} nekohtml-samples.jar + +%install +%mvn_install -J build/doc/javadoc +%jpackage_script org.cyberneko.html.filters.Writer "" "" "nekohtml:xerces-j2" nekohtml-filter true + +%files +%attr(0644,root,root) %{_datadir}/maven-metadata/nekohtml.xml +%attr(0644,root,root) %{_datadir}/maven-poms/nekohtml.pom +%attr(0644,root,root) %{_datadir}/java/nekohtml.jar +%attr(0644,root,root) %{_datadir}/java/nekohtml-xni.jar +%attr(0644,root,root) %{_datadir}/maven-metadata/nekohtml-demo.xml +%attr(0644,root,root) %{_datadir}/java/nekohtml-samples.jar +%doc LICENSE.txt README.txt doc/*.html +%{_bindir}/nekohtml-filter +%{_javadocdir}/%{name} + +%changelog +* Thu Dec 7 2019 openEuler Buildteam - 1.9.22-8 +- Package init