xref: /titanic_41/usr/src/cmd/krb5/kadmin/kclient/Makefile (revision b9175c69691c8949bec97fb8f689b7d1efdb05bb)
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 2008 Sun Microsystems, Inc.  All rights reserved.
22# Use is subject to license terms.
23#
24# ident	"%Z%%M%	%I%	%E% SMI"
25#
26# Makefile for Kerberos client-install utility.
27#
28
29PROG=		ksetpw \
30		kdyndns \
31		ksmb
32
33SHFILES=	kclient
34SECFILES=	pam_krb5_first \
35		pam_krb5_only \
36		pam_krb5_optional
37CLOBBERFILES=	$(SHFILES)
38
39KRB5SBINSHFILES=$(SHFILES:%=$(KRB5SBIN)/%)
40
41USRLIBSEC=	$(ROOT)/usr/lib/security
42SEC=		$(SECFILES:%=$(USRLIBSEC)/%)
43$(SEC):=	FILEMODE = $(LIBFILEMODE)
44
45KS_OBJS=	ksetpw.o
46KD_OBJS=	kdyndns.o
47KSMB_OBJS=	ksmb.o
48
49OBJS=		$(KS_OBJS) $(KD_OBJS) $(KSMB_OBJS)
50
51SSRCS=	kclient.sh
52SRCS=	$(OBJS:%.o=%.c)
53
54include ../../../Makefile.cmd
55include $(SRC)/lib/gss_mechs/mech_krb5/Makefile.mech_krb5
56
57POFILE=	$(SSRCS:%.sh=%.po)
58
59CPPFLAGS += -I$(SRC)/uts/common/gssapi/include \
60	-I$(SRC)/lib/krb5 -I$(SRC)/lib/gss_mechs/mech_krb5/include \
61	-I$(SRC)/uts/common/gssapi/include  \
62	-I$(SRC)/uts/common/gssapi/mechs/krb5/include
63
64ksetpw:=	LDFLAGS += $(KRUNPATH)
65kdyndns:=	LDFLAGS += -R/usr/lib/smbsrv
66ksmb:=		LDFLAGS += -R/usr/lib/smbsrv
67
68KS_LDLIBS =	$(LDLIBS) $(KMECHLIB)
69KD_LDLIBS =	$(LDLIBS) -L$(ROOT)/usr/lib/smbsrv -lsmbns
70KSMB_LDLIBS =	$(LDLIBS) -L$(ROOT)/usr/lib/smbsrv -lsmb
71
72.KEEP_STATE:
73
74all: $(PROG) $(SHFILES) $(SEC)
75
76install: all $(KRB5SBIN) $(KRB5SBINSHFILES) $(KRB5LIBSHFILES) $(KRB5LIBPROG)
77
78kdyndns:	$(KD_OBJS)
79	$(LINK.c) $(KD_OBJS) -o $@ $(KD_LDLIBS)
80	$(POST_PROCESS)
81
82ksmb:		$(KSMB_OBJS)
83	$(LINK.c) $(KSMB_OBJS) -o $@ $(KSMB_LDLIBS)
84	$(POST_PROCESS)
85
86ksetpw:		$(KS_OBJS)
87	$(LINK.c) $(KS_OBJS) -o $@ $(KS_LDLIBS)
88	$(POST_PROCESS)
89
90$(KRB5SBIN):
91	$(INS.dir)
92
93$(USRLIBSEC)/%: %
94	$(INS.file)
95
96clean:
97	$(RM) $(PROG) $(SHFILES)
98
99lint:	lint_SRCS
100
101include ../../../Makefile.targ
102