Initial import (#590681).
This commit is contained in:
parent
8eed5ef500
commit
77cba8c42b
1
.gitignore
vendored
1
.gitignore
vendored
@ -0,0 +1 @@
|
||||
/objenesis-1.2.tar.xz
|
||||
116
001-objenesis-fix-build.patch
Normal file
116
001-objenesis-fix-build.patch
Normal file
@ -0,0 +1,116 @@
|
||||
--- A/main/pom.xml 2009-08-27 00:15:13.000000000 +0200
|
||||
+++ B/main/pom.xml 2010-05-10 14:44:07.634785201 +0200
|
||||
@@ -38,7 +38,7 @@
|
||||
<artifactId>maven-timestamp-plugin</artifactId>
|
||||
</plugin>
|
||||
<plugin>
|
||||
- <groupId>com.google.code.maven-license-plugin</groupId>
|
||||
+ <groupId>com.mycila.maven-license-plugin</groupId>
|
||||
<artifactId>maven-license-plugin</artifactId>
|
||||
</plugin>
|
||||
<plugin>
|
||||
--- A/pom.xml 2009-08-26 23:12:00.000000000 +0200
|
||||
+++ B/pom.xml 2010-05-10 14:44:07.635789574 +0200
|
||||
@@ -203,9 +203,9 @@
|
||||
</executions>
|
||||
</plugin>
|
||||
<plugin>
|
||||
- <groupId>com.google.code.maven-license-plugin</groupId>
|
||||
+ <groupId>com.mycila.maven-license-plugin</groupId>
|
||||
<artifactId>maven-license-plugin</artifactId>
|
||||
- <version>1.4.0</version>
|
||||
+ <version>1.6.1</version>
|
||||
<configuration>
|
||||
<header>${basedir}/../header.txt</header>
|
||||
<excludes>
|
||||
@@ -291,7 +291,7 @@
|
||||
<pluginManagement>
|
||||
<plugins>
|
||||
<plugin>
|
||||
- <groupId>com.google.code.maven-license-plugin</groupId>
|
||||
+ <groupId>com.mycila.maven-license-plugin</groupId>
|
||||
<artifactId>maven-license-plugin</artifactId>
|
||||
<executions>
|
||||
<execution>
|
||||
--- A/tck/pom.xml 2009-08-26 23:27:20.000000000 +0200
|
||||
+++ B/tck/pom.xml 2010-05-10 14:52:36.424792684 +0200
|
||||
@@ -34,70 +34,6 @@
|
||||
<version>${project.version}</version>
|
||||
</dependency>
|
||||
|
||||
- <!-- Dependencies below are for the OSGi test -->
|
||||
-
|
||||
- <dependency>
|
||||
- <groupId>org.springframework.osgi</groupId>
|
||||
- <artifactId>spring-osgi-test</artifactId>
|
||||
- <version>1.2.0</version>
|
||||
- <scope>test</scope>
|
||||
- </dependency>
|
||||
- <dependency>
|
||||
- <groupId>org.springframework.osgi</groupId>
|
||||
- <artifactId>spring-osgi-annotation</artifactId>
|
||||
- <version>1.2.0</version>
|
||||
- <scope>test</scope>
|
||||
- </dependency>
|
||||
- <dependency>
|
||||
- <groupId>org.springframework.osgi</groupId>
|
||||
- <artifactId>spring-osgi-extender</artifactId>
|
||||
- <version>1.2.0</version>
|
||||
- <scope>test</scope>
|
||||
- </dependency>
|
||||
-
|
||||
- <!-- These are just to have a nice logging -->
|
||||
- <dependency>
|
||||
- <groupId>org.slf4j</groupId>
|
||||
- <artifactId>com.springsource.slf4j.org.apache.commons.logging</artifactId>
|
||||
- <version>1.5.0</version>
|
||||
- <scope>test</scope>
|
||||
- </dependency>
|
||||
- <dependency>
|
||||
- <groupId>org.slf4j</groupId>
|
||||
- <artifactId>com.springsource.slf4j.api</artifactId>
|
||||
- <version>1.5.0</version>
|
||||
- <scope>test</scope>
|
||||
- </dependency>
|
||||
- <dependency>
|
||||
- <groupId>org.slf4j</groupId>
|
||||
- <artifactId>com.springsource.slf4j.log4j</artifactId>
|
||||
- <version>1.5.0</version>
|
||||
- <scope>test</scope>
|
||||
- <exclusions>
|
||||
- <exclusion>
|
||||
- <artifactId>log4j</artifactId>
|
||||
- <groupId>log4j</groupId>
|
||||
- </exclusion>
|
||||
- <exclusion>
|
||||
- <artifactId>com.springsource.org.apache.log4j</artifactId>
|
||||
- <groupId>org.apache.log4j</groupId>
|
||||
- </exclusion>
|
||||
- </exclusions>
|
||||
- </dependency>
|
||||
- <dependency>
|
||||
- <groupId>org.springframework.osgi</groupId>
|
||||
- <artifactId>log4j.osgi</artifactId>
|
||||
- <version>1.2.15-SNAPSHOT</version>
|
||||
- <scope>test</scope>
|
||||
- </dependency>
|
||||
-
|
||||
- <!-- And this is our Equinox implementation -->
|
||||
- <dependency>
|
||||
- <groupId>org.eclipse.osgi</groupId>
|
||||
- <artifactId>org.eclipse.osgi</artifactId>
|
||||
- <version>3.2.2</version>
|
||||
- <scope>test</scope>
|
||||
- </dependency>
|
||||
</dependencies>
|
||||
|
||||
<build>
|
||||
@@ -107,7 +43,7 @@
|
||||
<artifactId>maven-timestamp-plugin</artifactId>
|
||||
</plugin>
|
||||
<plugin>
|
||||
- <groupId>com.google.code.maven-license-plugin</groupId>
|
||||
+ <groupId>com.mycila.maven-license-plugin</groupId>
|
||||
<artifactId>maven-license-plugin</artifactId>
|
||||
</plugin>
|
||||
<plugin>
|
||||
215
objenesis.spec
Normal file
215
objenesis.spec
Normal file
@ -0,0 +1,215 @@
|
||||
# Copyright (c) 2000-2009, JPackage Project
|
||||
# All rights reserved.
|
||||
#
|
||||
# Redistribution and use in source and binary forms, with or without
|
||||
# modification, are permitted provided that the following conditions
|
||||
# are met:
|
||||
#
|
||||
# 1. Redistributions of source code must retain the above copyright
|
||||
# notice, this list of conditions and the following disclaimer.
|
||||
# 2. Redistributions in binary form must reproduce the above copyright
|
||||
# notice, this list of conditions and the following disclaimer in the
|
||||
# documentation and/or other materials provided with the
|
||||
# distribution.
|
||||
# 3. Neither the name of the JPackage Project nor the names of its
|
||||
# contributors may be used to endorse or promote products derived
|
||||
# from this software without specific prior written permission.
|
||||
#
|
||||
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
|
||||
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
|
||||
# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
|
||||
# A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
|
||||
# OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
|
||||
# LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
||||
# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
|
||||
# THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
|
||||
# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||
# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
#
|
||||
|
||||
Summary: A library for instantiating Java objects
|
||||
Name: objenesis
|
||||
Version: 1.2
|
||||
Release: 6%{dist}
|
||||
Group: Development/Libraries
|
||||
License: ASL 2.0
|
||||
URL: http://objenesis.googlecode.com/svn/docs/index.html
|
||||
# svn export http://objenesis.googlecode.com/svn/tags/1_2/ objenesis-1.2
|
||||
# tar cfJ objenesis-1.2.tar.xz objenesis-1.2
|
||||
Source0: %{name}-%{version}.tar.xz
|
||||
|
||||
# Skipping website (requires xsite), this patch is unused atm
|
||||
#Patch0: objenesis-website-pom.patch
|
||||
|
||||
# Remove deps for test scope (unavailable); fix
|
||||
# maven-license-plugin groupID to latest version available.
|
||||
Patch1: 001-objenesis-fix-build.patch
|
||||
|
||||
BuildRequires: jpackage-utils
|
||||
BuildRequires: java-devel
|
||||
BuildRequires: junit
|
||||
BuildRequires: maven
|
||||
BuildRequires: maven-antrun-plugin
|
||||
BuildRequires: maven-assembly-plugin
|
||||
BuildRequires: maven-compiler-plugin
|
||||
BuildRequires: maven-eclipse-plugin
|
||||
BuildRequires: maven-install-plugin
|
||||
BuildRequires: maven-jar-plugin
|
||||
BuildRequires: maven-javadoc-plugin
|
||||
BuildRequires: maven-resources-plugin
|
||||
BuildRequires: maven-site-plugin
|
||||
BuildRequires: maven-shade-plugin
|
||||
BuildRequires: maven-source-plugin
|
||||
BuildRequires: maven-surefire-plugin
|
||||
BuildRequires: maven-license-plugin
|
||||
BuildRequires: maven-timestamp-plugin
|
||||
BuildRequires: xpp3-minimal
|
||||
BuildRequires: asm2
|
||||
|
||||
Requires: java
|
||||
BuildRequires: jpackage-utils
|
||||
|
||||
Requires(post): jpackage-utils
|
||||
Requires(postun): jpackage-utils
|
||||
|
||||
BuildArch: noarch
|
||||
|
||||
%description
|
||||
Java supports dynamic instantiation of classes using Class.newInstance().
|
||||
However, this only works if the class has an appropriate constructor. There
|
||||
are many times when a class cannot be instantiated this way, such as when
|
||||
the class contains:
|
||||
* Constructors that require arguments.
|
||||
* Constructors that have side effects.
|
||||
* Constructors that throw exceptions.
|
||||
As a result, it is common to see restrictions in libraries stating that
|
||||
classes must require a default constructor. Objenesis aims to overcome these
|
||||
restrictions by bypassing the constructor on object instantiation.
|
||||
Needing to instantiate an object without calling the constructor is a fairly
|
||||
specialized task, however there are certain cases when this is useful:
|
||||
* Serialization, Remoting and Persistence - Objects need to be instantiated
|
||||
and restored to a specific state, without invoking code.
|
||||
* Proxies, AOP Libraries and Mock Objects - Classes can be subclassed without
|
||||
needing to worry about the super() constructor.
|
||||
* Container Frameworks - Objects can be dynamically instantiated in
|
||||
non-standard ways.
|
||||
|
||||
|
||||
%package javadoc
|
||||
Group: Documentation
|
||||
Summary: Javadoc for %{name}
|
||||
Requires: %{name} = %{version}-%{release}
|
||||
Requires: jpackage-utils
|
||||
BuildArch: noarch
|
||||
|
||||
%description javadoc
|
||||
This package contains the API documentation for %{name}.
|
||||
|
||||
|
||||
# Skipped till xsite avilable in fedora
|
||||
#%%package manual
|
||||
#Group: Documentation
|
||||
#Summary: Documents for %%{name}
|
||||
#
|
||||
#%%description manual
|
||||
#This package contains the %%{name} manual.
|
||||
|
||||
|
||||
%prep
|
||||
%setup -q
|
||||
#%%patch0 -b .sav0
|
||||
%patch1 -p1
|
||||
|
||||
|
||||
%build
|
||||
# tests are skipped because of missing dependency spring-osgi-test
|
||||
mvn-rpmbuild -e \
|
||||
-Dyear=2009 \
|
||||
-Dmaven.test.skip=true \
|
||||
install javadoc:javadoc
|
||||
|
||||
# Below is for manual (requires xsite), skipped
|
||||
#pushd website
|
||||
#mvn-jpp -e \
|
||||
# -s ${M2SETTINGS} \
|
||||
# -Dmaven.repo.local=$MAVEN_REPO_LOCAL \
|
||||
# -Dmaven2.jpp.depmap.file=%%{SOURCE1} \
|
||||
# antrun:run
|
||||
#popd
|
||||
|
||||
|
||||
%install
|
||||
rm -rf $RPM_BUILD_ROOT
|
||||
|
||||
# jars
|
||||
install -Dp -m 644 pom.xml $RPM_BUILD_ROOT%{_mavenpomdir}/JPP-%{name}-parent.pom
|
||||
%add_to_maven_depmap org.objenesis objenesis-parent %{version} JPP %{name}-parent
|
||||
|
||||
install -Dp -m 644 main/target/%{name}-%{version}.jar $RPM_BUILD_ROOT%{_javadir}/%{name}.jar
|
||||
install -Dp -m 644 main/pom.xml $RPM_BUILD_ROOT%{_mavenpomdir}/JPP-%{name}.pom
|
||||
%add_to_maven_depmap org.objenesis objenesis %{version} JPP %{name}
|
||||
|
||||
install -Dp -m 644 tck/target/%{name}-tck-%{version}.jar $RPM_BUILD_ROOT%{_javadir}/%{name}-tck.jar
|
||||
install -Dp -m 644 tck/pom.xml $RPM_BUILD_ROOT%{_mavenpomdir}/JPP-%{name}-tck.pom
|
||||
%add_to_maven_depmap org.objenesis objenesis-tck %{version} JPP %{name}-tck
|
||||
|
||||
# javadoc
|
||||
install -d -m 0755 $RPM_BUILD_ROOT%{_javadocdir}/%{name}/main
|
||||
cp -pr main/target/site/apidocs/* $RPM_BUILD_ROOT%{_javadocdir}/%{name}/main
|
||||
install -d -m 0755 $RPM_BUILD_ROOT%{_javadocdir}/%{name}/tck
|
||||
cp -pr tck/target/site/apidocs/* $RPM_BUILD_ROOT%{_javadocdir}/%{name}/tck
|
||||
|
||||
|
||||
%post
|
||||
%update_maven_depmap
|
||||
|
||||
%postun
|
||||
%update_maven_depmap
|
||||
|
||||
%files
|
||||
%defattr(-,root,root,-)
|
||||
%doc LICENSE.txt
|
||||
%{_javadir}/*.jar
|
||||
%{_mavenpomdir}/*
|
||||
%{_mavendepmapfragdir}/*
|
||||
|
||||
%files javadoc
|
||||
%defattr(-,root,root,-)
|
||||
%{_javadocdir}/%{name}
|
||||
|
||||
|
||||
%changelog
|
||||
* Thu Feb 24 2011 Guido Grazioli <guido.grazioli@gmail.com> 1.2-6
|
||||
- Build with mvn-rpmbuild
|
||||
- Fix License
|
||||
- Comment on skipped tests
|
||||
|
||||
* Fri Feb 04 2011 Guido Grazioli <guido.grazioli@gmail.com> 1.2-5
|
||||
- Build with maven 3
|
||||
|
||||
* Sun Jan 23 2011 Guido Grazioli <guido.grazioli@gmail.com> 1.2-4
|
||||
- Drop buildroot and %%clean section
|
||||
- Drop use of maven2-settings.xml and jpp-depmap.xml
|
||||
- Install unversioned jars
|
||||
- Clean up of needed patch and mvn-jpp execution
|
||||
|
||||
* Tue Jan 18 2011 Guido Grazioli <guido.grazioli@gmail.com> 1.2-3
|
||||
- Fix build in rawhide
|
||||
|
||||
* Sat Dec 04 2010 Guido Grazioli <guido.grazioli@gmail.com> 1.2-2
|
||||
- Fix build in rawhide
|
||||
- Update to new Java Packaging Guidelines
|
||||
|
||||
* Mon May 10 2010 Guido Grazioli <guido.grazioli@gmail.com> 1.2-1
|
||||
- Update to 1.2
|
||||
|
||||
* Thu May 06 2010 Guido Grazioli <guido.grazioli@gmail.com> 1.0-1
|
||||
- Import from JPackage
|
||||
|
||||
* Fri Feb 27 2009 Ralph Apel <r.apel at r-apel.de> 0:1.0-2.jpp5
|
||||
- BR xpp3-minimal and fix depmap accordingly
|
||||
- Disown poms and fragments dirs
|
||||
|
||||
* Wed Jun 18 2008 Ralph Apel <r.apel at r-apel.de> 0:1.0-1.jpp5
|
||||
- First release
|
||||
Loading…
Reference in New Issue
Block a user