xref: /titanic_41/usr/src/cmd/krb5/kadmin/cli/Makefile (revision 70025d765b044c6d8594bb965a2247a61e991a99)
1#
2# Copyright 2004 Sun Microsystems, Inc.  All rights reserved.
3# Use is subject to license terms.
4#
5# ident	"%Z%%M%	%I%	%E% SMI"
6#
7
8PROG= kadmin kadmin.local
9
10COMMON_OBJS   = kadmin.o kadmin_ct.o ss_wrapper.o getdate.o keytab.o
11RMT_OBJS= $(COMMON_OBJS) kadmin_rmt.o
12LOC_OBJS= $(COMMON_OBJS) kadmin_loc.o
13OBJS	= $(COMMON_OBJS) $(RMT_OBJS) $(LOC_OBJS)
14SRCS	= $(OBJS:.o=.c)
15
16include ../../../Makefile.cmd
17include $(SRC)/lib/gss_mechs/mech_krb5/Makefile.mech_krb5
18
19POFILE = kadmin.po
20POFILES = generic.po
21
22DEFS = -DHAVE_LIBSOCKET=1 -DHAVE_LIBNSL=1 -DHAVE_UNISTD_H=1 -DHAVE_SYS_TIMEB_H=1 \
23	-DHAVE_ALLOCA_H=1 -DHAVE_FTIME=1 -DHAVE_TIMEZONE
24
25CPPFLAGS += -I$(SRC)/uts/common/gssapi/include/ \
26		-I$(SRC)/uts/common/gssapi/mechs/krb5/include \
27		-I$(SRC)/uts/common/gssapi/include \
28		-I$(SRC)/cmd/krb5/iprop \
29		-I$(SRC)/lib/krb5 \
30		-I$(SRC)/lib/gss_mechs/mech_krb5/include $(DEFS)
31
32COPTFLAG += $(XESS) #-I$(KINCDIR)
33
34SHAREDLIBS = -lmech_krb5 -lss
35
36CLLIBS = $(LDLIBS) $(KRUNPATH) \
37	-L$(ROOT_KLIBDIR) -L$(KRB5LIB) $(SHAREDLIBS) -lkadm5clnt
38
39SRVLIBS = $(LDLIBS) $(KRUNPATH) \
40	-L$(ROOT_KLIBDIR) -L$(KRB5LIB) $(SHAREDLIBS) -lkadm5srv
41
42kadmin.local:=	DEFS += -D_KADMIN_LOCAL_
43
44.KEEP_STATE:
45
46all: $(PROG)
47
48kadmin:	$(RMT_OBJS)
49	$(LINK.c) $(RMT_OBJS) -o $@ $(CLLIBS)
50	$(POST_PROCESS)
51
52kadmin.local:	$(LOC_OBJS)
53	$(LINK.c) $(LOC_OBJS) -o $@ $(SRVLIBS)
54	$(POST_PROCESS)
55
56install: $(KRB5SBINPROG)
57
58clean:
59	$(RM) $(OBJS)
60
61lint: lint_SRCS
62
63include ../../../Makefile.targ
64
65$(POFILE): $(DERIVED_FILES) .WAIT $(POFILES)
66	$(RM) $@
67	$(CAT) $(POFILES) > $@
68
69generic.po: FRC
70	$(RM) messages.po
71	$(XGETTEXT) $(XGETFLAGS) `$(GREP) -l gettext *.[ch]`
72	$(SED) "/^domain/d" messages.po > $@
73	$(RM) messages.po
74
75FRC:
76