xref: /illumos-gate/usr/src/cmd/sgs/link_audit/Makefile (revision 689b9301078f0c35c7f198fcee8032a0d30eff3a)
1#
2# CDDL HEADER START
3#
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.
7#
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.
12#
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]
18#
19# CDDL HEADER END
20#
21# Copyright 2009 Sun Microsystems, Inc.  All rights reserved.
22# Use is subject to license terms.
23#
24# Copyright 2019 OmniOS Community Edition (OmniOSce) Association.
25#
26
27include		../../../Makefile.master
28
29ROOTDEMODIRBASE=	$(ROOT)/usr/demo/link_audit
30
31DEMOFILES= \
32		00README \
33		Makefile \
34		man/perfcnt.man \
35		man/symbindrep.man \
36		man/dumpbind.man \
37		src/bindings.c \
38		src/bindings.h \
39		src/dumpbind.c \
40		src/env.c \
41		src/env.h \
42		src/hash.c \
43		src/hash.h \
44		src/sotruss.ksh \
45		src/mach.h \
46		src/perfcnt.c \
47		src/perfcnt.ksh \
48		src/symbindrep.c \
49		src/symbindrep.ksh \
50		src/truss.c \
51		src/who.c \
52		src/who.h \
53		src/whocalls.ksh
54
55ROOTDEMODIRS=	$(ROOTDEMODIRBASE) .WAIT \
56		$(ROOTDEMODIRBASE)/man \
57		$(ROOTDEMODIRBASE)/src
58
59ROOTDEMOFILES=	$(DEMOFILES:%=$(ROOTDEMODIRBASE)/%)
60
61$(ROOTDEMODIRS) :=	DIRMODE =	755
62
63
64
65SUBDIRS=	$(MACH)
66
67all:=		TARGET=	all
68install:=	TARGET=	install
69clean:=		TARGET=	clean
70clobber:=	TARGET=	clobber
71
72.PARALLEL: $(ROOTDEMOFILES)
73
74.KEEP_STATE:
75
76all clean clobber: $(SUBDIRS)
77
78install: $(ROOTDEMODIRS) .WAIT $(SUBDIRS) $(ROOTDEMOFILES)
79
80$(SUBDIRS):	FRC
81		@cd $@; pwd; $(MAKE) $(TARGET)
82		@if [ -d $(MACH64) ]; then                      \
83			cd $(MACH64); pwd; $(MAKE) $(TARGET);   \
84		else /bin/true; fi
85
86$(ROOTDEMODIRS):
87	$(INS.dir)
88
89$(ROOTDEMODIRBASE)/man/%: man/%
90	$(INS.file)
91
92$(ROOTDEMODIRBASE)/src/%: common/%
93	$(INS.file)
94
95$(ROOTDEMODIRBASE)/%: common/%
96	$(INS.file)
97
98$(ROOTDEMODIRBASE)/%: common/%.demo
99	$(INS.rename)
100
101FRC:
102