]> git.cworth.org Git - fips/blob - test/Makefile.local
test: Rename util.c and util.h to util-x11.c and util-x11.h
[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-link-gpa
12 test_programs += $(dir)/glx-link-gpaa
13 test_programs += $(dir)/glx-dlopen-dlsym
14 test_programs += $(dir)/glx-dlopen-gpa
15 test_programs += $(dir)/glx-dlopen-gpaa
16 endif
17
18 glx_link_call_srcs = \
19         $(dir)/glx-link-call.c \
20         $(dir)/util-x11.c
21
22 glx_link_call_modules = $(glx_link_call_srcs:.c=.o)
23
24 $(dir)/glx-link-call: $(glx_link_call_modules)
25         $(call quiet,$(FIPS_LINKER) $(CFLAGS)) $^ $(GL_LDFLAGS) $(X11_LDFLAGS) -o $@
26
27 glx_link_gpa_srcs = \
28         $(dir)/glx-link-gpa.c \
29         $(dir)/util-x11.c
30
31 glx_link_gpa_modules = $(glx_link_gpa_srcs:.c=.o)
32
33 $(dir)/glx-link-gpa: $(glx_link_gpa_modules)
34         $(call quiet,$(FIPS_LINKER) $(CFLAGS)) $^ $(GL_LDFLAGS) $(X11_LDFLAGS) -o $@
35
36 glx_link_gpaa_srcs = \
37         $(dir)/glx-link-gpaa.c \
38         $(dir)/util-x11.c
39
40 glx_link_gpaa_modules = $(glx_link_gpaa_srcs:.c=.o)
41
42 $(dir)/glx-link-gpaa: $(glx_link_gpaa_modules)
43         $(call quiet,$(FIPS_LINKER) $(CFLAGS)) $^ $(GL_LDFLAGS) $(X11_LDFLAGS) -o $@
44
45 glx_dlopen_dlsym_srcs = \
46         $(dir)/glx-dlopen-dlsym.c \
47         $(dir)/util-x11.c
48
49 glx_dlopen_dlsym_modules = $(glx_dlopen_dlsym_srcs:.c=.o)
50
51 $(dir)/glx-dlopen-dlsym: $(glx_dlopen_dlsym_modules)
52         $(call quiet,$(FIPS_LINKER) $(CFLAGS)) $^ -ldl $(X11_LDFLAGS) -o $@
53
54 glx_dlopen_gpa_srcs = \
55         $(dir)/glx-dlopen-gpa.c \
56         $(dir)/util-x11.c
57
58 glx_dlopen_gpa_modules = $(glx_dlopen_gpa_srcs:.c=.o)
59
60 $(dir)/glx-dlopen-gpa: $(glx_dlopen_gpa_modules)
61         $(call quiet,$(FIPS_LINKER) $(CFLAGS)) $^ -ldl $(X11_LDFLAGS) -o $@
62
63 glx_dlopen_gpaa_srcs = \
64         $(dir)/glx-dlopen-gpaa.c \
65         $(dir)/util-x11.c
66
67 glx_dlopen_gpaa_modules = $(glx_dlopen_gpaa_srcs:.c=.o)
68
69 $(dir)/glx-dlopen-gpaa: $(glx_dlopen_gpaa_modules)
70         $(call quiet,$(FIPS_LINKER) $(CFLAGS)) $^ -ldl $(X11_LDFLAGS) -o $@
71
72 test: all $(test_programs)
73         @${dir}/fips-test
74
75 check: test
76
77 SRCS := $(SRCS) \
78         $(glx_link_call_srcs) \
79         $(glx_link_gpa_srcs) \
80         $(glx_link_gpaa_srcs) \
81         $(glx_dlopen_dlsym_srcs) \
82         $(glx_dlopen_gpa_srcs)
83
84 CLEAN += $(test_programs) \
85         $(glx_link_call_modules) \
86         $(glx_link_gpa_modules) \
87         $(glx_link_gpaa_modules) \
88         $(glx_dlopen_dlsym_modules) \
89         $(glx_dlopen_gpa_modules)