diff options
author | Lans Zhang <jia.zhang@windriver.com> | 2017-07-20 16:10:13 +0800 |
---|---|---|
committer | Lans Zhang <jia.zhang@windriver.com> | 2017-07-20 16:10:13 +0800 |
commit | 17376a20627be4f255d4dc92d294611f08452170 (patch) | |
tree | d7e7b6a3b5681eea83d70b37a241cc2b8eab385f | |
parent | c53a21104b00657587cf3961ca533578528d156d (diff) | |
download | meta-secure-core-17376a20627be4f255d4dc92d294611f08452170.tar.gz |
tpm2-abrmd: update to the latest and code style fixup
Signed-off-by: Lans Zhang <jia.zhang@windriver.com>
-rw-r--r-- | meta-tpm2/recipes-tpm/tpm2-abrmd/files/Fix-build-failure-when-searching-tabrmd.h.patch | 293 | ||||
-rw-r--r-- | meta-tpm2/recipes-tpm/tpm2-abrmd/tpm2-abrmd_git.bb | 72 |
2 files changed, 39 insertions, 326 deletions
diff --git a/meta-tpm2/recipes-tpm/tpm2-abrmd/files/Fix-build-failure-when-searching-tabrmd.h.patch b/meta-tpm2/recipes-tpm/tpm2-abrmd/files/Fix-build-failure-when-searching-tabrmd.h.patch deleted file mode 100644 index 24dc022..0000000 --- a/meta-tpm2/recipes-tpm/tpm2-abrmd/files/Fix-build-failure-when-searching-tabrmd.h.patch +++ /dev/null | |||
@@ -1,293 +0,0 @@ | |||
1 | From 034e9cd7e539e1feda2fbe9a3646e28156856594 Mon Sep 17 00:00:00 2001 | ||
2 | From: Lans Zhang <jia.zhang@windriver.com> | ||
3 | Date: Thu, 15 Jun 2017 10:21:02 +0800 | ||
4 | Subject: [PATCH] Fix build failure when searching tabrmd.h | ||
5 | |||
6 | Signed-off-by: Lans Zhang <jia.zhang@windriver.com> | ||
7 | --- | ||
8 | Makefile.am | 2 +- | ||
9 | src/access-broker.c | 2 +- | ||
10 | src/include/tabrmd.h | 56 --------------------------- | ||
11 | src/include/tcti-tabrmd.h | 2 +- | ||
12 | src/include/tss2/tabrmd.h | 56 +++++++++++++++++++++++++++ | ||
13 | src/resource-manager.c | 2 +- | ||
14 | src/tabrmd-error.c | 2 +- | ||
15 | src/tabrmd.c | 2 +- | ||
16 | src/tcti-tabrmd.c | 2 +- | ||
17 | test/integration/hash-sequence.int.c | 2 +- | ||
18 | test/integration/password-authorization.int.c | 2 +- | ||
19 | test/integration/tcti-cancel.int.c | 2 +- | ||
20 | test/integration/tcti-set-locality.int.c | 2 +- | ||
21 | 13 files changed, 67 insertions(+), 67 deletions(-) | ||
22 | delete mode 100644 src/include/tabrmd.h | ||
23 | create mode 100644 src/include/tss2/tabrmd.h | ||
24 | |||
25 | diff --git a/Makefile.am b/Makefile.am | ||
26 | index 5f88429..4733d4f 100644 | ||
27 | --- a/Makefile.am | ||
28 | +++ b/Makefile.am | ||
29 | @@ -90,7 +90,7 @@ install-data-hook: | ||
30 | $(DESTDIR)$(mandir)/man3/tss2_tcti_tabrmd_init_full.3 | ||
31 | |||
32 | tpm2_abrmddir = $(includedir)/tss2 | ||
33 | -tpm2_abrmd_HEADERS = $(srcdir)/src/include/tabrmd.h | ||
34 | +tpm2_abrmd_HEADERS = $(srcdir)/src/include/tss2/tabrmd.h | ||
35 | libtcti_tabrmddir = $(includedir)/tcti | ||
36 | libtcti_tabrmd_HEADERS = $(srcdir)/src/include/tcti-tabrmd.h | ||
37 | |||
38 | diff --git a/src/access-broker.c b/src/access-broker.c | ||
39 | index d21113d..f357101 100644 | ||
40 | --- a/src/access-broker.c | ||
41 | +++ b/src/access-broker.c | ||
42 | @@ -28,7 +28,7 @@ | ||
43 | #include <inttypes.h> | ||
44 | #include <stdbool.h> | ||
45 | |||
46 | -#include "tabrmd.h" | ||
47 | +#include <tss2/tabrmd.h> | ||
48 | |||
49 | #include "access-broker.h" | ||
50 | #include "tcti.h" | ||
51 | diff --git a/src/include/tabrmd.h b/src/include/tabrmd.h | ||
52 | deleted file mode 100644 | ||
53 | index 42d41a2..0000000 | ||
54 | --- a/src/include/tabrmd.h | ||
55 | +++ /dev/null | ||
56 | @@ -1,56 +0,0 @@ | ||
57 | -/* | ||
58 | - * Copyright (c) 2017, Intel Corporation | ||
59 | - * All rights reserved. | ||
60 | - * | ||
61 | - * Redistribution and use in source and binary forms, with or without | ||
62 | - * modification, are permitted provided that the following conditions are met: | ||
63 | - * | ||
64 | - * 1. Redistributions of source code must retain the above copyright notice, | ||
65 | - * this list of conditions and the following disclaimer. | ||
66 | - * | ||
67 | - * 2. Redistributions in binary form must reproduce the above copyright notice, | ||
68 | - * this list of conditions and the following disclaimer in the documentation | ||
69 | - * and/or other materials provided with the distribution. | ||
70 | - * | ||
71 | - * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" | ||
72 | - * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE | ||
73 | - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE | ||
74 | - * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE | ||
75 | - * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR | ||
76 | - * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF | ||
77 | - * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS | ||
78 | - * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN | ||
79 | - * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) | ||
80 | - * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF | ||
81 | - * THE POSSIBILITY OF SUCH DAMAGE. | ||
82 | - */ | ||
83 | -#ifndef TSS2_TABD_H | ||
84 | -#define TSS2_TABD_H | ||
85 | - | ||
86 | -#include <gio/gio.h> | ||
87 | -#include <tpm20.h> | ||
88 | - | ||
89 | -#define TABRMD_DBUS_INTERFACE "com.intel.tss2.TctiTabrmd" | ||
90 | -#define TABRMD_DBUS_NAME_DEFAULT "com.intel.tss2.Tabrmd" | ||
91 | -#define TABRMD_DBUS_PATH "/com/intel/tss2/Tabrmd/Tcti" | ||
92 | -#define TABRMD_DBUS_METHOD_CREATE_CONNECTION "CreateConnection" | ||
93 | -#define TABRMD_DBUS_METHOD_CANCEL "Cancel" | ||
94 | -#define TABRMD_DBUS_TYPE_DEFAULT G_BUS_TYPE_SYSTEM | ||
95 | - | ||
96 | -/* implementation specific RCs */ | ||
97 | -#define TSS2_RESMGR_RC_INTERNAL_ERROR (TSS2_RC)(TSS2_RESMGR_ERROR_LEVEL | (1 << TSS2_LEVEL_IMPLEMENTATION_SPECIFIC_SHIFT)) | ||
98 | -#define TSS2_RESMGR_RC_SAPI_INIT (TSS2_RC)(TSS2_RESMGR_ERROR_LEVEL | (2 << TSS2_LEVEL_IMPLEMENTATION_SPECIFIC_SHIFT)) | ||
99 | -#define TSS2_RESMGR_RC_OUT_OF_MEMORY (TSS2_RC)(TSS2_RESMGR_ERROR_LEVEL | (3 << TSS2_LEVEL_IMPLEMENTATION_SPECIFIC_SHIFT)) | ||
100 | -/* RCs in the RESMGR layer */ | ||
101 | -#define TSS2_RESMGR_RC_BAD_VALUE (TSS2_RC)(TSS2_RESMGR_ERROR_LEVEL | TSS2_BASE_RC_BAD_VALUE) | ||
102 | -#define TSS2_RESMGR_RC_NOT_PERMITTED (TSS2_RC)(TSS2_RESMGR_ERROR_LEVEL | TSS2_BASE_RC_NOT_PERMITTED) | ||
103 | -#define TSS2_RESMGR_RC_NOT_IMPLEMENTED (TSS2_RC)(TSS2_RESMGR_ERROR_LEVEL | TSS2_BASE_RC_NOT_IMPLEMENTED) | ||
104 | -#define TSS2_RESMGR_RC_GENERAL_FAILURE (TSS2_RC)(TSS2_RESMGR_ERROR_LEVEL | TSS2_BASE_RC_GENERAL_FAILURE) | ||
105 | -#define TSS2_RESMGR_RC_OBJECT_MEMORY (TSS2_RC)(TSS2_RESMGR_ERROR_LEVEL | TPM_RC_OBJECT_MEMORY) | ||
106 | - | ||
107 | -#define TABRMD_ERROR tabrmd_error_quark () | ||
108 | -GQuark tabrmd_error_quark (void); | ||
109 | - | ||
110 | -TSS2_RC tss2_tcti_tabrmd_dump_trans_state (TSS2_TCTI_CONTEXT *tcti_context); | ||
111 | - | ||
112 | -#endif /* TSS2_TABD_H */ | ||
113 | diff --git a/src/include/tcti-tabrmd.h b/src/include/tcti-tabrmd.h | ||
114 | index c145eb5..e8e0c7f 100644 | ||
115 | --- a/src/include/tcti-tabrmd.h | ||
116 | +++ b/src/include/tcti-tabrmd.h | ||
117 | @@ -35,7 +35,7 @@ extern "C" { | ||
118 | #include <sapi/tpm20.h> | ||
119 | #include <sapi/tss2_tcti.h> | ||
120 | |||
121 | -#include "tabrmd.h" | ||
122 | +#include <tss2/tabrmd.h> | ||
123 | |||
124 | #define TCTI_TABRMD_DBUS_TYPE_DEFAULT TABRMD_DBUS_TYPE_DEFAULT | ||
125 | #define TCTI_TABRMD_DBUS_NAME_DEFAULT TABRMD_DBUS_NAME_DEFAULT | ||
126 | diff --git a/src/include/tss2/tabrmd.h b/src/include/tss2/tabrmd.h | ||
127 | new file mode 100644 | ||
128 | index 0000000..42d41a2 | ||
129 | --- /dev/null | ||
130 | +++ b/src/include/tss2/tabrmd.h | ||
131 | @@ -0,0 +1,56 @@ | ||
132 | +/* | ||
133 | + * Copyright (c) 2017, Intel Corporation | ||
134 | + * All rights reserved. | ||
135 | + * | ||
136 | + * Redistribution and use in source and binary forms, with or without | ||
137 | + * modification, are permitted provided that the following conditions are met: | ||
138 | + * | ||
139 | + * 1. Redistributions of source code must retain the above copyright notice, | ||
140 | + * this list of conditions and the following disclaimer. | ||
141 | + * | ||
142 | + * 2. Redistributions in binary form must reproduce the above copyright notice, | ||
143 | + * this list of conditions and the following disclaimer in the documentation | ||
144 | + * and/or other materials provided with the distribution. | ||
145 | + * | ||
146 | + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" | ||
147 | + * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE | ||
148 | + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE | ||
149 | + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE | ||
150 | + * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR | ||
151 | + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF | ||
152 | + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS | ||
153 | + * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN | ||
154 | + * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) | ||
155 | + * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF | ||
156 | + * THE POSSIBILITY OF SUCH DAMAGE. | ||
157 | + */ | ||
158 | +#ifndef TSS2_TABD_H | ||
159 | +#define TSS2_TABD_H | ||
160 | + | ||
161 | +#include <gio/gio.h> | ||
162 | +#include <tpm20.h> | ||
163 | + | ||
164 | +#define TABRMD_DBUS_INTERFACE "com.intel.tss2.TctiTabrmd" | ||
165 | +#define TABRMD_DBUS_NAME_DEFAULT "com.intel.tss2.Tabrmd" | ||
166 | +#define TABRMD_DBUS_PATH "/com/intel/tss2/Tabrmd/Tcti" | ||
167 | +#define TABRMD_DBUS_METHOD_CREATE_CONNECTION "CreateConnection" | ||
168 | +#define TABRMD_DBUS_METHOD_CANCEL "Cancel" | ||
169 | +#define TABRMD_DBUS_TYPE_DEFAULT G_BUS_TYPE_SYSTEM | ||
170 | + | ||
171 | +/* implementation specific RCs */ | ||
172 | +#define TSS2_RESMGR_RC_INTERNAL_ERROR (TSS2_RC)(TSS2_RESMGR_ERROR_LEVEL | (1 << TSS2_LEVEL_IMPLEMENTATION_SPECIFIC_SHIFT)) | ||
173 | +#define TSS2_RESMGR_RC_SAPI_INIT (TSS2_RC)(TSS2_RESMGR_ERROR_LEVEL | (2 << TSS2_LEVEL_IMPLEMENTATION_SPECIFIC_SHIFT)) | ||
174 | +#define TSS2_RESMGR_RC_OUT_OF_MEMORY (TSS2_RC)(TSS2_RESMGR_ERROR_LEVEL | (3 << TSS2_LEVEL_IMPLEMENTATION_SPECIFIC_SHIFT)) | ||
175 | +/* RCs in the RESMGR layer */ | ||
176 | +#define TSS2_RESMGR_RC_BAD_VALUE (TSS2_RC)(TSS2_RESMGR_ERROR_LEVEL | TSS2_BASE_RC_BAD_VALUE) | ||
177 | +#define TSS2_RESMGR_RC_NOT_PERMITTED (TSS2_RC)(TSS2_RESMGR_ERROR_LEVEL | TSS2_BASE_RC_NOT_PERMITTED) | ||
178 | +#define TSS2_RESMGR_RC_NOT_IMPLEMENTED (TSS2_RC)(TSS2_RESMGR_ERROR_LEVEL | TSS2_BASE_RC_NOT_IMPLEMENTED) | ||
179 | +#define TSS2_RESMGR_RC_GENERAL_FAILURE (TSS2_RC)(TSS2_RESMGR_ERROR_LEVEL | TSS2_BASE_RC_GENERAL_FAILURE) | ||
180 | +#define TSS2_RESMGR_RC_OBJECT_MEMORY (TSS2_RC)(TSS2_RESMGR_ERROR_LEVEL | TPM_RC_OBJECT_MEMORY) | ||
181 | + | ||
182 | +#define TABRMD_ERROR tabrmd_error_quark () | ||
183 | +GQuark tabrmd_error_quark (void); | ||
184 | + | ||
185 | +TSS2_RC tss2_tcti_tabrmd_dump_trans_state (TSS2_TCTI_CONTEXT *tcti_context); | ||
186 | + | ||
187 | +#endif /* TSS2_TABD_H */ | ||
188 | diff --git a/src/resource-manager.c b/src/resource-manager.c | ||
189 | index 6efdd82..8ad4e46 100644 | ||
190 | --- a/src/resource-manager.c | ||
191 | +++ b/src/resource-manager.c | ||
192 | @@ -35,7 +35,7 @@ | ||
193 | #include "resource-manager.h" | ||
194 | #include "sink-interface.h" | ||
195 | #include "source-interface.h" | ||
196 | -#include "tabrmd.h" | ||
197 | +#include <tss2/tabrmd.h> | ||
198 | #include "tpm2-header.h" | ||
199 | #include "tpm2-command.h" | ||
200 | #include "tpm2-response.h" | ||
201 | diff --git a/src/tabrmd-error.c b/src/tabrmd-error.c | ||
202 | index 5ff5a7d..41a561d 100644 | ||
203 | --- a/src/tabrmd-error.c | ||
204 | +++ b/src/tabrmd-error.c | ||
205 | @@ -1,6 +1,6 @@ | ||
206 | #include <gio/gio.h> | ||
207 | #include <glib.h> | ||
208 | -#include "tabrmd.h" | ||
209 | +#include <tss2/tabrmd.h> | ||
210 | |||
211 | static const GDBusErrorEntry tabrmd_error_entries[] = { | ||
212 | { | ||
213 | diff --git a/src/tabrmd.c b/src/tabrmd.c | ||
214 | index 2275aa5..7156cdf 100644 | ||
215 | --- a/src/tabrmd.c | ||
216 | +++ b/src/tabrmd.c | ||
217 | @@ -34,7 +34,7 @@ | ||
218 | #include <unistd.h> | ||
219 | |||
220 | #include <sapi/tpm20.h> | ||
221 | -#include "tabrmd.h" | ||
222 | +#include <tss2/tabrmd.h> | ||
223 | #include "access-broker.h" | ||
224 | #include "connection.h" | ||
225 | #include "connection-manager.h" | ||
226 | diff --git a/src/tcti-tabrmd.c b/src/tcti-tabrmd.c | ||
227 | index d6d78ea..52418de 100644 | ||
228 | --- a/src/tcti-tabrmd.c | ||
229 | +++ b/src/tcti-tabrmd.c | ||
230 | @@ -35,7 +35,7 @@ | ||
231 | |||
232 | #include <sapi/tpm20.h> | ||
233 | |||
234 | -#include "tabrmd.h" | ||
235 | +#include <tss2/tabrmd.h> | ||
236 | #include "tcti-tabrmd.h" | ||
237 | #include "tcti-tabrmd-priv.h" | ||
238 | #include "tpm2-header.h" | ||
239 | diff --git a/test/integration/hash-sequence.int.c b/test/integration/hash-sequence.int.c | ||
240 | index cf8331d..fd489f9 100644 | ||
241 | --- a/test/integration/hash-sequence.int.c | ||
242 | +++ b/test/integration/hash-sequence.int.c | ||
243 | @@ -34,7 +34,7 @@ | ||
244 | |||
245 | #include <sapi/tpm20.h> | ||
246 | |||
247 | -#include "tabrmd.h" | ||
248 | +#include <tss2/tabrmd.h> | ||
249 | #include "tcti-tabrmd.h" | ||
250 | #include "common.h" | ||
251 | |||
252 | diff --git a/test/integration/password-authorization.int.c b/test/integration/password-authorization.int.c | ||
253 | index e6298ef..5416eaa 100644 | ||
254 | --- a/test/integration/password-authorization.int.c | ||
255 | +++ b/test/integration/password-authorization.int.c | ||
256 | @@ -32,7 +32,7 @@ | ||
257 | #include <glib.h> | ||
258 | #include <inttypes.h> | ||
259 | |||
260 | -#include "tabrmd.h" | ||
261 | +#include <tss2/tabrmd.h> | ||
262 | #include "tcti-tabrmd.h" | ||
263 | #include "common.h" | ||
264 | |||
265 | diff --git a/test/integration/tcti-cancel.int.c b/test/integration/tcti-cancel.int.c | ||
266 | index 31f0f9a..c2a808b 100644 | ||
267 | --- a/test/integration/tcti-cancel.int.c | ||
268 | +++ b/test/integration/tcti-cancel.int.c | ||
269 | @@ -27,7 +27,7 @@ | ||
270 | #include <glib.h> | ||
271 | #include <inttypes.h> | ||
272 | |||
273 | -#include "tabrmd.h" | ||
274 | +#include <tss2/tabrmd.h> | ||
275 | #include "tcti-tabrmd.h" | ||
276 | #include "common.h" | ||
277 | |||
278 | diff --git a/test/integration/tcti-set-locality.int.c b/test/integration/tcti-set-locality.int.c | ||
279 | index 6b7509b..0a54b6a 100644 | ||
280 | --- a/test/integration/tcti-set-locality.int.c | ||
281 | +++ b/test/integration/tcti-set-locality.int.c | ||
282 | @@ -27,7 +27,7 @@ | ||
283 | #include <glib.h> | ||
284 | #include <inttypes.h> | ||
285 | |||
286 | -#include "tabrmd.h" | ||
287 | +#include <tss2/tabrmd.h> | ||
288 | #include "tcti-tabrmd.h" | ||
289 | #include "common.h" | ||
290 | |||
291 | -- | ||
292 | 2.7.5 | ||
293 | |||
diff --git a/meta-tpm2/recipes-tpm/tpm2-abrmd/tpm2-abrmd_git.bb b/meta-tpm2/recipes-tpm/tpm2-abrmd/tpm2-abrmd_git.bb index 17dc449..8f48c9a 100644 --- a/meta-tpm2/recipes-tpm/tpm2-abrmd/tpm2-abrmd_git.bb +++ b/meta-tpm2/recipes-tpm/tpm2-abrmd/tpm2-abrmd_git.bb | |||
@@ -1,26 +1,26 @@ | |||
1 | SUMMARY = "" | 1 | SUMMARY = "TPM2 Access Broker & Resource Manager" |
2 | DESCRIPTION = "" | 2 | DESCRIPTION = "This is a system daemon implementing the TPM2 access \ |
3 | SECTION = "tpm" | 3 | broker (TAB) & Resource Manager (RM) spec from the TCG. The daemon (tpm2-abrmd) \ |
4 | is implemented using Glib and the GObject system. In this documentation and \ | ||
5 | in the code we use `tpm2-abrmd` and `tabrmd` interchangeably. \ | ||
6 | " | ||
7 | SECTION = "security/tpm" | ||
4 | 8 | ||
5 | # This is a lie. The source for this project is covered by several licenses. | 9 | LICENSE = "BSD-2-Clause" |
6 | # We're currently working on a way to make this clear for those consuming the | 10 | LIC_FILES_CHKSUM = "file://${S}/LICENSE;md5=500b2e742befc3da00684d8a1d5fd9da" |
7 | # project. Till then I'm using 'BSD' as a place holder since the Intel license | ||
8 | # is "BSD-like". | ||
9 | LICENSE = "BSD" | ||
10 | LIC_FILES_CHKSUM = "file://${COREBASE}/meta/files/common-licenses/BSD;md5=3775480a712fc46a69647678acb234cb" | ||
11 | 11 | ||
12 | DEPENDS += "autoconf-archive dbus glib-2.0 pkgconfig tpm2.0-tss glib-2.0-native" | 12 | DEPENDS += "autoconf-archive dbus glib-2.0 pkgconfig tpm2.0-tss glib-2.0-native" |
13 | RDEPENDS_${PN} += "libgcc dbus-glib" | ||
14 | 13 | ||
15 | SRC_URI = " \ | 14 | PV = "1.1.0+git${SRCPV}" |
16 | git://github.com/01org/tpm2-abrmd.git;branch=master;name=tpm2-abrmd;destsuffix=tpm2-abrmd \ | ||
17 | file://tpm2-abrmd-init.sh \ | ||
18 | file://tpm2-abrmd.default \ | ||
19 | " | ||
20 | 15 | ||
21 | SRCREV = "4f0bd204d07176084b245d005df665fbfdf68db5" | 16 | SRC_URI = "\ |
22 | PV = "1.0.0+git${SRCPV}" | 17 | git://github.com/01org/tpm2-abrmd.git \ |
23 | S = "${WORKDIR}/${BPN}" | 18 | file://tpm2-abrmd-init.sh \ |
19 | file://tpm2-abrmd.default \ | ||
20 | " | ||
21 | SRCREV = "1003fcfaad39f5c27f75deb678f4fba253f38a82" | ||
22 | |||
23 | S = "${WORKDIR}/git" | ||
24 | 24 | ||
25 | inherit autotools pkgconfig systemd update-rc.d useradd | 25 | inherit autotools pkgconfig systemd update-rc.d useradd |
26 | 26 | ||
@@ -28,34 +28,40 @@ SYSTEMD_PACKAGES += "${PN}" | |||
28 | SYSTEMD_SERVICE_${PN} = "tpm2-abrmd.service" | 28 | SYSTEMD_SERVICE_${PN} = "tpm2-abrmd.service" |
29 | SYSTEMD_AUTO_ENABLE_${PN} = "enable" | 29 | SYSTEMD_AUTO_ENABLE_${PN} = "enable" |
30 | 30 | ||
31 | INITSCRIPT_NAME = "tpm2-abrmd" | 31 | INITSCRIPT_NAME = "${PN}" |
32 | INITSCRIPT_PARAMS = "start 99 2 3 4 5 . stop 19 0 1 6 ." | 32 | INITSCRIPT_PARAMS = "start 99 2 3 4 5 . stop 19 0 1 6 ." |
33 | 33 | ||
34 | USERADD_PACKAGES = "${PN}" | 34 | USERADD_PACKAGES = "${PN}" |
35 | GROUPADD_PARAM_${PN} = "tss" | 35 | GROUPADD_PARAM_${PN} = "tss" |
36 | USERADD_PARAM_${PN} = "-M -d /var/lib/tpm -s /bin/false -g tss tss" | 36 | USERADD_PARAM_${PN} = "--system -M -d /var/lib/tpm -s /bin/false -g tss tss" |
37 | 37 | ||
38 | # break out tcti into a package: libtcti-tabrmd | 38 | # break out tcti into a package: libtcti-tabrmd |
39 | # package up the service file | 39 | # package up the service file |
40 | 40 | ||
41 | EXTRA_OECONF += " \ | 41 | EXTRA_OECONF += "\ |
42 | --with-systemdsystemunitdir=${systemd_system_unitdir} \ | 42 | --with-systemdsystemunitdir=${systemd_system_unitdir} \ |
43 | --with-udevrulesdir=${sysconfdir}/udev/rules.d \ | 43 | --with-udevrulesdir=${sysconfdir}/udev/rules.d \ |
44 | " | 44 | " |
45 | 45 | ||
46 | do_configure_prepend() { | 46 | do_configure_prepend() { |
47 | # execute the bootstrap script | 47 | # execute the bootstrap script |
48 | currentdir=$(pwd) | 48 | currentdir=$(pwd) |
49 | cd "${S}" | 49 | cd "${S}" |
50 | ACLOCAL="aclocal --system-acdir=${STAGING_DATADIR}/aclocal" ./bootstrap --force | 50 | ACLOCAL="aclocal --system-acdir=${STAGING_DATADIR}/aclocal" \ |
51 | cd "${currentdir}" | 51 | ./bootstrap --force |
52 | cd "${currentdir}" | ||
52 | } | 53 | } |
53 | 54 | ||
54 | do_install_append() { | 55 | do_install_append() { |
55 | install -d "${D}${sysconfdir}/init.d" | 56 | install -d "${D}${sysconfdir}/init.d" |
56 | install -m 0755 "${WORKDIR}/tpm2-abrmd-init.sh" "${D}${sysconfdir}/init.d/tpm2-abrmd" | 57 | install -m 0755 "${WORKDIR}/tpm2-abrmd-init.sh" "${D}${sysconfdir}/init.d/tpm2-abrmd" |
57 | install -d "${D}${sysconfdir}/default" | 58 | |
58 | install -m 0644 "${WORKDIR}/tpm2-abrmd.default" "${D}${sysconfdir}/default/tpm2-abrmd" | 59 | install -d "${D}${sysconfdir}/default" |
60 | install -m 0644 "${WORKDIR}/tpm2-abrmd.default" "${D}${sysconfdir}/default/tpm2-abrmd" | ||
59 | } | 61 | } |
60 | 62 | ||
63 | RDEPENDS_${PN} += "\ | ||
64 | libgcc dbus-glib libtss2 libtctidevice libtctisocket libmarshal \ | ||
65 | " | ||
66 | |||
61 | BBCLASSEXTEND = "native" | 67 | BBCLASSEXTEND = "native" |