xref: /illumos-gate/usr/src/cmd/picl/plugins/sun4u/lw8/fruaccess/Makefile (revision f875b4ebb1dd9fdbeb043557cab38ab3bf7f6e01)
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
22#
23# Copyright 2006 Sun Microsystems, Inc.  All rights reserved.
24# Use is subject to license terms.
25#
26# ident	"%Z%%M%	%I%	%E% SMI"
27#
28
29include $(SRC)/Makefile.psm
30
31LIBRARY=	libfruaccess.a
32VERS=		.1
33
34OBJECTS=	libfruaccess.o
35
36# include library definitions
37include $(SRC)/lib/Makefile.lib
38
39ROOT_PLATFORM = $(USR_PLAT_DIR)/SUNW,Netra-T12
40
41include	$(SRC)/cmd/picl/plugins/Makefile.com
42
43CPPFLAGS +=	-D_REENTRANT
44CPPFLAGS +=	-I$(SRC)/uts/sun4u/ -I$(SRC)/uts/common/
45
46SRCS=		$(OBJECTS:%.o=%.c)
47
48LIBS =		$(DYNLIB)
49
50ROOTLIBDIR	= $(ROOT_PLAT_LIBDIR)
51ROOTLIBDIR	:= OWNER = root
52ROOTLIBDIR	:= GROUP = sys
53
54LINTSRC =	$(LINTLIB:%.ln=%)
55ROOTLINTDIR =	$(ROOTLIBDIR)
56ROOTLINT =	$(LINTSRC:%=$(ROOTLINTDIR)/%)
57
58CLEANFILES=	$(LINTOUT) $(LINTLIB)
59
60CFLAGS +=	$(CCVERBOSE)
61CPPFLAGS +=	-I$(SRC)/uts/sun4u/lw8
62CPPFLAGS +=	-I$(SRC)/cmd/picl/plugins/sun4u/lib/fruaccess
63DYNFLAGS +=	-R/usr/platform/\$$PLATFORM/lib/picl/plugins:/usr/platform/sun4u/lib/picl/plugins:/usr/lib/picl/plugins
64LDLIBS +=	-L$(SRC)/lib/libptree/$(MACH)
65LDLIBS +=	-L$(ROOT)/usr/lib/picl/plugins
66LDLIBS +=	-lc -lpicltree
67
68.KEEP_STATE:
69
70SUBDIRS=
71
72all :=		TARGET= all
73install :=	TARGET= install
74clean :=	TARGET= clean
75clobber :=	TARGET= clobber
76lint :=		TARGET= lint
77_msg :=		TARGET= _msg
78
79POFILE= libfruaccess.po
80
81all: $(LIBS) $(LIBLINKS)
82
83install:	$(ROOTLIBDIR) all  $(ROOTLIBS) $(ROOTLINKS)
84
85_msg:	$(MSGDOMAIN) $(POFILE)
86	$(RM) $(MSGDOMAIN)/$(POFILE)
87	$(CP) $(POFILE) $(MSGDOMAIN)/lw8_$(POFILE)
88
89$(MSGDOMAIN):
90	$(INS.dir)
91
92$(LIBLINKS):    FRC
93	rm -f $(LIBLINKS); ln -s $(DYNLIB) $(LIBLINKS)
94
95# include library targets
96include	$(SRC)/cmd/picl/plugins/Makefile.targ
97include $(SRC)/lib/Makefile.targ
98
99$(ROOTLINTDIR)/%: ../%
100	$(INS.file)
101
102lint :
103	$(LINT.c) $(SRCS)
104
105$(SUBDIRS): FRC
106	@cd $@; pwd; $(MAKE) $(TARGET)
107
108FRC:
109