77cba8c
# Copyright (c) 2000-2009, JPackage Project
77cba8c
# All rights reserved.
77cba8c
#
77cba8c
# Redistribution and use in source and binary forms, with or without
77cba8c
# modification, are permitted provided that the following conditions
77cba8c
# are met:
77cba8c
#
77cba8c
# 1. Redistributions of source code must retain the above copyright
77cba8c
#    notice, this list of conditions and the following disclaimer.
77cba8c
# 2. Redistributions in binary form must reproduce the above copyright
77cba8c
#    notice, this list of conditions and the following disclaimer in the
77cba8c
#    documentation and/or other materials provided with the
77cba8c
#    distribution.
77cba8c
# 3. Neither the name of the JPackage Project nor the names of its
77cba8c
#    contributors may be used to endorse or promote products derived
77cba8c
#    from this software without specific prior written permission.
77cba8c
#
77cba8c
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
77cba8c
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
77cba8c
# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
77cba8c
# A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
77cba8c
# OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
77cba8c
# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
77cba8c
# LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
77cba8c
# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
77cba8c
# THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
77cba8c
# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
77cba8c
# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
77cba8c
#
77cba8c
77cba8c
Summary:        A library for instantiating Java objects
77cba8c
Name:           objenesis
77cba8c
Version:        1.2
b7a6753
Release:        18%{dist}
77cba8c
Group:          Development/Libraries
77cba8c
License:        ASL 2.0
Mat Booth 7875ce3
URL:            http://objenesis.org/
77cba8c
# svn export http://objenesis.googlecode.com/svn/tags/1_2/ objenesis-1.2
77cba8c
# tar cfJ objenesis-1.2.tar.xz objenesis-1.2
77cba8c
Source0:        %{name}-%{version}.tar.xz
77cba8c
77cba8c
# Skipping website (requires xsite), this patch is unused atm
77cba8c
#Patch0:         objenesis-website-pom.patch
77cba8c
77cba8c
# Remove deps for test scope (unavailable); fix
77cba8c
# maven-license-plugin groupID to latest version available.
77cba8c
Patch1:         001-objenesis-fix-build.patch
Jiri Vanek 17a7625
Patch2:         JRockitInstantntiatorCharacters.patch
77cba8c
77cba8c
BuildRequires:  jpackage-utils
77cba8c
BuildRequires:  java-devel
77cba8c
BuildRequires:  junit
Stanislav Ochotnicky 0c06e2c
BuildRequires:  maven-local
77cba8c
BuildRequires:  maven-shade-plugin
77cba8c
BuildRequires:  maven-license-plugin
77cba8c
BuildRequires:  maven-timestamp-plugin
77cba8c
BuildRequires:  xpp3-minimal
Mat Booth 7875ce3
BuildRequires:  objectweb-asm
Jiri Vanek 17a7625
BuildRequires:  apache-resource-bundles
b7a6753
BuildRequires:  maven-wagon-ssh-external
77cba8c
77cba8c
BuildArch:      noarch
77cba8c
77cba8c
%description
6c3e4ba
Objenesis is a small Java library that serves one purpose: to instantiate 
6c3e4ba
a new object of a particular class.
6c3e4ba
Java supports dynamic instantiation of classes using Class.newInstance(); 
6c3e4ba
however, this only works if the class has an appropriate constructor. There 
77cba8c
are many times when a class cannot be instantiated this way, such as when 
6c3e4ba
the class contains constructors that require arguments, that have side effects,
6c3e4ba
and/or that throw exceptions. As a result, it is common to see restrictions 
6c3e4ba
in libraries stating that classes must require a default constructor. 
6c3e4ba
Objenesis aims to overcome these restrictions by bypassing the constructor 
6c3e4ba
on object instantiation. Needing to instantiate an object without calling 
6c3e4ba
the constructor is a fairly specialized task, however there are certain cases 
6c3e4ba
when this is useful:
77cba8c
* Serialization, Remoting and Persistence - Objects need to be instantiated 
77cba8c
  and restored to a specific state, without invoking code.
Mat Booth 7875ce3
* Proxies, AOP Libraries and Mock Objects - Classes can be sub-classed without 
77cba8c
  needing to worry about the super() constructor.
77cba8c
* Container Frameworks - Objects can be dynamically instantiated in 
77cba8c
  non-standard ways.
