MY_SUBDIRS=util include lib @krb524@ kdc kadmin slave clients appl tests \
config-files gen-manpages
BUILDTOP=$(REL)$(C)
-CFLAGS = $(CCOPTS) $(DEFS)
-
-##DOS##BUILDTOP = .
+LOCALINCLUDES = -I$(srcdir)
SRCS =
HDRS =
all-mac::
-all-windows:: Makefile-windows
- @echo Making in util\windows
- cd util\windows
- -$(MAKE) -$(MAKEFLAGS)
+all-windows:: maybe-awk Makefile-windows
+ @echo Making in util
+ cd util
+ $(MAKE) -$(MFLAGS)
@echo Making in include
- cd ..\..\include
- -$(MAKE) -$(MAKEFLAGS)
- @echo Making in util\et
- cd ..\util\et
- -$(MAKE) -$(MAKEFLAGS)
- @echo Making in util\profile
- cd ..\profile
- -$(MAKE) -$(MAKEFLAGS)
+ cd ..\include
+ $(MAKE) -$(MFLAGS)
@echo Making in lib
- cd ..\..\lib
- -$(MAKE) -$(MAKEFLAGS)
+ cd ..\lib
+ $(MAKE) -$(MFLAGS)
@echo Making in windows
cd ..\windows
- -$(MAKE) -$(MAKEFLAGS)
+ $(MAKE) -$(MFLAGS)
@echo Making in clients
cd ..\clients
- -$(MAKE) -$(MAKEFLAGS)
- cd ..
+ $(MAKE) -$(MFLAGS)
+ @echo Making in appl\gss-sample
+ cd ..\appl\gss-sample
+ $(MAKE) -$(MFLAGS)
+ cd ..\..
world::
date
install-mkdirs:
@for i in $(INSTALLMKDIRS); do \
- if test -d $(DESTDIR)$$i; then :; else (set -x; mkdir -p $(DESTDIR)$$i); fi ; \
+ $(srcdir)/config/mkinstalldirs $(DESTDIR)$$i; \
done
# install::
# $(MAKE) $(MFLAGS) install.man
-.c.o:
- $(CC) -c $(CPPFLAGS) $(DEFS) -I$(srcdir) $(CFLAGS) $<
-
TAGS: $(SRCS)
etags $(SRCS)
#
config-windows:: Makefile-windows
- @echo Making in include
- cd include
- -$(MAKE) -$(MAKEFLAGS)
- cd ..
+# @echo Making in include
+# cd include
+# $(MAKE) -$(MFLAGS)
+# cd ..
-##DOS##WCONFIG_EXE=.\$(OUTPRE)wconfig.exe
-##DOS##WCONFIG_OBJ=$(OUTPRE)wconfig.obj
-
-##DOS##$(WCONFIG_EXE): $(OUTPRE) wconfig.c
+#
+# We need outpre-dir explicitly in here because we may
+# try to build wconfig on a config-windows.
+#
+##DOS##$(WCONFIG_EXE): outpre-dir wconfig.c
##DOS## $(CC) -Fe$@ -Fo$*.obj wconfig.c
-##DOS##MKFDEP= $(WCONFIG_EXE) config\pre.in config\post.in \
-##DOS## config\windows.in config\win-post.in
-##DOS##WCONFIG= $(WCONFIG_EXE) $(WCONFIG_FLAGS)
+##DOS##MKFDEP=$(WCONFIG_EXE) config\win-pre.in config\win-post.in
WINMAKEFILES=Makefile \
+ appl\gss-sample\Makefile \
clients\Makefile clients\kdestroy\Makefile \
clients\kinit\Makefile clients\klist\Makefile \
+ clients\kpasswd\Makefile clients\kvno\Makefile \
include\Makefile include\krb5\Makefile \
lib\Makefile lib\crypto\Makefile \
lib\crypto\crc32\Makefile lib\crypto\des\Makefile \
lib\krb5\ccache\ccapi\Makefile \
lib\krb5\error_tables\Makefile \
lib\krb5\keytab\Makefile \
- lib\krb5\keytab\file\Makefile lib\krb5\krb\Makefile \
+ lib\krb5\keytab\file\Makefile \
+ lib\krb5\keytab\srvtab\Makefile \
+ lib\krb5\krb\Makefile \
lib\krb5\os\Makefile lib\krb5\posix\Makefile \
lib\krb5\rcache\Makefile \
+ util\Makefile \
util\et\Makefile util\profile\Makefile \
util\windows\Makefile \
windows\Makefile windows\lib\Makefile \
windows\gss\Makefile windows\wintel\Makefile
##DOS##Makefile-windows:: $(MKFDEP) $(WINMAKEFILES)
-##DOS## config\rm.bat $(WCONFIG_OBJ)
##DOS##Makefile: Makefile.in $(MKFDEP)
##DOS## $(WCONFIG) config < $@.in > $@
+##DOS##appl\gss-sample\Makefile: appl\gss-sample\Makefile.in $(MKFDEP)
+##DOS## $(WCONFIG) config < $@.in > $@
##DOS##clients\Makefile: clients\Makefile.in $(MKFDEP)
##DOS## $(WCONFIG) config < $@.in > $@
##DOS##clients\kdestroy\Makefile: clients\kdestroy\Makefile.in $(MKFDEP)
##DOS## $(WCONFIG) config < $@.in > $@
##DOS##clients\klist\Makefile: clients\klist\Makefile.in $(MKFDEP)
##DOS## $(WCONFIG) config < $@.in > $@
+##DOS##clients\kpasswd\Makefile: clients\kpasswd\Makefile.in $(MKFDEP)
+##DOS## $(WCONFIG) config < $@.in > $@
+##DOS##clients\kvno\Makefile: clients\kvno\Makefile.in $(MKFDEP)
+##DOS## $(WCONFIG) config < $@.in > $@
##DOS##include\Makefile: include\Makefile.in $(MKFDEP)
##DOS## $(WCONFIG) config < $@.in > $@
##DOS##include\krb5\Makefile: include\krb5\Makefile.in $(MKFDEP)
##DOS## $(WCONFIG) config < $@.in > $@
##DOS##lib\krb5\error_tables\Makefile: lib\krb5\error_tables\Makefile.in $(MKFDEP)
##DOS## $(WCONFIG) config < $@.in > $@
-##DOS##lib\krb5\keytab\Makefile: lib\krb5\keytab\Makefile.in $(MKFDEP)
+##DOS##lib\krb5\keytab\Makefile: $$@.in $(MKFDEP)
##DOS## $(WCONFIG) config < $@.in > $@
-##DOS##lib\krb5\keytab\file\Makefile: lib\krb5\keytab\file\Makefile.in $(MKFDEP)
+##DOS##lib\krb5\keytab\file\Makefile: $$@.in $(MKFDEP)
+##DOS## $(WCONFIG) config < $@.in > $@
+##DOS##lib\krb5\keytab\srvtab\Makefile: $$@.in $(MKFDEP)
##DOS## $(WCONFIG) config < $@.in > $@
##DOS##lib\krb5\krb\Makefile: lib\krb5\krb\Makefile.in $(MKFDEP)
##DOS## $(WCONFIG) config < $@.in > $@
##DOS## $(WCONFIG) config < $@.in > $@
##DOS##lib\krb5\rcache\Makefile: lib\krb5\rcache\Makefile.in $(MKFDEP)
##DOS## $(WCONFIG) config < $@.in > $@
+##DOS##util\Makefile: util\Makefile.in $(MKFDEP)
+##DOS## $(WCONFIG) config < $@.in > $@
##DOS##util\et\Makefile: util\et\Makefile.in $(MKFDEP)
##DOS## $(WCONFIG) config < $@.in > $@
##DOS##util\profile\Makefile: util\profile\Makefile.in $(MKFDEP)
##DOS## $(WCONFIG) config < $@.in > $@
##DOS##util\windows\Makefile: util\windows\Makefile.in $(MKFDEP)
##DOS## $(WCONFIG) config < $@.in > $@
-##DOS##windows\Makefile: windows\Makefile.in $(MKFDEP)
+##DOS##windows\Makefile: windows\Makefile.in $(MKFDEP)
##DOS## $(WCONFIG) config < $@.in > $@
-##DOS##windows\lib\Makefile: windows\lib\Makefile.in $(MKFDEP)
+##DOS##windows\lib\Makefile: windows\lib\Makefile.in $(MKFDEP)
##DOS## $(WCONFIG) config < $@.in > $@
-##DOS##windows\cns\Makefile: windows\cns\Makefile.in $(MKFDEP)
+##DOS##windows\cns\Makefile: windows\cns\Makefile.in $(MKFDEP)
##DOS## $(WCONFIG) config < $@.in > $@
-##DOS##windows\gina\Makefile: windows\gina\Makefile.in $(MKFDEP)
+##DOS##windows\gina\Makefile: windows\gina\Makefile.in $(MKFDEP)
##DOS## $(WCONFIG) config < $@.in > $@
-##DOS##windows\gss\Makefile: windows\gss\Makefile.in $(MKFDEP)
+##DOS##windows\gss\Makefile: windows\gss\Makefile.in $(MKFDEP)
##DOS## $(WCONFIG) config < $@.in > $@
-##DOS##windows\wintel\Makefile: windows\wintel\Makefile.in $(MKFDEP)
+##DOS##windows\wintel\Makefile: windows\wintel\Makefile.in $(MKFDEP)
##DOS## $(WCONFIG) config < $@.in > $@
clean-windows:: Makefile-windows
- @echo Making clean in util\windows
- cd util\windows
- -$(MAKE) -$(MAKEFLAGS) clean
+ @echo Making clean in util
+ cd util
+ $(MAKE) -$(MFLAGS) clean
@echo Making clean in include
- cd ..\..\include
- -$(MAKE) -$(MAKEFLAGS) clean
- @echo Making clean in util\et
- cd ..\util\et
- -$(MAKE) -$(MAKEFLAGS) clean
- @echo Making clean in util\profile
- cd ..\profile
- -$(MAKE) -$(MAKEFLAGS) clean
+ cd ..\include
+ $(MAKE) -$(MFLAGS) clean
@echo Making clean in lib
- cd ..\..\lib
- -$(MAKE) -$(MAKEFLAGS) clean
+ cd ..\lib
+ $(MAKE) -$(MFLAGS) clean
@echo Making clean in windows
cd ..\windows
- -$(MAKE) -$(MAKEFLAGS) clean
+ $(MAKE) -$(MFLAGS) clean
@echo Making clean in clients
cd ..\clients
- -$(MAKE) -$(MAKEFLAGS) clean
- cd ..
+ $(MAKE) -$(MFLAGS) clean
+ @echo Making in appl\gss-sample
+ cd ..\appl\gss-sample
+ $(MAKE) -$(MFLAGS) clean
+ cd ..\..
@echo Making clean in root
- config\rm.bat $(WCONFIG_OBJ) $(WCONFIG_EXE)
#
# Renames DOS 8.3 filenames back to their proper, longer names.
ZIP=zip
FILES= ./* \
clients/* clients/kdestroy/* clients/kinit/* clients/klist/* \
+ clients/kpasswd/* \
config/* include/* include/kerberosIV/* \
include/krb5/* include/krb5/stock/* include/sys/* lib/* \
lib/crypto/* lib/crypto/crc32/* lib/crypto/des/* lib/crypto/dk/* \
lib/krb5/ccache/* lib/krb5/ccache/file/* lib/krb5/ccache/memory/* \
lib/krb5/ccache/stdio/* lib/krb5/ccache/ccapi/* \
lib/krb5/error_tables/* \
- lib/krb5/keytab/* lib/krb5/keytab/file/* \
+ lib/krb5/keytab/* lib/krb5/keytab/file/* lib/krb5/keytab/srvtab/* \
lib/krb5/os/* lib/krb5/posix/* lib/krb5/rcache/* \
- util/et/* util/profile/*
+ util/* util/et/* util/profile/*
WINFILES= util/windows/* windows/* windows/lib/* windows/cns/* \
windows/wintel/* windows/gss/* windows/gina/*
-MACFILES= mac/* mac/kconfig/* mac/libraries/* config/* include/* \
+MACFILES= mac/* mac/libraries/* config/* include/* \
include/krb5/* include/krb5/stock/* include/sys/* \
./patchlevel.h
-MITWINFILES= mit/windows/include/*
-MITWINBINARYFILES= mit/windows/lib/*
-
WINBINARYFILES= windows/*/*.ico windows/*/*.doc windows/*/*.hlp \
windows/*/*.hpj windows/lib/*.lib
winfile.list:
echo $(FILES) $(WINFILES) | tr ' ' \\012 | \
sed -f config/winexclude.sed > winfile.list
- if test -d mit ; then \
- echo $(MITWINFILES) | tr ' ' \\012 | \
- sed -f config/winexclude.sed >> winfile.list ; \
- fi
MAC_SUBDIRS = lib util
macfile.list:
sed -f config/winexclude.sed >> macfile.list
dos-Makefile:
- cat config/windows.in Makefile.in config/win-post.in | \
- sed -e "s/^##DOS##//" -e "s/^##DOS//" > Makefile
+ cat config/win-pre.in Makefile.in config/win-post.in | \
+ sed -e "s/^##DOS##//" -e "s/^##DOS//" > Makefile.tmp
+ mv Makefile.tmp Makefile
prep-windows: dos-Makefile awk-windows-mac
-# Not supported....
-krbsrc83.zip: dos-Makefile awk-windows-mac winfile.list
- rm -f krbsrc83.zip
- $(ZIP) -@Dlk krbsrc83.zip < winfile.list
- $(ZIP) -Dk krbsrc83.zip $(WINBINARYFILES)
- if test -d mit ; then \
- $(ZIP) -rDk krbsrc83.zip $(MITWINBINARYFILES) ; \
- fi
- rm -f $(CLEANUP)
+krbsrc83.zip: krbsrc83-is-obsolete
+
+krbsrc83-is-obsolete:
+ @echo "Win16 and krbsrc83.zip are no longer supported."
+ @echo "We don't support building under 8.3 restricted filesystems"
+ @echo "anymore. You can still build for Win32 on filesystems"
+ @echo "without 8.3 restrictions using kerbsrc.zip"
+ @echo " "
kerbsrc.zip: dos-Makefile awk-windows-mac winfile.list
rm -f kerbsrc.zip
$(ZIP) -@Dl kerbsrc.zip < winfile.list
$(ZIP) -D kerbsrc.zip $(WINBINARYFILES)
- if test -d mit ; then \
- $(ZIP) -rD kerbsrc.zip $(MITWINBINARYFILES) ; \
- fi
rm -f $(CLEANUP)
kerbsrc-nt.zip: kerbsrc-nt-is-obsolete
kerbsrc-nt-is-obsolete:
- @echo "Kerbsrc-nt.zip is now obsolete. Just use and build kerbsrc.zip"
+ @echo "kerbsrc-nt.zip is now obsolete. Just use and build kerbsrc.zip"
@echo "We don't support building under 8.3 restricted filesystems"
@echo "anymore, so what was kerbsrc-nt.zip is now kerbsrc.zip."
@echo " "
awk-windows-mac: $(ETOUT) $(HOUT)
+#
+# The maybe-awk target needs to happen after AWK is defined.
+#
+
+##DOS##maybe-awk::
+##DOS##!ifdef WHICH_CMD
+##DOS##!if ![ $(WHICH_CMD) $(AWK) ]
+##DOS##maybe-awk:: awk-windows-mac
+##DOS##!endif
+##DOS##!endif
+
clean-windows-mac:
rm -f $(CLEANUP)
-KBINDIR=kbin
-
distclean-windows:
- rm -f $(CLEANUP)
- rm -f $(WINMAKEFILES)
- rm -f $(KBINDIR)\*
+ config\rm.bat $(CLEANUP:^/=^\)
+ config\rm.bat $(WINMAKEFILES)
+ config\rm.bat $(KBINDIR)\*.dll $(KBINDIR)\*.exe
@if exist $(KBINDIR)\nul rmdir $(KBINDIR)
-mkbin:
- @if not exist $(KBINDIR)\nul mkdir $(KBINDIR)
- -$(CP) lib\$(OUTPRE)*.dll $(KBINDIR)\.
- -$(CP) windows\cns\$(OUTPRE)krb5.exe $(KBINDIR)\.
- -$(CP) windows\telnet\$(OUTPRE)telnet.exe $(KBINDIR)\.
- -$(CP) windows\gss\$(OUTPRE)gss.exe $(KBINDIR)\.
- -$(CP) clients\klist\$(OUTPRE)klist.exe $(KBINDIR)\.
- -$(CP) clients\kinit\$(OUTPRE)kinit.exe $(KBINDIR)\.
- -$(CP) clients\kdestroy\$(OUTPRE)kdestroy.exe $(KBINDIR)\.
+install-windows::
+ @if "$(KRB_INSTALL_DIR)"=="" @echo KRB_INSTALL_DIR is not defined! Please define it.
+ @if "$(KRB_INSTALL_DIR)"=="" @dir /b \nul\nul
+ @if not exist "$(KRB_INSTALL_DIR)\$(NULL)" @echo The directory $(KRB_INSTALL_DIR) does not exist. Please create it.
+ @if not exist "$(KRB_INSTALL_DIR)\$(NULL)" @dir /b $(KRB_INSTALL_DIR)\nul
+ @if not exist "$(KRB_INSTALL_DIR)\include\$(NULL)" @mkdir "$(KRB_INSTALL_DIR)\include"
+ @if not exist "$(KRB_INSTALL_DIR)\include\gssapi\$(NULL)" @mkdir "$(KRB_INSTALL_DIR)\include\gssapi"
+ @if not exist "$(KRB_INSTALL_DIR)\lib\$(NULL)" @mkdir "$(KRB_INSTALL_DIR)\lib"
+ @if not exist "$(KRB_INSTALL_DIR)\bin\$(NULL)" @mkdir "$(KRB_INSTALL_DIR)\bin"
+ $(CP) include\krb5.h "$(KRB_INSTALL_DIR)\include\."
+ $(CP) include\win-mac.h "$(KRB_INSTALL_DIR)\include\."
+ $(CP) include\profile.h "$(KRB_INSTALL_DIR)\include\."
+ $(CP) include\com_err.h "$(KRB_INSTALL_DIR)\include\."
+ $(CP) include\gssapi\gssapi.h "$(KRB_INSTALL_DIR)\include\gssapi\."
+ $(CP) include\gssapi\gssapi_krb5.h "$(KRB_INSTALL_DIR)\include\gssapi\."
+ $(CP) lib\$(OUTPRE)*.lib "$(KRB_INSTALL_DIR)\lib\."
+ $(CP) lib\$(OUTPRE)*.dll "$(KRB_INSTALL_DIR)\bin\."
+ $(CP) windows\cns\$(OUTPRE)krb5.exe "$(KRB_INSTALL_DIR)\bin\."
+ $(CP) windows\wintel\$(OUTPRE)telnet.exe "$(KRB_INSTALL_DIR)\bin\."
+ $(CP) windows\gss\$(OUTPRE)gss.exe "$(KRB_INSTALL_DIR)\bin\."
+ $(CP) clients\klist\$(OUTPRE)klist.exe "$(KRB_INSTALL_DIR)\bin\."
+ $(CP) clients\kinit\$(OUTPRE)kinit.exe "$(KRB_INSTALL_DIR)\bin\."
+ $(CP) clients\kdestroy\$(OUTPRE)kdestroy.exe "$(KRB_INSTALL_DIR)\bin\."
+ $(CP) clients\kpasswd\$(OUTPRE)kpasswd.exe "$(KRB_INSTALL_DIR)\bin\."
+ @if exist "$(KRB_INSTALL_DIR)\bin\krb4_32.dll" del "$(KRB_INSTALL_DIR)\bin\krb4_32.dll"
+ @if exist "$(KRB_INSTALL_DIR)\lib\krb4_32.lib" del "$(KRB_INSTALL_DIR)\lib\krb4_32.lib"