2011-08-04 11:25:42 +02:00
|
|
|
#
|
|
|
|
# spec file for package p11-kit
|
|
|
|
#
|
2018-03-20 15:50:58 +01:00
|
|
|
# Copyright (c) 2018 SUSE LINUX GmbH, Nuernberg, Germany.
|
2011-08-04 11:25:42 +02:00
|
|
|
#
|
|
|
|
# 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/
|
|
|
|
#
|
|
|
|
|
2012-02-16 16:20:41 +01:00
|
|
|
|
2016-02-09 08:21:01 +01:00
|
|
|
%define pkidir_cfg %{_sysconfdir}/pki
|
|
|
|
%define pkidir_static %{_datadir}/pki
|
2013-06-25 09:36:47 +02:00
|
|
|
%define trustdir_cfg %{pkidir_cfg}/trust
|
|
|
|
%define trustdir_static %{pkidir_static}/trust
|
|
|
|
|
2011-08-04 11:25:42 +02:00
|
|
|
Name: p11-kit
|
2016-02-09 08:21:01 +01:00
|
|
|
Version: 0.23.2
|
2012-01-06 11:46:18 +01:00
|
|
|
Release: 0
|
2011-08-04 11:25:42 +02:00
|
|
|
Summary: Library to work with PKCS#11 modules
|
2012-01-06 11:46:18 +01:00
|
|
|
License: BSD-3-Clause
|
2011-08-04 11:25:42 +02:00
|
|
|
Group: Development/Libraries/C and C++
|
|
|
|
Url: http://p11-glue.freedesktop.org/p11-kit.html
|
|
|
|
Source0: http://p11-glue.freedesktop.org/releases/%{name}-%{version}.tar.gz
|
2014-02-11 13:53:20 +01:00
|
|
|
Source1: http://p11-glue.freedesktop.org/releases/%{name}-%{version}.tar.gz.sig
|
2014-09-01 13:07:03 +02:00
|
|
|
Source98: p11-kit.keyring
|
2011-08-04 11:25:42 +02:00
|
|
|
Source99: baselibs.conf
|
2016-11-28 15:40:00 +01:00
|
|
|
Patch: p11-kit-biarch.patch
|
2015-03-18 17:41:54 +01:00
|
|
|
BuildRequires: gtk-doc
|
2011-08-04 11:25:42 +02:00
|
|
|
BuildRequires: pkg-config
|
2013-06-25 09:36:47 +02:00
|
|
|
BuildRequires: pkgconfig(libffi) >= 3.0.0
|
2013-05-16 11:19:13 +02:00
|
|
|
BuildRequires: pkgconfig(libtasn1) >= 2.3
|
2016-11-28 15:40:00 +01:00
|
|
|
# autotools are needed for p11-kit-biarch.patch
|
|
|
|
BuildRequires: autoconf
|
|
|
|
BuildRequires: automake
|
|
|
|
BuildRequires: libtool
|
2011-08-04 11:25:42 +02:00
|
|
|
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
|
|
|
|
|
|
|
%description
|
|
|
|
p11-kit provides a way to load and enumerate PKCS#11 modules, as well
|
|
|
|
as a standard configuration setup for installing PKCS#11 modules in
|
|
|
|
such a way that they're discoverable.
|
|
|
|
|
|
|
|
%package -n libp11-kit0
|
|
|
|
Summary: Library to work with PKCS#11 modules
|
|
|
|
Group: System/Libraries
|
|
|
|
|
|
|
|
%description -n libp11-kit0
|
|
|
|
p11-kit provides a way to load and enumerate PKCS#11 modules, as well
|
|
|
|
as a standard configuration setup for installing PKCS#11 modules in
|
|
|
|
such a way that they're discoverable.
|
|
|
|
|
|
|
|
%package tools
|
|
|
|
Summary: Library to work with PKCS#11 modules -- Tools
|
|
|
|
Group: Development/Libraries/C and C++
|
|
|
|
|
|
|
|
%description tools
|
|
|
|
p11-kit provides a way to load and enumerate PKCS#11 modules, as well
|
|
|
|
as a standard configuration setup for installing PKCS#11 modules in
|
|
|
|
such a way that they're discoverable.
|
|
|
|
|
|
|
|
%package devel
|
|
|
|
Summary: Library to work with PKCS#11 modules -- Development Files
|
|
|
|
Group: Development/Libraries/C and C++
|
|
|
|
Requires: libp11-kit0 = %{version}
|
|
|
|
|
|
|
|
%description devel
|
|
|
|
p11-kit provides a way to load and enumerate PKCS#11 modules, as well
|
|
|
|
as a standard configuration setup for installing PKCS#11 modules in
|
|
|
|
such a way that they're discoverable.
|
|
|
|
|
2013-07-03 11:21:14 +02:00
|
|
|
%package nss-trust
|
|
|
|
Summary: Adaptor to make NSS read the p11-kit trust store
|
|
|
|
Group: Productivity/Networking/Security
|
|
|
|
Requires: p11-kit = %{version}
|
|
|
|
Conflicts: mozilla-nss-certs
|
|
|
|
%if %{_lib} == lib64
|
|
|
|
Provides: libnssckbi.so()(64bit)
|
|
|
|
%else
|
2013-07-05 10:22:30 +02:00
|
|
|
Provides: libnssckbi.so
|
2013-07-03 11:21:14 +02:00
|
|
|
%endif
|
|
|
|
|
|
|
|
%description nss-trust
|
|
|
|
Adaptor library to make NSS read the p11-kit trust store. It has
|
|
|
|
to be installed intead of mozilla-nss-certs.
|
|
|
|
|
2011-08-04 11:25:42 +02:00
|
|
|
%prep
|
2016-02-09 08:21:01 +01:00
|
|
|
%setup -q
|
2016-11-28 15:40:00 +01:00
|
|
|
%patch -p1
|
2011-08-04 11:25:42 +02:00
|
|
|
|
|
|
|
%build
|
2016-11-28 15:40:00 +01:00
|
|
|
# autoreconf needed for p11-kit-biarch.patch
|
|
|
|
autoreconf -f -i
|
2015-03-18 17:41:54 +01:00
|
|
|
%configure --with-trust-paths=%{trustdir_cfg}:%{trustdir_static}
|
2016-02-09 08:21:01 +01:00
|
|
|
make %{?_smp_mflags} V=1
|
2011-08-04 11:25:42 +02:00
|
|
|
|
|
|
|
%install
|
|
|
|
%make_install
|
2013-06-25 09:36:47 +02:00
|
|
|
#
|
|
|
|
install -d m 755 %{buildroot}%{trustdir_cfg}/{anchors,blacklist}
|
|
|
|
install -d m 755 %{buildroot}%{trustdir_static}/{anchors,blacklist}
|
2011-08-04 11:25:42 +02:00
|
|
|
# Create pkcs11 config directory
|
|
|
|
test ! -e %{buildroot}%{_sysconfdir}/pkcs11/modules
|
|
|
|
install -d %{buildroot}%{_sysconfdir}/pkcs11/modules
|
2011-09-09 11:49:49 +02:00
|
|
|
# Remove sample config away to doc folder. Having the sample there would conflict
|
|
|
|
# with future versions of the library on file level. As replacement, we package
|
|
|
|
# the file as documentation file.
|
|
|
|
rm %{buildroot}%{_sysconfdir}/pkcs11/pkcs11.conf.example
|
2016-02-09 08:21:01 +01:00
|
|
|
find %{buildroot} -type f -name "*.la" -delete -print
|
2013-06-25 09:36:47 +02:00
|
|
|
#
|
2016-02-09 08:21:01 +01:00
|
|
|
install -d -m 755 %{buildroot}%{_sysconfdir}/rpm/
|
|
|
|
cat <<'FIN' >%{buildroot}%{_sysconfdir}/rpm/macros.%{name}
|
|
|
|
# Macros from p11-kit package
|
2013-06-25 09:36:47 +02:00
|
|
|
%%pkidir_cfg %{pkidir_cfg}
|
|
|
|
%%pkidir_static %{pkidir_static}
|
|
|
|
%%trustdir_cfg %{trustdir_cfg}
|
|
|
|
%%trustdir_static %{trustdir_static}
|
|
|
|
FIN
|
2013-07-03 11:21:14 +02:00
|
|
|
#
|
2013-07-05 10:22:30 +02:00
|
|
|
# nss compat lib
|
2013-07-03 11:21:14 +02:00
|
|
|
ln -s %{_libdir}/pkcs11/p11-kit-trust.so %{buildroot}%{_libdir}/libnssckbi.so
|
2013-07-05 10:22:30 +02:00
|
|
|
#
|
|
|
|
# call update-ca-certificates when trust changes
|
2016-11-28 15:40:00 +01:00
|
|
|
rm %{buildroot}%{_libexecdir}/%{name}/trust-extract-compat
|
|
|
|
ln -s ../../sbin/update-ca-certificates %{buildroot}%{_libexecdir}/%{name}/p11-kit-extract-trust
|
2013-07-05 10:22:30 +02:00
|
|
|
export NO_BRP_STALE_LINK_ERROR=yes # *grr*
|
2011-08-04 11:25:42 +02:00
|
|
|
|
2016-02-09 08:21:01 +01:00
|
|
|
%check
|
|
|
|
make %{?_smp_mflags} check
|
|
|
|
|
2011-08-04 11:25:42 +02:00
|
|
|
%post -n libp11-kit0 -p /sbin/ldconfig
|
|
|
|
|
|
|
|
%postun -n libp11-kit0 -p /sbin/ldconfig
|
|
|
|
|
2013-04-02 12:33:56 +02:00
|
|
|
%files
|
|
|
|
%defattr(-,root,root)
|
|
|
|
%dir %{_libdir}/pkcs11
|
|
|
|
%dir %{_datadir}/%{name}
|
|
|
|
%dir %{_datadir}/%{name}/modules
|
2013-06-25 09:36:47 +02:00
|
|
|
%dir %{pkidir_cfg}
|
|
|
|
%dir %{trustdir_cfg}
|
|
|
|
%dir %{trustdir_cfg}/anchors
|
|
|
|
%dir %{trustdir_cfg}/blacklist
|
|
|
|
%dir %{pkidir_static}
|
|
|
|
%dir %{trustdir_static}
|
|
|
|
%dir %{trustdir_static}/anchors
|
|
|
|
%dir %{trustdir_static}/blacklist
|
2013-04-02 12:33:56 +02:00
|
|
|
%{_datadir}/%{name}/modules/p11-kit-trust.module
|
2013-04-26 15:53:05 +02:00
|
|
|
%{_libdir}/pkcs11/p11-kit-trust.so
|
2016-11-28 15:40:00 +01:00
|
|
|
%dir %{_libexecdir}/%{name}
|
|
|
|
%{_libexecdir}/%{name}/p11-kit-remote
|
|
|
|
%{_libexecdir}/%{name}/p11-kit-extract-trust
|
2013-04-02 12:33:56 +02:00
|
|
|
|
2011-08-04 11:25:42 +02:00
|
|
|
%files -n libp11-kit0
|
|
|
|
%defattr(-,root,root)
|
2018-03-20 15:50:58 +01:00
|
|
|
%license COPYING
|
2011-09-09 11:49:49 +02:00
|
|
|
# Package the example conf file as documentation. Like this we're sure that we will
|
|
|
|
# not introduce conflicts with this version of the library and future ones.
|
|
|
|
%doc p11-kit/pkcs11.conf.example
|
2018-03-20 15:50:58 +01:00
|
|
|
%doc AUTHORS ChangeLog NEWS README
|
2011-09-09 11:49:49 +02:00
|
|
|
%dir %{_sysconfdir}/pkcs11
|
2011-08-04 11:25:42 +02:00
|
|
|
%dir %{_sysconfdir}/pkcs11/modules/
|
|
|
|
%{_libdir}/libp11-kit.so.*
|
|
|
|
%{_libdir}/p11-kit-proxy.so
|
|
|
|
|
|
|
|
%files tools
|
|
|
|
%defattr(-,root,root)
|
|
|
|
%{_bindir}/p11-kit
|
2013-08-23 11:46:13 +02:00
|
|
|
%{_bindir}/trust
|
2011-08-04 11:25:42 +02:00
|
|
|
|
|
|
|
%files devel
|
|
|
|
%defattr(-,root,root)
|
2016-02-09 08:21:01 +01:00
|
|
|
%config %{_sysconfdir}/rpm/macros.%{name}
|
2011-08-04 11:25:42 +02:00
|
|
|
%{_includedir}/p11-kit-1/
|
|
|
|
%{_libdir}/libp11-kit.so
|
|
|
|
%{_libdir}/pkgconfig/p11-kit-1.pc
|
|
|
|
%doc %dir %{_datadir}/gtk-doc
|
|
|
|
%doc %dir %{_datadir}/gtk-doc/html
|
|
|
|
%doc %{_datadir}/gtk-doc/html/p11-kit/
|
|
|
|
|
2013-07-03 11:21:14 +02:00
|
|
|
%files nss-trust
|
2013-09-10 11:57:28 +02:00
|
|
|
%defattr(-,root,root)
|
2013-07-03 11:21:14 +02:00
|
|
|
%{_libdir}/libnssckbi.so
|
|
|
|
|
2011-08-04 11:25:42 +02:00
|
|
|
%changelog
|