Sisyphus repository
Last update: 1 october 2023 | SRPMs: 18631 | Visits: 37566879
en ru br
ALT Linux repos
5.0: 1.3.0-alt1_2jpp5
4.1: 1.3.0-alt1_1jpp1.7
4.0: 1.3.0-alt1_1jpp1.7

Group :: Development/Java
RPM: xml-security

 Main   Changelog   Spec   Patches   Sources   Download   Gear   Bugs and FR  Repocop 

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.
#

%define name xml-security
%define version 1.3.0
%define release 1jpp

Name: %{name}
Version: %{version}
Release: alt1_1jpp1.7
Epoch: 0
Summary: Implementation of W3C security standards for XML
License: Apache Software License 2.0
Url: http://xml.apache.org/security
Group: Development/Java
Source0: xml-security-1.3-src.tar.gz
# cvs -d :pserver:anoncvs at cvs.apache.org:/home/cvspublic login
# cvs -d :pserver:anoncvs at cvs.apache.org:/home/cvspublic export -r J_1_3 xml-security
Patch0: xml-security-build_xml.patch
Patch1: xml-security-1.3-nosun.patch
BuildRequires: ant
##BuildRequires: java-devel >= 0:1.4
#BuildRequires: bouncycastle
BuildRequires: jakarta-commons-logging
BuildRequires: log4j
BuildRequires: xalan-j2 >= 0:2.7
BuildRequires: xml-commons-apis >= 0:1.3
BuildRequires: xerces-j2 >= 0:2.7
#Requires: bouncycastle
Requires: jakarta-commons-logging
Requires: log4j
Requires: xalan-j2 >= 0:2.7
Requires: xml-commons-apis >= 0:1.3
Requires: xerces-j2 >= 0:2.7
BuildArch: noarch

%description
The XML Security project is aimed at providing implementation
of security standards for XML. Currently the focus is on the
W3C standards :
- XML-Signature Syntax and Processing; and
- XML Encryption Syntax and Processing.
Once these are implemented, XML Key Management is likely to
be the next focus for the project.
Two libraries are currently available.
A Java library, which includes a mature Digital Signature
implementation. Encryption is currently under development.
A C++ library is also now available. Functionality is
currently more basic than that provided by the Java library.

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

%description javadoc
Javadoc for %{name}.

%package demo
Summary: Samples for %{name}
Group: Development/Documentation

%description demo
Samples for %{name}.

%prep
%setup -q -n %{name}
# remove all binary libs
for f in $(find . -name "*.jar"); do
 rm $f
done

%patch0 -b .sav
%patch1 -b .sav

%build
mkdir -p libs/endorsed
build-jar-repository -p -s libs \
commons-logging \
commons-logging-api \
log4j \
xalan-j2 \
xalan-j2-serializer \
xml-commons-apis \
xerces-j2 \
junit \

ant -Djava.endorsed.dirs=libs \
   -Dlib.jce=`build-classpath . gcj-endorsed/gnu-crypto-jce-jdk1.4` \
build.src build.jar build.docs test

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

install -m 644 build/xmlsec-%{version}.jar \
$RPM_BUILD_ROOT%{_javadir}/%{name}-%{version}.jar
# create unversioned symlinks
(cd $RPM_BUILD_ROOT%{_javadir}
for jar in *-%{version}*; do ln -sf ${jar} ${jar/-%{version}/}; done
)

install -d -m 755 $RPM_BUILD_ROOT%{_javadocdir}/%{name}-%{version}
cp -pr build/docs/html/javadoc/* $RPM_BUILD_ROOT%{_javadocdir}/%{name}-%{version}
ln -s %{name}-%{version} $RPM_BUILD_ROOT%{_javadocdir}/%{name} # ghost symlink

install -d -m 755 $RPM_BUILD_ROOT%{_docdir}/%{name}-%{version}
cp -p LICENSE $RPM_BUILD_ROOT%{_docdir}/%{name}-%{version}

install -d -m 755 $RPM_BUILD_ROOT%{_datadir}/%{name}-%{version}
cp -pr src_samples/* $RPM_BUILD_ROOT%{_datadir}/%{name}-%{version}

%post javadoc
rm -f %{_javadocdir}/%{name}
ln -s %{name}-%{version} %{_javadocdir}/%{name}

%postun javadoc
if [ "$1" = "0" ]; then
   rm -f %{_javadocdir}/%{name}
fi

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

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

%files demo
%{_datadir}/%{name}-%{version}

%changelog

Full changelog you can see here

 
design & coding: Vladimir Lettiev aka crux © 2004-2005, Andrew Avramenko aka liks © 2007-2008
current maintainer: Michael Shigorin