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