home *** CD-ROM | disk | FTP | other *** search
/ Tricks of the Windows Gam…ming Gurus (2nd Edition) / Disc2.iso / msdn_vcb / samples / vc98 / sdk / netds / rpc / interop / makefile < prev    next >
Encoding:
Makefile  |  1997-10-15  |  2.1 KB  |  80 lines

  1.  
  2. #*************************************************************#
  3. #**                                                         **#
  4. #**                 Microsoft RPC Examples                  **#
  5. #**                 OSF DCE Interop Application             **#
  6. #**           Copyright(c) Microsoft Corp. 1993-1995        **#
  7. #**                                                         **#
  8. #*************************************************************#
  9.  
  10. SEHMAP=TRUE
  11. !include <win32.mak>
  12.  
  13. !if "$(CPU)" == "i386"
  14. cflags = $(cflags:G3=Gz)
  15. cflags = $(cflags:Zi=Z7)
  16. !else
  17. cflags = $(cflags) -D_CRTAPI1= -D_CRTAPI2=
  18. !endif
  19.  
  20. !if "$(CPU)" == "i386"
  21. cflags = $(cflags) -D_CRTAPI1=_cdecl -D_CRTAPI2=_cdecl
  22. !endif
  23.  
  24. all : client.exe server.exe
  25.  
  26. # Make the client
  27. client : client.exe
  28. client.exe : client.obj msg_c.obj midluser.obj
  29.     $(link) $(linkdebug) $(conflags) -out:client.exe -map:client.map \
  30.       client.obj msg_c.obj midluser.obj \
  31.       rpcrt4.lib $(conlibsdll)
  32.  
  33. # client main program
  34. client.obj : client.c msg.h
  35.    $(cc) $(cdebug) $(cflags) $(cvarsdll) $*.c
  36.  
  37. # client stub
  38. msg_c.obj : msg_c.c msg.h
  39.    $(cc) $(cdebug) $(cflags) $(cvarsdll) $*.c
  40.  
  41.  
  42. # Make the server executable
  43. server : server.exe
  44. server.exe : server.obj manager.obj msg_s.obj midluser.obj
  45.     $(link) $(linkdebug) $(conflags) -out:server.exe -map:server.map \
  46.       server.obj manager.obj msg_s.obj midluser.obj \
  47.       rpcrt4.lib $(conlibsdll)
  48.  
  49. # server main program
  50. server.obj : msg.h
  51.    $(cc) $(cdebug) $(cflags) $(cvarsdll) $*.c
  52.  
  53. # remote procedures
  54. manager.obj : msg.h
  55.    $(cc) $(cdebug) $(cflags) $(cvarsdll) $*.c
  56.  
  57. # server stub
  58. msg_s.obj : msg_s.c msg.h
  59.    $(cc) $(cdebug) $(cflags) $(cvarsdll) $*.c
  60.  
  61. # midl_user* routines
  62. midluser.obj : midluser.c
  63.    $(cc) $(cdebug) $(cflags) $(cvarsdll) $*.c
  64.  
  65.  
  66. # Stubs and header file from the IDL file
  67. msg.h msg_s.c msg_c.c : msg.idl msg.acf
  68.     midl -cpp_cmd $(cc) -cpp_opt "-E" msg.idl
  69.  
  70. # Clean up everything
  71. cleanall : clean
  72.     -del *.exe
  73.  
  74. # Clean up everything but the .EXEs
  75. clean :
  76.     -del *.obj
  77.     -del *.map
  78.     -del msg_?.c
  79.     -del msg.h
  80.