1 #
2 # This file and its contents are supplied under the terms of the
3 # Common Development and Distribution License ("CDDL"), version 1.0.
4 # You may only use this file in accordance with the terms of version
5 # 1.0 of the CDDL.
6 #
7 # A full copy of the text of the CDDL should have accompanied this
8 # source. A copy of the CDDL is also available via the Internet at
9 # http://www.illumos.org/license/CDDL.
10 #
11
12 #
13 # Copyright (c) 2019, Joyent, Inc.
14 #
15
16 include $(SRC)/Makefile.master
17
18 ROOTOPTPKG = $(ROOT)/opt/util-tests
19 TESTDIR = $(ROOTOPTPKG)/tests/ctf
20
21 SCRIPTS = precheck.ksh \
22 ctftest.ksh \
23 ctftest-convert-non-c.ksh \
24 ctftest-convert-no-dwarf.ksh \
25 ctftest-merge-no-ctf.ksh \
26
27 TESTS = test-float.c \
28 test-reference.c \
29 test-int.c \
30 test-array.c \
31 test-enum.c \
32 test-forward.c \
33 test-sou.c \
34 test-function.c \
35 test-merge-static/Makefile.ctftest \
36 test-merge-static/test-a.c \
37 test-merge-static/test-b.c \
38 test-merge-static/test-c.c \
39 test-merge-static/test-d.c \
40 test-merge-static/test-main.c \
41 test-merge-forward/Makefile.ctftest \
42 test-merge-forward/test-impl.c \
43 test-merge-forward/test-merge.c \
44 test-merge-dedup/Makefile.ctftest \
45 test-merge-dedup/test-merge-1.c \
46 test-merge-dedup/test-merge-2.c \
47 test-merge-dedup/test-merge-3.c \
48 test-merge-dedup/test-merge-dedup.c \
49 test-merge-reduction/Makefile.ctftest \
50 test-merge-reduction/mapfile-vers \
51 test-merge-reduction/test-global.c \
52 test-merge-reduction/test-scoped.c \
53 test-merge-weak/Makefile.ctftest \
54 test-merge-weak/test-merge-weak.c \
56 Makefile.ctftest.com
57
58 MAKEDIRS = test-merge-static \
59 test-merge-forward \
60 test-merge-dedup \
61 test-merge-reduction \
62 test-merge-weak
63
64 CHECKS = check-float-32 \
65 check-float-64 \
66 check-int-32 \
67 check-int-64 \
68 check-reference \
69 check-array \
70 check-enum \
71 check-sou-32 \
72 check-sou-64 \
73 check-forward-32 \
74 check-forward-64 \
75 check-function \
76 check-merge-static \
77 check-merge-forward-32 \
78 check-merge-forward-64 \
79 check-merge-dedup \
80 check-merge-reduction \
81 check-merge-weak \
82 check-weak
83
84 COMMON_OBJS = check-common.o
85 ALL_OBJS = $(CHECKS:%=%.o) $(CHECKS:%-32=%.32.o) $(CHECKS:%-64=%.64.o) $(COMMON_OBJS)
86
87 ROOTTESTS = $(TESTS:%=$(TESTDIR)/%)
88 ROOTMAKEDIRS = $(MAKEDIRS:%=$(TESTDIR)/%)
89 ROOTCHECKS = $(CHECKS:%=$(TESTDIR)/%)
90 ROOTSCRIPTS = $(SCRIPTS:%.ksh=$(TESTDIR)/%)
91
92 ROOTTESTS := FILEMODE = 0444
93 ROOTCHECKS := FILEMODE = 0555
94 ROOTSCRIPTS := FILEMODE = 0555
95
96 include $(SRC)/cmd/Makefile.cmd
97 include $(SRC)/test/Makefile.com
98
99 LDLIBS += -lctf
100
101 check-merge-static := LDLIBS += -lelf
102
103 all: $(CHECKS)
104
105 install: all $(ROOTTESTS) $(ROOTCHECKS) $(ROOTSCRIPTS)
106
107 $(CHECKS): $(COMMON_OBJS)
108
109 clean:
110 $(RM) $(ALL_OBJS)
111
112 clobber: clean
113 $(RM) $(CHECKS)
114
115 $(ROOTTESTS): $(TESTDIR) $(ROOTMAKEDIRS) $(TESTS)
116 $(ROOTCHECKS): $(TESTDIR) $(CHECKS)
117 $(ROOTSCRIPTS): $(TESTDIR) $(SCRIPTS)
118
|
1 #
2 # This file and its contents are supplied under the terms of the
3 # Common Development and Distribution License ("CDDL"), version 1.0.
4 # You may only use this file in accordance with the terms of version
5 # 1.0 of the CDDL.
6 #
7 # A full copy of the text of the CDDL should have accompanied this
8 # source. A copy of the CDDL is also available via the Internet at
9 # http://www.illumos.org/license/CDDL.
10 #
11
12 #
13 # Copyright 2019, Joyent, Inc.
14 #
15
16 include $(SRC)/Makefile.master
17
18 ROOTOPTPKG = $(ROOT)/opt/util-tests
19 TESTDIR = $(ROOTOPTPKG)/tests/ctf
20
21 SCRIPTS = precheck.ksh \
22 ctftest.ksh \
23 ctftest-convert-non-c.ksh \
24 ctftest-convert-no-dwarf.ksh \
25 ctftest-merge-no-ctf.ksh \
26
27 TESTS = test-float.c \
28 test-reference.c \
29 test-int.c \
30 test-array.c \
31 test-enum.c \
32 test-forward.c \
33 test-sou.c \
34 test-function.c \
35 test-qualifiers.c \
36 test-merge-static/Makefile.ctftest \
37 test-merge-static/test-a.c \
38 test-merge-static/test-b.c \
39 test-merge-static/test-c.c \
40 test-merge-static/test-d.c \
41 test-merge-static/test-main.c \
42 test-merge-forward/Makefile.ctftest \
43 test-merge-forward/test-impl.c \
44 test-merge-forward/test-merge.c \
45 test-merge-dedup/Makefile.ctftest \
46 test-merge-dedup/test-merge-1.c \
47 test-merge-dedup/test-merge-2.c \
48 test-merge-dedup/test-merge-3.c \
49 test-merge-dedup/test-merge-dedup.c \
50 test-merge-reduction/Makefile.ctftest \
51 test-merge-reduction/mapfile-vers \
52 test-merge-reduction/test-global.c \
53 test-merge-reduction/test-scoped.c \
54 test-merge-weak/Makefile.ctftest \
55 test-merge-weak/test-merge-weak.c \
57 Makefile.ctftest.com
58
59 MAKEDIRS = test-merge-static \
60 test-merge-forward \
61 test-merge-dedup \
62 test-merge-reduction \
63 test-merge-weak
64
65 CHECKS = check-float-32 \
66 check-float-64 \
67 check-int-32 \
68 check-int-64 \
69 check-reference \
70 check-array \
71 check-enum \
72 check-sou-32 \
73 check-sou-64 \
74 check-forward-32 \
75 check-forward-64 \
76 check-function \
77 check-qualifiers \
78 check-merge-static \
79 check-merge-forward-32 \
80 check-merge-forward-64 \
81 check-merge-dedup \
82 check-merge-reduction \
83 check-merge-weak \
84 check-weak
85
86 COMMON_OBJS = check-common.o
87 ALL_OBJS = $(CHECKS:%=%.o) $(CHECKS:%-32=%.32.o) $(CHECKS:%-64=%.64.o) $(COMMON_OBJS)
88
89 ROOTTESTS = $(TESTS:%=$(TESTDIR)/%)
90 ROOTMAKEDIRS = $(MAKEDIRS:%=$(TESTDIR)/%)
91 ROOTCHECKS = $(CHECKS:%=$(TESTDIR)/%)
92 ROOTSCRIPTS = $(SCRIPTS:%.ksh=$(TESTDIR)/%)
93
94 ROOTTESTS := FILEMODE = 0444
95 ROOTCHECKS := FILEMODE = 0555
96 ROOTSCRIPTS := FILEMODE = 0555
97
98 include $(SRC)/cmd/Makefile.cmd
99 include $(SRC)/test/Makefile.com
100
101 CSTD = $(CSTD_GNU99)
102
103 LDLIBS += -lctf
104
105 check-merge-static := LDLIBS += -lelf
106
107 all: $(CHECKS)
108
109 install: all $(ROOTTESTS) $(ROOTCHECKS) $(ROOTSCRIPTS)
110
111 $(CHECKS): $(COMMON_OBJS)
112
113 clean:
114 $(RM) $(ALL_OBJS)
115
116 clobber: clean
117 $(RM) $(CHECKS)
118
119 $(ROOTTESTS): $(TESTDIR) $(ROOTMAKEDIRS) $(TESTS)
120 $(ROOTCHECKS): $(TESTDIR) $(CHECKS)
121 $(ROOTSCRIPTS): $(TESTDIR) $(SCRIPTS)
122
|