2017-08-03 10:13:01 +02:00
|
|
|
#
|
2017-08-30 10:33:05 +02:00
|
|
|
# spec file for package tpm2.0-abrmd
|
2017-08-03 10:13:01 +02:00
|
|
|
#
|
2018-02-22 12:37:19 +01:00
|
|
|
# Copyright (c) 2018 SUSE LINUX GmbH, Nuernberg, Germany.
|
2017-08-03 10:13:01 +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/
|
|
|
|
#
|
|
|
|
|
|
|
|
|
|
|
|
Name: tpm2.0-abrmd
|
2018-06-29 16:14:44 +02:00
|
|
|
Version: 2.0.0
|
2017-08-03 10:13:01 +02:00
|
|
|
Release: 0
|
|
|
|
Summary: Intel's TCG Software Stack Access Broker & Resource Manager for TPM 2.0 chips
|
|
|
|
License: BSD-2-Clause
|
|
|
|
Group: Productivity/Security
|
|
|
|
Url: https://github.com/01org/tpm2-abrmd
|
2018-02-22 12:37:19 +01:00
|
|
|
Source0: https://github.com/01org/tpm2-abrmd/releases/download/1.2.0/tpm2-abrmd-%{version}.tar.gz
|
2017-08-03 10:13:01 +02:00
|
|
|
BuildRequires: autoconf-archive
|
|
|
|
BuildRequires: automake
|
|
|
|
BuildRequires: gcc-c++
|
|
|
|
BuildRequires: libtool
|
|
|
|
BuildRequires: pkg-config
|
2017-08-30 10:33:05 +02:00
|
|
|
BuildRequires: systemd-rpm-macros
|
2017-08-03 10:13:01 +02:00
|
|
|
BuildRequires: pkgconfig(dbus-1)
|
|
|
|
BuildRequires: pkgconfig(gio-unix-2.0)
|
2018-06-29 16:14:44 +02:00
|
|
|
BuildRequires: pkgconfig(tss2-sys)
|
2017-08-03 10:13:01 +02:00
|
|
|
Requires(pre): pwdutils
|
|
|
|
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
2018-07-02 11:29:58 +02:00
|
|
|
Patch0: fix_dlopen.patch
|
2017-08-03 10:13:01 +02:00
|
|
|
|
|
|
|
%description
|
|
|
|
The tpm2.0-abrmd package provides the TPM2 Access Broker & Resource Manager.
|
|
|
|
This is a daemon service that coordinates requests to the TPM2 chip via
|
|
|
|
Intel's TPM 2.0 software stack.
|
|
|
|
|
|
|
|
%package devel
|
|
|
|
Summary: Development headers the Access Broker & Resource Manager for TPM 2.0 chips
|
|
|
|
Group: Development/Libraries/C and C++
|
|
|
|
Requires: glibc-devel
|
2018-06-29 16:14:44 +02:00
|
|
|
Requires: libtss2-tcti-tabrmd0 = %{version}
|
2017-08-30 10:33:05 +02:00
|
|
|
Requires: tpm2.0-abrmd = %{version}
|
2017-08-03 10:13:01 +02:00
|
|
|
|
|
|
|
%description devel
|
|
|
|
This package provides the development files for the Access Broker & Resource
|
|
|
|
Manager for coordinating access to TPM 2.0 chips.
|
|
|
|
|
2018-06-29 16:14:44 +02:00
|
|
|
%package -n libtss2-tcti-tabrmd0
|
2017-08-30 10:33:05 +02:00
|
|
|
Summary: Client interface library for tpm2-abrmd
|
|
|
|
Group: System/Libraries
|
2017-08-03 10:13:01 +02:00
|
|
|
|
2018-06-29 16:14:44 +02:00
|
|
|
%description -n libtss2-tcti-tabrmd0
|
2017-08-03 10:13:01 +02:00
|
|
|
This library allows to interact with the tpm2-abrmd daemon. It is intended for
|
2018-06-29 16:14:44 +02:00
|
|
|
use with the SAPI library (libtss2-sys) like any other TCTI.
|
2017-08-03 10:13:01 +02:00
|
|
|
|
2018-06-29 16:14:44 +02:00
|
|
|
%post -n libtss2-tcti-tabrmd0 -p /sbin/ldconfig
|
|
|
|
%postun -n libtss2-tcti-tabrmd0 -p /sbin/ldconfig
|
2017-08-03 10:13:01 +02:00
|
|
|
|
|
|
|
%prep
|
|
|
|
%setup -q -n tpm2-abrmd-%{version}
|
2018-07-02 11:29:58 +02:00
|
|
|
%patch0 -p1
|
2017-08-03 10:13:01 +02:00
|
|
|
|
|
|
|
%build
|
|
|
|
export CFLAGS="%optflags -fPIE"
|
|
|
|
export LDFLAGS="-pie -fPIE"
|
2018-06-29 16:14:44 +02:00
|
|
|
%configure --disable-static --with-systemdsystemunitdir=%{_unitdir}
|
2017-08-03 10:13:01 +02:00
|
|
|
make %{?_smp_mflags} PTHREAD_LDFLAGS=-pthread
|
|
|
|
|
|
|
|
# TODO: add the tss user again
|
|
|
|
%install
|
|
|
|
%make_install
|
|
|
|
# don't package libtool files as is best practice
|
|
|
|
find %{buildroot} -type f -name "*.la" -delete -print
|
|
|
|
ln -sv %{_sbindir}/service %{buildroot}%{_sbindir}/rctpm2-abrmd
|
2017-08-30 10:33:05 +02:00
|
|
|
# don't install the systemd preset, our presets are handled by
|
|
|
|
# systemd-presets-* packages
|
2017-08-30 10:45:40 +02:00
|
|
|
rm %{buildroot}/usr/lib*/systemd/system-preset/tpm2-abrmd.preset
|
2017-08-03 10:13:01 +02:00
|
|
|
|
|
|
|
%pre
|
|
|
|
%service_add_pre tpm2-abrmd.service
|
|
|
|
|
|
|
|
%post
|
|
|
|
%service_add_post tpm2-abrmd.service
|
|
|
|
|
|
|
|
%postun
|
|
|
|
%service_del_postun tpm2-abrmd.service
|
|
|
|
|
|
|
|
%preun
|
|
|
|
%service_del_preun tpm2-abrmd.service
|
|
|
|
|
|
|
|
%files
|
|
|
|
%defattr(-,root,root)
|
|
|
|
%doc *.md LICENSE
|
2018-06-29 16:14:44 +02:00
|
|
|
%{_mandir}/man7/tss2-*
|
2017-08-03 10:13:01 +02:00
|
|
|
%{_mandir}/man8/tpm2-*
|
|
|
|
%{_sbindir}/tpm2-abrmd
|
|
|
|
%{_sbindir}/rctpm2-abrmd
|
|
|
|
%{_unitdir}/tpm2-abrmd.service
|
2018-07-03 11:59:56 +02:00
|
|
|
%if 0%{?sle_version} > 120200 || 0%{?is_opensuse}
|
|
|
|
# the auto activation is not whitelisted for <= SLE12-SP3
|
2017-08-03 10:13:01 +02:00
|
|
|
%config %{_sysconfdir}/dbus-1/system.d/tpm2-abrmd.conf
|
2018-06-29 16:14:44 +02:00
|
|
|
%{_datadir}/dbus-1/system-services/com.intel.tss2.Tabrmd.service
|
2018-07-03 11:59:56 +02:00
|
|
|
%endif
|
2017-08-03 10:13:01 +02:00
|
|
|
|
|
|
|
%files devel
|
|
|
|
%defattr(-,root,root)
|
2018-06-29 16:14:44 +02:00
|
|
|
%{_includedir}/tss2
|
2017-08-03 10:13:01 +02:00
|
|
|
%{_libdir}/*.so
|
|
|
|
%{_libdir}/pkgconfig/*.pc
|
2018-06-29 16:14:44 +02:00
|
|
|
%{_mandir}/man3/Tss2*
|
2017-08-03 10:13:01 +02:00
|
|
|
|
2018-06-29 16:14:44 +02:00
|
|
|
%files -n libtss2-tcti-tabrmd0
|
2017-08-03 10:13:01 +02:00
|
|
|
%defattr(-,root,root)
|
2018-06-29 16:14:44 +02:00
|
|
|
%{_libdir}/libtss2-tcti-tabrmd.so.*
|
2017-08-03 10:13:01 +02:00
|
|
|
|
|
|
|
%changelog
|