%global finalversion %{version}.Final %global name_finalver %{name}-%{finalversion} Name: hibernate-commons-annotations Version: 5.0.1 Release: 7 Summary: Hibernate Commons Annotations License: LGPLv2 URL: http://www.hibernate.org/ Source0: https://github.com/hibernate/%{name}/archive/%{finalversion}/%{name_finalver}.tar.gz Source1: https://repository.jboss.org/nexus/service/local/repositories/central/content/org/hibernate/common/%{name}/%{finalversion}/%{name_finalver}.pom Source2: encoding-code.txt Source3: logging-code.txt Source4: MANIFEST-code.txt Source5: OSGi-code.txt BuildArch: noarch BuildRequires: maven-local mvn(junit:junit) mvn(org.apache.felix:maven-bundle-plugin) BuildRequires: mvn(org.bsc.maven:maven-processor-plugin) mvn(org.jboss.logging:jboss-logging) BuildRequires: mvn(org.jboss.logging:jboss-logging-annotations) BuildRequires: mvn(org.jboss.logging:jboss-logging-processor) %description Hibernate Commons Annotations is a utility project used by several Hibernate projects; as a user of Hibernate libraries you probably are not going to use this directly. It's first scope is to support Java Generics type discovery. It's second scope is to support Java Annotations overriding through XML files (mainly but not conceptually limited to). %package_help %prep %autosetup -n %{name_finalver} find . -name '*.class' -print -delete find . -name '*.jar' -print -delete cp %{SOURCE1} pom.xml %pom_xpath_inject pom:project "`cat %{SOURCE2}`" %pom_add_plugin org.bsc.maven:maven-processor-plugin:2.2.4 . "`cat %{SOURCE3}`" %pom_add_plugin org.apache.maven.plugins:maven-jar-plugin:2.6 . "`cat %{SOURCE4}`" %pom_add_plugin org.apache.felix:maven-bundle-plugin:2.5.4 . "`cat %{SOURCE5}`" %pom_add_dep org.jboss.logging:jboss-logging-annotations:2.0.1.Final:compile %pom_add_dep junit:junit:4.12:test %build %mvn_build %install %mvn_install %files -f .mfiles %license lgpl.txt %files help -f .mfiles-javadoc %doc changelog.txt readme.txt %changelog * Mon Dec 16 2019 mengxian - 5.0.1-7 - Add missing source files * Tue Dec 10 2019 mengxian - 5.0.1-6 - Package init