diff --git a/.gitignore b/.gitignore index e69de29..52140df 100644 --- a/.gitignore +++ b/.gitignore @@ -0,0 +1 @@ +/hibernate-commons-annotations-3.2.0.Final.tar.xz diff --git a/hibernate-commons-annotations.spec b/hibernate-commons-annotations.spec new file mode 100644 index 0000000..936ce8f --- /dev/null +++ b/hibernate-commons-annotations.spec @@ -0,0 +1,106 @@ +%global namedreltag .Final +%global namedversion %{version}%{?namedreltag} + +Name: hibernate-commons-annotations +Version: 3.2.0 +Release: 3%{?dist} +Summary: Hibernate Annotations + +Group: Development/Libraries + +# For details see: +# - https://github.com/hibernate/hibernate-commons-annotations/commit/4a902b4f97f923f9044a4127357b44fe5dc39cdc +# - https://github.com/hibernate/hibernate-commons-annotations/commit/a11c44cd65dadcedaf8981379b94a2c4e31428d1 +License: LGPLv2 +URL: http://www.hibernate.org/ + +# git clone git://github.com/hibernate/hibernate-commons-annotations.git +# cd hibernate-commons-annotations && git archive --format=tar --prefix=hibernate-commons-annotations-3.2.0.Final/ 3.2.0.Final | xz > hibernate-commons-annotations-3.2.0.Final.tar.xz +Source0: %{name}-%{namedversion}.tar.xz + +BuildArch: noarch + +Requires: java +Requires: slf4j +Requires: jpackage-utils + +Requires(post): jpackage-utils +Requires(postun): jpackage-utils + +BuildRequires: junit +BuildRequires: slf4j +BuildRequires: apache-commons-logging +BuildRequires: jpackage-utils +BuildRequires: java-devel +BuildRequires: maven + +BuildRequires: maven-compiler-plugin +BuildRequires: maven-install-plugin +BuildRequires: maven-jar-plugin +BuildRequires: maven-javadoc-plugin +BuildRequires: maven-release-plugin +BuildRequires: maven-resources-plugin +BuildRequires: maven-surefire-plugin + +%description +Following the DRY (Don't Repeat Yourself) principle, +Hibernate Validator let's you express your domain +constraints once (and only once) and ensure their +compliance at various level of your system +automatically. + +Common reflection code used in support of annotation processing. + +%package javadoc +Summary: Javadocs for %{name} +Group: Documentation +Requires: jpackage-utils + +%description javadoc +This package contains the API documentation for %{name}. + +%prep +%setup -q -n %{name}-%{namedversion} + +%build +mvn-rpmbuild install javadoc:aggregate + +%install + +mkdir -p $RPM_BUILD_ROOT%{_javadir}/hibernate +cp -p target/%{name}-%{namedversion}.jar $RPM_BUILD_ROOT%{_javadir}/hibernate/%{name}.jar + +mkdir -p $RPM_BUILD_ROOT%{_javadocdir}/%{name} +cp -rp target/site/apidocs/ $RPM_BUILD_ROOT%{_javadocdir}/%{name} + +install -d -m 755 $RPM_BUILD_ROOT%{_mavenpomdir} +install -pm 644 pom.xml $RPM_BUILD_ROOT%{_mavenpomdir}/JPP.hibernate-%{name}.pom + +%add_to_maven_depmap org.hibernate hibernate-commons-annotations %{version} JPP/hibernate %{name} + +%post +%update_maven_depmap + +%postun +%update_maven_depmap + +%files +%{_mavenpomdir}/* +%{_mavendepmapfragdir}/* +%{_javadir}/* +%doc changelog.txt readme.txt + +%files javadoc +%{_javadocdir}/%{name} + +%changelog +* Wed Jun 01 2011 Marek Goldmann 3.2.0-3 +- Fixed license +- Using source from git + +* Mon May 23 2011 Marek Goldmann 3.2.0-2 +- Moved to hibernate subdirectory + +* Fri May 20 2011 Marek Goldmann 3.2.0-1 +- Initial packaging + diff --git a/sources b/sources index e69de29..5e2e56a 100644 --- a/sources +++ b/sources @@ -0,0 +1 @@ +c9e229adddede975861bcf6dfb54eb38 hibernate-commons-annotations-3.2.0.Final.tar.xz