| 1 |
# SPDX-License-Identifier: LGPL-2.1-or-later |
| 2 |
# ----------------------------------------------------------------------------- |
| 3 |
# libcockpit-common.a: common code that has no dependencies other than libc |
| 4 |
|
| 5 |
noinst_LIBRARIES += libcockpit-common.a |
| 6 |
|
| 7 |
libcockpit_common_a_LIBS = libcockpit-common.a |
| 8 |
|
| 9 |
libcockpit_common_a_SOURCES = \ |
| 10 |
src/common/cockpitauthorize.c \ |
| 11 |
src/common/cockpitauthorize.h \ |
| 12 |
src/common/cockpitbase64.c \ |
| 13 |
src/common/cockpitbase64.h \ |
| 14 |
src/common/cockpitconf.h \ |
| 15 |
src/common/cockpitconf.c \ |
| 16 |
src/common/cockpitfdpassing.c \ |
| 17 |
src/common/cockpitfdpassing.h \ |
| 18 |
src/common/cockpitframe.c \ |
| 19 |
src/common/cockpitframe.h \ |
| 20 |
src/common/cockpithex.c \ |
| 21 |
src/common/cockpithex.h \ |
| 22 |
src/common/cockpitjsonprint.c \ |
| 23 |
src/common/cockpitjsonprint.h \ |
| 24 |
src/common/cockpitmemory.c \ |
| 25 |
src/common/cockpitmemory.h \ |
| 26 |
src/common/cockpitwebcertificate.h \ |
| 27 |
src/common/cockpitwebcertificate.c \ |
| 28 |
$(NULL) |
| 29 |
|
| 30 |
# Used from both cockpit-ws and cockpit-bridge |
| 31 |
EXTRA_DIST += src/common/fail.html |
| 32 |
|
| 33 |
# ----------------------------------------------------------------------------- |
| 34 |
# Unit tests |
| 35 |
|
| 36 |
dist_check_DATA += src/common/mock-config |
| 37 |
|
| 38 |
TEST_PROGRAM += test-authorize |
| 39 |
test_authorize_CPPFLAGS = $(TEST_CPP) |
| 40 |
test_authorize_LDADD = $(TEST_LIBS) $(libcockpit_common_a_LIBS) |
| 41 |
test_authorize_SOURCES = src/common/test-authorize.c |
| 42 |
|
| 43 |
TEST_PROGRAM += test-base64 |
| 44 |
test_base64_CPPFLAGS = $(TEST_CPP) |
| 45 |
test_base64_LDADD = $(TEST_LIBS) $(libcockpit_common_a_LIBS) |
| 46 |
test_base64_SOURCES = src/common/test-base64.c |
| 47 |
|
| 48 |
TEST_PROGRAM += test-config |
| 49 |
test_config_CPPFLAGS = $(TEST_CPP) |
| 50 |
test_config_LDADD = $(TEST_LIBS) $(libcockpit_common_a_LIBS) |
| 51 |
test_config_SOURCES = src/common/test-config.c |
| 52 |
|
| 53 |
TEST_PROGRAM += test-frame |
| 54 |
test_frame_CPPFLAGS = $(TEST_CPP) |
| 55 |
test_frame_LDADD = $(TEST_LIBS) $(libcockpit_common_a_LIBS) |
| 56 |
test_frame_SOURCES = src/common/test-frame.c |
| 57 |
|
| 58 |
TEST_PROGRAM += test-jsonprint |
| 59 |
test_jsonprint_CPPFLAGS = $(TEST_CPP) |
| 60 |
test_jsonprint_LDADD = $(TEST_LIBS) $(libcockpit_common_a_LIBS) |
| 61 |
test_jsonprint_SOURCES = src/common/test-jsonprint.c |
| 62 |
|
| 63 |
TEST_PROGRAM += test-webcertificate |
| 64 |
test_webcertificate_CPPFLAGS = $(TEST_CPP) |
| 65 |
test_webcertificate_LDADD = $(TEST_LIBS) $(libcockpit_common_a_LIBS) |
| 66 |
test_webcertificate_SOURCES = src/common/test-webcertificate.c |