aboutsummaryrefslogtreecommitdiff
path: root/src/benchmarks/t_test1/Makefile
blob: 109e9a607ac3ca4ca9acedade5b651d195556e8e (plain)
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
# Makefile for t-test1 from ptmalloc, version 2
# by Florian Fischer 2019
# derived from
# Makefile for ptmalloc, version 2
# by Wolfram Gloger 1996-1999, 2001, 2002, 2003, 2004, 2006

OBJDIR ?= obj

CC ?= cc

SYS_FLAGS  = -D_GNU_SOURCE=1
OPT_FLAGS  ?= -g -O # -O2
WARN_FLAGS ?= -Wall -Wstrict-prototypes

# Flags for the test programs
T_FLAGS   = -DTEST=1

# Thread flags.
# See the platform-specific targets below.
THR_FLAGS = -DUSE_TSD_DATA_HACK -D_REENTRANT
THR_LIBS  = -lpthread

RM        = rm -f

CFLAGS ?= $(SYS_FLAGS) $(OPT_FLAGS) $(WARN_FLAGS) $(THR_FLAGS)

all: $(OBJDIR)/t-test1

$(OBJDIR)/t-test1: t-test1.c t-test.h | $(OBJDIR)
	@echo compiling $@
	$(CC) $(CFLAGS) $(T_FLAGS) t-test1.c $(THR_LIBS) -o $@

$(OBJDIR):
	mkdir -p $@

clean:
	$(RM) -rf $(OBJDIR)