xref: /illumos-gate/usr/src/cmd/picl/plugins/sun4u/psvc/psvcobj/Makefile (revision 8226594fdd4479be135127f43632f1f995074654)
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
27LIBRARY=	libpsvcobj.a
28VERS=		.1
29
30OBJECTS=	psvcobj.o
31
32# include library definitions
33include $(SRC)/lib/Makefile.lib
34include $(SRC)/Makefile.psm
35
36include $(SRC)/cmd/picl/plugins/Makefile.com
37
38SRCS=		$(OBJECTS:%.o=%.c)
39
40LIBS =		$(DYNLIB)
41
42PLATFORM = sun4u
43
44USR_PLAT_PSVCOBJ = $(LIBS:%=$(USR_PSM_LIB_DIR)/%)
45
46CPPFLAGS +=	-I$(SRC)/uts/sun4u -I.
47
48CFLAGS +=	$(CCVERBOSE)
49LDLIBS +=	-L$(SRC)/lib/libdevfsevent
50LDLIBS +=	-lc
51
52# definitions for install_h target
53HDRS=		psvc_objects.h
54PLATHDRS=	$(HDRS:%=$(USR_PSM_INCL_DIR)/%)
55CHECKHDRS=	$(HDRS:%.h=%.check)
56
57.KEEP_STATE:
58
59SUBDIRS=
60
61POFILE=	psvcobj.po
62
63all :=		TARGET= all
64install :=	TARGET= install
65clean :=	TARGET= clean
66clobber :=	TARGET= clobber
67_msg :=		TARGET= _msg
68
69all: $(LIBS) $(LIBLINKS)
70
71install:	all $(USR_PSM_LIB_DIR) $(USR_PLAT_PSVCOBJ)
72
73install_h:	$(USR_PSM_INCL_DIR) $(PLATHDRS)
74
75$(LIBLINKS):	FRC
76	$(RM) $(LIBLINKS); $(SYMLINK) $(DYNLIB) $(LIBLINKS)
77
78_msg:	$(POFILE)
79
80# include library targets
81include $(SRC)/cmd/picl/plugins/Makefile.targ
82include $(SRC)/lib/Makefile.targ
83
84$(USR_PSM_LIB_DIR):	FRC
85	$(INS.dir)
86
87$(USR_PSM_INCL_DIR)/%: %
88	$(INS.file)
89
90$(USR_PSM_LIB_DIR)/%: % $(USR_PSM_LIB_DIR)
91	$(INS.file) ;\
92	$(RM) -r $(USR_PSM_LIB_DIR)/libpsvcobj.so; \
93	$(SYMLINK) ./libpsvcobj.so$(VERS) $(USR_PSM_LIB_DIR)/libpsvcobj.so
94
95lint :
96
97$(SUBDIRS): FRC
98	@cd $@; pwd; $(MAKE) $(TARGET)
99
100FRC:
101