Репозиторий Sisyphus
Последнее обновление: 1 октября 2023 | Пакетов: 18631 | Посещений: 37741937
en ru br
Репозитории ALT
S:2.3.31-alt1_4jpp11
5.1: 2.3.15-alt2_1jpp5
4.1: 2.3.6-alt1_2jpp1.7
4.0: 2.3.6-alt1_2jpp1.7
www.altlinux.org/Changes

Группа :: Базы Данных
Пакет: freemarker

 Главная   Изменения   Спек   Патчи   Sources   Загрузить   Gear   Bugs and FR  Repocop 

BuildRequires: javacc rhino
BuildRequires: /proc
BuildRequires: jpackage-1.4-compat
# 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.
#



Name: freemarker
Summary: FreeMarker template engine
Url: http://freemarker.sourceforge.net/
Version: 2.3.6
Release: alt1_2jpp1.7
Epoch: 0
License: BSD-style
Group: Databases
BuildArch: noarch
Source0: freemarker-2.3.6.tar.gz
Patch0: freemarker-2.3-jdom.patch

BuildRequires: jpackage-utils >= 0:1.6
BuildRequires: ant >= 0:1.6
BuildRequires: junit
BuildRequires: servletapi4
BuildRequires: jaxen >= 0:1.1
BuildRequires: jython
BuildRequires: excalibur-avalon-framework-api
BuildRequires: excalibur-avalon-framework-impl
BuildRequires: excalibur-avalon-logkit
BuildRequires: dom4j
BuildRequires: javacc3
BuildRequires: jdom
BuildRequires: log4j
BuildRequires: struts
BuildRequires: xerces-j2
BuildRequires: xalan-j2
Requires: excalibur-avalon-framework-api
Requires: excalibur-avalon-framework-impl
Requires: excalibur-avalon-logkit
Requires: servletapi4
Requires: jaxen >= 0:1.1
Requires: jython
Requires: jdom
Requires: dom4j
Requires: log4j
Requires: struts


%description
FreeMarker is a "template engine"; a generic tool to
generate text output (anything from HTML or RTF to
autogenerated source code) based on templates.
FreeMarker is designed to be practical for the generation
of HTML Web pages, particularly by servlet-based applications
following the MVC (Model View Controller) pattern.
Although FreeMarker has some programming capabilities,
it is not a full-blown programming language like PHP. Instead,
Java programs prepare the data to be displayed, and FreeMarker
just generates textual pages that display the prepared data
using templates.
FreeMarker is not a Web application framework. It is suitable
for a component in a Web application framework, but the
FreeMarker engine itself knows nothing about HTTP or servlets.


%package javadoc
Summary: Javadoc for %{name}
Group: Development/Documentation

%description javadoc
%{summary}.

%package manual
Summary: Documents for %{name}
Group: Development/Documentation

%description manual
%{summary}.

%prep
%setup -q -n %{name}-%{version}
chmod -R go=u-w *
find . -name "*.jar" -exec rm -f {} \;
cat << EOT > dependencies.properties
javacc.home=%{_javadir}
lib.jdom=$(build-classpath jdom)
lib.jaxen=$(build-classpath jaxen)
lib.servlet23=$(build-classpath servletapi4)
lib.servlet24=$(build-classpath servletapi5)
jython.home=%{_javadir}
lib.log4j=$(build-classpath log4j)
lib.logkit=$(build-classpath excalibur/avalon-logkit)
lib.xerces=$(build-classpath xerces-j2)
lib.junit=$(build-classpath junit)
lib.dom4j=$(build-classpath dom4j)
lib.rhino=$(build-classpath js)
lib.struts=$(build-classpath struts)
EOT

%patch0 -b .sav

# until 2.3.10 (bug reported upstream)

find ./src/freemarker/ext/ -type f -exec \
%__subst 's,.__class__.__name__,.__findattr__("__class__").__findattr__("__name__"),' \
{} \;

%build
export OPT_JAR_LIST="ant/ant-junit junit ant/ant-nodeps javacc3"
export CLASSPATH=$(build-classpath \
excalibur/avalon-framework-api \
excalibur/avalon-framework-impl \
excalibur/avalon-logkit \
dom4j \
javacc3 \
jaxen \
jdom \
jython \
log4j \
servletapi4 \
jspapi \
struts \
xalan-j2 \
xerces-j2 \
)
CLASSPATH=$CLASSPATH:target/classes
ant -Dbuild.sysclasspath=first jar javadoc examples test

%install
# jars
install -d -m 755 $RPM_BUILD_ROOT%{_javadir}

install -m 644 lib/%{name}.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/docs/api/* $RPM_BUILD_ROOT%{_javadocdir}/%{name}-%{version}
ln -s %{name}-%{version} $RPM_BUILD_ROOT%{_javadocdir}/%{name} # ghost symlink
rm -rf docs/docs/api

# manual

install -d -m 755 $RPM_BUILD_ROOT%{_docdir}/%{name}-%{version}
cp -pr docs/* $RPM_BUILD_ROOT%{_docdir}/%{name}-%{version}
cp -p LICENSE.txt $RPM_BUILD_ROOT%{_docdir}/%{name}-%{version}

%files
%{_javadir}/*.jar
%{_docdir}/%{name}-%{version}/LICENSE.txt

%files javadoc
%{_javadocdir}/%{name}-%{version}
%ghost %doc %{_javadocdir}/%{name}

%files manual
%{_docdir}/%{name}-%{version}

%changelog

Полный changelog можно просмотреть здесь

 
дизайн и разработка: Vladimir Lettiev aka crux © 2004-2005, Andrew Avramenko aka liks © 2007-2008
текущий майнтейнер: Michael Shigorin