mirror of https://github.com/lianthony/NT4.0
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
151 lines
5.8 KiB
151 lines
5.8 KiB
#
|
|
# This is the MIDL compile phase of the build process.
|
|
#
|
|
# The following is where you put the name of your .idl file without
|
|
# the .idl extension:
|
|
|
|
!INCLUDE $(NTMAKEENV)\makefile.plt
|
|
|
|
#####################################################################
|
|
#
|
|
# For the UI RPC functions
|
|
#
|
|
IDL_NAME = llsrpc
|
|
CLIENT_ACF = llscli.acf
|
|
SERVER_ACF = llssrv.acf
|
|
|
|
CLIENT_INC_FILE = $(IDL_NAME)_c.h
|
|
SERVER_INC_FILE = $(IDL_NAME)_s.h
|
|
|
|
#####################################################################
|
|
#
|
|
# For the NtLSApi functions
|
|
#
|
|
LSAPI_IDL_NAME = lsapi
|
|
LSAPI_CLIENT_ACF = lsapicli.acf
|
|
LSAPI_SERVER_ACF = lsapisrv.acf
|
|
|
|
LSAPI_CLIENT_INC_FILE = $(LSAPI_IDL_NAME)_c.h
|
|
LSAPI_SERVER_INC_FILE = $(LSAPI_IDL_NAME)_s.h
|
|
|
|
#####################################################################
|
|
#
|
|
# For the Debugging RPC functions
|
|
#
|
|
DEBUG_IDL_NAME = llsdbg
|
|
DEBUG_CLIENT_ACF = lsdbgcli.acf
|
|
DEBUG_SERVER_ACF = lsdbgsrv.acf
|
|
|
|
DEBUG_CLIENT_INC_FILE = $(DEBUG_IDL_NAME)_c.h
|
|
DEBUG_SERVER_INC_FILE = $(DEBUG_IDL_NAME)_s.h
|
|
|
|
#####################################################################
|
|
#
|
|
# Common INC files
|
|
#
|
|
SDKINC = $(BASEDIR)\public\sdk\inc
|
|
SDKCRTINC = $(BASEDIR)\public\sdk\inc\crt
|
|
LLSINC = .\inc
|
|
|
|
INCS = -I$(SDKINC) -I$(SDKCRTINC) -I$(LLSINC)
|
|
|
|
EXTRN_DEPENDS =
|
|
|
|
CLIENT_FLAGS = -Oi -oldnames -error allocation -error ref -c_ext -ms_ext $(MIDL_FLAGS) -acf $(CLIENT_ACF) -header $(CLIENT_INC_FILE)
|
|
SERVER_FLAGS = -oldnames -error allocation -error ref -c_ext -ms_ext $(MIDL_FLAGS) -acf $(SERVER_ACF) -header $(SERVER_INC_FILE)
|
|
|
|
LSAPI_CLIENT_FLAGS = -Oi -oldnames -error allocation -error ref -c_ext -ms_ext $(MIDL_FLAGS) -acf $(LSAPI_CLIENT_ACF) -header $(LSAPI_CLIENT_INC_FILE)
|
|
LSAPI_SERVER_FLAGS = -oldnames -error allocation -error ref -c_ext -ms_ext $(MIDL_FLAGS) -acf $(LSAPI_SERVER_ACF) -header $(LSAPI_SERVER_INC_FILE)
|
|
|
|
DEBUG_CLIENT_FLAGS = -Oi -oldnames -error allocation -error ref -c_ext -ms_ext $(MIDL_FLAGS) -acf $(DEBUG_CLIENT_ACF) -header $(DEBUG_CLIENT_INC_FILE)
|
|
DEBUG_SERVER_FLAGS = -oldnames -error allocation -error ref -c_ext -ms_ext $(MIDL_FLAGS) -acf $(DEBUG_SERVER_ACF) -header $(DEBUG_SERVER_INC_FILE)
|
|
|
|
CPP = -cpp_cmd "$(MIDL_CPP)"
|
|
|
|
#
|
|
# Separate client and server targets. Note that the .h file produced
|
|
# when MIDL is run with the client .acf file attached differs from the
|
|
# .h file produced when MIDL is run with the server .acf file attached.
|
|
#
|
|
|
|
CLIENT_TARGETS = client\$(IDL_NAME)_c.c \
|
|
client\$(CLIENT_INC_FILE)
|
|
|
|
SERVER_TARGETS = server\$(IDL_NAME)_s.c \
|
|
server\$(SERVER_INC_FILE)
|
|
|
|
LSAPI_CLIENT_TARGETS = \
|
|
ntlsapi\$(LSAPI_IDL_NAME)_c.c \
|
|
ntlsapi\$(LSAPI_CLIENT_INC_FILE)
|
|
|
|
LSAPI_SERVER_TARGETS = \
|
|
server\$(LSAPI_IDL_NAME)_s.c \
|
|
server\$(LSAPI_SERVER_INC_FILE)
|
|
|
|
DEBUG_CLIENT_TARGETS = \
|
|
test\common\$(DEBUG_IDL_NAME)_c.c \
|
|
test\common\$(DEBUG_CLIENT_INC_FILE)
|
|
|
|
DEBUG_SERVER_TARGETS = \
|
|
server\$(DEBUG_IDL_NAME)_s.c \
|
|
server\$(DEBUG_SERVER_INC_FILE)
|
|
|
|
TARGETS = $(CLIENT_TARGETS) \
|
|
$(SERVER_TARGETS) \
|
|
$(LSAPI_CLIENT_TARGETS) \
|
|
$(LSAPI_SERVER_TARGETS) \
|
|
$(DEBUG_CLIENT_TARGETS) \
|
|
$(DEBUG_SERVER_TARGETS)
|
|
|
|
|
|
CLIENT_EXTRN_DEPENDS = $(CLIENT_ACF) $(LSAPI_CLIENT_ACF) $(DEBUG_CLIENT_ACF)
|
|
SERVER_EXTRN_DEPENDS = $(SERVER_ACF) $(LSAPI_SERVER_ACF) $(DEBUG_SERVER_ACF)
|
|
EXTRN_DEPENDS = $(CLIENT_EXTRN_DEPENDS)
|
|
|
|
#
|
|
# Define Products and Dependencies
|
|
#
|
|
|
|
all: $(CLIENT_TARGETS) $(SERVER_TARGETS) $(LSAPI_CLIENT_TARGETS) $(LSAPI_SERVER_TARGETS) $(DEBUG_CLIENT_TARGETS) $(DEBUG_SERVER_TARGETS)
|
|
!IF "$(BUILDMSG)" != ""
|
|
@ech ; $(BUILDMSG) ;
|
|
!ENDIF
|
|
|
|
clean: delete_source all
|
|
|
|
delete_source:
|
|
-erase $(TARGETS)
|
|
|
|
#
|
|
# MIDL COMPILE
|
|
#
|
|
|
|
$(CLIENT_TARGETS) : $(IDL_NAME).idl $(CLIENT_EXTRN_DEPENDS)
|
|
midl $(CPP) $(CLIENT_FLAGS) $(IDL_NAME).idl $(INCS)
|
|
IF EXIST $(IDL_NAME)_c.c copy $(IDL_NAME)_c.c .\client & del $(IDL_NAME)_c.c
|
|
IF EXIST $(CLIENT_INC_FILE) copy $(CLIENT_INC_FILE) .\client & del $(CLIENT_INC_FILE)
|
|
|
|
$(SERVER_TARGETS) : $(IDL_NAME).idl $(SERVER_EXTRN_DEPENDS)
|
|
midl $(CPP) $(SERVER_FLAGS) $(IDL_NAME).idl $(INCS)
|
|
IF EXIST $(IDL_NAME)_s.c copy $(IDL_NAME)_s.c .\server & del $(IDL_NAME)_s.c
|
|
IF EXIST $(SERVER_INC_FILE) copy $(SERVER_INC_FILE) .\server & del $(SERVER_INC_FILE)
|
|
|
|
$(LSAPI_CLIENT_TARGETS) : $(LSAPI_IDL_NAME).idl $(CLIENT_EXTRN_DEPENDS)
|
|
midl $(CPP) $(LSAPI_CLIENT_FLAGS) $(LSAPI_IDL_NAME).idl $(INCS)
|
|
IF EXIST $(LSAPI_IDL_NAME)_c.c copy $(LSAPI_IDL_NAME)_c.c .\ntlsapi & del $(LSAPI_IDL_NAME)_c.c
|
|
IF EXIST $(LSAPI_CLIENT_INC_FILE) copy $(LSAPI_CLIENT_INC_FILE) .\ntlsapi & del $(LSAPI_CLIENT_INC_FILE)
|
|
|
|
$(LSAPI_SERVER_TARGETS) : $(LSAPI_IDL_NAME).idl $(SERVER_EXTRN_DEPENDS)
|
|
midl $(CPP) $(LSAPI_SERVER_FLAGS) $(LSAPI_IDL_NAME).idl $(INCS)
|
|
IF EXIST $(LSAPI_IDL_NAME)_s.c copy $(LSAPI_IDL_NAME)_s.c .\server & del $(LSAPI_IDL_NAME)_s.c
|
|
IF EXIST $(LSAPI_SERVER_INC_FILE) copy $(LSAPI_SERVER_INC_FILE) .\server & del $(LSAPI_SERVER_INC_FILE)
|
|
|
|
$(DEBUG_CLIENT_TARGETS) : $(DEBUG_IDL_NAME).idl $(CLIENT_EXTRN_DEPENDS)
|
|
midl $(CPP) $(DEBUG_CLIENT_FLAGS) $(DEBUG_IDL_NAME).idl $(INCS)
|
|
IF EXIST $(DEBUG_IDL_NAME)_c.c copy $(DEBUG_IDL_NAME)_c.c .\test\common & del $(DEBUG_IDL_NAME)_c.c
|
|
IF EXIST $(DEBUG_CLIENT_INC_FILE) copy $(DEBUG_CLIENT_INC_FILE) .\test\common & del $(DEBUG_CLIENT_INC_FILE)
|
|
|
|
$(DEBUG_SERVER_TARGETS) : $(DEBUG_IDL_NAME).idl $(SERVER_EXTRN_DEPENDS)
|
|
midl $(CPP) $(DEBUG_SERVER_FLAGS) $(DEBUG_IDL_NAME).idl $(INCS)
|
|
IF EXIST $(DEBUG_IDL_NAME)_s.c copy $(DEBUG_IDL_NAME)_s.c .\server & del $(DEBUG_IDL_NAME)_s.c
|
|
IF EXIST $(DEBUG_SERVER_INC_FILE) copy $(DEBUG_SERVER_INC_FILE) .\server & del $(DEBUG_SERVER_INC_FILE)
|