opensc/opensc.spec
Stanislav Brabec 13de599d03 Accepting request 441453 from home:sbrabec:branches:security:chipcard
- Add baselibs.conf to provide 32-bit PKCS11 plugins (bsc#996047).
- Drop opensc-ADVISORIES. There is no new advisory since 2009.

OBS-URL: https://build.opensuse.org/request/show/441453
OBS-URL: https://build.opensuse.org/package/show/security:chipcard/opensc?expand=0&rev=41
2016-11-24 15:11:00 +00:00

107 lines
3.4 KiB
RPMSpec

#
# spec file for package opensc
#
# Copyright (c) 2016 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/
#
Name: opensc
Version: 0.16.0
Release: 0
Summary: Smart Card Utilities
License: LGPL-2.1+
Group: Productivity/Security
Url: https://github.com/OpenSC/OpenSC/wiki
Source: %{name}-%{version}.tar.gz
Source1: baselibs.conf
Source2: %{name}-rpmlintrc
# Register with p11-kit
# https://www.opensc-project.org/opensc/ticket/390
Source3: opensc.module
BuildRequires: docbook-xsl-stylesheets
BuildRequires: libtool
BuildRequires: libxslt
BuildRequires: openssl-devel
BuildRequires: pcsc-lite-devel
BuildRequires: pkg-config
BuildRequires: readline-devel
Requires: pcsc-lite
# There is no more devel package.
Obsoletes: opensc-devel < %{version}
BuildRoot: %{_tmppath}/%{name}-%{version}-build
%description
OpenSC provides a set of utilities to access smart cards. It mainly
focuses on cards that support cryptographic operations. It facilitates
their use in security applications such as mail encryption,
authentication, and digital signature. OpenSC implements the PKCS#11
API. Applications supporting this API, such as Mozilla Firefox and
Thunderbird, can use it. OpenSC implements the PKCS#15 standard and aims
to be compatible with every software that does so, too.
Before purchasing any cards, please read carefully documentation on the
web pageonly some cards are supported. Not only card type matters, but
also card version, card OS version and preloaded applet. Only subset of
possible operations may be supported for your card. Card initialization
may require third party proprietary software.
%prep
%setup -q
%build
%if 0%{?suse_version} > 1100
autoreconf -f -i
%endif
%configure\
--docdir=%{_docdir}/%{name}\
--disable-static\
--enable-doc
make %{?_smp_mflags}
%install
mkdir -p %{buildroot}%{_sysconfdir}
mkdir -p %{buildroot}%{_libdir}/pkcs11
make %{?_smp_mflags} DESTDIR=%{buildroot} install
cp COPYING NEWS README %{buildroot}%{_docdir}/%{name}
# Private library.
rm %{buildroot}%{_libdir}/libopensc.so
install -D -m 644 %{SOURCE3} %{buildroot}%{_sysconfdir}/pkcs11/modules/opensc.module
%post -p /sbin/ldconfig
%postun -p /sbin/ldconfig
%files
%defattr(-,root,root)
%doc %dir %{_docdir}/%{name}
%doc %{_docdir}/%{name}/COPYING
%doc %{_docdir}/%{name}/NEWS
%doc %{_docdir}/%{name}/README
%doc %{_docdir}/%{name}/tools.html
%{_bindir}/*
%{_datadir}/opensc
# Note: .la and .so must be in the main package, required by ltdl:
%{_libdir}/*.la
%{_libdir}/*.so*
%dir %{_libdir}/pkcs11
%{_libdir}/pkcs11/*.so
%{_mandir}/man?/*.*
%config %{_sysconfdir}/opensc.conf
%dir %{_sysconfdir}/pkcs11
%config %{_sysconfdir}/pkcs11/modules/
%{_sysconfdir}/bash_completion.d/*
# This is a private library. There is no reason to split it to libopensc* package.
%{_libdir}/libopensc.so.*
%changelog