-
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile.am
131 lines (100 loc) · 3.94 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
#
# fmt
#
# Copyright (c) 2017 Guillermo Calvo
# Licensed under the GNU Lesser General Public License
#
AUTOMAKE_OPTIONS = foreign subdir-objects
AM_CFLAGS = -Wall -Wextra -Werror --pedantic -Wno-missing-field-initializers -coverage -O0 -I$(FMT_PATH)
# Library
FMT_PATH = src
FMT_LIBRARY = lib/libfmt.a
# Install
lib_LIBRARIES = \
$(FMT_LIBRARY)
include_HEADERS = \
src/fmt.h
# Documentation
docdir = $(datadir)/doc/fmt
doc_DATA = doc/*
# Cleanup
CLEANFILES = \
*.log \
*.gcda \
*.gcno \
*.gcov \
src/*.gcda \
src/*.gcno \
src/*.gcov \
test/*.gcda \
test/*.gcno \
test/*.gcov
# Check
check_PROGRAMS = \
bin/check/double \
bin/check/file \
bin/check/flags \
bin/check/indirect \
bin/check/integer \
bin/check/intmax \
bin/check/ldouble \
bin/check/long \
bin/check/longlong \
bin/check/meta \
bin/check/month \
bin/check/percent \
bin/check/person \
bin/check/ptrdiff \
bin/check/precision \
bin/check/short \
bin/check/size \
bin/check/string \
bin/check/wrongid
TESTS = \
bin/check/double \
bin/check/file \
bin/check/flags \
bin/check/indirect \
bin/check/integer \
bin/check/intmax \
bin/check/ldouble \
bin/check/long \
bin/check/longlong \
bin/check/meta \
bin/check/month \
bin/check/percent \
bin/check/person \
bin/check/ptrdiff \
bin/check/precision \
bin/check/short \
bin/check/size \
bin/check/string \
bin/check/wrongid
tests: check
# fmt library
lib_libfmt_a_CFLAGS = -Wall -Wextra -Werror --pedantic
lib_libfmt_a_SOURCES = src/fmt.c
# fmt tests
bin_check_double_SOURCES = src/fmt.c test/double.c
bin_check_file_SOURCES = src/fmt.c test/file.c
bin_check_flags_SOURCES = src/fmt.c test/flags.c
bin_check_indirect_SOURCES = src/fmt.c test/indirect.c
bin_check_integer_SOURCES = src/fmt.c test/integer.c
bin_check_intmax_SOURCES = src/fmt.c test/intmax.c
bin_check_ldouble_SOURCES = src/fmt.c test/ldouble.c
bin_check_long_SOURCES = src/fmt.c test/long.c
bin_check_longlong_SOURCES = src/fmt.c test/longlong.c
bin_check_meta_SOURCES = src/fmt.c test/meta.c
bin_check_month_SOURCES = src/fmt.c test/month.c
bin_check_percent_SOURCES = src/fmt.c test/percent.c
bin_check_person_SOURCES = src/fmt.c test/person.c
bin_check_ptrdiff_SOURCES = src/fmt.c test/ptrdiff.c
bin_check_precision_SOURCES = src/fmt.c test/precision.c
bin_check_short_SOURCES = src/fmt.c test/short.c
bin_check_size_SOURCES = src/fmt.c test/size.c
bin_check_string_SOURCES = src/fmt.c test/string.c
bin_check_wrongid_SOURCES = src/fmt.c test/wrongid.c
# coverage
coverage: check fmt.c.gcov
fmt.c.gcov:
gcov src/fmt.c --object-directory src/*