diff --git a/juniversalchardet-1.0.3-build.patch b/juniversalchardet-1.0.3-build.patch new file mode 100644 index 0000000..2293890 --- /dev/null +++ b/juniversalchardet-1.0.3-build.patch @@ -0,0 +1,50 @@ +--- build.xml 2008-07-23 14:46:29.000000000 +0200 ++++ build.xml-gil 2013-01-21 11:49:53.832802087 +0100 +@@ -72,7 +72,7 @@ + + + +- ++ + + + ++ + + + +@@ -100,4 +104,27 @@ + + + ++ ++ ++ ++ ++ ++ ++ ++ ++ juniversalchardet ${version} API]]> ++ Copyright © ${year}. All rights reserved]]> ++ ++ ++ + diff --git a/juniversalchardet-1.0.3.pom b/juniversalchardet-1.0.3.pom new file mode 100644 index 0000000..d4dacc5 --- /dev/null +++ b/juniversalchardet-1.0.3.pom @@ -0,0 +1,46 @@ + + + 4.0.0 + com.googlecode.juniversalchardet + juniversalchardet + 1.0.3 + jar + juniversalchardet + Java port of universalchardet + http://juniversalchardet.googlecode.com/ + + + Mozilla Public License 1.1 (MPL 1.1) + http://www.mozilla.org/MPL/MPL-1.1.html + repo + + + + scm:svn:http://juniversalchardet.googlecode.com/svn/trunk/ + http://code.google.com/p/juniversalchardet/source/browse/ + + + + takscape + takscape@gmail.com + + + + ${basedir}/src + + + maven-compiler-plugin + 2.3.2 + + 1.5 + 1.5 + + + + + + us-ascii + + \ No newline at end of file diff --git a/juniversalchardet-3fd330c443272699cd8ba5d7da7e56c27a567ec1.tar.gz b/juniversalchardet-3fd330c443272699cd8ba5d7da7e56c27a567ec1.tar.gz new file mode 100644 index 0000000..904ff81 Binary files /dev/null and b/juniversalchardet-3fd330c443272699cd8ba5d7da7e56c27a567ec1.tar.gz differ diff --git a/juniversalchardet.spec b/juniversalchardet.spec new file mode 100644 index 0000000..4e0e6b8 --- /dev/null +++ b/juniversalchardet.spec @@ -0,0 +1,52 @@ +%global githash 3fd330c443272699cd8ba5d7da7e56c27a567ec1 +Name: juniversalchardet +Version: 1.0.3 +Release: 1 +Summary: A Java port of Mozilla's universalchardet +License: MPLv1.1 or GPLv2+ or LGPLv2+ +URL: https://github.com/thkoch2001/juniversalchardet +Source0: https://github.com/thkoch2001/juniversalchardet/archive/%{githash}/%{name}-%{githash}.tar.gz +Source1: http://repo1.maven.org/maven2/com/googlecode/%{name}/%{name}/%{version}/%{name}-%{version}.pom +Patch0: %{name}-1.0.3-build.patch +BuildRequires: ant java-devel javapackages-local +BuildArch: noarch +%description +juniversalchardet is a Java port of 'universalchardet', +that is the encoding detector library of Mozilla. + +%package help +Summary: Javadoc for %{name} +Provides: %{name}-javadoc = %{version}-%{release} +Obsoletes: %{name}-javadoc < %{version}-%{release} +%description help +This package contains javadoc for %{name}. + +%prep +%setup -q -n %{name}-%{githash} +find . -name "*.class" -delete +find . -name "*.jar" -delete +%patch0 -p0 +sed -i 's/1.5/1.6/' build.xml +sed -i 's/\r//' readme.txt + +%build +%ant dist javadoc example + +%install +%mvn_artifact %{SOURCE1} dist/%{name}-%{version}.jar +%mvn_file com.googlecode.%{name}:%{name} %{name} +%mvn_install -J dist/docs +install -pm 644 dist/%{name}-example-%{version}.jar \ + %{buildroot}%{_javadir}/%{name}-example.jar + +%files -f .mfiles +%{_javadir}/%{name}-example.jar +%doc readme.txt +%license MPL-1.1.txt + +%files help -f .mfiles-javadoc +%license MPL-1.1.txt + +%changelog +* Mon Aug 24 2020 wangyue - 1.0.3-1 +- package init diff --git a/juniversalchardet.yaml b/juniversalchardet.yaml new file mode 100644 index 0000000..a15e4b3 --- /dev/null +++ b/juniversalchardet.yaml @@ -0,0 +1,5 @@ +git_url: https://github.com/thkoch2001/juniversalchardet +version_control: github +src_repo: thkoch2001/juniversalchardet +tag_prefix: "^juniversalchardet-" +seperator: "_"