414 lines
13 KiB
RPMSpec
414 lines
13 KiB
RPMSpec
# Copyright (c) 2000-2005, 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.
|
||
#
|
||
|
||
%define _with_gcj_support 1
|
||
|
||
%define gcj_support %{?_with_gcj_support:1}%{!?_with_gcj_support:%{?_without_gcj_support:0}%{!?_without_gcj_support:%{?_gcj_support:%{_gcj_support}}%{!?_gcj_support:0}}}
|
||
|
||
%define section free
|
||
|
||
|
||
Name: velocity
|
||
Version: 1.4
|
||
Release: 8.3%{?dist}
|
||
Epoch: 0
|
||
Summary: Java-based template engine
|
||
License: ASL 2.0
|
||
Source: velocity-1.4-RHCLEAN.tar.bz2
|
||
Patch0: velocity-AnakiaJDOMFactory-jdom-DefaultJDOMFactory.patch
|
||
Patch1: velocity-AnakiaTask-jdom-XMLOutputter.patch
|
||
Patch2: velocity-servletapi5.patch
|
||
#Disable failure-on-tests rather than not running tests.
|
||
Patch3: velocity-build-testcases.patch
|
||
#Patch3: velocity-notexentests.patch
|
||
URL: http://jakarta.apache.org/velocity/
|
||
Group: Development/Libraries/Java
|
||
Requires: jakarta-commons-collections
|
||
# Use servletapi5 instead of servletapi3
|
||
Requires: servletapi5
|
||
Requires: oro
|
||
Requires: werken.xpath
|
||
Requires: jdom >= 0:1.0-1
|
||
Requires: bcel
|
||
Requires: log4j >= 0:1.1
|
||
#FIXME replace with excalibur-avalon-logkit when available
|
||
Requires: avalon-logkit
|
||
BuildRequires: werken.xpath
|
||
BuildRequires: ant
|
||
BuildRequires: antlr
|
||
BuildRequires: junit
|
||
BuildRequires: jakarta-commons-collections
|
||
# Use servletapi5 instead of servletapi3
|
||
BuildRequires: servletapi5
|
||
BuildRequires: oro
|
||
BuildRequires: jdom >= 0:1.0-1
|
||
BuildRequires: bcel
|
||
BuildRequires: log4j >= 0:1.1
|
||
#FIXME replace with excalibur-avalon-logkit when available
|
||
BuildRequires: avalon-logkit
|
||
BuildRequires: jpackage-utils >= 0:1.6
|
||
%if ! %{gcj_support}
|
||
BuildArch: noarch
|
||
%endif
|
||
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-buildroot
|
||
|
||
%if %{gcj_support}
|
||
BuildRequires: java-gcj-compat-devel
|
||
Requires(post): java-gcj-compat
|
||
Requires(postun): java-gcj-compat
|
||
%endif
|
||
|
||
%description
|
||
Velocity is a Java-based template engine. It permits anyone to use the
|
||
simple yet powerful template language to reference objects defined in
|
||
Java code.
|
||
When Velocity is used for web development, Web designers can work in
|
||
parallel with Java programmers to develop web sites according to the
|
||
Model-View-Controller (MVC) model, meaning that web page designers can
|
||
focus solely on creating a site that looks good, and programmers can
|
||
focus solely on writing top-notch code. Velocity separates Java code
|
||
from the web pages, making the web site more maintainable over the long
|
||
run and providing a viable alternative to Java Server Pages (JSPs) or
|
||
PHP.
|
||
Velocity's capabilities reach well beyond the realm of web sites; for
|
||
example, it can generate SQL and PostScript and XML (see Anakia for more
|
||
information on XML transformations) from templates. It can be used
|
||
either as a standalone utility for generating source code and reports,
|
||
or as an integrated component of other systems. Velocity also provides
|
||
template services for the Turbine web application framework.
|
||
Velocity+Turbine provides a template service that will allow web
|
||
applications to be developed according to a true MVC model.
|
||
|
||
%package manual
|
||
Summary: Manual for %{name}
|
||
Group: Development/Libraries/Java
|
||
|
||
%description manual
|
||
Documentation for %{name}.
|
||
|
||
%package javadoc
|
||
Summary: Javadoc for %{name}
|
||
Group: Development/Documentation
|
||
# for /bin/rm and /bin/ln
|
||
Requires(post): coreutils
|
||
Requires(postun): coreutils
|
||
|
||
%description javadoc
|
||
Javadoc for %{name}.
|
||
|
||
%package demo
|
||
Summary: Demo for %{name}
|
||
Group: Development/Libraries/Java
|
||
Requires: %{name} = %{epoch}:%{version}-%{release}
|
||
|
||
%if %{gcj_support}
|
||
BuildRequires: java-gcj-compat-devel
|
||
Requires(post): java-gcj-compat
|
||
Requires(postun): java-gcj-compat
|
||
%endif
|
||
|
||
%description demo
|
||
Demonstrations and samples for %{name}.
|
||
|
||
# -----------------------------------------------------------------------------
|
||
|
||
%prep
|
||
%setup -q -n %{name}-%{version}
|
||
# Remove all binary libs used in compiling the package.
|
||
# Note that velocity has some jar files containing macros under
|
||
# examples and test that should not be removed.
|
||
find build -name '*.jar' -exec rm -f \{\} \;
|
||
|
||
%patch0 -b .sav
|
||
%patch1 -b .sav
|
||
#Apply patch to remove explicit dependency on servletapi3
|
||
%patch2 -p1
|
||
%patch3 -p1
|
||
# -----------------------------------------------------------------------------
|
||
|
||
%build
|
||
# Use servletapi5 instead of servletapi3 in CLASSPATH
|
||
#FIXME Replace avalon-logkit with excalibur-avalon-logkit when ready
|
||
export CLASSPATH=$(build-classpath \
|
||
antlr \
|
||
jakarta-commons-collections \
|
||
servletapi5 \
|
||
avalon-logkit \
|
||
junit \
|
||
oro \
|
||
log4j \
|
||
jdom \
|
||
bcel \
|
||
werken.xpath)
|
||
ant \
|
||
-buildfile build/build.xml \
|
||
-Djunit.jar=%{_javadir}/junit.jar \
|
||
-Dbuild.sysclasspath=first \
|
||
jar javadocs test
|
||
|
||
# -----------------------------------------------------------------------------
|
||
|
||
%install
|
||
rm -rf $RPM_BUILD_ROOT
|
||
|
||
# jars
|
||
install -d -m 755 $RPM_BUILD_ROOT%{_javadir}
|
||
install -p -m 644 bin/%{name}-%{version}.jar $RPM_BUILD_ROOT%{_javadir}/%{name}-%{version}.jar
|
||
(cd $RPM_BUILD_ROOT%{_javadir} && for jar in *-%{version}*; do ln -sf ${jar} `echo $jar| sed "s|-%{version}||g"`; done)
|
||
|
||
# javadoc
|
||
install -d -m 755 $RPM_BUILD_ROOT%{_javadocdir}/%{name}-%{version}
|
||
cp -pr docs/api/* $RPM_BUILD_ROOT%{_javadocdir}/%{name}-%{version}
|
||
rm -rf docs/api
|
||
|
||
# data
|
||
install -d -m 755 $RPM_BUILD_ROOT%{_datadir}/%{name}
|
||
cp -pr convert examples test $RPM_BUILD_ROOT%{_datadir}/%{name}
|
||
|
||
# -----------------------------------------------------------------------------
|
||
|
||
%if %{gcj_support}
|
||
%{_bindir}/aot-compile-rpm
|
||
%endif
|
||
|
||
%clean
|
||
rm -rf $RPM_BUILD_ROOT
|
||
|
||
# -----------------------------------------------------------------------------
|
||
|
||
%post javadoc
|
||
rm -f %{_javadocdir}/%{name}
|
||
ln -s %{name}-%{version} %{_javadocdir}/%{name}
|
||
|
||
%postun javadoc
|
||
if [ "$1" = "0" ]; then
|
||
rm -f %{_javadocdir}/%{name}
|
||
fi
|
||
|
||
# -----------------------------------------------------------------------------
|
||
|
||
%post
|
||
%if %{gcj_support}
|
||
if [ -x %{_bindir}/rebuild-gcj-db ]
|
||
then
|
||
%{_bindir}/rebuild-gcj-db
|
||
fi
|
||
%endif
|
||
|
||
%postun
|
||
%if %{gcj_support}
|
||
if [ -x %{_bindir}/rebuild-gcj-db ]
|
||
then
|
||
%{_bindir}/rebuild-gcj-db
|
||
fi
|
||
%endif
|
||
|
||
%post demo
|
||
%if %{gcj_support}
|
||
if [ -x %{_bindir}/rebuild-gcj-db ]
|
||
then
|
||
%{_bindir}/rebuild-gcj-db
|
||
fi
|
||
%endif
|
||
|
||
%postun demo
|
||
%if %{gcj_support}
|
||
if [ -x %{_bindir}/rebuild-gcj-db ]
|
||
then
|
||
%{_bindir}/rebuild-gcj-db
|
||
fi
|
||
%endif
|
||
|
||
%files
|
||
%defattr(0644,root,root,0755)
|
||
%doc LICENSE NOTICE README.txt
|
||
%{_javadir}/*.jar
|
||
|
||
%if %{gcj_support}
|
||
%attr(-,root,root) %{_libdir}/gcj/%{name}/velocity-1.4.jar.*
|
||
%attr(-,root,root) %{_libdir}/gcj/%{name}/classloader.*
|
||
%endif
|
||
|
||
%files manual
|
||
%defattr(0644,root,root,0755)
|
||
%doc docs/*
|
||
|
||
%files javadoc
|
||
%defattr(0644,root,root,0755)
|
||
%{_javadocdir}/%{name}-%{version}
|
||
|
||
%files demo
|
||
%defattr(0644,root,root,0755)
|
||
%{_datadir}/%{name}
|
||
|
||
# -----------------------------------------------------------------------------
|
||
|
||
#FIXME: Generated by spec-convert-gcj-* script. These cant be natively compiled
|
||
#since they only contain *.vm files. Check if these are ignored in subsequent versions
|
||
#of spec-convert-gcj-* script.
|
||
#%if %{gcj_support}
|
||
#%attr(-,root,root) %{_libdir}/gcj/%{name}/template.jar.*
|
||
#%attr(-,root,root) %{_libdir}/gcj/%{name}/test1.jar.*
|
||
#%attr(-,root,root) %{_libdir}/gcj/%{name}/test2.jar.*
|
||
#%attr(-,root,root) %{_libdir}/gcj/%{name}/test1.jar.*
|
||
#%attr(-,root,root) %{_libdir}/gcj/%{name}/test2.jar.*
|
||
#%attr(-,root,root) %{_libdir}/gcj/%{name}/test.jar.*
|
||
#%endif
|
||
|
||
%changelog
|
||
* Wed Feb 25 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0:1.4-8.3
|
||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild
|
||
|
||
* Thu Jul 10 2008 Tom "spot" Callaway <tcallawa@redhat.com> - 0:1.4-7.3
|
||
- drop repotag
|
||
|
||
* Thu May 29 2008 Tom "spot" Callaway <tcallawa@redhat.com> - 0:1.4-7jpp.2
|
||
- fix license tag
|
||
|
||
* Tue Feb 19 2008 Fedora Release Engineering <rel-eng@fedoraproject.org> - 0:1.4-7jpp.1
|
||
- Autorebuild for GCC 4.3
|
||
|
||
* Tue Aug 08 2006 Vivek Lakshmanan <vivekl@redhat.com> - 0:1.4-6jpp.1
|
||
- Resync with latest from JPP.
|
||
- Partially adopt new naming convention.
|
||
|
||
* Sat Jul 22 2006 Vivek Lakshmanan <vivekl@redhat.com> - 0:1.4-5jpp_2fc
|
||
- Rebuilt
|
||
|
||
* Sat Jul 22 2006 Vivek Lakshmanan <vivekl@redhat.com> - 0:1.4-5jpp_1fc
|
||
- Merge with latest from JPP.
|
||
- Remove fileversion and my_version macros.
|
||
- Remove notexentests patch and replace with a patch to disable
|
||
- failure on tests.
|
||
|
||
* Sat Jul 22 2006 Jakub Jelinek <jakub@redhat.com> - 0:1.4-3jpp_8fc
|
||
- Rebuilt
|
||
|
||
* Tue Jul 18 2006 Deepak Bhole <dbhole@redhat.com> - 0:1.4-3jpp_7fc
|
||
- Build on all archs.
|
||
|
||
* Wed Jul 12 2006 Jesse Keating <jkeating@redhat.com> - 0:1.4-3jpp_6fc
|
||
- rebuild
|
||
|
||
* Wed Mar 8 2006 Rafael Schloming <rafaels@redhat.com> - 0:1.4-3jpp_5fc
|
||
- excluded s390[x] and ppc64 due to eclipse
|
||
|
||
* Mon Mar 6 2006 Jeremy Katz <katzj@redhat.com> - 0:1.4-3jpp_4fc
|
||
- stop scriptlet spew
|
||
|
||
* Wed Dec 21 2005 Jesse Keating <jkeating@redhat.com> - 0:1.4-3jpp_3fc
|
||
- rebuilt again
|
||
|
||
* Fri Dec 09 2005 Jesse Keating <jkeating@redhat.com> - 0:1.4-3jpp_2fc
|
||
- rebuilt
|
||
|
||
* Tue Nov 8 2005 Vadim Nasardinov <vadimn@redhat.com> - 0:1.4-3jpp_1fc
|
||
- Converted from ISO-8859-1 to UTF-8
|
||
|
||
* Wed Jun 15 2005 Gary Benson <gbenson@redhat.com> 0:1.4-3jpp_1fc
|
||
- Build into Fedora.
|
||
|
||
* Thu Jun 9 2005 Gary Benson <gbenson@redhat.com>
|
||
- Remove jarfiles from the tarball.
|
||
|
||
* Mon Jun 6 2005 Gary Benson <gbenson@redhat.com>
|
||
- Build with servletapi5.
|
||
- Add NOTICE file as per Apache License version 2.0.
|
||
- Skip some failing tests.
|
||
|
||
* Mon Oct 18 2004 Fernando Nasser <fnasser@redhat.com> 0:1.4-3jpp_1rh
|
||
- First Red Hat build
|
||
|
||
* Thu Sep 23 2004 Ralph Apel <r.apel at r-apel.de> 0:1.4-3jpp
|
||
- Adapt to jdom-1.0-1 replacing org.jdom.input.DefaultJDOMFactory
|
||
by org.jdom.DefaultJDOMFactory in AnakiaJDOMFactory.java
|
||
as well as using org.jdom.output.Format in AnakiaTask.java
|
||
- Therefore require jdom >= 0:1.0-1
|
||
|
||
* Thu Sep 02 2004 Ralph Apel <r.apel at r-apel.de> 0:1.4-2jpp
|
||
- Build with ant-1.6.2
|
||
|
||
* Mon Jun 07 2004 Kaj J. Niemi <kajtzu@fi.basen.net> 0:1.4-1jpp
|
||
- 1.4 final
|
||
- Patch #0 is unnecessary (upstream)
|
||
- We have to build velocity against servletapi3
|
||
|
||
* Wed Feb 18 2004 Kaj J. Niemi <kajtzu@fi.basen.net> 0:1.4-0.rc1.2jpp
|
||
- Fix a few jpackage related .spec typos, oops.
|
||
|
||
* Wed Feb 18 2004 Kaj J. Niemi <kajtzu@fi.basen.net> 0:1.4-0.rc1.1jpp
|
||
- Added Patch #0 (velocity-1.4-rc1-ServletTest.patch) from CVS which fixes
|
||
build problems.
|
||
|
||
* Sun May 25 2003 Ville Skytt<74> <ville.skytta at iki.fi> - 0:1.3.1-2jpp
|
||
- Add Epochs to dependencies.
|
||
- Add explicit defattrs.
|
||
- Add non-versioned javadoc symlinks.
|
||
- Use sed instead of bash 2 extension when symlinking jars during build.
|
||
- Use full URL in Source.
|
||
- Fix -javadoc Group tag.
|
||
- Drop patch in favour of ant options.
|
||
- BuildRequire jpackage-utils and antlr (latter needed for Anakia tests).
|
||
|
||
* Sat May 24 2003 Richard Bullington-McGuire <rbulling@pkrinternet.com> 1.3.1-1jpp
|
||
- 1.3.1 stable release
|
||
|
||
* Fri May 23 2003 Richard Bullington-McGuire <rbulling@pkrinternet.com> 1.3-1jpp
|
||
- 1.3 stable release
|
||
- Updated for JPackage 1.5
|
||
- Run JUnit regression tests as part of the build process
|
||
- Added patch file to fix test case classpath for JUnit standard locations
|
||
|
||
* Mon May 06 2002 Guillaume Rousse <guillomovitch@users.sourceforge.net> 1.3-0.rc1.1jpp
|
||
- 1.3.0rc1
|
||
- dropped patch
|
||
- versioned dir for javadoc
|
||
- no dependencies for manual and javadoc packages
|
||
- stricter dependency for demo package
|
||
|
||
* Wed Dec 12 2001 Guillaume Rousse <guillomovitch@users.sourceforge.net> 1.2-1jpp
|
||
- 1.2
|
||
- regenerated patch and corrected manifest
|
||
- requires and buildrequires jdom >= 1.0-0.b7.1
|
||
|
||
* Wed Dec 5 2001 Guillaume Rousse <guillomovitch@users.sourceforge.net> 1.1-4jpp
|
||
- javadoc into javadoc package
|
||
|
||
* Wed Nov 21 2001 Christian Zoffoli <czoffoli@littlepenguin.org> 1.1-3jpp
|
||
- removed packager tag
|
||
- new jpp extension
|
||
|
||
* Thu Nov 1 2001 Guillaume Rousse <guillomovitch@users.sourceforge.net> 1.1-2jpp
|
||
- first unified release
|
||
- s/jPackage/JPackage
|
||
|
||
* Fri Sep 14 2001 Guillaume Rousse <guillomovitch@users.sourceforge.net> 1.1-1jpp
|
||
- first Mandrake release
|