]> git.cworth.org Git - fips/blob - test/Makefile.local
7291dd23854585d5135166cdbbbb46000c397992
[fips] / test / Makefile.local
1 # -*- makefile -*-
2
3 dir := test
4
5 extra_cflags += -I. $(GL_CFLAGS) $(X11_CFLAGS)
6
7 test_programs =
8
9 ifeq ($(HAVE_X11),Yes)
10 test_programs += $(dir)/glx-link-call
11 test_programs += $(dir)/glx-dlopen-dlsym
12 test_programs += $(dir)/glx-dlopen-gpa
13 test_programs += $(dir)/glx-dlopen-gpaa
14 endif
15
16 glx_link_call_srcs = \
17         $(dir)/glx-link-call.c \
18         $(dir)/util.c
19
20 glx_link_call_modules = $(glx_link_call_srcs:.c=.o)
21
22 $(dir)/glx-link-call: $(glx_link_call_modules)
23         $(call quiet,$(FIPS_LINKER) $(CFLAGS)) $^ $(GL_LDFLAGS) $(X11_LDFLAGS) -o $@
24
25 glx_dlopen_dlsym_srcs = \
26         $(dir)/glx-dlopen-dlsym.c \
27         $(dir)/util.c
28
29 glx_dlopen_dlsym_modules = $(glx_dlopen_dlsym_srcs:.c=.o)
30
31 $(dir)/glx-dlopen-dlsym: $(glx_dlopen_dlsym_modules)
32         $(call quiet,$(FIPS_LINKER) $(CFLAGS)) $^ -ldl $(X11_LDFLAGS) -o $@
33
34 glx_dlopen_gpa_srcs = \
35         $(dir)/glx-dlopen-gpa.c \
36         $(dir)/util.c
37
38 glx_dlopen_gpa_modules = $(glx_dlopen_gpa_srcs:.c=.o)
39
40 $(dir)/glx-dlopen-gpa: $(glx_dlopen_gpa_modules)
41         $(call quiet,$(FIPS_LINKER) $(CFLAGS)) $^ -ldl $(X11_LDFLAGS) -o $@
42
43 glx_dlopen_gpaa_srcs = \
44         $(dir)/glx-dlopen-gpaa.c \
45         $(dir)/util.c
46
47 glx_dlopen_gpaa_modules = $(glx_dlopen_gpaa_srcs:.c=.o)
48
49 $(dir)/glx-dlopen-gpaa: $(glx_dlopen_gpaa_modules)
50         $(call quiet,$(FIPS_LINKER) $(CFLAGS)) $^ -ldl $(X11_LDFLAGS) -o $@
51
52 test: all $(test_programs)
53         @${dir}/fips-test
54
55 check: test
56
57 SRCS := $(SRCS) $(glx_link_call_srcs) $(glx_dlopen_dlsym_srcs) $(glx_dlopen_gpa_srcs)
58
59 CLEAN += $(test_programs) $(glx_link_call_modules) $(glx_dlopen_dlsym_modules) $(glx_dlopen_gpa_modules)