77cba8c
77cba8c
77cba8c
%package javadoc
77cba8c
Group:          Documentation
77cba8c
Summary:        Javadoc for %{name}
77cba8c
BuildArch:      noarch
77cba8c
77cba8c
%description javadoc
77cba8c
This package contains the API documentation for %{name}.
77cba8c
77cba8c
77cba8c
# Skipped till xsite avilable in fedora
77cba8c
#%%package manual
77cba8c
#Group:          Documentation
77cba8c
#Summary:        Documents for %%{name}
77cba8c
#
77cba8c
#%%description manual
77cba8c
#This package contains the %%{name} manual.
77cba8c
77cba8c
77cba8c
%prep
77cba8c
%setup -q 
77cba8c
#%%patch0 -b .sav0
77cba8c
%patch1 -p1
Jiri Vanek 17a7625
%patch2 -p2
77cba8c
0140e12
# Enable generation of pom.properties (rhbz#1017850)
0140e12
%pom_xpath_remove pom:addMavenDescriptor
0140e12
77cba8c
77cba8c
%build
77cba8c
# tests are skipped because of missing dependency spring-osgi-test
Mat Booth 7875ce3
%mvn_build -- -Dyear=2009 -Dmaven.test.skip=true
77cba8c
77cba8c
# Below is for manual (requires xsite), skipped
77cba8c
#pushd website
77cba8c
#mvn-jpp -e \
77cba8c
#        -s ${M2SETTINGS} \
77cba8c
#        -Dmaven.repo.local=$MAVEN_REPO_LOCAL \
77cba8c
#        -Dmaven2.jpp.depmap.file=%%{SOURCE1} \
77cba8c
#        antrun:run 
77cba8c
#popd
77cba8c
77cba8c
77cba8c
%install
Mat Booth 7875ce3
%mvn_install
77cba8c
77cba8c
Mat Booth 7875ce3
%files -f .mfiles
Mat Booth 7875ce3
%dir %{_javadir}/%{name}
77cba8c
%doc LICENSE.txt
77cba8c
Mat Booth 7875ce3
%files javadoc -f .mfiles-javadoc
16d6166
%doc LICENSE.txt
77cba8c
77cba8c
77cba8c
%changelog
b7a6753
* Tue Feb  3 2015 Mikolaj Izdebski <mizdebsk@redhat.com> - 1.2-18
b7a6753
- Add missing BR on maven-wagon-ssh-external
b7a6753
- Resolves: rhbz#1106608
b7a6753
4724fd0
* Sat Jun 07 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.2-17
4724fd0
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild
4724fd0
0140e12
* Thu Oct 10 2013 Mikolaj Izdebski <mizdebsk@redhat.com> - 1.2-16
0140e12
- Enable generation of pom.properties
0140e12
- Resolves: rhbz#1017850
0140e12
Mat Booth 7875ce3
* Sun Sep 08 2013 Mat Booth <fedora@matbooth.co.uk> - 1.2-15
Mat Booth 7875ce3
- Update for latest guidelines, rhbz #992389
Mat Booth 7875ce3
2df37fe
* Sat Aug 03 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.2-14
2df37fe
- Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild
2df37fe
ed112fe
* Thu Feb 14 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.2-13
ed112fe
- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild
ed112fe
Stanislav Ochotnicky 0c06e2c
* Wed Feb 06 2013 Java SIG <java-devel@lists.fedoraproject.org> - 1.2-12
Stanislav Ochotnicky 0c06e2c
- Update for https://fedoraproject.org/wiki/Fedora_19_Maven_Rebuild
Stanislav Ochotnicky 0c06e2c
- Replace maven BuildRequires with maven-local
Stanislav Ochotnicky 0c06e2c
6ed6774
* Fri Jul 20 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.2-11
6ed6774
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
6ed6774
16d6166
* Mon May 14 2012 Guido Grazioli <guido.grazioli@gmail.com> 1.2-10
16d6166
- Update to current Java packaging guidelines
16d6166
- Remove maven-eclipse-plugin BR
16d6166
Jiri Vanek 17a7625
* Mon Feb 20 2012 Jiri Vanek <jvanek@redhat.com> 1.2-9
Jiri Vanek 17a7625
- Added patch2 - JRockitInstantntiatorCharacters.patch to fix unmappable characters
Jiri Vanek 17a7625
- Added build requires  apache-resource-bundles and  maven-remote-resources-plugin
Jiri Vanek 17a7625
9c37b5e
* Fri Jan 13 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.2-8
9c37b5e
- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild
9c37b5e
6c3e4ba
* Mon May 09 2011 Guido Grazioli <guido.grazioli@gmail.com> 1.2-7
6c3e4ba
- Improve project description
6c3e4ba
77cba8c
* Thu Feb 24 2011 Guido Grazioli <guido.grazioli@gmail.com> 1.2-6
77cba8c
- Build with mvn-rpmbuild
77cba8c
- Fix License
77cba8c
- Comment on skipped tests
77cba8c
77cba8c
* Fri Feb 04 2011 Guido Grazioli <guido.grazioli@gmail.com> 1.2-5
77cba8c
- Build with maven 3
77cba8c
77cba8c
* Sun Jan 23 2011 Guido Grazioli <guido.grazioli@gmail.com> 1.2-4
77cba8c
- Drop buildroot and %%clean section
77cba8c
- Drop use of maven2-settings.xml and jpp-depmap.xml
77cba8c
- Install unversioned jars
77cba8c
- Clean up of needed patch and mvn-jpp execution
77cba8c
77cba8c
* Tue Jan 18 2011 Guido Grazioli <guido.grazioli@gmail.com> 1.2-3
77cba8c
- Fix build in rawhide
77cba8c
77cba8c
* Sat Dec 04 2010 Guido Grazioli <guido.grazioli@gmail.com> 1.2-2
77cba8c
- Fix build in rawhide
77cba8c
- Update to new Java Packaging Guidelines
77cba8c
77cba8c
* Mon May 10 2010 Guido Grazioli <guido.grazioli@gmail.com> 1.2-1
77cba8c
- Update to 1.2
77cba8c
77cba8c
* Thu May 06 2010 Guido Grazioli <guido.grazioli@gmail.com> 1.0-1
77cba8c
- Import from JPackage 
77cba8c
77cba8c
* Fri Feb 27 2009 Ralph Apel <r.apel at r-apel.de> 0:1.0-2.jpp5
77cba8c
- BR xpp3-minimal and fix depmap accordingly
77cba8c
- Disown poms and fragments dirs
77cba8c
77cba8c
* Wed Jun 18 2008 Ralph Apel <r.apel at r-apel.de> 0:1.0-1.jpp5
77cba8c
- First release