[packages/tpm_emulator] - fix building with linux 4.7 - rel 15
baggins
baggins at pld-linux.org
Mon Aug 1 22:22:28 CEST 2016
commit 6e1dd8e8c8c8e9820a1e605b22cc1c813ad283b4
Author: Jan Rękorajski <baggins at pld-linux.org>
Date: Mon Aug 1 22:22:11 2016 +0200
- fix building with linux 4.7
- rel 15
linux-4.7.patch | 14 ++++++++++++++
tpm_emulator.spec | 4 +++-
2 files changed, 17 insertions(+), 1 deletion(-)
---
diff --git a/tpm_emulator.spec b/tpm_emulator.spec
index e136c40..0e18a42 100644
--- a/tpm_emulator.spec
+++ b/tpm_emulator.spec
@@ -21,7 +21,7 @@ exit 1
%define _duplicate_files_terminate_build 0
%define pname tpm_emulator
-%define rel 14
+%define rel 15
Summary: Software-based TPM and MTM Emulator
Summary(pl.UTF-8): Programowy emulator TPM i MTM
Name: %{pname}%{?_pld_builder:%{?with_kernel:-kernel}}%{_alt_kernel}
@@ -34,6 +34,7 @@ Source0: http://downloads.sourceforge.net/tpm-emulator.berlios/%{pname}-%{versio
Patch0: %{pname}-libdir.patch
Patch1: linux-3.19.patch
Patch2: linux-4.1.patch
+Patch3: linux-4.7.patch
URL: http://tpm-emulator.berlios.de/
BuildRequires: cmake >= 2.4
BuildRequires: gmp-devel
@@ -126,6 +127,7 @@ przekazujący odebrane polecenia do tpmd.\
%patch0 -p1
%patch1 -p1
%patch2 -p1
+%patch3 -p1
# separate kernel module from userspace build
echo > tpmd_dev/CMakeLists.txt
diff --git a/linux-4.7.patch b/linux-4.7.patch
new file mode 100644
index 0000000..49567eb
--- /dev/null
+++ b/linux-4.7.patch
@@ -0,0 +1,14 @@
+--- tpm_emulator-0.7.4/tpmd_dev/linux/tpmd_dev.c~ 2016-08-01 22:08:44.000000000 +0200
++++ tpm_emulator-0.7.4/tpmd_dev/linux/tpmd_dev.c 2016-08-01 22:20:50.942899171 +0200
+@@ -140,7 +140,11 @@
+ #endif
+ oldmm = get_fs();
+ set_fs(KERNEL_DS);
++#if LINUX_VERSION_CODE < KERNEL_VERSION(4,7,0)
+ res = sock_recvmsg(tpmd_sock, &msg, tpm_response.size, 0);
++#else
++ res = sock_recvmsg(tpmd_sock, &msg, 0);
++#endif
+ set_fs(oldmm);
+ if (res < 0) {
+ error("sock_recvmsg() failed: %d\n", res);
================================================================
---- gitweb:
http://git.pld-linux.org/gitweb.cgi/packages/tpm_emulator.git/commitdiff/6e1dd8e8c8c8e9820a1e605b22cc1c813ad283b4
More information about the pld-cvs-commit
mailing list