7712 mandoc -Tlint does always exit with error code 0
[unleashed.git] / usr / src / cmd / lvm / rpc.metamedd / Makefile.com
blob08d37bdbd21f8cb735a4f96e58fda7dc3c95981b
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
22 # Copyright 2007 Sun Microsystems, Inc.  All rights reserved.
23 # Use is subject to license terms.
25 # ident "%Z%%M% %I%     %E% SMI"
27 # Architecture independent makefile for rpc.metamedd
29 # cmd/lvm/rpc.metamedd/Makefile.com
31 PROG = rpc.metamedd 
33 RPC_DIR = $(SRC)/uts/common/sys/lvm
35 RPC_OBJS = \
36         meta_basic.x \
37         metamed.x \
38         meta_arr.x
40 DERIVED_OBJS = \
41         metamed_svc.o \
42         metamed_xdr.o \
43         meta_basic_xdr.o
45 LOCAL_OBJS= \
46         med_db.o \
47         med_error.o \
48         med_freeresult.o \
49         med_hash.o \
50         med_init.o \
51         med_mem.o \
52         med_synch.o \
53         med_svc_subr.o
55 LOCAL_SRCS   = $(LOCAL_OBJS:%.o=../%.c)
56 DERIVED_SRCS = $(DERIVED_OBJS:%.o=%.c)
58 include ../../../Makefile.cmd
59 include ../../Makefile.lvm
61 LDLIBS += -lmeta -lsocket -lnsl
62 LDFLAGS += $(ZINTERPOSE)
64 CPPFLAGS += $(DEFINES)
66 lint := LINTFLAGS += -m
68 metamed_svc.c := RPCGENFLAGS += -K -1
70 .KEEP_STATE:
72 %.o:    ../%.c
73         $(COMPILE.c) $<
74         $(POST_PROCESS_O)
76 all:    $(PROG)
78 $(PROG): $(LOCAL_OBJS) $(DERIVED_OBJS)
79         $(LINK.c) -o $@ $(LOCAL_OBJS) $(DERIVED_OBJS) $(LDLIBS)
80         $(POST_PROCESS)
82 install: all $(ROOTUSRSBINPROG)
84 cstyle:
85         $(CSTYLE) $(LOCAL_SRCS)
87 lint:
88         $(LINT.c) $(LINTFLAGS) $(LOCAL_SRCS)
90 clean:
91         $(RM) $(DERIVED_SRCS) $(DERIVED_OBJS) $(LOCAL_OBJS) $(RPC_OBJS)
93 clobber: clean
94         $(RM) $(PROG)
96 $(RPC_OBJS): $$(@:%=$(RPC_DIR)/%)
97         $(RM) $@
98         $(CP) $(RPC_DIR)/$@ .
100 meta_basic_xdr.c: meta_basic.x
101         $(RPCGEN) $(RPCGENFLAGS) -c meta_basic.x > $@
103 metamed_xdr.c: metamed.x meta_arr.x
104         $(RPCGEN) $(RPCGENFLAGS) -c metamed.x > $@
106 metamed_svc.c: metamed.x meta_arr.x
107         $(RPCGEN) $(RPCGENFLAGS_SERVER) metamed.x > $@