byte-buddy/byte-buddy.spec

145 lines
5.0 KiB
RPMSpec
Raw Normal View History

2020-08-18 19:27:56 +08:00
%bcond_with bootstrap
Name: byte-buddy
Version: 1.14.2
2020-08-18 19:27:56 +08:00
Release: 1
Summary: Runtime code generation for the Java virtual machine
2022-06-20 17:07:42 +08:00
License: Apache-2.0
2020-08-18 19:27:56 +08:00
URL: http://bytebuddy.net/
Source0: https://github.com/raphw/byte-buddy/archive/byte-buddy-%{version}.tar.gz
2022-06-20 17:07:42 +08:00
Source1: xmvn-reactor
2022-06-20 17:07:42 +08:00
Patch0: 0001-Avoid-bundling-asm.patch
Patch1: 0002-Remove-dependencies.patch
2020-08-18 19:27:56 +08:00
BuildRequires: maven-local
2022-06-20 17:07:42 +08:00
BuildRequires: java-1.8.0-openjdk-devel maven
2022-06-20 17:07:42 +08:00
Requires: byte-buddy-agent byte-buddy-maven-plugin byte-buddy-parent
2020-08-18 19:27:56 +08:00
BuildArch: noarch
%description
Byte Buddy is a code generation library for creating Java classes during the
runtime of a Java application and without the help of a compiler. Other than
the code generation utilities that ship with the Java Class Library, Byte Buddy
allows the creation of arbitrary classes and is not limited to implementing
interfaces for the creation of runtime proxies.
%package agent
Summary: Byte Buddy Java agent
2022-06-20 17:07:42 +08:00
Requires: byte-buddy
2020-08-18 19:27:56 +08:00
%description agent
The Byte Buddy Java agent allows to access the JVM's HotSwap feature.
%package maven-plugin
Summary: Byte Buddy Maven plugin
2022-06-20 17:07:42 +08:00
Requires: byte-buddy
2020-08-18 19:27:56 +08:00
%description maven-plugin
A plugin for post-processing class files via Byte Buddy in a Maven build.
%package parent
Summary: Byte Buddy parent POM
2022-06-20 17:07:42 +08:00
Requires: byte-buddy
2020-08-18 19:27:56 +08:00
%description parent
The parent artifact contains configuration information that
concern all modules.
%package javadoc
Summary: Javadoc for %{name}
%description javadoc
This package contains API documentation for %{name}.
%prep
%autosetup -n %{name}-%{name}-%{version} -p1
find -name '*.class' -delete
2022-06-20 17:07:42 +08:00
rm byte-buddy-agent/src/test/java/net/bytebuddy/agent/VirtualMachineAttachmentTest.java
rm byte-buddy-agent/src/test/java/net/bytebuddy/agent/VirtualMachineForOpenJ9Test.java
rm byte-buddy-agent/src/test/java/net/bytebuddy/test/utility/JnaRule.java
2022-06-20 17:07:42 +08:00
2020-08-18 19:27:56 +08:00
%pom_disable_module byte-buddy-android
2022-06-20 17:07:42 +08:00
%pom_disable_module byte-buddy-android-test
2020-08-18 19:27:56 +08:00
%pom_disable_module byte-buddy-benchmark
%pom_disable_module byte-buddy-gradle-plugin
2022-06-20 17:07:42 +08:00
2020-08-18 19:27:56 +08:00
%pom_remove_plugin :jacoco-maven-plugin
%pom_remove_plugin :license-maven-plugin
%pom_remove_plugin :pitest-maven
%pom_remove_plugin :coveralls-maven-plugin
%pom_remove_plugin :spotbugs-maven-plugin
%pom_remove_plugin :jitwatch-jarscan-maven-plugin
%pom_remove_plugin :maven-release-plugin
2022-06-20 17:07:42 +08:00
%pom_remove_plugin :nexus-staging-maven-plugin
%pom_remove_plugin :byte-buddy-maven-plugin byte-buddy-dep
2020-08-18 19:27:56 +08:00
%pom_xpath_set "pom:createSourcesJar" "false" byte-buddy
%pom_remove_dep :findbugs-annotations
sed -i -e '/SuppressFBWarnings/d' $(grep -lr SuppressFBWarnings)
2022-06-20 17:07:42 +08:00
%pom_remove_dep org.ow2.asm:asm-deprecated
%pom_remove_plugin -r :maven-shade-plugin
%pom_remove_dep -r net.java.dev.jna:jna
%pom_remove_dep -r net.java.dev.jna:jna-platform
2022-06-20 17:07:42 +08:00
cp %{SOURCE1} ./.xmvn-reactor
echo `pwd` > absolute_prefix.log
sed -i 's/\//\\\//g' absolute_prefix.log
absolute_prefix=`head -n 1 absolute_prefix.log`
sed -i 's/absolute-prefix/'"$absolute_prefix"'/g' .xmvn-reactor
2020-08-18 19:27:56 +08:00
%build
2022-06-20 17:07:42 +08:00
mvn package -Dsourcecode.test.version=1.8 -Dmaven.test.failure.ignore=true -P'java8,!checks' verify org.apache.maven.plugins:maven-javadoc-plugin:aggregate
2020-08-18 19:27:56 +08:00
%install
%mvn_install
2022-06-20 17:07:42 +08:00
%files
%attr(0644,root,root) /usr/share/maven-metadata/byte-buddy.xml
%attr(0755,root,root) %dir /usr/share/java/byte-buddy
%attr(0644,root,root) /usr/share/java/byte-buddy/byte-buddy.jar
%attr(0755,root,root) %dir /usr/share/maven-poms/byte-buddy
%attr(0644,root,root) /usr/share/maven-poms/byte-buddy/byte-buddy.pom
%attr(0755,root,root) %dir /usr/share/java/byte-buddy
%attr(0644,root,root) /usr/share/java/byte-buddy/byte-buddy-dep.jar
%attr(0755,root,root) %dir /usr/share/maven-poms/byte-buddy
%attr(0644,root,root) /usr/share/maven-poms/byte-buddy/byte-buddy-dep.pom
2020-08-18 19:27:56 +08:00
%doc README.md release-notes.md
%license LICENSE NOTICE
2022-06-20 17:07:42 +08:00
%files agent
%attr(0755,root,root) %dir /usr/share/java/byte-buddy
%attr(0644,root,root) /usr/share/java/byte-buddy/byte-buddy-agent.jar
%attr(0755,root,root) %dir /usr/share/maven-poms/byte-buddy
%attr(0644,root,root) /usr/share/maven-poms/byte-buddy/byte-buddy-agent.pom
2020-08-18 19:27:56 +08:00
%license LICENSE NOTICE
2022-06-20 17:07:42 +08:00
%files maven-plugin
%attr(0755,root,root) %dir /usr/share/java/byte-buddy
%attr(0644,root,root) /usr/share/java/byte-buddy/byte-buddy-maven-plugin.jar
%attr(0755,root,root) %dir /usr/share/maven-poms/byte-buddy
%attr(0644,root,root) /usr/share/maven-poms/byte-buddy/byte-buddy-maven-plugin.pom
2020-08-18 19:27:56 +08:00
2022-06-20 17:07:42 +08:00
%files parent
%attr(0755,root,root) %dir /usr/share/maven-poms/byte-buddy
%attr(0644,root,root) /usr/share/maven-poms/byte-buddy/byte-buddy-parent.pom
2020-08-18 19:27:56 +08:00
%license LICENSE NOTICE
2022-06-20 17:07:42 +08:00
%files javadoc
/usr/share/javadoc/byte-buddy
2020-08-18 19:27:56 +08:00
%license LICENSE NOTICE
%changelog
* Wed Aug 02 2023 xu_ping <707078654@qq.com> - 1.14.2-1
- Upgrade to version 1.14.2
2022-06-20 17:07:42 +08:00
* Thu Jun 16 2022 Ge Wang <wangge20@h-partners.com> - 1.12.0-1
- Upgrade to version 1.12.0
2020-08-18 19:27:56 +08:00
* Fri Aug 14 2020 leiju <leiju4@huawei.com> - 1.9.5-1
- Package init