forked from tpm2-software/tpm2-abrmd
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile.am
531 lines (448 loc) · 20.9 KB
/
Makefile.am
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
# SPDX-License-Identifier: BSD-2
# we have BUILT_SOURCES so builddir must be in VPATH
VPATH = $(srcdir) $(builddir)
ACLOCAL_AMFLAGS = -I m4 --install
.PHONY: unit-count
unit-count: check
sh scripts/unit-count.sh
AM_CFLAGS = $(EXTRA_CFLAGS) \
-I$(srcdir)/src -I$(srcdir)/src/include -I$(builddir)/src \
$(DBUS_CFLAGS) $(GIO_CFLAGS) $(GLIB_CFLAGS) $(PTHREAD_CFLAGS) \
$(TSS2_SYS_CFLAGS) $(TCTI_DEVICE_CFLAGS) $(TCTI_SOCKET_CFLAGS) \
$(CODE_COVERAGE_CFLAGS)
AM_LDFLAGS = $(EXTRA_LDFLAGS) $(CODE_COVERAGE_LIBS)
UNIT_AM_CFLAGS = $(AM_CFLAGS) $(CMOCKA_CFLAGS)
TESTS_UNIT = \
test/access-broker_unit \
test/command-attrs_unit \
test/connection_unit \
test/connection-manager_unit \
test/logging_unit \
test/message-queue_unit \
test/resource-manager_unit \
test/response-sink_unit \
test/command-source_unit \
test/handle-map-entry_unit \
test/handle-map_unit \
test/ipc-frontend_unit \
test/ipc-frontend-dbus_unit \
test/random_unit \
test/session-entry_unit \
test/session-list_unit \
test/test-skeleton_unit \
test/tcti_unit \
test/tcti-factory_unit \
test/tcti-util_unit \
test/thread_unit \
test/tpm2-command_unit \
test/tpm2-response_unit \
test/tss2-tcti-tabrmd_unit \
test/util_unit
TESTS_INTEGRATION = \
test/integration/auth-session-max.int \
test/integration/auth-session-start-flush.int \
test/integration/auth-session-start-save.int \
test/integration/auth-session-start-save-load.int \
test/integration/max-transient-upperbound.int \
test/integration/get-capability-handles-transient.int \
test/integration/manage-transient-keys.int \
test/integration/session-gap.int \
test/integration/session-load-from-closed-connection.int \
test/integration/session-load-from-closed-connections-lru.int \
test/integration/session-load-from-open-connection.int \
test/integration/start-auth-session.int \
test/integration/tcti-cancel.int \
test/integration/tcti-connections-max.int \
test/integration/tcti-double-finalize.int \
test/integration/tcti-set-locality.int \
test/integration/hash-sequence.int \
test/integration/not-enough-handles-for-command.int \
test/integration/password-authorization.int \
test/integration/tpm2-command-flush-no-handle.int \
test/integration/util-buf-max-upper-bound.int
TESTS_INTEGRATION_NOHW = test/integration/tcti-connect-multiple.int
# empty init for these since they're manipulated by conditionals
TESTS =
noinst_LTLIBRARIES =
XFAIL_TESTS = \
test/integration/start-auth-session.int
TEST_EXTENSIONS = .int
AM_TESTS_ENVIRONMENT = \
TEST_FUNC_LIB=$(srcdir)/scripts/int-test-funcs.sh \
PATH=./src:$(PATH) \
dbus-run-session
INT_LOG_COMPILER = $(srcdir)/scripts/int-test-setup.sh
INT_LOG_FLAGS = --tabrmd-tcti=$(TABRMD_TCTI)
if ENABLE_INTEGRATION
noinst_LTLIBRARIES += $(libtest)
TESTS += $(TESTS_INTEGRATION)
if HWTPM
TABRMD_TCTI = device
else
TABRMD_TCTI = mssim
TESTS += $(TESTS_INTEGRATION_NOHW)
endif
endif
if UNIT
TESTS += $(TESTS_UNIT)
endif
sbin_PROGRAMS = src/tpm2-abrmd
check_PROGRAMS = $(sbin_PROGRAMS) $(TESTS)
# libraries
libtss2_tcti_tabrmd = src/libtss2-tcti-tabrmd.la
libtest = test/integration/libtest.la
libutil = src/libutil.la
lib_LTLIBRARIES = $(libtss2_tcti_tabrmd)
noinst_LTLIBRARIES += \
$(libutil)
man3_MANS = man/man3/Tss2_Tcti_Tabrmd_Init.3
man7_MANS = man/man7/tss2-tcti-tabrmd.7
man8_MANS = man/man8/tpm2-abrmd.8
libtss2_tcti_tabrmddir = $(includedir)/tss2
libtss2_tcti_tabrmd_HEADERS = $(srcdir)/src/include/tss2-tcti-tabrmd.h
EXTRA_DIST = \
src/tabrmd.xml \
test/integration/test.h \
test/integration/tpm2-struct-init.h \
src/tcti-tabrmd.map \
man/colophon.in \
man/Tss2_Tcti_Tabrmd_Init.3.in \
man/tss2-tcti-tabrmd.7.in \
man/tpm2-abrmd.8.in \
dist/tpm2-abrmd.conf \
dist/tpm2-abrmd.preset.in \
dist/tss2-tcti-tabrmd.pc.in \
dist/tpm2-abrmd.service.in \
dist/com.intel.tss2.Tabrmd.service \
scripts/int-test-funcs.sh \
scripts/int-test-setup.sh \
selinux/Makefile \
selinux/tabrmd.fc \
selinux/tabrmd.if \
selinux/tabrmd.te \
AUTHORS \
CHANGELOG.md \
CONTRIBUTING.md \
INSTALL.md \
LICENSE \
README.md \
VERSION
CLEANFILES = \
$(man3_MANS) \
$(man7_MANS) \
man/man8/tpm2-abrmd.8 \
src/tabrmd-generated.c \
src/tabrmd-generated.h \
$(pkgconfig_DATA) \
$(systemdpreset_DATA) \
$(systemdsystemunit_DATA) \
test/integration/*.log \
_tabrmd.log
DISTCLEANFILES = core default.profraw
BUILT_SOURCES = src/tabrmd-generated.h src/tabrmd-generated.c
pkgconfigdir = $(libdir)/pkgconfig
pkgconfig_DATA = dist/tss2-tcti-tabrmd.pc
dbuspolicy_DATA = dist/tpm2-abrmd.conf
if HAVE_SYSTEMD
systemdpreset_DATA = dist/tpm2-abrmd.preset
systemdsystemunit_DATA = dist/tpm2-abrmd.service
dbusservicedir = $(datadir)/dbus-1/system-services
dbusservice_DATA = dist/com.intel.tss2.Tabrmd.service
endif # HAVE_SYSTEMD
# ax_code_coverage
if AUTOCONF_CODE_COVERAGE_2019_01_06
include $(top_srcdir)/aminclude_static.am
clean-local: code-coverage-clean
distclean-local: code-coverage-dist-clean
# workaround for a bug in Autoconf Archive 2019.01.06
# (https://github.com/autoconf-archive/autoconf-archive/pull/182)
if CODE_COVERAGE_ENABLED
AM_DISTCHECK_CONFIGURE_FLAGS := $(AM_DISTCHECK_CONFIGURE_FLAGS) --disable-code-coverage
endif # CODE_COVERAGE_ENABLED
else # AUTOCONF_CODE_COVERAGE_2019_01_06
@CODE_COVERAGE_RULES@
endif # AUTOCONF_CODE_COVERAGE_2019_01_06
@VALGRIND_CHECK_RULES@
VALGRIND_G_DEBUG = fatal-criticals,gc-friendly
VALGRIND_memcheck_FLAGS = --leak-check=full --show-leak-kinds=definite,indirect --track-origins=yes --error-exitcode=1
# This is a hack required to ensure that BUILT_SOURCES are generated before
# the file that requires them.
src/ipc-frontend-dbus.c : $(BUILT_SOURCES)
# utility library with most of the code that makes up the daemon
# -Wno-unused-parameter for automatically-generated tabrmd-generated.c:
src_libutil_la_CFLAGS = $(AM_CFLAGS) -Wno-unused-parameter
src_libutil_la_LIBADD = $(DBUS_LIBS) $(GIO_LIBS) $(GLIB_LIBS) $(PTHREAD_LIBS) \
$(TSS2_SYS_LIBS) $(TCTI_DEVICE_LIBS) $(TCTI_SOCKET_LIBS)
src_libutil_la_SOURCES = \
src/access-broker.c \
src/access-broker.h \
src/command-attrs.c \
src/command-attrs.h \
src/command-source.c \
src/command-source.h \
src/connection.c \
src/connection.h \
src/connection-manager.c \
src/connection-manager.h \
src/control-message.c \
src/control-message.h \
src/handle-map-entry.c \
src/handle-map-entry.h \
src/handle-map.c \
src/handle-map.h \
src/ipc-frontend.c \
src/ipc-frontend.h \
src/ipc-frontend-dbus.h \
src/ipc-frontend-dbus.c \
src/logging.c \
src/logging.h \
src/message-queue.c \
src/message-queue.h \
src/random.c \
src/random.h \
src/resource-manager-session.c \
src/resource-manager-session.h \
src/resource-manager.c \
src/resource-manager.h \
src/response-sink.c \
src/response-sink.h \
src/session-entry-state-enum.c \
src/session-entry-state-enum.h \
src/session-entry.c \
src/session-entry.h \
src/session-list.c \
src/session-list.h \
src/sink-interface.c \
src/sink-interface.h \
src/source-interface.c \
src/source-interface.h \
src/tabrmd-error.c \
src/tabrmd-generated.c \
src/tabrmd-generated.h \
src/tabrmd.h \
src/tcti.c \
src/tcti.h \
src/tcti-factory.c \
src/tcti-factory.h \
src/tcti-util.c \
src/tcti-util.h \
src/thread.c \
src/thread.h \
src/tpm2-command.c \
src/tpm2-command.h \
src/tpm2-header.c \
src/tpm2-header.h \
src/tpm2-response.c \
src/tpm2-response.h \
src/util.c \
src/util.h
test_integration_libtest_la_LIBADD = $(TSS2_SYS_LIBS) $(TCTI_SOCKET_LIBS) \
$(TCTI_DEVICE_LIBS) $(GLIB_LIBS)
test_integration_libtest_la_SOURCES = \
test/integration/common.c \
test/integration/common.h \
test/integration/context-util.c \
test/integration/context-util.h \
test/integration/test-options.c \
test/integration/test-options.h \
test/mock-io-stream.c \
test/mock-io-stream.h \
test/tcti-mock.c \
test/tcti-mock.h
src_libtss2_tcti_tabrmd_la_LIBADD = $(DBUS_LIBS) $(GIO_LIBS) $(GLIB_LIBS) \
$(PTHREAD_LIBS) $(libutil) $(TSS2_SYS_LIBS)
src_libtss2_tcti_tabrmd_la_LDFLAGS = -fPIC -Wl,--no-undefined -Wl,-z,nodelete -Wl,--version-script=$(srcdir)/src/tcti-tabrmd.map
src_libtss2_tcti_tabrmd_la_SOURCES = src/tcti-tabrmd.c src/tcti-tabrmd-priv.h $(srcdir)/src/tcti-tabrmd.map
src_tpm2_abrmd_LDADD = $(DBUS_LIBS) $(GIO_LIBS) $(GLIB_LIBS) $(PTHREAD_LIBS) \
$(TSS2_SYS_LIBS) $(libutil)
src_tpm2_abrmd_SOURCES = src/tabrmd.c
AUTHORS :
git log --format='%aN <%aE>' | grep -v 'users.noreply.github.com' | sort | \
uniq -c | sort -nr | sed 's/^\s*//' | cut -d" " -f2- > $@
man/man3/%.3 : man/%.3.in
$(AM_V_GEN)$(call man_tcti_prefix,$@,$^)
man/man7/%.7 : man/%.7.in
$(AM_V_GEN)$(call man_tcti_prefix,$@,$^)
man/man8/%.8 : man/%.8.in
$(AM_V_GEN)$(call man_tcti_prefix,$@,$^)
# this function is used to generate man pages from templates found in
# $(srcdir)/man/*.in
define man_tcti_prefix
$(call make_parent_dir,$@)
-$(AM_V_at)rm -f $@
$(AM_V_GEN)sed -e "s,[@]VERSION[@],$(PACKAGE_VERSION),g;" $2 $(srcdir)/man/colophon.in >> $1
endef # man_tcti_prefix
%-generated.c %-generated.h : src/tabrmd.xml
$(AM_V_GEN)$(call make_parent_dir,$@) && \
$(GDBUS_CODEGEN) --interface-prefix=com.intel.tss2. \
--generate-c-code=src/tabrmd-generated $^
%.preset : %.preset.in
$(AM_V_GEN)$(call make_parent_dir,$@) && \
sed -e "s,[@]SYSTEMD_PRESET_DEFAULT[@],$(SYSTEMD_PRESET_DEFAULT),g;" $^ > $@
%.service : %.service.in
$(AM_V_GEN)$(call make_parent_dir,$@) && \
sed -e "s,[@]SBINDIR[@],$(sbindir),g; \
s,[@]sysconfdir[@],$(sysconfdir),g;" $^ > $@
%.pc : %.pc.in
$(AM_V_GEN)$(call make_parent_dir,$@) && \
sed -e "s,[@]VERSION[@],$(PACKAGE_VERSION),g; \
s,[@]includedir[@],$(includedir),g;" $^ > $@
define make_parent_dir
if [ ! -d $(dir $1) ]; then mkdir -p $(dir $1); fi
endef
if UNIT
test_test_skeleton_unit_CFLAGS = $(UNIT_AM_CFLAGS)
test_test_skeleton_unit_LDADD = $(CMOCKA_LIBS)
test_test_skeleton_unit_SOURCES = test/test-skeleton_unit.c
test_response_sink_unit_CFLAGS = $(UNIT_AM_CFLAGS)
test_response_sink_unit_LDADD = $(CMOCKA_LIBS) $(GLIB_LIBS) $(TSS2_SYS_LIBS) \
$(PTHREAD_LIBS) $(noinst_LTLIBRARIES) $(GOBJECT_LIBS)
test_response_sink_unit_SOURCES = \
src/connection.c \
src/control-message.c \
src/handle-map.c \
src/handle-map-entry.c \
src/thread.c \
src/message-queue.c \
src/response-sink.c \
src/sink-interface.c \
src/tpm2-response.c \
test/response-sink_unit.c
test_connection_unit_CFLAGS = $(UNIT_AM_CFLAGS)
test_connection_unit_LDADD = $(CMOCKA_LIBS) $(GLIB_LIBS) $(GOBJECT_LIBS) $(libutil)
test_connection_unit_SOURCES = test/connection_unit.c
test_connection_manager_unit_CFLAGS = $(UNIT_AM_CFLAGS)
test_connection_manager_unit_LDADD = $(CMOCKA_LIBS) $(GLIB_LIBS) $(GOBJECT_LIBS) $(libutil)
test_connection_manager_unit_SOURCES = test/connection-manager_unit.c
test_command_attrs_unit_CFLAGS = $(UNIT_AM_CFLAGS)
test_command_attrs_unit_LDADD = $(CMOCKA_LIBS) $(GLIB_LIBS) $(TSS2_SYS_LIBS) $(GOBJECT_LIBS) $(libutil) $(libtest)
test_command_attrs_unit_LDFLAGS = -Wl,--wrap=access_broker_lock_sapi,--wrap=access_broker_get_max_command,--wrap=Tss2_Sys_GetCapability
test_command_attrs_unit_SOURCES = test/command-attrs_unit.c
test_command_source_unit_CFLAGS = $(UNIT_AM_CFLAGS)
test_command_source_unit_LDADD = $(CMOCKA_LIBS) $(GLIB_LIBS) $(TSS2_SYS_LIBS) $(PTHREAD_LIBS) $(GOBJECT_LIBS) $(libutil)
test_command_source_unit_LDFLAGS = -Wl,--wrap=g_source_set_callback,--wrap=connection_manager_lookup_istream,--wrap=connection_manager_remove,--wrap=sink_enqueue,--wrap=read_tpm_buffer_alloc,--wrap=command_attrs_from_cc
test_command_source_unit_SOURCES = test/command-source_unit.c
test_handle_map_entry_unit_CFLAGS = $(UNIT_AM_CFLAGS)
test_handle_map_entry_unit_LDADD = $(CMOCKA_LIBS) $(GLIB_LIBS) $(GOBJECT_LIBS) $(libutil)
test_handle_map_entry_unit_SOURCES = test/handle-map-entry_unit.c
test_handle_map_unit_CFLAGS = $(UNIT_AM_CFLAGS)
test_handle_map_unit_LDADD = $(CMOCKA_LIBS) $(GLIB_LIBS) $(TSS2_SYS_LIBS) $(PTHREAD_LIBS) $(GOBJECT_LIBS) $(libutil)
test_handle_map_unit_SOURCES = test/handle-map_unit.c
test_ipc_frontend_unit_CFLAGS = $(UNIT_AM_CFLAGS)
test_ipc_frontend_unit_LDADD = $(CMOCKA_LIBS) $(GLIB_LIBS) $(GOBJECT_LIBS) $(libutil)
test_ipc_frontend_unit_SOURCES = test/ipc-frontend_unit.c
test_ipc_frontend_dbus_unit_CFLAGS = $(UNIT_AM_CFLAGS)
test_ipc_frontend_dbus_unit_LDADD = $(CMOCKA_LIBS) $(GLIB_LIBS) $(GOBJECT_LIBS) $(libutil)
test_ipc_frontend_dbus_unit_SOURCES = test/ipc-frontend-dbus_unit.c
test_logging_unit_CFLAGS = $(UNIT_AM_CFLAGS)
test_logging_unit_LDADD = $(CMOCKA_LIBS) $(GLIB_LIBS) $(GOBJECT_LIBS) $(libutil)
test_logging_unit_LDFLAGS = -Wl,--wrap=getenv,--wrap=syslog
test_logging_unit_SOURCES = test/logging_unit.c
test_thread_unit_CFLAGS = $(UNIT_AM_CFLAGS)
test_thread_unit_LDADD = $(CMOCKA_LIBS) $(GLIB_LIBS) $(GOBJECT_LIBS) $(TSS2_SYS_LIBS) $(libutil)
test_thread_unit_SOURCES = test/thread_unit.c
test_tpm2_command_unit_CFLAGS = $(UNIT_AM_CFLAGS)
test_tpm2_command_unit_LDADD = $(CMOCKA_LIBS) $(GLIB_LIBS) $(GOBJECT_LIBS) $(TSS2_SYS_LIBS) $(libutil)
test_tpm2_command_unit_SOURCES = test/tpm2-command_unit.c
test_tpm2_response_unit_CFLAGS = $(UNIT_AM_CFLAGS)
test_tpm2_response_unit_LDADD = $(CMOCKA_LIBS) $(GLIB_LIBS) $(GOBJECT_LIBS) $(TSS2_SYS_LIBS) $(libutil)
test_tpm2_response_unit_SOURCES = test/tpm2-response_unit.c
test_util_unit_CFLAGS = $(UNIT_AM_CFLAGS)
test_util_unit_LDADD = $(CMOCKA_LIBS) $(GLIB_LIBS) $(libutil)
test_util_unit_LDFLAGS = -Wl,--wrap=g_input_stream_read,--wrap=g_output_stream_write
test_util_unit_SOURCES = test/util_unit.c
test_message_queue_unit_CFLAGS = $(UNIT_AM_CFLAGS)
test_message_queue_unit_LDADD = $(CMOCKA_LIBS) $(GLIB_LIBS) $(GOBJECT_LIBS) $(libutil)
test_message_queue_unit_SOURCES = test/message-queue_unit.c
test_access_broker_unit_CFLAGS = $(UNIT_AM_CFLAGS)
test_access_broker_unit_LDFLAGS = -Wl,--wrap=Tss2_Sys_Startup,--wrap=Tss2_Sys_GetCapability
test_access_broker_unit_LDADD = $(CMOCKA_LIBS) $(GLIB_LIBS) $(GOBJECT_LIBS) $(TSS2_SYS_LIBS) $(PTHREAD_LIBS) $(libutil) $(libtest)
test_access_broker_unit_SOURCES = test/access-broker_unit.c
test_random_unit_CFLAGS = $(UNIT_AM_CFLAGS)
test_random_unit_LDADD = $(CMOCKA_LIBS) $(GLIB_LIBS) $(GOBJECT_LIBS) $(libutil)
test_random_unit_LDFLAGS = -Wl,--wrap=open,--wrap=read,--wrap=close
test_random_unit_SOURCES = test/random_unit.c
test_session_entry_unit_CFLAGS = $(UNIT_AM_CFLAGS)
test_session_entry_unit_LDADD = $(CMOCKA_LIBS) $(GLIB_LIBS) $(GOBJECT_LIBS) $(libutil)
test_session_entry_unit_SOURCES = test/session-entry_unit.c
test_session_list_unit_CFLAGS = $(UNIT_AM_CFLAGS)
test_session_list_unit_LDADD = $(CMOCKA_LIBS) $(GLIB_LIBS) $(GOBJECT_LIBS) $(libutil) $(libtest)
test_session_list_unit_SOURCES = test/session-list_unit.c
test_resource_manager_unit_CFLAGS = $(UNIT_AM_CFLAGS)
test_resource_manager_unit_LDFLAGS = -Wl,--wrap=access_broker_send_command,--wrap=sink_enqueue,--wrap=access_broker_context_saveflush,--wrap=access_broker_context_load
test_resource_manager_unit_LDADD = $(CMOCKA_LIBS) $(GLIB_LIBS) $(GOBJECT_LIBS) $(TSS2_SYS_LIBS) $(PTHREAD_LIBS) $(libutil) $(libtest)
test_resource_manager_unit_SOURCES = test/resource-manager_unit.c
test_tcti_unit_CFLAGS = $(UNIT_AM_CFLAGS)
test_tcti_unit_LDADD = $(CMOCKA_LIBS) $(GLIB_LIBS) $(GOBJECT_LIBS) $(libutil) $(libtest)
test_tcti_unit_SOURCES = test/tcti_unit.c
test_tcti_factory_unit_CFLAGS = $(UNIT_AM_CFLAGS)
test_tcti_factory_unit_LDADD = $(CMOCKA_LIBS) $(GLIB_LIBS) $(GOBJECT_LIBS) $(libutil)
test_tcti_factory_unit_LDFLAGS = -Wl,--wrap=tcti_util_discover_info,--wrap=tcti_util_dynamic_init,--wrap=dlclose
test_tcti_factory_unit_SOURCES = test/tcti-factory_unit.c
test_tcti_util_unit_CFLAGS = $(UNIT_AM_CFLAGS)
test_tcti_util_unit_LDADD = $(CMOCKA_LIBS) $(GLIB_LIBS) $(GOBJECT_LIBS) $(libutil)
test_tcti_util_unit_LDFLAGS = -Wl,--wrap=dlopen,--wrap=dlsym,--wrap=dlclose
test_tcti_util_unit_SOURCES = test/tcti-util_unit.c
test_tss2_tcti_tabrmd_unit_CFLAGS = $(UNIT_AM_CFLAGS)
test_tss2_tcti_tabrmd_unit_LDFLAGS = -Wl,--wrap=g_dbus_proxy_call_with_unix_fd_list_sync,--wrap=tcti_tabrmd_call_cancel_sync,--wrap=tcti_tabrmd_call_set_locality_sync,--wrap=read_data,--wrap=poll,--wrap=tcti_tabrmd_proxy_new_for_bus_sync
test_tss2_tcti_tabrmd_unit_LDADD = $(CMOCKA_LIBS) $(GIO_LIBS) $(libutil)
test_tss2_tcti_tabrmd_unit_SOURCES = src/tcti-tabrmd.c test/tss2-tcti-tabrmd_unit.c
endif
TEST_INT_LIBS = $(libtest) $(libutil) $(libtss2_tcti_tabrmd) $(GLIB_LIBS)
test_integration_auth_session_max_int_LDADD = $(TEST_INT_LIBS)
test_integration_auth_session_max_int_SOURCES = test/integration/main.c \
test/integration/auth-session-max.int.c
test_integration_auth_session_start_flush_int_LDADD = $(TEST_INT_LIBS)
test_integration_auth_session_start_flush_int_SOURCES = test/integration/main.c \
test/integration/auth-session-start-flush.int.c
test_integration_auth_session_start_save_int_LDADD = $(TEST_INT_LIBS)
test_integration_auth_session_start_save_int_SOURCES = test/integration/main.c \
test/integration/auth-session-start-save.int.c
test_integration_auth_session_start_save_load_int_LDADD = $(TEST_INT_LIBS)
test_integration_auth_session_start_save_load_int_SOURCES = test/integration/main.c \
test/integration/auth-session-start-save-load.int.c
test_integration_max_transient_upperbound_int_LDADD = $(TEST_INT_LIBS)
test_integration_max_transient_upperbound_int_SOURCES = test/integration/main.c \
test/integration/max-transient-upperbound.int.c
test_integration_get_capability_handles_transient_int_LDADD = $(TEST_INT_LIBS)
test_integration_get_capability_handles_transient_int_SOURCES = \
test/integration/main.c test/integration/get-capability-handles-transient.int.c
test_integration_session_gap_int_LDADD = $(TEST_INT_LIBS)
test_integration_session_gap_int_SOURCES = test/integration/main.c \
test/integration/session-gap.int.c
test_integration_session_load_from_open_connection_int_LDADD = $(TEST_INT_LIBS)
test_integration_session_load_from_open_connection_int_SOURCES = \
test/integration/session-load-from-open-connection.int.c
test_integration_session_load_from_closed_connection_int_LDADD = $(TEST_INT_LIBS)
test_integration_session_load_from_closed_connection_int_SOURCES = \
test/integration/session-load-from-closed-connection.int.c
test_integration_session_load_from_closed_connections_lru_int_LDADD = $(TEST_INT_LIBS)
test_integration_session_load_from_closed_connections_lru_int_SOURCES = \
test/integration/session-load-from-closed-connections-lru.int.c
test_integration_start_auth_session_int_LDADD = $(TEST_INT_LIBS)
test_integration_start_auth_session_int_SOURCES = test/integration/main.c test/integration/start-auth-session.int.c
test_integration_tcti_cancel_int_LDADD = $(TEST_INT_LIBS)
test_integration_tcti_cancel_int_SOURCES = test/integration/main.c test/integration/tcti-cancel.int.c
test_integration_tcti_double_finalize_int_LDADD = $(TEST_INT_LIBS)
test_integration_tcti_double_finalize_int_SOURCES = test/integration/main.c \
test/integration/tcti-double-finalize.int.c
test_integration_tcti_connect_multiple_int_LDADD = $(TEST_INT_LIBS)
test_integration_tcti_connect_multiple_int_SOURCES = test/integration/tcti-connect-multiple.int.c
test_integration_tcti_connections_max_int_LDADD = $(TEST_INT_LIBS)
test_integration_tcti_connections_max_int_SOURCES = test/integration/tcti-connections-max.int.c
test_integration_tcti_set_locality_int_LDADD = $(TEST_INT_LIBS)
test_integration_tcti_set_locality_int_SOURCES = test/integration/main.c test/integration/tcti-set-locality.int.c
test_integration_hash_sequence_int_LDADD = $(TEST_INT_LIBS)
test_integration_hash_sequence_int_SOURCES = test/integration/main.c test/integration/hash-sequence.int.c
test_integration_not_enough_handles_for_command_int_LDADD = $(TEST_INT_LIBS)
test_integration_not_enough_handles_for_command_int_SOURCES = test/integration/main.c test/integration/not-enough-handles-for-command.int.c
test_integration_password_authorization_int_LDADD = $(TEST_INT_LIBS)
test_integration_password_authorization_int_SOURCES = test/integration/main.c test/integration/password-authorization.int.c
test_integration_manage_transient_keys_int_LDADD = $(TEST_INT_LIBS)
test_integration_manage_transient_keys_int_SOURCES = test/integration/main.c test/integration/manage-transient-keys.int.c
test_integration_tpm2_command_flush_no_handle_int_LDADD = $(TEST_INT_LIBS)
test_integration_tpm2_command_flush_no_handle_int_SOURCES = \
test/integration/main.c test/integration/tpm2-command-flush-no-handle.int.c
test_integration_util_buf_max_upper_bound_int_LDADD = $(TEST_INT_LIBS)
test_integration_util_buf_max_upper_bound_int_SOURCES = \
test/integration/main.c test/integration/util-buf-max-upper-bound.int.c