7857 zfs/zpool commands print scary errors after 7741
[unleashed.git] / usr / src / cmd / Makefile
blob1c5318893df84f7d5e9da0ff4e300eb61dc9119e
2 # CDDL HEADER START
4 # The contents of this file are subject to the terms of the
5 # Common Development and Distribution License (the "License").
6 # You may not use this file except in compliance with the License.
8 # You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
9 # or http://www.opensolaris.org/os/licensing.
10 # See the License for the specific language governing permissions
11 # and limitations under the License.
13 # When distributing Covered Code, include this CDDL HEADER in each
14 # file and include the License file at usr/src/OPENSOLARIS.LICENSE.
15 # If applicable, add the following below this CDDL HEADER, with the
16 # fields enclosed by brackets "[]" replaced with your own identifying
17 # information: Portions Copyright [yyyy] [name of copyright owner]
19 # CDDL HEADER END
23 # Copyright (c) 1989, 2010, Oracle and/or its affiliates. All rights reserved.
24 # Copyright 2016 Joyent, Inc.
25 # Copyright (c) 2012 by Delphix. All rights reserved.
26 # Copyright (c) 2013 DEY Storage Systems, Inc. All rights reserved.
27 # Copyright 2014 Garrett D'Amore <garrett@damore.org>
28 # Copyright 2016 Toomas Soome <tsoome@me.com>
29 # Copyright 2016 Nexenta Systems, Inc.
32 include ../Makefile.master
35 # Note that the commands 'lp', and 'perl' are first in
36 # the list, violating alphabetical order. This is because they are very
37 # long-running and should be given the most wall-clock time for a
38 # parallel build.
40 # Commands in the FIRST_SUBDIRS list are built before starting the build
41 # of other commands. Currently this includes only 'isaexec' and
42 # 'platexec'. This is necessary because $(ROOT)/usr/lib/isaexec or
43 # $(ROOT)/usr/lib/platexec must exist when some other commands are built
44 # because their 'make install' creates a hard link to one of them.
46 # Commands are listed one per line so that TeamWare can auto-merge most
47 # changes.
50 FIRST_SUBDIRS= \
51 isaexec \
52 platexec
54 COMMON_SUBDIRS= \
55 allocate \
56 availdevs \
57 lp \
58 perl \
59 Adm \
60 abi \
61 adbgen \
62 acct \
63 acctadm \
64 arch \
65 asa \
66 ast \
67 audio \
68 auths \
69 autopush \
70 avs \
71 awk \
72 awk_xpg4 \
73 backup \
74 banner \
75 bart \
76 basename \
77 bc \
78 bdiff \
79 beadm \
80 bnu \
81 boot \
82 busstat \
83 cal \
84 calendar \
85 captoinfo \
86 cat \
87 cdrw \
88 cfgadm \
89 checkeq \
90 checknr \
91 chgrp \
92 chmod \
93 chown \
94 chroot \
95 clear \
96 clinfo \
97 cmd-crypto \
98 cmd-inet \
99 col \
100 compress \
101 consadm \
102 coreadm \
103 cpio \
104 cpc \
105 cron \
106 crypt \
107 csh \
108 csplit \
109 ctrun \
110 ctstat \
111 ctwatch \
112 datadm \
113 date \
114 dc \
115 dd \
116 deroff \
117 devfsadm \
118 syseventd \
119 devctl \
120 devinfo \
121 devmgmt \
122 devprop \
123 dfs.cmds \
124 diff \
125 diff3 \
126 diffmk \
127 dircmp \
128 dirname \
129 dis \
130 diskinfo \
131 diskmgtd \
132 dispadmin \
133 dladm \
134 dlstat \
135 dmesg \
136 dodatadm \
137 dtrace \
138 du \
139 dumpadm \
140 dumpcs \
141 echo \
142 ed \
143 eeprom \
144 egrep \
145 eject \
146 emul64ioctl \
147 enhance \
148 env \
149 eqn \
150 expand \
151 expr \
152 exstr \
153 factor \
154 false \
155 fcinfo \
156 fcoesvc \
157 fdetach \
158 fdformat \
159 fdisk \
160 ficl \
161 filesync \
162 fgrep \
163 file \
164 find \
165 flowadm \
166 flowstat \
167 fm \
168 fmt \
169 fmthard \
170 fmtmsg \
171 fold \
172 format \
173 fs.d \
174 fstyp \
175 fuser \
176 fwflash \
177 gcore \
178 gencat \
179 geniconvtbl \
180 genmsg \
181 getconf \
182 getdevpolicy \
183 getent \
184 getfacl \
185 getmajor \
186 getopt \
187 gettext \
188 gettxt \
189 grep \
190 grep_xpg4 \
191 groups \
192 growfs \
193 grpck \
194 gss \
195 hal \
196 halt \
197 head \
198 hostid \
199 hostname \
200 hotplug \
201 hotplugd \
202 hwdata \
203 ibd_upgrade \
204 iconv \
205 id \
206 idmap \
207 infocmp \
208 init \
209 initpkg \
210 install.d \
211 intrd \
212 intrstat \
213 ipcrm \
214 ipcs \
215 ipdadm \
216 ipf \
217 isainfo \
218 isalist \
219 itutools \
220 iscsiadm \
221 iscsid \
222 iscsitsvc \
223 isns \
224 itadm \
225 kbd \
226 keyserv \
227 killall \
228 krb5 \
229 ksh \
230 kvmstat \
231 last \
232 lastcomm \
233 latencytop \
234 ldap \
235 ldapcachemgr \
236 lgrpinfo \
237 line \
238 link \
239 dlmgmtd \
240 listen \
241 loadkeys \
242 locale \
243 localedef \
244 lockstat \
245 locator \
246 lofiadm \
247 logadm \
248 logger \
249 login \
250 logins \
251 look \
252 ls \
253 luxadm \
254 mach \
255 mail \
256 mailwrapper \
257 mailx \
258 make \
259 makekey \
260 man \
261 mandoc \
262 mdb \
263 mesg \
264 mkdir \
265 mkfifo \
266 mkfile \
267 mkmsgs \
268 mknod \
269 mkpwdict \
270 mktemp \
271 modload \
272 more \
273 mpathadm \
274 msgfmt \
275 msgid \
276 mt \
277 mv \
278 mvdir \
279 ndmpadm \
280 ndmpd \
281 ndmpstat \
282 netadm \
283 netfiles \
284 newform \
285 newgrp \
286 news \
287 newtask \
288 nice \
289 nl \
290 nlsadmin \
291 nohup \
292 nsadmin \
293 nscd \
294 oamuser \
295 oawk \
296 od \
297 pack \
298 pagesize \
299 passmgmt \
300 passwd \
301 pathchk \
302 pbind \
303 pcidr \
304 pcitool \
305 pfexec \
306 pfexecd \
307 pginfo \
308 pgstat \
309 pgrep \
310 picl \
311 plimit \
312 policykit \
313 pools \
314 power \
315 powertop \
316 ppgsz \
317 pg \
318 plockstat \
319 pr \
320 prctl \
321 print \
322 printf \
323 priocntl \
324 profiles \
325 projadd \
326 projects \
327 prstat \
328 prtconf \
329 prtdiag \
330 prtvtoc \
331 ps \
332 psradm \
333 psrinfo \
334 psrset \
335 ptools \
336 pwck \
337 pwconv \
338 pwd \
339 pyzfs \
340 raidctl \
341 ramdiskadm \
342 rcap \
343 rcm_daemon \
344 rctladm \
345 refer \
346 regcmp \
347 renice \
348 rexd \
349 rm \
350 rmdir \
351 rmformat \
352 rmmount \
353 rmt \
354 rmvolmgr \
355 roles \
356 rpcbind \
357 rpcgen \
358 rpcinfo \
359 rpcsvc \
360 runat \
361 sa \
362 saf \
363 sasinfo \
364 savecore \
365 sbdadm \
366 script \
367 scsi \
368 sdiff \
369 sdpadm \
370 sed \
371 sendmail \
372 setfacl \
373 setmnt \
374 setpgrp \
375 setuname \
376 sgs \
377 sh \
378 shcomp \
379 smbios \
380 smbsrv \
381 smserverd \
382 soelim \
383 sort \
384 spell \
385 split \
386 sqlite \
387 srchtxt \
388 srptadm \
389 srptsvc \
390 ssh \
391 stat \
392 stmfadm \
393 stmfproxy \
394 stmfsvc \
395 stmsboot \
396 streams \
397 strings \
398 su \
399 sulogin \
400 sunpc \
401 svc \
402 svr4pkg \
403 swap \
404 sync \
405 sysdef \
406 syseventadm \
407 syslogd \
408 tabs \
409 tail \
410 tar \
411 tbl \
412 tcopy \
413 tcpd \
414 terminfo \
415 th_tools \
416 tic \
417 time \
418 tip \
419 tnf \
420 touch \
421 tput \
422 tr \
423 trapstat \
424 troff \
425 true \
426 truss \
427 tsol \
428 tty \
429 ttymon \
430 tzreload \
431 uadmin \
432 ul \
433 uname \
434 units \
435 unlink \
436 unpack \
437 userattr \
438 users \
439 utmp_update \
440 utmpd \
441 uuidgen \
442 valtools \
443 vgrind \
444 vi \
445 volcheck \
446 volrmmount \
447 vrrpadm \
448 vscan \
449 vt \
451 wall \
452 which \
453 who \
454 whodo \
455 wracct \
456 write \
457 xargs \
458 xstr \
459 yes \
460 ypcmd \
461 yppasswd \
462 zdb \
463 zdump \
464 zfs \
465 zhack \
466 zic \
467 zinject \
468 zlogin \
469 zoneadm \
470 zoneadmd \
471 zonecfg \
472 zonename \
473 zpool \
474 zlook \
475 zonestat \
476 zstreamdump \
477 ztest
479 i386_SUBDIRS= \
480 acpi \
481 acpihpd \
482 addbadsec \
483 biosdev \
484 diskscan \
485 lms \
486 rtc \
487 ucodeadm \
490 sparc_SUBDIRS= \
491 cvcd \
492 dcs \
493 device_remap \
494 drd \
495 fruadm \
496 ldmad \
497 oplhpd \
498 prtdscp \
499 prtfru \
500 scadm \
501 sckmd \
502 sf880drd \
503 virtinfo \
504 vntsd
507 # Commands that are messaged. Note that 'lp' comes first
508 # (see previous comment about 'lp'.)
510 MSGSUBDIRS= \
511 lp \
512 abi \
513 acctadm \
514 allocate \
515 asa \
516 audio \
517 audit \
518 auditconfig \
519 auditd \
520 auditrecord \
521 auditset \
522 auths \
523 autopush \
524 avs \
525 awk \
526 awk_xpg4 \
527 backup \
528 banner \
529 bart \
530 basename \
531 beadm \
532 bnu \
533 busstat \
534 cal \
535 cat \
536 cdrw \
537 cfgadm \
538 checkeq \
539 checknr \
540 chgrp \
541 chmod \
542 chown \
543 cmd-crypto \
544 cmd-inet \
545 col \
546 compress \
547 consadm \
548 coreadm \
549 cpio \
550 cpc \
551 cron \
552 csh \
553 csplit \
554 ctrun \
555 ctstat \
556 ctwatch \
557 datadm \
558 date \
559 dc \
560 dcs \
561 dd \
562 deroff \
563 devfsadm \
564 dfs.cmds \
565 diff \
566 diffmk \
567 dladm \
568 dlstat \
569 du \
570 dumpcs \
571 ed \
572 eject \
573 env \
574 eqn \
575 expand \
576 expr \
577 fcinfo \
578 fgrep \
579 file \
580 filesync \
581 find \
582 flowadm \
583 flowstat \
584 fm \
585 fold \
586 fs.d \
587 fwflash \
588 geniconvtbl \
589 genmsg \
590 getconf \
591 getent \
592 gettext \
593 gettxt \
594 grep \
595 grep_xpg4 \
596 grpck \
597 gss \
598 halt \
599 head \
600 hostname \
601 hotplug \
602 iconv \
603 id \
604 idmap \
605 isaexec \
606 iscsiadm \
607 iscsid \
608 isns \
609 itadm \
610 kbd \
611 krb5 \
612 ksh \
613 last \
614 ldap \
615 ldapcachemgr \
616 lgrpinfo \
617 locale \
618 lofiadm \
619 logadm \
620 logger \
621 logins \
622 ls \
623 luxadm \
624 mailx \
625 make \
626 man \
627 mesg \
628 mkdir \
629 mkpwdict \
630 mktemp \
631 more \
632 mpathadm \
633 msgfmt \
634 mv \
635 ndmpadm \
636 ndmpstat \
637 newgrp \
638 newtask \
639 nice \
640 nohup \
641 oawk \
642 pack \
643 passwd \
644 passmgmt \
645 pathchk \
646 pfexec \
647 pg \
648 pgrep \
649 picl \
650 pools \
651 power \
652 pr \
653 praudit \
654 print \
655 profiles \
656 projadd \
657 projects \
658 prstat \
659 prtdiag \
660 ps \
661 psrinfo \
662 ptools \
663 pwconv \
664 pwd \
665 pyzfs \
666 raidctl \
667 ramdiskadm \
668 rcap \
669 rcm_daemon \
670 refer \
671 regcmp \
672 renice \
673 roles \
674 rm \
675 rmdir \
676 rmformat \
677 rmmount \
678 rmvolmgr \
679 sasinfo \
680 sbdadm \
681 scadm \
682 script \
683 scsi \
684 sdiff \
685 sdpadm \
686 sgs \
687 sh \
688 shcomp \
689 smbsrv \
690 sort \
691 split \
692 srptadm \
693 stat \
694 stmfadm \
695 stmsboot \
696 strings \
697 su \
698 svc \
699 svr4pkg \
700 swap \
701 syseventadm \
702 syseventd \
703 tabs \
704 tar \
705 tbl \
706 time \
707 tnf \
708 touch \
709 tput \
710 troff \
711 tsol \
712 tty \
713 ttymon \
714 tzreload \
715 ul \
716 uname \
717 units \
718 unlink \
719 unpack \
720 userattr \
721 valtools \
722 vgrind \
723 vi \
724 volcheck \
725 volrmmount \
726 vrrpadm \
727 vscan \
729 who \
730 whodo \
731 wracct \
732 write \
733 xargs \
734 yppasswd \
735 zdump \
736 zfs \
737 zic \
738 zlogin \
739 zoneadm \
740 zoneadmd \
741 zonecfg \
742 zonename \
743 zpool \
744 zonestat
746 sparc_MSGSUBDIRS= \
747 fruadm \
748 prtdscp \
749 prtfru \
750 virtinfo \
751 vntsd
753 i386_MSGSUBDIRS= \
754 ucodeadm
757 # commands that use dcgettext for localized time, LC_TIME
759 DCSUBDIRS= \
760 cal \
761 cfgadm \
762 diff \
763 ls \
764 pr \
765 ps \
766 tar \
768 who \
769 whodo \
770 write
773 # commands that belong only to audit.
775 AUDITSUBDIRS= \
776 amt \
777 audit \
778 audit_warn \
779 auditconfig \
780 auditd \
781 auditrecord \
782 auditreduce \
783 auditset \
784 auditstat \
785 praudit
788 # commands not owned by the systems group
790 BWOSDIRS=
793 all := TARGET = all
794 install := TARGET = install
795 clean := TARGET = clean
796 clobber := TARGET = clobber
797 lint := TARGET = lint
798 _msg := TARGET = _msg
799 _dc := TARGET = _dc
801 .KEEP_STATE:
803 SUBDIRS = $(COMMON_SUBDIRS) $($(MACH)_SUBDIRS)
805 .PARALLEL: $(BWOSDIRS) $(SUBDIRS) $(MSGSUBDIRS) $(AUDITSUBDIRS)
807 all install clean clobber lint: $(FIRST_SUBDIRS) .WAIT $(SUBDIRS) \
808 $(AUDITSUBDIRS)
811 # Manifests cannot be checked in parallel, because we are using
812 # the global repository that is in $(SRC)/cmd/svc/seed/global.db.
813 # For this reason, to avoid .PARALLEL and .NO_PARALLEL conflicts,
814 # we spawn off a sub-make to perform the non-parallel 'make check'
816 check:
817 $(MAKE) -f Makefile.check check
820 # The .WAIT directive works around an apparent bug in parallel make.
821 # Evidently make was getting the target _msg vs. _dc confused under
822 # some level of parallelization, causing some of the _dc objects
823 # not to be built.
825 _msg: $(MSGSUBDIRS) $($(MACH)_MSGSUBDIRS) .WAIT _dc
827 _dc: $(DCSUBDIRS)
830 # Dependencies
832 fs.d: fstyp
833 ksh: shcomp isaexec
834 mdb: terminfo
835 print: lp
836 fmt: mailx
838 $(FIRST_SUBDIRS) $(BWOSDIRS) $(SUBDIRS) $(AUDITSUBDIRS): FRC
839 @if [ -f $@/Makefile ]; then \
840 cd $@; pwd; $(MAKE) $(TARGET); \
841 else \
842 true; \
845 FRC: