File libxmlsec1.spec of Package libxmlsec1

#
# spec file for package libxmlsec1
#
# Copyright (c) 2015 SUSE LINUX 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/
#


%define soname 1
Name:           libxmlsec1
Version:        1.2.20
Release:        0
Summary:        Library providing support for "XML Signature" and "XML Encryption" standards
License:        MIT
Group:          Development/Libraries/C and C++
Url:            http://www.aleksey.com/xmlsec
Source:         http://www.aleksey.com/xmlsec/download/xmlsec1-%{version}.tar.gz
BuildRequires:  libltdl-devel
BuildRequires:  libxml2-devel >= 2.6.12
BuildRequires:  libxslt-devel >= 1.0.20
BuildRequires:  pkg-config
Requires:       libxml2 >= 2.6.12
Requires:       libxslt >= 1.0.20
BuildRoot:      %{_tmppath}/%{name}-%{version}-build

%description
XML Security Library is a C library based on LibXML2  and OpenSSL.
The library was created with a goal to support major XML security
standards "XML Digital Signature" and "XML Encryption".

%package -n %{name}-%{soname}
Summary:        Library providing support for "XML Signature" and "XML Encryption" standards
Group:          System/Libraries

%description -n %{name}-%{soname}
XML Security Library is a C library based on LibXML2  and OpenSSL.
The library was created with a goal to support major XML security
standards "XML Digital Signature" and "XML Encryption".

%package devel
Summary:        Development files for %{name}
Group:          Development/Languages/C and C++
Requires:       %{name}-%{soname} = %{version}
Requires:	libxml2-devel >= 2.6.12
Requires:	libxslt-devel >= 1.0.20
Requires:       zlib-devel

%description devel
Libraries, includes, etc. you can use to develop applications with XML Digital
Signatures and XML Encryption support.

#%%package openssl%{soname}
#Summary:        OpenSSL crypto plugin for XML Security Library
#Group:          System/Libraries
#Requires:       %{name}-%{soname} = %{version}, libxml2 >= 2.6.12, libxslt >= 1.0.20, openssl >= 0.9.6
#BuildRequires:  openssl-devel >= 0.9.6

#%%description openssl%{soname}
#OpenSSL plugin for XML Security Library provides OpenSSL based crypto services
#for the xmlsec library

#%%package openssl-devel
#Summary:        OpenSSL crypto plugin for XML Security Library
#Group:          Development/Languages/C and C++
#Requires:       %{name}-%{soname} = %{version}, %{name}-devel = %{version}, %{name}-openssl = %{version}, libxml2-devel >= 2.6.12, libxslt-devel >= 1.0.20
#Requires:       openssl >= 0.9.6, openssl-devel >= 0.9.6

#%%description openssl-devel
#Libraries, includes, etc. for developing XML Security applications with OpenSSL

#%package nss%{soname}
#Summary:        NSS crypto plugin for XML Security Library
#Group:          System/Libraries
#Requires:       %{name} = %{version}, libxml2 >= 2.6.12, libxslt >= 1.0.20, mozilla-nss >= 1.4
#BuildRequires:  mozilla-nss-devel >= 1.4

#%description nss%{soname}
#NSS plugin for XML Security Library provides NSS based crypto services
#for the xmlsec library

#%package nss-devel
#Summary:        NSS crypto plugin for XML Security Library
#Group:          Development/Languages/C and C++
#Requires:       %{name} = %{version}, %{name}-devel = %{version}, %{name}-nss = %{version}, libxml2-devel >= 2.6.12, libxslt-devel >= 1.0.20, mozilla-nss-devel >= 1.4

#%description nss-devel
#Libraries, includes, etc. for developing XML Security applications with NSS

%prep
%setup -q -n xmlsec1-%{version}

%build
%configure --with-html-dir=%{_docdir}/xmlsec1 --disable-static
make %{?_smp_mflags}

%install
%make_install

%post -n %{name}-%{soname} -p /sbin/ldconfig

%postun -n %{name}-%{soname} -p /sbin/ldconfig

#%%post openssl%{soname} -p /sbin/ldconfig

#%%postun openssl%{soname} -p /sbin/ldconfig

%files -n %{name}-%{soname}
%defattr(-,root,root)
%doc AUTHORS ChangeLog NEWS README Copyright COPYING HACKING
%doc %{_mandir}/man1/xmlsec1.1*

%{_libdir}/%{name}*.so.*
%{_bindir}/xmlsec1

%files devel
%defattr(-,root,root)
%{_bindir}/xmlsec1-config
%dir %{_includedir}/xmlsec1
%dir %{_includedir}/xmlsec1/xmlsec
%{_includedir}/xmlsec1/xmlsec/*.h
%dir %{_includedir}/xmlsec1/xmlsec/gcrypt
%{_includedir}/xmlsec1/xmlsec/gcrypt/*.h
%dir %{_includedir}/xmlsec1/xmlsec/private
%{_includedir}/xmlsec1/xmlsec/private/*.h
%{_libdir}/%{name}*.*a
%{_libdir}/%{name}*.so
%{_libdir}/pkgconfig/xmlsec1*.pc
%{_libdir}/xmlsec1Conf.sh
%{_datadir}/aclocal/xmlsec1.m4
%doc %{_docdir}/xmlsec1
%doc %{_mandir}/man1/xmlsec1-config.1*

#%%files openssl%{soname}
#%%defattr(-,root,root)
#%%{_libdir}/%{name}-openssl.so.*

#%%files openssl-devel
#%%defattr(-,root,root)
#%%%dir %{_includedir}/xmlsec1/xmlsec/openssl
#%%{_includedir}/xmlsec1/xmlsec/openssl/*.h
#%%{_libdir}/%{name}-openssl.*a
#%%{_libdir}/%{name}-openssl.so
#%%{_libdir}/pkgconfig/xmlsec1-openssl.pc

#%files nss
#%defattr(-,root,root)
#%{prefix}/lib/libxmlsec1-nss.so.*
#%{prefix}/lib/libxmlsec1-nss.so

#%files nss-devel
#%defattr(-,root,root)
#%{_includedir}/%{name}/xmlsec/nss/*.h
#%{prefix}/lib/libxmlsec1-nss.*a
#%{prefix}/lib/pkgconfig/xmlsec1-nss.pc

%changelog
openSUSE Build Service is sponsored by