xref: /titanic_41/usr/src/cmd/krb5/kadmin/cli/Makefile (revision 7014882c6a3672fd0e5d60200af8643ae53c5928)
17c478bd9Sstevel@tonic-gate#
267e3a03eSrie# Copyright 2008 Sun Microsystems, Inc.  All rights reserved.
37c478bd9Sstevel@tonic-gate# Use is subject to license terms.
47c478bd9Sstevel@tonic-gate#
57c478bd9Sstevel@tonic-gate
67c478bd9Sstevel@tonic-gatePROG= kadmin kadmin.local
756a424ccSmp153739SHFILES= k5srvutil
856a424ccSmp153739CLOBBERFILES= $(SHFILES)
956a424ccSmp153739
1056a424ccSmp153739KRB5SBINSHFILES= $(SHFILES:%=$(KRB5SBIN)/%)
117c478bd9Sstevel@tonic-gate
127c478bd9Sstevel@tonic-gateCOMMON_OBJS   = kadmin.o kadmin_ct.o ss_wrapper.o getdate.o keytab.o
137c478bd9Sstevel@tonic-gateRMT_OBJS= $(COMMON_OBJS) kadmin_rmt.o
147c478bd9Sstevel@tonic-gateLOC_OBJS= $(COMMON_OBJS) kadmin_loc.o
157c478bd9Sstevel@tonic-gateOBJS	= $(COMMON_OBJS) $(RMT_OBJS) $(LOC_OBJS)
167c478bd9Sstevel@tonic-gateSRCS	= $(OBJS:.o=.c)
177c478bd9Sstevel@tonic-gate
187c478bd9Sstevel@tonic-gateinclude ../../../Makefile.cmd
197c478bd9Sstevel@tonic-gateinclude $(SRC)/lib/gss_mechs/mech_krb5/Makefile.mech_krb5
207c478bd9Sstevel@tonic-gate
2156a424ccSmp153739POFILE = generic.po
2256a424ccSmp153739POFILES = kadmin.po k5srvutil.po
237c478bd9Sstevel@tonic-gate
247c478bd9Sstevel@tonic-gateDEFS = -DHAVE_LIBSOCKET=1 -DHAVE_LIBNSL=1 -DHAVE_UNISTD_H=1 -DHAVE_SYS_TIMEB_H=1 \
257c478bd9Sstevel@tonic-gate	-DHAVE_ALLOCA_H=1 -DHAVE_FTIME=1 -DHAVE_TIMEZONE
267c478bd9Sstevel@tonic-gate
277c478bd9Sstevel@tonic-gateCPPFLAGS += -I$(SRC)/uts/common/gssapi/include/ \
287c478bd9Sstevel@tonic-gate		-I$(SRC)/uts/common/gssapi/mechs/krb5/include \
297c478bd9Sstevel@tonic-gate		-I$(SRC)/uts/common/gssapi/include \
307c478bd9Sstevel@tonic-gate		-I$(SRC)/cmd/krb5/iprop \
317c478bd9Sstevel@tonic-gate		-I$(SRC)/lib/krb5 \
327c478bd9Sstevel@tonic-gate		-I$(SRC)/lib/gss_mechs/mech_krb5/include $(DEFS)
337c478bd9Sstevel@tonic-gate
34*7014882cSRichard LoweCERRWARN += -_gcc=-Wno-implicit-function-declaration
35*7014882cSRichard LoweCERRWARN += -_gcc=-Wno-unused-label
36*7014882cSRichard LoweCERRWARN += -_gcc=-Wno-unused-function
37*7014882cSRichard LoweCERRWARN += -_gcc=-Wno-parentheses
38*7014882cSRichard LoweCERRWARN += -_gcc=-Wno-unused-variable
39*7014882cSRichard Lowe
407c478bd9Sstevel@tonic-gateCOPTFLAG += $(XESS) #-I$(KINCDIR)
417c478bd9Sstevel@tonic-gate
427c478bd9Sstevel@tonic-gateSHAREDLIBS = -lmech_krb5 -lss
437c478bd9Sstevel@tonic-gate
4467e3a03eSrieCLLIBS = $(LDLIBS) $(KRUNPATH) $(KERBRUNPATH) \
457c478bd9Sstevel@tonic-gate	-L$(ROOT_KLIBDIR) -L$(KRB5LIB) $(SHAREDLIBS) -lkadm5clnt
467c478bd9Sstevel@tonic-gate
4767e3a03eSrieSRVLIBS = $(LDLIBS) $(KRUNPATH) $(KERBRUNPATH) \
487c478bd9Sstevel@tonic-gate	-L$(ROOT_KLIBDIR) -L$(KRB5LIB) $(SHAREDLIBS) -lkadm5srv
497c478bd9Sstevel@tonic-gate
507c478bd9Sstevel@tonic-gatekadmin.local:=	DEFS += -D_KADMIN_LOCAL_
517c478bd9Sstevel@tonic-gate
527c478bd9Sstevel@tonic-gate.KEEP_STATE:
537c478bd9Sstevel@tonic-gate
5456a424ccSmp153739all: $(PROG) $(SHFILES)
557c478bd9Sstevel@tonic-gate
567c478bd9Sstevel@tonic-gatekadmin:	$(RMT_OBJS)
577c478bd9Sstevel@tonic-gate	$(LINK.c) $(RMT_OBJS) -o $@ $(CLLIBS)
587c478bd9Sstevel@tonic-gate	$(POST_PROCESS)
597c478bd9Sstevel@tonic-gate
607c478bd9Sstevel@tonic-gatekadmin.local:	$(LOC_OBJS)
617c478bd9Sstevel@tonic-gate	$(LINK.c) $(LOC_OBJS) -o $@ $(SRVLIBS)
627c478bd9Sstevel@tonic-gate	$(POST_PROCESS)
637c478bd9Sstevel@tonic-gate
6456a424ccSmp153739$(SHFILES): $(SHFILES).sh
6556a424ccSmp153739	$(RM) $(SHFILES)
6656a424ccSmp153739	$(CP) $(SHFILES).sh $(SHFILES)
6756a424ccSmp153739
6856a424ccSmp153739install: $(KRB5SBINPROG) $(KRB5SBINSHFILES)
697c478bd9Sstevel@tonic-gate
707c478bd9Sstevel@tonic-gateclean:
717c478bd9Sstevel@tonic-gate	$(RM) $(OBJS)
727c478bd9Sstevel@tonic-gate
737c478bd9Sstevel@tonic-gatelint: lint_SRCS
747c478bd9Sstevel@tonic-gate
757c478bd9Sstevel@tonic-gateinclude ../../../Makefile.targ
767c478bd9Sstevel@tonic-gate
777c478bd9Sstevel@tonic-gate$(POFILE): $(DERIVED_FILES) .WAIT $(POFILES)
787c478bd9Sstevel@tonic-gate	$(RM) $@
797c478bd9Sstevel@tonic-gate	$(CAT) $(POFILES) > $@
807c478bd9Sstevel@tonic-gate
8156a424ccSmp153739kadmin.po: FRC
827c478bd9Sstevel@tonic-gate	$(RM) messages.po
837c478bd9Sstevel@tonic-gate	$(XGETTEXT) $(XGETFLAGS) `$(GREP) -l gettext *.[ch]`
847c478bd9Sstevel@tonic-gate	$(SED) "/^domain/d" messages.po > $@
857c478bd9Sstevel@tonic-gate	$(RM) messages.po
867c478bd9Sstevel@tonic-gate
877c478bd9Sstevel@tonic-gateFRC:
88