RELDIR=packages\windows\assembly
!include ../../../windows/NTMakefile.w32
!ifndef CODESIGN_PKT
! error CODESIGN_PKT should be set to the public key token for codesigning certificate
!endif
prep:: mk-asm-dirs
ASMKRBDIR=$(ASMDIR)\Heimdal.Kerberos
ASMKRBVER=$(VER_PRODUCT_MAJOR).$(VER_PRODUCT_MINOR).$(VER_PRODUCT_AUX).$(VER_PRODUCT_PATCH)
ASMKRBVER_OLD_BEGIN=$(VER_OLD_BEGIN_MAJOR).$(VER_OLD_BEGIN_MINOR).$(VER_OLD_BEGIN_AUX).$(VER_OLD_BEGIN_PATCH)
ASMKRBVER_OLD_END=$(VER_OLD_END_MAJOR).$(VER_OLD_END_MINOR).$(VER_OLD_END_AUX).$(VER_OLD_END_PATCH)
ASMKRBMAN=$(ASMKRBNAME).manifest
ASMKRBBINS=\
$(ASMKRBDIR)\heimdal.dll \
$(ASMKRBDIR)\com_err.dll \
$(ASMKRBDIR)\heimntlm.dll \
$(ASMKRBDIR)\gssapi.dll \
$(ASMKRBDIR)\heimdal.pdb \
$(ASMKRBDIR)\com_err.pdb \
$(ASMKRBDIR)\heimntlm.pdb \
$(ASMKRBDIR)\gssapi.pdb
$(ASMKRBDIR)\$(ASMKRBMAN).nohash: Heimdal.Kerberos.manifest.in
$(SED) -e "s,[@]name[@],$(ASMKRBNAME),g" \
-e "s,[@]cpu[@],$(MCPU),g" \
-e "s,[@]version[@],$(ASMKRBVER),g" \
-e "s,[@]pkt[@],$(CODESIGN_PKT),g" < $** > $@
$(ASMKRBDIR)\$(ASMKRBMAN) $(ASMKRBDIR)\$(ASMKRBMAN).cdf: \
$(ASMKRBDIR)\$(ASMKRBMAN).nohash $(ASMKRBBINS)
-$(RM) $(ASMKRBDIR)\$(ASMKRBMAN)
-$(RM) $(ASMKRBDIR)\$(ASMKRBMAN).cdf
$(MT) -manifest $(ASMKRBDIR)\$(ASMKRBMAN).nohash -out:$(ASMKRBDIR)\$(ASMKRBMAN) -hashupdate -makecdfs
$(ASMKRBDIR)\$(ASMKRBNAME).cat: $(ASMKRBDIR)\$(ASMKRBMAN).cdf
cd $(ASMKRBDIR)
$(MAKECAT) $**
$(_CODESIGN)
cd $(SRCDIR)
asm-krb: \
$(APPMANIFEST) \
$(ASMKRBBINS) \
$(ASMKRBDIR)\$(ASMKRBMAN) \
$(ASMKRBDIR)\$(ASMKRBNAME).cat \
all:: asm-krb
clean::
-$(RM) $(ASMKRBDIR)\*.*
test::
$(MT) -manifest $(ASMKRBDIR)\$(ASMKRBMAN) -validate_manifest
{$(BINDIR)}.dll{$(ASMKRBDIR)}.dll:
$(CP) $< $@
$(DLLPREP_MERGE)
{$(BINDIR)}.pdb{$(ASMKRBDIR)}.pdb:
$(CP) $< $@
all:: $(APPMANIFEST)
clean::
-$(RM) $(APPMANIFEST)
$(APPMANIFEST): Heimdal.Application.manifest.in
$(SED) -e "s,[@]krbname[@],$(ASMKRBNAME),g" \
-e "s,[@]krbversion[@],$(ASMKRBVER),g" \
-e "s,[@]cpu[@],$(MCPU),g" \
-e "s,[@]pkt[@],$(CODESIGN_PKT),g" < $** > $@
test::
$(MT) -manifest $(APPMANIFEST) -validate_manifest
POLKRB=policy.$(VER_PRODUCT_MAJOR).$(VER_PRODUCT_MINOR).Heimdal.Kerberos
POLKRBDIR=$(ASMDIR)\$(POLKRB)
POLKRBFILE=$(POLKRBDIR)\$(ASMKRBVER).pol
POLKRBCAT=$(POLKRBDIR)\$(ASMKRBVER).cat
$(POLKRBFILE): policy.Heimdal.Kerberos.in
$(SED) -e "s,[@]krbname[@],$(ASMKRBNAME),g" \
-e "s,[@]krbversion[@],$(ASMKRBVER),g" \
-e "s,[@]krbverfrom_begin[@],$(ASMKRBVER_OLD_BEGIN),g" \
-e "s,[@]krbverfrom_end[@],$(ASMKRBVER_OLD_END),g" \
-e "s,[@]krbpolname[@],$(POLKRB),g" \
-e "s,[@]cpu[@],$(MCPU),g" \
-e "s,[@]pkt[@],$(CODESIGN_PKT),g" < $** > $@
$(POLKRBFILE).cdf: $(POLKRBFILE)
$(MT) -manifest $(POLKRBFILE) -makecdfs
$(POLKRBCAT): $(POLKRBFILE).cdf
cd $(POLKRBDIR)
$(MAKECAT) $**
$(_CODESIGN)
cd $(SRCDIR)
all:: $(POLKRBFILE) $(POLKRBCAT)
clean::
-$(RM) $(POLKRBDIR)\*.*
.SUFFIXES: .dll .pdb
mk-asm-dirs:
! if !exist($(ASMKRBDIR))
$(MKDIR) $(ASMKRBDIR)
! endif
! if !exist($(POLKRBDIR))
$(MKDIR) $(POLKRBDIR)
! endif