annotate Makefile.gen @ 476:61fed1286780

Build th_file module.
author Matti Hamalainen <ccr@tnsp.org>
date Mon, 09 Jul 2018 07:29:33 +0300
parents b3b8f90bbbe6
children 5d2c1bfc04aa
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
426
56874ab723d3 Fix build for older GCC versions.
Matti Hamalainen <ccr@tnsp.org>
parents: 419
diff changeset
1 CFLAGS += -W -Wall -Wextra -D_XOPEN_SOURCE=500 -I./
56874ab723d3 Fix build for older GCC versions.
Matti Hamalainen <ccr@tnsp.org>
parents: 419
diff changeset
2 #CFLAGS += -std=c11 -pedantic
406
30432a52026a Adjust build flags.
Matti Hamalainen <ccr@tnsp.org>
parents: 382
diff changeset
3 CFLAGS += -g
254
3d1e2af4e4e6 Start of a very simplistic unit test suite. Initially handling just printf()
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
4 CFLAGS += -O2
426
56874ab723d3 Fix build for older GCC versions.
Matti Hamalainen <ccr@tnsp.org>
parents: 419
diff changeset
5 CFLAGS += -DTH_USE_INTERNAL_SPRINTF=1
406
30432a52026a Adjust build flags.
Matti Hamalainen <ccr@tnsp.org>
parents: 382
diff changeset
6 CFLAGS += -DTH_PRINTF_DEBUG=1
426
56874ab723d3 Fix build for older GCC versions.
Matti Hamalainen <ccr@tnsp.org>
parents: 419
diff changeset
7
406
30432a52026a Adjust build flags.
Matti Hamalainen <ccr@tnsp.org>
parents: 382
diff changeset
8 THLIBS = ./
254
3d1e2af4e4e6 Start of a very simplistic unit test suite. Initially handling just printf()
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
9
3d1e2af4e4e6 Start of a very simplistic unit test suite. Initially handling just printf()
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
10 #
3d1e2af4e4e6 Start of a very simplistic unit test suite. Initially handling just printf()
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
11 # Objects
3d1e2af4e4e6 Start of a very simplistic unit test suite. Initially handling just printf()
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
12 #
3d1e2af4e4e6 Start of a very simplistic unit test suite. Initially handling just printf()
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
13 THLIBS_A=$(OBJPATH)thlibs.a
273
7bea1d5ab944 Build all modules.
Matti Hamalainen <ccr@tnsp.org>
parents: 254
diff changeset
14 THLIBS_OBJ=th_util.o th_config.o th_string.o th_ioctx.o \
476
61fed1286780 Build th_file module.
Matti Hamalainen <ccr@tnsp.org>
parents: 474
diff changeset
15 th_args.o th_crypto.o th_datastruct.o th_network.o \
61fed1286780 Build th_file module.
Matti Hamalainen <ccr@tnsp.org>
parents: 474
diff changeset
16 th_file.o
273
7bea1d5ab944 Build all modules.
Matti Hamalainen <ccr@tnsp.org>
parents: 254
diff changeset
17
254
3d1e2af4e4e6 Start of a very simplistic unit test suite. Initially handling just printf()
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
18
3d1e2af4e4e6 Start of a very simplistic unit test suite. Initially handling just printf()
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
19 TESTS_OBJ=tests.o
3d1e2af4e4e6 Start of a very simplistic unit test suite. Initially handling just printf()
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
20 TESTS_BIN=$(BINPATH)tests$(EXEEXT)
3d1e2af4e4e6 Start of a very simplistic unit test suite. Initially handling just printf()
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
21
3d1e2af4e4e6 Start of a very simplistic unit test suite. Initially handling just printf()
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
22 TARGETS += $(TESTS_BIN)
3d1e2af4e4e6 Start of a very simplistic unit test suite. Initially handling just printf()
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
23
433
0a2f32b8a26e Improve the build system.
Matti Hamalainen <ccr@tnsp.org>
parents: 426
diff changeset
24 include $(THLIBS)/Makefile.inc
0a2f32b8a26e Improve the build system.
Matti Hamalainen <ccr@tnsp.org>
parents: 426
diff changeset
25
302
3f05f6fb5dfd Fix build.
Matti Hamalainen <ccr@tnsp.org>
parents: 294
diff changeset
26 $(TESTS_BIN): $(addprefix $(OBJPATH),$(TESTS_OBJ)) $(THLIBS_A)
474
b3b8f90bbbe6 Improve build system.
Matti Hamalainen <ccr@tnsp.org>
parents: 433
diff changeset
27 $(LINK_BIN)
254
3d1e2af4e4e6 Start of a very simplistic unit test suite. Initially handling just printf()
Matti Hamalainen <ccr@tnsp.org>
parents:
diff changeset
28
292
54032f17c7e5 Add 'make check' target.
Matti Hamalainen <ccr@tnsp.org>
parents: 273
diff changeset
29 check: $(TESTS_BIN)
54032f17c7e5 Add 'make check' target.
Matti Hamalainen <ccr@tnsp.org>
parents: 273
diff changeset
30 $(TESTS_BIN) -v
54032f17c7e5 Add 'make check' target.
Matti Hamalainen <ccr@tnsp.org>
parents: 273
diff changeset
31