File libtpms.spec of Package libtpms (Revision f879851c12753ffc94905d0c47cbfc0b)
Currently displaying revision f879851c12753ffc94905d0c47cbfc0b , Show latest
101
1
#
2
# spec file for package libtpms
3
#
4
# Copyright (c) 2021 SUSE LLC
5
#
6
# All modifications and additions to the file contributed by third parties
7
# remain the property of their copyright owners, unless otherwise agreed
8
# upon. The license for this file, and modifications and additions to the
9
# file, is the same license as for the pristine package itself (unless the
10
# license for the pristine package is not an Open Source License, in which
11
# case the license is the MIT License). An "Open Source License" is a
12
# license that conforms to the Open Source Definition (Version 1.9)
13
# published by the Open Source Initiative.
14
15
# Please submit bugfixes or comments via https://bugs.opensuse.org/
16
#
17
18
19
%define lname libtpms0
20
Name: libtpms
21
Version: 0.8.2
22
Release: 0
23
Summary: Library providing Trusted Platform Module (TPM) functionality
24
License: BSD-3-Clause
25
Group: Development/Libraries/C and C++
26
URL: https://github.com/stefanberger/libtpms
27
Source0: https://github.com/stefanberger/libtpms/archive/v%{version}.tar.gz
28
# CVE-2021-3746 [bsc#1189935], out-of-bounds access via specially crafted TPM 2 command packets
29
Patch0: libtpms-CVE-2021-3746.patch
30
BuildRequires: autoconf
31
BuildRequires: automake
32
BuildRequires: gcc-c++
33
BuildRequires: libtool
34
BuildRequires: mozilla-nspr-devel
35
BuildRequires: openssl-devel
36
BuildRequires: pkgconfig
37
38
%description
39
A library providing TPM functionality for VMs. Targeted for integration
40
into Qemu.
41
42
%package -n %{lname}
43
Summary: Library providing Trusted Platform Module (TPM) functionality
44
Group: Development/Libraries/C and C++
45
46
%description -n %{lname}
47
A library providing TPM functionality for VMs. Targeted for integration
48
into Qemu.
49
50
%package devel
51
Summary: Include files for libtpms
52
Group: Development/Libraries/C and C++
53
Requires: %{lname} = %{version}
54
Requires: libopenssl-devel
55
Requires: mozilla-nspr-devel
56
57
%description devel
58
Libtpms header files and documentation.
59
60
%prep
61
%setup -q -n libtpms-%{version}
62
%patch0 -p1
63
64
%build
65
./bootstrap.sh
66
%configure \
67
--with-tpm2 \
68
--with-openssl \
69
--disable-static
70
71
make %{?_smp_mflags}
72
73
%check
74
make %{?_smp_mflags} check
75
76
%install
77
install -d -m 0755 %{buildroot}%{_libdir}
78
install -d -m 0755 %{buildroot}%{_includedir}/libtpms
79
install -d -m 0755 %{buildroot}%{_mandir}/man3
80
81
%make_install
82
83
%post -n %{lname} -p /sbin/ldconfig
84
%postun -n %{lname} -p /sbin/ldconfig
85
86
%files -n %{lname}
87
%doc README CHANGES
88
%license LICENSE
89
%{_libdir}/%{name}.so.%{version}
90
%{_libdir}/%{name}.so.0
91
92
%files devel
93
%{_libdir}/%{name}.so
94
%{_libdir}/%{name}.la
95
%dir %{_includedir}/%{name}
96
%attr(644, root, root) %{_libdir}/pkgconfig/*.pc
97
%attr(644, root, root) %{_includedir}/%{name}/*.h
98
%attr(644, root, root) %{_mandir}/man3/*
99
100
%changelog
101