xref: /titanic_50/usr/src/cmd/picl/plugins/sun4u/frudata/Makefile (revision da6c28aaf62fa55f0fdb8004aa40f88f23bf53f0)
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, Version 1.0 only
6# (the "License").  You may not use this file except in compliance
7# with the License.
8#
9# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
10# or http://www.opensolaris.org/os/licensing.
11# See the License for the specific language governing permissions
12# and limitations under the License.
13#
14# When distributing Covered Code, include this CDDL HEADER in each
15# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
16# If applicable, add the following below this CDDL HEADER, with the
17# fields enclosed by brackets "[]" replaced with your own identifying
18# information: Portions Copyright [yyyy] [name of copyright owner]
19#
20# CDDL HEADER END
21#
22#
23# Copyright 2004 Sun Microsystems, Inc.  All rights reserved.
24# Use is subject to license terms.
25#
26# ident	"%Z%%M%	%I%	%E% SMI"
27#
28
29LIBRARY=	libpiclfrudata.a
30VERS=		.1
31OBJECTS=	fru_data.o
32
33# include library definitions
34include $(SRC)/Makefile.psm
35include $(SRC)/lib/Makefile.lib
36
37ROOT_PLATFORM =	$(USR_PLAT_DIR)/sun4u
38
39include $(SRC)/cmd/picl/plugins/Makefile.com
40
41LIBLINKS=	libpiclfrudata.so
42
43SRCS=		$(OBJECTS:%.o=%.c)
44
45LIBS =		$(DYNLIB)
46
47ROOTLIBDIR =	$(ROOT_PLAT_PLUGINDIR)
48ROOTLIBDIR      := OWNER = root
49ROOTLIBDIR      := GROUP = sys
50
51CLEANFILES=	$(LINTOUT) $(LINTLIB)
52CLOBBERFILES += $(LIBLINKS)
53CSTYLE	=	cstyle -p -P
54HDRCHK	=	hdrchk
55
56
57CPPFLAGS +=	-I$(SRC)/lib/libfru/include -I../lib/fruaccess
58CPPFLAGS +=	-I$(SRC)/cmd/picl/plugins/lib/picld_pluginutil
59CPPFLAGS +=	-I$(SRC)/lib/libfruutils/
60CFLAGS +=	$(CCVERBOSE)
61LDLIBS +=	-L$(SRC)/cmd/picl/plugins/sun4u/lib/fruaccess
62LDLIBS +=	-L$(SRC)/lib/libfruutils/$(MACH)
63LDLIBS +=	-L$(SRC)/cmd/picl/plugins/common/frutree
64LDLIBS +=	-L$(ROOT)/usr/lib/picl/plugins
65LDLIBS +=	-lc -lnvpair -lfruutils
66LDLIBS +=	-lpicltree -lpiclfrutree -lfruaccess -lpicld_pluginutil
67LDLIBS +=	-R/usr/platform/\$$PLATFORM/lib/picl/plugins:/usr/platform/\$$PLATFORM/lib:/usr/platform/sun4u/lib/picl/plugins:/usr/lib/picl/plugins:/usr/platform/sun4u/lib
68.KEEP_STATE:
69
70
71SUBDIRS=
72
73all :=		TARGET= all
74install :=	TARGET= install
75clean :=	TARGET= clean
76clobber :=	TARGET= clobber
77lint :=		TARGET= lint
78_msg :=		TARGET= _msg
79
80POFILE=		$(LIBRARY:.a=.po)
81POFILES=	frudata.po
82
83all:  $(LIBS) $(LIBLINKS) $(CONF)
84
85install:	$(ROOTLIBDIR) all $(ROOTLIBS) $(ROOTLINKS)
86
87check-style :
88	$(CSTYLE) *.c *.h
89	$(HDRCHK) *.h
90
91_msg:	$(MSGDOMAIN) $(POFILE)
92	$(RM) $(MSGDOMAIN)/$(POFILE)
93	$(CP) $(POFILE) $(MSGDOMAIN)
94
95$(MSGDOMAIN):
96	$(INS.dir)
97
98$(POFILE): .WAIT $(POFILES)
99	$(RM) $@
100	$(CAT) $(POFILES) > $@
101
102$(POFILES):
103	$(RM) messages.po
104	$(XGETTEXT) $(XGETFLAGS) *.[ch]* */*.[ch]*
105	$(SED) -e '/^# msg/d' -e '/^domain/d' messages.po > $@
106	$(RM) messages.po
107
108$(LIBLINKS):	FRC
109	$(RM) $@; $(SYMLINK) $(DYNLIB) $@
110
111# include library targets
112include $(SRC)/cmd/picl/plugins/Makefile.targ
113include $(SRC)/lib/Makefile.targ
114
115lint :
116	$(LINT.c) $(SRCS)
117
118$(SUBDIRS): FRC
119	@cd $@; pwd; $(MAKE) $(TARGET)
120
121FRC:
122