File tls.spec of Package tls

#
# spec file for package tls (Version 1.6)
#
# Copyright (c) 2009 SUSE LINUX Products GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.

# Please submit bugfixes or comments via http://bugs.opensuse.org/
#

# norootforbuild


Name:           tls
BuildRequires:  openssl openssl-devel tcl-devel
Summary:        Tcl Binding for the OpenSSL Library
Version:        1.6
Release:        43
License:        BSD 3-clause (or similar)
Group:          Development/Libraries/Tcl
Url:            http://tls.sourceforge.net
Source0:        %name%version-src.tar.bz2
Patch1:         tls-ciphers.patch
BuildRoot:      %{_tmppath}/%{name}-%{version}-build

%description
This extension provides a generic binding for Tcl to OpenSSL, utilizing
the new Tcl_StackChannel API for Tcl 8.2 and higher. The sockets behave
exactly the same as channels created using Tcl's built-in socket
command with additional options for controlling the SSL session.



Authors:
--------
    Matt Newman <matt@novadigm.com>
    Jeff Hobbs <jeff@hobbs.org>

%prep
%setup -q -n %name%version
%patch1

%build
CFLAGS="$RPM_OPT_FLAGS" \
./configure \
	--libdir=%_libdir \
	--prefix=/usr \
	--with-ssl-dir=/usr \
	--with-tcl=%_libdir
make

%check
cat > known-failures <<EOF
tlsIO-12.3
EOF
make test 2>&1 | tee testresults
grep FAILED testresults | grep -Fqvf known-failures && exit 1

%install
make install \
	DESTDIR=%buildroot \
	PKG_HEADERS= \
	libdir=%_libdir/tcl

%clean
rm -rf %buildroot

%files
%defattr(-,root,root,-)
%doc ChangeLog README.txt license.terms tls.htm
%_libdir/tcl

%changelog