Deleted Added
full compact
Makefile (277725) Makefile (277727)
1# $FreeBSD: head/share/examples/Makefile 277725 2015-01-26 06:27:07Z ngie $
1# $FreeBSD: head/share/examples/Makefile 277727 2015-01-26 06:44:48Z ngie $
2#
3# Doing a make install builds /usr/share/examples
4
5.include <src.opts.mk>
6
7LDIRS= BSD_daemon \
8 FreeBSD_version \
9 IPv6 \
2#
3# Doing a make install builds /usr/share/examples
4
5.include <src.opts.mk>
6
7LDIRS= BSD_daemon \
8 FreeBSD_version \
9 IPv6 \
10 bhyve \
11 bootforth \
12 csh \
13 diskless \
14 drivers \
15 etc \
16 find_interface \
17 ibcs2 \
18 indent \
19 ipfw \
20 jails \
21 kld \
22 libusb20 \
23 libvgl \
24 mdoc \
25 netgraph \
26 perfmon \
27 ppi \
28 ppp \
29 printing \
30 ses \
31 scsi_target \
32 sunrpc
33
34XFILES= BSD_daemon/FreeBSD.pfa \
35 BSD_daemon/README \
36 BSD_daemon/beastie.eps \
37 BSD_daemon/beastie.fig \
38 BSD_daemon/eps.patch \
39 BSD_daemon/poster.sh \
40 FreeBSD_version/FreeBSD_version.c \
41 FreeBSD_version/Makefile \
42 FreeBSD_version/README \
43 IPv6/USAGE \
10 bootforth \
11 csh \
12 diskless \
13 drivers \
14 etc \
15 find_interface \
16 ibcs2 \
17 indent \
18 ipfw \
19 jails \
20 kld \
21 libusb20 \
22 libvgl \
23 mdoc \
24 netgraph \
25 perfmon \
26 ppi \
27 ppp \
28 printing \
29 ses \
30 scsi_target \
31 sunrpc
32
33XFILES= BSD_daemon/FreeBSD.pfa \
34 BSD_daemon/README \
35 BSD_daemon/beastie.eps \
36 BSD_daemon/beastie.fig \
37 BSD_daemon/eps.patch \
38 BSD_daemon/poster.sh \
39 FreeBSD_version/FreeBSD_version.c \
40 FreeBSD_version/Makefile \
41 FreeBSD_version/README \
42 IPv6/USAGE \
44 bhyve/vmrun.sh \
45 bootforth/README \
46 bootforth/boot.4th \
47 bootforth/frames.4th \
48 bootforth/loader.rc \
49 bootforth/menu.4th \
50 bootforth/menuconf.4th \
51 bootforth/screen.4th \
52 csh/dot.cshrc \
53 diskless/ME \
54 diskless/README.BOOTP \
55 diskless/README.TEMPLATING \
56 diskless/clone_root \
57 drivers/README \
58 drivers/make_device_driver.sh \
59 drivers/make_pseudo_driver.sh \
60 etc/README.examples \
61 etc/bsd-style-copyright \
62 etc/make.conf \
63 find_interface/Makefile \
64 find_interface/README \
65 find_interface/find_interface.c \
66 ibcs2/README \
67 ibcs2/hello.uu \
68 indent/indent.pro \
69 ipfw/change_rules.sh \
70 jails/README \
71 kld/Makefile \
72 kld/cdev/Makefile \
73 kld/cdev/README \
74 kld/cdev/module/Makefile \
75 kld/cdev/module/cdev.c \
76 kld/cdev/module/cdev.h \
77 kld/cdev/module/cdevmod.c \
78 kld/cdev/test/Makefile \
79 kld/cdev/test/testcdev.c \
80 kld/dyn_sysctl/Makefile \
81 kld/dyn_sysctl/README \
82 kld/dyn_sysctl/dyn_sysctl.c \
83 kld/firmware/Makefile \
84 kld/firmware/README \
85 kld/firmware/fwconsumer/Makefile \
86 kld/firmware/fwconsumer/fw_consumer.c \
87 kld/firmware/fwimage/Makefile \
88 kld/firmware/fwimage/firmware.img.uu \
89 kld/khelp/Makefile \
90 kld/khelp/README \
91 kld/khelp/h_example.c \
92 kld/syscall/Makefile \
93 kld/syscall/module/Makefile \
94 kld/syscall/module/syscall.c \
95 kld/syscall/test/Makefile \
96 kld/syscall/test/call.c \
97 libusb20/Makefile \
98 libusb20/README \
99 libusb20/util.c \
100 libusb20/util.h \
101 libusb20/bulk.c \
102 libusb20/control.c \
103 libvgl/Makefile \
104 libvgl/demo.c \
105 mdoc/POSIX-copyright \
106 mdoc/deshallify.sh \
107 mdoc/example.1 \
108 mdoc/example.3 \
109 mdoc/example.4 \
110 mdoc/example.9 \
111 netgraph/ether.bridge \
112 netgraph/frame_relay \
113 netgraph/ngctl \
114 netgraph/raw \
115 netgraph/udp.tunnel \
116 netgraph/virtual.chain \
117 netgraph/virtual.lan \
118 perfmon/Makefile \
119 perfmon/README \
120 perfmon/perfmon.c \
121 ppi/Makefile \
122 ppi/ppilcd.c \
123 ppp/chap-auth \
124 ppp/login-auth \
125 ppp/ppp.conf.sample \
126 ppp/ppp.conf.span-isp \
127 ppp/ppp.conf.span-isp.working \
128 ppp/ppp.linkdown.sample \
129 ppp/ppp.linkdown.span-isp \
130 ppp/ppp.linkdown.span-isp.working \
131 ppp/ppp.linkup.sample \
132 ppp/ppp.linkup.span-isp \
133 ppp/ppp.linkup.span-isp.working \
134 ppp/ppp.secret.sample \
135 ppp/ppp.secret.span-isp \
136 ppp/ppp.secret.span-isp.working \
137 printing/README \
138 printing/diablo-if-net \
139 printing/hpdf \
140 printing/hpif \
141 printing/hpof \
142 printing/hprf \
143 printing/hpvf \
144 printing/if-simple \
145 printing/if-simpleX \
146 printing/ifhp \
147 printing/make-ps-header \
148 printing/netprint \
149 printing/psdf \
150 printing/psdfX \
151 printing/psif \
152 printing/pstf \
153 printing/pstfX \
154 ses/Makefile \
155 ses/Makefile.inc \
156 ses/getencstat/Makefile \
157 ses/getencstat/getencstat.0 \
158 ses/sesd/Makefile \
159 ses/sesd/sesd.0 \
160 ses/setencstat/Makefile \
161 ses/setencstat/setencstat.0 \
162 ses/setobjstat/Makefile \
163 ses/setobjstat/setobjstat.0 \
164 ses/srcs/chpmon.c \
165 ses/srcs/eltsub.c \
166 ses/srcs/eltsub.h \
167 ses/srcs/getencstat.c \
168 ses/srcs/getnobj.c \
169 ses/srcs/getobjmap.c \
170 ses/srcs/getobjstat.c \
171 ses/srcs/inienc.c \
172 ses/srcs/sesd.c \
173 ses/srcs/setencstat.c \
174 ses/srcs/setobjstat.c \
175 scsi_target/Makefile \
176 scsi_target/scsi_target.c \
177 scsi_target/scsi_target.h \
178 scsi_target/scsi_target.8 \
179 scsi_target/scsi_cmds.c \
180 sunrpc/Makefile \
181 sunrpc/dir/Makefile \
182 sunrpc/dir/dir.x \
183 sunrpc/dir/dir_proc.c \
184 sunrpc/dir/rls.c \
185 sunrpc/msg/Makefile \
186 sunrpc/msg/msg.x \
187 sunrpc/msg/msg_proc.c \
188 sunrpc/msg/printmsg.c \
189 sunrpc/msg/rprintmsg.c \
190 sunrpc/sort/Makefile \
191 sunrpc/sort/rsort.c \
192 sunrpc/sort/sort.x \
193 sunrpc/sort/sort_proc.c
194
195BINDIR= ${SHAREDIR}/examples
196
197NO_OBJ=
198
199.if ${MK_HAST} != "no"
200LDIRS+= hast
201XFILES+= hast/ucarp.sh \
202 hast/ucarp_down.sh \
203 hast/ucarp_up.sh \
204 hast/vip-down.sh \
205 hast/vip-up.sh
206.endif
207
43 bootforth/README \
44 bootforth/boot.4th \
45 bootforth/frames.4th \
46 bootforth/loader.rc \
47 bootforth/menu.4th \
48 bootforth/menuconf.4th \
49 bootforth/screen.4th \
50 csh/dot.cshrc \
51 diskless/ME \
52 diskless/README.BOOTP \
53 diskless/README.TEMPLATING \
54 diskless/clone_root \
55 drivers/README \
56 drivers/make_device_driver.sh \
57 drivers/make_pseudo_driver.sh \
58 etc/README.examples \
59 etc/bsd-style-copyright \
60 etc/make.conf \
61 find_interface/Makefile \
62 find_interface/README \
63 find_interface/find_interface.c \
64 ibcs2/README \
65 ibcs2/hello.uu \
66 indent/indent.pro \
67 ipfw/change_rules.sh \
68 jails/README \
69 kld/Makefile \
70 kld/cdev/Makefile \
71 kld/cdev/README \
72 kld/cdev/module/Makefile \
73 kld/cdev/module/cdev.c \
74 kld/cdev/module/cdev.h \
75 kld/cdev/module/cdevmod.c \
76 kld/cdev/test/Makefile \
77 kld/cdev/test/testcdev.c \
78 kld/dyn_sysctl/Makefile \
79 kld/dyn_sysctl/README \
80 kld/dyn_sysctl/dyn_sysctl.c \
81 kld/firmware/Makefile \
82 kld/firmware/README \
83 kld/firmware/fwconsumer/Makefile \
84 kld/firmware/fwconsumer/fw_consumer.c \
85 kld/firmware/fwimage/Makefile \
86 kld/firmware/fwimage/firmware.img.uu \
87 kld/khelp/Makefile \
88 kld/khelp/README \
89 kld/khelp/h_example.c \
90 kld/syscall/Makefile \
91 kld/syscall/module/Makefile \
92 kld/syscall/module/syscall.c \
93 kld/syscall/test/Makefile \
94 kld/syscall/test/call.c \
95 libusb20/Makefile \
96 libusb20/README \
97 libusb20/util.c \
98 libusb20/util.h \
99 libusb20/bulk.c \
100 libusb20/control.c \
101 libvgl/Makefile \
102 libvgl/demo.c \
103 mdoc/POSIX-copyright \
104 mdoc/deshallify.sh \
105 mdoc/example.1 \
106 mdoc/example.3 \
107 mdoc/example.4 \
108 mdoc/example.9 \
109 netgraph/ether.bridge \
110 netgraph/frame_relay \
111 netgraph/ngctl \
112 netgraph/raw \
113 netgraph/udp.tunnel \
114 netgraph/virtual.chain \
115 netgraph/virtual.lan \
116 perfmon/Makefile \
117 perfmon/README \
118 perfmon/perfmon.c \
119 ppi/Makefile \
120 ppi/ppilcd.c \
121 ppp/chap-auth \
122 ppp/login-auth \
123 ppp/ppp.conf.sample \
124 ppp/ppp.conf.span-isp \
125 ppp/ppp.conf.span-isp.working \
126 ppp/ppp.linkdown.sample \
127 ppp/ppp.linkdown.span-isp \
128 ppp/ppp.linkdown.span-isp.working \
129 ppp/ppp.linkup.sample \
130 ppp/ppp.linkup.span-isp \
131 ppp/ppp.linkup.span-isp.working \
132 ppp/ppp.secret.sample \
133 ppp/ppp.secret.span-isp \
134 ppp/ppp.secret.span-isp.working \
135 printing/README \
136 printing/diablo-if-net \
137 printing/hpdf \
138 printing/hpif \
139 printing/hpof \
140 printing/hprf \
141 printing/hpvf \
142 printing/if-simple \
143 printing/if-simpleX \
144 printing/ifhp \
145 printing/make-ps-header \
146 printing/netprint \
147 printing/psdf \
148 printing/psdfX \
149 printing/psif \
150 printing/pstf \
151 printing/pstfX \
152 ses/Makefile \
153 ses/Makefile.inc \
154 ses/getencstat/Makefile \
155 ses/getencstat/getencstat.0 \
156 ses/sesd/Makefile \
157 ses/sesd/sesd.0 \
158 ses/setencstat/Makefile \
159 ses/setencstat/setencstat.0 \
160 ses/setobjstat/Makefile \
161 ses/setobjstat/setobjstat.0 \
162 ses/srcs/chpmon.c \
163 ses/srcs/eltsub.c \
164 ses/srcs/eltsub.h \
165 ses/srcs/getencstat.c \
166 ses/srcs/getnobj.c \
167 ses/srcs/getobjmap.c \
168 ses/srcs/getobjstat.c \
169 ses/srcs/inienc.c \
170 ses/srcs/sesd.c \
171 ses/srcs/setencstat.c \
172 ses/srcs/setobjstat.c \
173 scsi_target/Makefile \
174 scsi_target/scsi_target.c \
175 scsi_target/scsi_target.h \
176 scsi_target/scsi_target.8 \
177 scsi_target/scsi_cmds.c \
178 sunrpc/Makefile \
179 sunrpc/dir/Makefile \
180 sunrpc/dir/dir.x \
181 sunrpc/dir/dir_proc.c \
182 sunrpc/dir/rls.c \
183 sunrpc/msg/Makefile \
184 sunrpc/msg/msg.x \
185 sunrpc/msg/msg_proc.c \
186 sunrpc/msg/printmsg.c \
187 sunrpc/msg/rprintmsg.c \
188 sunrpc/sort/Makefile \
189 sunrpc/sort/rsort.c \
190 sunrpc/sort/sort.x \
191 sunrpc/sort/sort_proc.c
192
193BINDIR= ${SHAREDIR}/examples
194
195NO_OBJ=
196
197.if ${MK_HAST} != "no"
198LDIRS+= hast
199XFILES+= hast/ucarp.sh \
200 hast/ucarp_down.sh \
201 hast/ucarp_up.sh \
202 hast/vip-down.sh \
203 hast/vip-up.sh
204.endif
205
206.if ${MACHINE_CPUARCH} == "amd64"
207.if ${MK_BHYVE} != "no"
208LDIRS+= bhyve
209XFILES+= bhyve/vmrun.sh
210.endif
211.endif
212
208# Define SHARED to indicate whether you want symbolic links to the system
209# source (``symlinks''), or a separate copy (``copies''); (latter useful
210# in environments where it's not possible to keep /sys publicly readable)
211SHARED?= copies
212
213beforeinstall: ${SHARED} etc-examples
214.ORDER: ${SHARED} etc-examples
215
216copies:
217.for i in ${LDIRS}
218 if [ -L ${DESTDIR}${BINDIR}/$i ]; then \
219 rm -f ${DESTDIR}${BINDIR}/$i; \
220 fi
221.endfor
222 mtree -deU ${MTREE_FOLLOWS_SYMLINKS} \
223 -f ${.CURDIR}/../../etc/mtree/BSD.usr.dist -p ${DESTDIR}/usr
224.for file in ${XFILES}
225 ${INSTALL} -o ${SHAREOWN} -g ${SHAREGRP} -m ${SHAREMODE} \
226 ${.CURDIR}/${file} ${DESTDIR}${BINDIR}/${file}
227.endfor
228
229symlinks:
230.for i in ${LDIRS}
231 rm -rf ${DESTDIR}${BINDIR}/$i
232 ln -s ${.CURDIR}/$i ${DESTDIR}${BINDIR}/$i
233.endfor
234
235etc-examples:
236.if ${SHARED} != "symlinks"
237 (cd ${.CURDIR}/../../etc; ${MAKE} etc-examples)
238.endif
239
240.if ${SHARED} != "symlinks"
241SUBDIR= smbfs
242.if ${MK_IPFILTER} != "no"
243SUBDIR+=ipfilter
244.endif
245.if ${MK_PF} != "no"
246SUBDIR+=pf
247.endif
248.if ${MK_DMAGENT} != "no"
249SUBDIR+=dma
250.endif
251.endif
252
253.if ${MK_TESTS} != "no"
254SUBDIR+=tests
255.endif
256
257.include <bsd.subdir.mk>
213# Define SHARED to indicate whether you want symbolic links to the system
214# source (``symlinks''), or a separate copy (``copies''); (latter useful
215# in environments where it's not possible to keep /sys publicly readable)
216SHARED?= copies
217
218beforeinstall: ${SHARED} etc-examples
219.ORDER: ${SHARED} etc-examples
220
221copies:
222.for i in ${LDIRS}
223 if [ -L ${DESTDIR}${BINDIR}/$i ]; then \
224 rm -f ${DESTDIR}${BINDIR}/$i; \
225 fi
226.endfor
227 mtree -deU ${MTREE_FOLLOWS_SYMLINKS} \
228 -f ${.CURDIR}/../../etc/mtree/BSD.usr.dist -p ${DESTDIR}/usr
229.for file in ${XFILES}
230 ${INSTALL} -o ${SHAREOWN} -g ${SHAREGRP} -m ${SHAREMODE} \
231 ${.CURDIR}/${file} ${DESTDIR}${BINDIR}/${file}
232.endfor
233
234symlinks:
235.for i in ${LDIRS}
236 rm -rf ${DESTDIR}${BINDIR}/$i
237 ln -s ${.CURDIR}/$i ${DESTDIR}${BINDIR}/$i
238.endfor
239
240etc-examples:
241.if ${SHARED} != "symlinks"
242 (cd ${.CURDIR}/../../etc; ${MAKE} etc-examples)
243.endif
244
245.if ${SHARED} != "symlinks"
246SUBDIR= smbfs
247.if ${MK_IPFILTER} != "no"
248SUBDIR+=ipfilter
249.endif
250.if ${MK_PF} != "no"
251SUBDIR+=pf
252.endif
253.if ${MK_DMAGENT} != "no"
254SUBDIR+=dma
255.endif
256.endif
257
258.if ${MK_TESTS} != "no"
259SUBDIR+=tests
260.endif
261
262.include <bsd.subdir.mk>