66cd316
66cd316
%global base_name       configuration
66cd316
%global short_name      commons-%{base_name}
66cd316
66cd316
Name:           apache-%{short_name}
e9c57c8
Version:        1.8
ff23bab
Release:        2%{?dist}
66cd316
Summary:        Commons Configuration Package
66cd316
66cd316
Group:          Development/Libraries
66cd316
License:        ASL 2.0
66cd316
URL:            http://commons.apache.org/%{base_name}/
fd0eb1b
Source0:        http://archive.apache.org/dist/commons/%{base_name}/source/%{short_name}-%{version}-src.tar.gz
66cd316
BuildArch:      noarch
66cd316
66cd316
BuildRequires:  java-devel
fd0eb1b
BuildRequires:  jpackage-utils
fd0eb1b
BuildRequires:  maven
cef07ae
BuildRequires:  maven-antrun-plugin
cef07ae
BuildRequires:  maven-assembly-plugin
cef07ae
BuildRequires:  maven-compiler-plugin
fd0eb1b
BuildRequires:  maven-doxia-sitetools
cef07ae
BuildRequires:  maven-idea-plugin
cef07ae
BuildRequires:  maven-install-plugin
cef07ae
BuildRequires:  maven-jar-plugin
fd0eb1b
BuildRequires:  javacc-maven-plugin
cef07ae
BuildRequires:  maven-javadoc-plugin
fd0eb1b
BuildRequires:  maven-plugin-bundle
cef07ae
BuildRequires:  maven-resources-plugin
fd0eb1b
BuildRequires:  maven-surefire-plugin
fd0eb1b
BuildRequires:  maven-surefire-provider-junit
66cd316
fd0eb1b
BuildRequires:  apache-commons-beanutils
66cd316
BuildRequires:  apache-commons-codec
Stanislav Ochotnicky 7c98f70
BuildRequires:  apache-commons-collections
Stanislav Ochotnicky 7c98f70
BuildRequires:  apache-commons-digester
fd0eb1b
BuildRequires:  apache-commons-jexl
Stanislav Ochotnicky 7c98f70
BuildRequires:  apache-commons-jxpath
fd0eb1b
BuildRequires:  apache-commons-lang
fd0eb1b
BuildRequires:  apache-commons-logging
fd0eb1b
BuildRequires:  apache-commons-vfs
cef07ae
BuildRequires:  tomcat-servlet-3.0-api
fd0eb1b
BuildRequires:  xml-commons-resolver
66cd316
fd0eb1b
Requires:       java
fd0eb1b
Requires:       jpackage-utils
fd0eb1b
Requires:       apache-commons-beanutils
fd0eb1b
Requires:       apache-commons-codec
fd0eb1b
Requires:       apache-commons-collections
fd0eb1b
Requires:       apache-commons-digester
fd0eb1b
Requires:       apache-commons-jexl
fd0eb1b
Requires:       apache-commons-jxpath
fd0eb1b
Requires:       apache-commons-lang
fd0eb1b
Requires:       apache-commons-logging
fd0eb1b
Requires:       apache-commons-vfs
fd0eb1b
Requires:       tomcat-servlet-3.0-api
fd0eb1b
Requires:       xml-commons-resolver
66cd316
66cd316
Provides:       jakarta-%{short_name} = 0:%{version}-%{release}
66cd316
Obsoletes:      jakarta-%{short_name} < 0:%{version}-%{release}
66cd316
e9c57c8
66cd316
%description
66cd316
Configuration is a project to provide a generic Configuration
66cd316
interface and allow the source of the values to vary. It
66cd316
provides easy typed access to single, as well as lists of
66cd316
configuration values based on a 'key'.
66cd316
Right now you can load properties from a simple properties
66cd316
file, a properties file in a jar, an XML file, JNDI settings,
66cd316
as well as use a mix of different sources using a
66cd316
ConfigurationFactory and CompositeConfiguration.
66cd316
Custom configuration objects are very easy to create now
66cd316
by just subclassing AbstractConfiguration. This works
66cd316
similar to how AbstractList works.
66cd316
66cd316
%package        javadoc
66cd316
Summary:        API documentation for %{name}
66cd316
Group:          Documentation
66cd316
Requires:       jpackage-utils
66cd316
66cd316
Provides:       jakarta-%{short_name}-javadoc = 0:%{version}-%{release}
66cd316
Obsoletes:      jakarta-%{short_name}-javadoc < 0:%{version}-%{release}
66cd316
66cd316
%description    javadoc
66cd316
%{summary}.
66cd316
66cd316
66cd316
%prep
66cd316
%setup -q -n %{short_name}-%{version}-src
40784f2
%{__sed} -i 's/\r//' LICENSE.txt NOTICE.txt
66cd316
66cd316
%build
fd0eb1b
# We skip tests because we don't have test deps (dbunit in particular).
fd0eb1b
mvn-rpmbuild -Dmaven.test.skip=true install javadoc:javadoc
66cd316
66cd316
%install
66cd316
# jars
66cd316
install -d -m 755 $RPM_BUILD_ROOT%{_javadir}
Stanislav Ochotnicky e173b25
install -p -m 644 target/%{short_name}-%{version}.jar $RPM_BUILD_ROOT%{_javadir}/%{name}.jar
Stanislav Ochotnicky e173b25
ln -sf %{name}.jar $RPM_BUILD_ROOT%{_javadir}/%{short_name}.jar
66cd316
66cd316
66cd316
# javadoc
Stanislav Ochotnicky e173b25
install -d -m 755 $RPM_BUILD_ROOT%{_javadocdir}/%{name}
Stanislav Ochotnicky e173b25
cp -pr target/site/apidocs/* $RPM_BUILD_ROOT%{_javadocdir}/%{name}
66cd316
66cd316
# Install pom
66cd316
install -d -m 755 $RPM_BUILD_ROOT%{_mavenpomdir}
66cd316
install -pm 644 pom.xml $RPM_BUILD_ROOT/%{_mavenpomdir}/JPP-%{short_name}.pom
66cd316
%add_to_maven_depmap org.apache.commons %{short_name} %{version} JPP %{short_name}
66cd316
66cd316
# following line is only for backwards compatibility. New packages
66cd316
# should use proper groupid org.apache.commons and also artifactid
66cd316
%add_to_maven_depmap %{short_name} %{short_name} %{version} JPP %{short_name}
66cd316
66cd316
%files
66cd316
%{_mavendepmapfragdir}/*
66cd316
%{_mavenpomdir}/JPP-%{short_name}.pom
40784f2
%doc LICENSE.txt NOTICE.txt
66cd316
%{_javadir}/*.jar
66cd316
66cd316
%files javadoc
40784f2
%doc LICENSE.txt NOTICE.txt
66cd316
%doc %{_javadocdir}/%{name}
66cd316
66cd316
66cd316
%changelog
ff23bab
* Wed Jul 18 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.8-2
ff23bab
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
ff23bab
e9c57c8
* Tue Jun 19 2012 Mikolaj Izdebski <mizdebsk@redhat.com> - 1.8-1
e9c57c8
- Update to upstream 1.8
40784f2
- Install NOTICE.txt file
e9c57c8
cef07ae
* Wed Apr 18 2012 Alexander Kurtakov <akurtako@redhat.com> 1.6-7
cef07ae
- Update to current guidelines.
cef07ae
- Move to servlet 3.
cef07ae
f137614
* Thu Jan 12 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.6-6
f137614
- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild
f137614
Stanislav Ochotnicky e173b25
* Tue Feb 15 2011 Stanislav Ochotnicky <sochotnicky@redhat.com> - 1.6-5
Stanislav Ochotnicky e173b25
- Change ant dep groupId to org.apache.ant to fix build
Stanislav Ochotnicky e173b25
- Versionless jar & javadocs
Stanislav Ochotnicky e173b25
- Use maven 3 to build
Stanislav Ochotnicky e173b25
3aa8a11
* Mon Feb 07 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.6-4
3aa8a11
- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild
3aa8a11
Stanislav Ochotnicky 7c98f70
* Thu Oct 14 2010 Stanislav Ochotnicky <sochotnicky@redhat.com> - 1.6-3
Stanislav Ochotnicky 7c98f70
- tomcat5 -> tomcat6 BRs/Rs
Stanislav Ochotnicky 7c98f70
- jakarta -> apache BRs/Rs
Stanislav Ochotnicky 7c98f70
cd707a2
* Thu Jul  8 2010 Stanislav Ochotnicky <sochotnicky@redhat.com> - 1.6-2
cd707a2
- Add license to javadoc subpackage
cd707a2
66cd316
* Thu May 27 2010 Stanislav Ochotnicky <sochotnicky@redhat.com> - 1.6-1
66cd316
- Rename package (jakarta-commons-configuration->apache-commons-configuration)
66cd316
- Build with maven instead of ant, drop deprecated patches
66cd316
- Rebase, cleanups, drop epoch
66cd316
66cd316
* Thu Aug 20 2009 Alexander Kurtakov <akurtako@redhat.com> 0:1.4-7
66cd316
- Fix description.
66cd316
- Remove requires(post/postun) for javadoc subpackage.
66cd316
- Use sed instead of dos2unix.
66cd316
66cd316
* Thu Aug 20 2009 Alexander Kurtakov <akurtako@redhat.com> 0:1.4-6
66cd316
- Remove gcj support.
66cd316
- Initial build for Fedora.
66cd316
66cd316
* Mon May 18 2009 Fernando Nasser <fnasser@redhat.com> - 0:1.4-5
66cd316
- Fix license
66cd316
- Fix source URL
66cd316
66cd316
* Wed Mar 18 2009 Yong Yang <yyang@redhat.com> - 0:1.4-4
66cd316
- rebuild with new maven2 2.0.8 built in bootstrap mode
66cd316
66cd316
* Thu Feb 05 2009 Yong Yang <yyang@redhat.com> - 0:1.4-3
66cd316
- Fix release tag
66cd316
66cd316
* Wed Jan 14 2009 Yong Yang <yyang@redhat.com> - 0:1.4-2jpp
66cd316
- Import from dbhole's maven 2.0.8 packages, initial building
66cd316
66cd316
* Mon Aug 13 2007 Ralph Apel <r.apel at r-apel.de> - 0:1.4-1jpp
66cd316
- Upgrade to 1.4
66cd316
- Add pom file
66cd316
66cd316
* Thu May 03 2007 Ralph Apel <r.apel at r-apel.de> - 0:1.2-3jpp
66cd316
- Patch one test
66cd316
66cd316
* Wed Mar 07 2007 Ralph Apel <r.apel at r-apel.de> - 0:1.2-2jpp
66cd316
- Add gcj_support option
66cd316
- Optionally build without maven
66cd316
66cd316
* Mon Feb 20 2006 Ralph Apel <r.apel at r-apel.de> - 0:1.2-1jpp
66cd316
- Upgrade to 1.2
66cd316
66cd316
* Mon Feb 20 2006 Ralph Apel <r.apel at r-apel.de> - 0:1.1-2jpp
66cd316
- Rebuild for JPP-1.7 and maven-1.1
66cd316
66cd316
* Thu Sep 15 2005 Ralph Apel <r.apel at r-apel.de> - 0:1.1-1jpp
66cd316
- Upgrade to 1.1
66cd316
- Omit findbugs and tasks reports: don't have these plugins yet
66cd316
- Requires java 1.4.2 to build
66cd316
66cd316
* Mon Feb 21 2005 Ralph Apel <r.apel at r-apel.de> - 0:1.0.f-1jpp
66cd316
- Upgrade to 1.0 final, letter in version can be bumped with 1.1
66cd316
- Prepare for build with maven, but still build with ant
66cd316
66cd316
* Sun Aug 23 2004 Randy Watler <rwatler at finali.com> - 0:1.0.d3-2jpp
66cd316
- Rebuild with ant-1.6.2
66cd316
- Upgrade to Ant 1.6.X
66cd316
* Mon Jan 19 2004 Ralph Apel <r.apel at r-apel.de> - 0:1.0.d3-1jpp
66cd316
- First JPackage release