# Copyright 2000, International Business Machines Corporation and others.
# All Rights Reserved.
# 
# This software has been released under the terms of the IBM Public
# License.  For details, see the LICENSE file in the top-level source
# directory or online at http://www.openafs.org/dl/license10.html

AFSDEV_AUXCDEFINES = -DAFS_PTHREAD_ENV -DRXDEBUG

RELDIR=tviced
!INCLUDE ..\config\NTMakefile.$(SYS_NAME)
!INCLUDE ..\config\NTMakefile.version

SRC_DIR = ..\viced

############################################################################
# Build the fileserver

EXEFILE = $(DESTDIR)\root.server\usr\afs\bin\fileserver.exe

VICED = ..\viced
VLSERVER = ..\vlserver
LWP = ..\lwp
LIBACL = ..\libacl
UTIL = ..\util
DIR = ..\dir
VOL = ..\vol
FSINT = ..\fsint
RX = ..\rx

RXOBJS = $(OUT)\xdr_int64.obj \
         $(OUT)\xdr_int32.obj

VICEDOBJS = $(OUT)\viced.obj $(OUT)\afsfileprocs.obj $(OUT)\host.obj $(OUT)\physio.obj $(OUT)\callback.obj
VICEDRES =	$(OUT)\$(VICED)\fileserver.res

VLSERVEROBJS = $(OUT)\vldbint.cs.obj $(OUT)\vldbint.xdr.obj

LWPOBJS = $(OUT)\lock.obj $(OUT)\fasttime.obj $(OUT)\threadname.obj

LIBACLOBJS = $(OUT)\aclprocs.obj $(OUT)\netprocs.obj

UTILOBJS = $(OUT)\assert.obj $(OUT)\uuid.obj $(OUT)\serverLog.obj $(OUT)\fileutil.obj 

DIROBJS = $(OUT)\buffer.obj $(OUT)\dir.obj $(OUT)\salvage.obj

VOLOBJS = $(OUT)\vnode.obj $(OUT)\volume.obj $(OUT)\vutil.obj $(OUT)\partition.obj $(OUT)\fssync.obj $(OUT)\purge.obj \
	  $(OUT)\clone.obj $(OUT)\common.obj $(OUT)\ihandle.obj $(OUT)\ntops.obj

FSINTOBJS = $(OUT)\afsaux.obj $(OUT)\afscbint.cs.obj $(OUT)\afsint.ss.obj $(OUT)\afsint.xdr.obj

EXEOBJS = $(VICEDOBJS) $(VICEDRES) $(VLSERVEROBJS) $(LWPOBJS) $(LIBACLOBJS) \
	 $(UTILOBJS) $(DIROBJS) $(VOLOBJS) $(FSINTOBJS) $(RXOBJS)



noversion: install

all: fileserver

$(RXOBJS): $(RX)\$$(@B).c
	$(C2OBJ) -I$(RX) $**

$(VICEDOBJS): $(VICED)\$$(@B).c
	$(C2OBJ) -I$(VICED) -I$(UTIL) $**

$(UTILOBJS): $(UTIL)\$$(@B).c
	$(C2OBJ) -I$(UTIL) $**

$(LWPOBJS): $(LWP)\$$(@B).C
	$(C2OBJ) -I$(LWP) $**

$(LIBACLOBJS): $(LIBACL)\$$(@B).C
	$(C2OBJ) -I$(LIBACL) $**

$(VLSERVEROBJS): $(VLSERVER)\$$(@B).C
	$(C2OBJ) -I$(VLSERVER) $**

$(DIROBJS): $(DIR)\$$(@B).C
	$(C2OBJ) -I$(DIR) $**

$(VOLOBJS): $(VOL)\$$(@B).C
	$(C2OBJ) -I$(VOL) $**

$(FSINTOBJS): $(FSINT)\$$(@B).C
	$(C2OBJ) -I$(FSINT) $**

EXELIBS = \
	$(DESTDIR)\lib\afsauthent.lib \
	$(DESTDIR)\lib\afsrpc.lib \
	$(DESTDIR)\lib\afs\afscmd.lib \
	$(DESTDIR)\lib\afs\afsaudit.lib \
	$(DESTDIR)\lib/afs/afscom_err.lib \
	$(DESTDIR)\lib\afs\afsreg.lib \
	$(DESTDIR)\lib\afs\afsprocmgmt.lib \
	$(DESTDIR)\lib\afs\afseventlog.lib \
	$(DESTDIR)\lib\afs\afsutil.lib \
	$(DESTDIR)\lib\afspthread.lib

$(EXEFILE): $(EXEOBJS) $(EXELIBS)
	$(EXECONLINK)
	$(EXEPREP) 

install:  $(EXEFILE)

mkdir:
	
