diff --git a/0001-add-dependency-package.patch b/0001-add-dependency-package.patch new file mode 100644 index 0000000..2ab52d7 --- /dev/null +++ b/0001-add-dependency-package.patch @@ -0,0 +1,54 @@ +From b6676a64cf6b27fdadd2c216d0bf86fe1ce9fcf5 Mon Sep 17 00:00:00 2001 +From: wang--ge +Date: Wed, 17 May 2023 16:58:50 +0800 +Subject: [PATCH] add dependency package + +--- + pom.xml | 31 +++++++++++++++++++++++++++++++ + 1 file changed, 31 insertions(+) + +diff --git a/pom.xml b/pom.xml +index 57edaed..d13bc8b 100644 +--- a/pom.xml ++++ b/pom.xml +@@ -122,6 +122,37 @@ + + + ++ ++ org.apache.maven.plugins ++ maven-dependency-plugin ++ 3.2.0 ++ ++ ++ prepare-package ++ ++ copy ++ ++ ++ ++ ++ org.jruby.jcodings ++ jcodings ++ 1.0.9 ++ false ++ ${project.build.directory} ++ ++ ++ org.jruby.joni ++ joni ++ 2.1.3 ++ false ++ ${project.build.directory} ++ ++ ++ ++ ++ ++ + + + +-- +2.33.0 + diff --git a/bytelist.spec b/bytelist.spec index 09b8cf4..7d66c1f 100644 --- a/bytelist.spec +++ b/bytelist.spec @@ -2,37 +2,57 @@ Name: bytelist Version: 1.0.8 -Release: 17 +Release: 18 Summary: Java library for lists of bytes License: CPL or GPLv2+ or LGPLv2+ URL: http://github.com/jruby/bytelist Source0: https://github.com/jruby/bytelist/archive/%{version}.tar.gz +Source1: https://repo.maven.apache.org/maven2/org/jruby/jcodings/jcodings/1.0.9/jcodings-1.0.9.pom +Source2: https://repo.maven.apache.org/maven2/org/jruby/joni/joni/2.1.3/joni-2.1.3.pom +Patch0: 0001-add-dependency-package.patch BuildArch: noarch -BuildRequires: ant, ant-junit, java-devel, jcodings, jpackage-utils, javapackages-local, junit -Requires: java-headless, jcodings, jpackage-utils +BuildRequires: java-devel, jcodings, jpackage-utils, javapackages-local, junit +BuildRequires: maven-local +BuildRequires: maven +Requires: java-headless, jpackage-utils +Conflicts: mvn(org.jruby.jcodings:jcodings) > 1.0.9 +Conflicts: mvn(org.jruby.joni:joni) > 2.1.3 +Provides: mvn(org.jruby.jcodings:jcodings) = 1.0.9 +Provides: mvn(org.jruby.joni:joni) = 2.1.3 %description This module is a small java library for manipulating lists of bytes. %prep %autosetup -p1 +cp %{SOURCE1} . +cp %{SOURCE2} . find \( -name "*.jar" -o -name "*.class" \) -delete +%pom_remove_plugin org.apache.maven.plugins:maven-javadoc-plugin %build echo "See %{url} for more info about the %{name} project." > README.txt export CLASSPATH=$(build-classpath junit jcodings) install -d lib -%ant +mvn package -DskipTests -Pdist -Dtar %install +install -d -m 755 %{buildroot}%{_javadir}/joni install -d $RPM_BUILD_ROOT%{_javadir} -cp -p lib/%{name}-1.0.2.jar $RPM_BUILD_ROOT%{_javadir}/%{name}.jar +cp -p target/%{name}-%{version}.jar $RPM_BUILD_ROOT%{_javadir}/%{name}.jar +cp -arf target/jcodings-1.0.9.jar %{buildroot}%{_javadir}/jcodings.jar +cp -arf target/joni-2.1.3.jar %{buildroot}%{_javadir}/joni/joni.jar +install -d -m 755 %{buildroot}%{_mavenpomdir}/joni install -d $RPM_BUILD_ROOT%{_mavenpomdir} install -pm 644 pom.xml $RPM_BUILD_ROOT%{_mavenpomdir}/JPP-%{name}.pom +install -pm 644 jcodings-1.0.9.pom %{buildroot}%{_mavenpomdir}/jcodings.pom +install -pm 644 joni-2.1.3.pom %{buildroot}%{_mavenpomdir}/joni/joni.pom %add_maven_depmap JPP-%{name}.pom %{name}.jar +%add_maven_depmap jcodings.pom jcodings.jar +%add_maven_depmap joni/joni.pom joni/joni.jar %check export CLASSPATH=$(build-classpath junit jcodings) @@ -45,5 +65,8 @@ export CLASSPATH=$(build-classpath junit jcodings) %{_datadir}/maven-metadata/%{name}.xml %changelog +* Wed May 17 2023 Ge Wang - 1.0.8-18 +- Add dependency package + * Tue Feb 11 2020 Shuaishuai Song - 1.0.8-17 - Package init diff --git a/jcodings-1.0.9.pom b/jcodings-1.0.9.pom new file mode 100644 index 0000000..7c42aaf --- /dev/null +++ b/jcodings-1.0.9.pom @@ -0,0 +1,152 @@ + + + 4.0.0 + org.jruby.jcodings + jcodings + jar + 1.0.9 + JCodings + + Byte based encoding support library for java + + + + JIRA + http://jira.codehaus.org/browse/JRUBY + + + + scm:svn:http://svn.codehaus.org/jruby + scm:svn:https://svn.codehaus.org/jruby + http://svn.codehaus.org/jruby + + + + + MIT License + http://www.opensource.org/licenses/mit-license.php + repo + + + + + + codehaus-jruby-repository + JRuby Central Repository + dav:https://dav.codehaus.org/repository/jruby + + + codehaus-jruby-snapshot-repository + JRuby Central Development Repository + dav:https://dav.codehaus.org/snapshots.repository/jruby + + + codehaus-jruby-site + JRuby Maven site + dav:https://dav.codehaus.org/jruby/info + + + + + + codehaus + Codehaus Repository + + true + + + false + + http://repository.codehaus.org + + + + + + lopex + Marcin Mielzynski + lopx@gazeta.pl + + + + + + junit + junit + 4.10 + test + + + + + src + scripts + test + jcodings + + + org.apache.maven.wagon + wagon-webdav-jackrabbit + 2.1 + + + + + org.apache.maven.plugins + maven-source-plugin + + + attach-sources + + jar + + + + + + org.apache.maven.plugins + maven-javadoc-plugin + + + attach-javadocs + + jar + + + + + true + + + + maven-compiler-plugin + + 1.5 + 1.5 + + + + maven-jar-plugin + + + MANIFEST.MF + + + + + org.apache.maven.plugins + maven-resources-plugin + + + + + resources + + **/*.bin + + + + + + diff --git a/joni-2.1.3.pom b/joni-2.1.3.pom new file mode 100644 index 0000000..89890d2 --- /dev/null +++ b/joni-2.1.3.pom @@ -0,0 +1,157 @@ + + + 4.0.0 + org.jruby.joni + joni + jar + 2.1.3 + Joni + + Java port of Oniguruma: http://www.geocities.jp/kosako3/oniguruma + that uses byte arrays directly instead of java Strings and chars + + + + UTF-8 + + + + org.sonatype.oss + oss-parent + 7 + + + + JIRA + http://jira.codehaus.org/browse/JRUBY + + + + scm:git:https://github.com/jruby/joni.git + scm:git:git@github.com:jruby/joni.git + https://github.com/jruby/joni + + + + + MIT License + http://www.opensource.org/licenses/mit-license.php + repo + + + + + + codehaus + Codehaus Repository + + true + + + false + + http://repository.codehaus.org + + + + + + lopex + Marcin Mielzynski + lopx@gazeta.pl + + + + + + org.jruby.jcodings + jcodings + 1.0.8 + + + junit + junit + 3.8.1 + test + + + org.ow2.asm + asm + 4.0 + provided + + + + + src + test + joni + + + org.apache.maven.wagon + wagon-webdav + + + + + maven-compiler-plugin + 2.3.2 + + 1.5 + 1.5 + + + + org.apache.maven.plugins + maven-surefire-plugin + 2.4.3 + + + **/TestJoni.java + + + + + maven-jar-plugin + 2.2 + + + MANIFEST.MF + + + + + org.apache.maven.plugins + maven-source-plugin + 2.1.2 + + + attach-sources + verify + + jar-no-fork + + + + + + org.apache.maven.plugins + maven-javadoc-plugin + 2.8.1 + + private + true + + + + attach-sources + verify + + jar + + + + + + +