home *** CD-ROM | disk | FTP | other *** search
/ Tricks of the Windows Gam…ming Gurus (2nd Edition) / Disc2.iso / msdn_vcb / samples / vc98 / sdk / dbmsg / sql / buildall.bat next >
Encoding:
DOS Batch File  |  1996-04-03  |  3.1 KB  |  106 lines

  1. @echo off
  2. rem
  3. rem  BUILDALL.BAT
  4. rem  Copyright (C) 1996 Microsoft Corp.
  5. rem
  6. rem  This batch file allows you to build all the SQL Server 32-bit sample
  7. rem  C/C++ programs.
  8. rem
  9.  
  10. if "%1" == "?" goto usage
  11. if "%1" == "/?" goto usage
  12. if "%1" == "-?" goto usage
  13. if "%1" == "" goto usage
  14.  
  15. set platform=
  16. if "%1" == "intel" set platform=Win32
  17. if "%1" == "x86" set platform=Win32
  18. if "%1" == "alpha" set platform=Win32 (ALPHA)
  19. if "%1" == "axp" set platform=Win32 (ALPHA)
  20. if "%1" == "mips" set platform=Win32 MIPS
  21. if "%1" == "powerpc" set platform=Win32 (PPC)
  22. if "%1" == "ppc" set platform=Win32 (PPC)
  23. if "%platform%" == "" set platform=Win32
  24.  
  25. set debug=
  26. if "%2" == "debug" set debug=Debug
  27. if "%2" == "retail" set debug=Release
  28. if "%debug%" == "" set debug=Release
  29.  
  30. set force=
  31. if "%3" == "force" set force=/a
  32.  
  33. set ptkplatform=%platform% %debug%
  34. @echo Building for %ptkplatform%
  35.  
  36. rem DB-Library samples
  37. cd  DBLib\C\Example1
  38. nmake %force% /f Example1.mak cfg="Example1 - %ptkplatform%" all
  39. cd ..\Example2
  40. nmake %force% /f Example2.mak cfg="Example2 - %ptkplatform%" all
  41. cd  ..\Example3
  42. nmake %force% /f Example3.mak cfg="Example3 - %ptkplatform%" all
  43. cd  ..\Example4
  44. nmake %force% /f Example4.mak cfg="Example4 - %ptkplatform%" all
  45. cd  ..\Example5
  46. nmake %force% /f Example5.mak cfg="Example5 - %ptkplatform%" all
  47. cd  ..\Example6
  48. nmake %force% /f Example6.mak cfg="Example6 - %ptkplatform%" all
  49. cd  ..\Example7
  50. nmake %force% /f Example7.mak cfg="Example7 - %ptkplatform%" all
  51. cd  ..\Example8
  52. nmake %force% /f Example8.mak cfg="Example8 - %ptkplatform%" all
  53. cd  ..\Nmpsdmp
  54. nmake %force% /f Nmpsdmp.mak cfg="Nmpsdmp - %ptkplatform%" all
  55. cd  ..\SQLCurs
  56. nmake %force% /f SQLCurs.mak cfg="SQLCurs - %ptkplatform%" all
  57. cd  ..\SQLExamp
  58. nmake %force% /f SQLExamp.mak cfg="SQLExamp - %ptkplatform%" all
  59. cd  ..\SQLTestC
  60. nmake %force% /f SQLTestC.mak cfg="SQLTestC - %ptkplatform%" all
  61. cd  ..\SQLTestN
  62. nmake %force% /f SQLTestN.mak cfg="SQLTestN - %ptkplatform%" all
  63. cd  ..\Textcopy
  64. nmake %force% /f Textcopy.mak cfg="Textcopy - %ptkplatform%" all
  65. cd  ..\Twophase
  66. nmake %force% /f Twophase.mak cfg="Twophase - %ptkplatform%" all
  67. cd ..\..\..
  68.  
  69. rem MSDTC samples
  70. cd  MSDTC\DBLIB
  71. nmake %force% /f DBLib.mak cfg="DBLib - %ptkplatform%" all 
  72. cd  ..\ODBC
  73. nmake %force% /f Odbc.mak cfg="Odbc - %ptkplatform%" all
  74. cd ..\..
  75.  
  76. rem ODS samples
  77. cd  ODS\Gateway
  78. nmake %force% /f Gateway.mak cfg="Gateway - %ptkplatform%" all 
  79. cd  ..\ODSODBC
  80. nmake %force% /f ODSSamp.mak cfg="ODSSamp - %ptkplatform%" all 
  81. cd  ..\PROCSRV
  82. nmake %force% /f Procsrv.mak cfg="Procsrv - %ptkplatform%" all 
  83. cd  ..\Xp
  84. nmake %force% /f xp.mak cfg="xp - %ptkplatform%" all 
  85. cd  ..\xp_dblib
  86. nmake %force% /f xp_dblib.mak cfg="xp_dblib - %ptkplatform%" all 
  87. cd  ..\xp_odbc
  88. nmake %force% /f xp_odbc.mak cfg="xp_odbc - %ptkplatform%" all
  89. cd ..\..
  90.  
  91. rem SQL-DMO samples
  92. cd  SQLDMO\C\SOC
  93. nmake %force% /f soc.mak cfg="soc - %ptkplatform%" all 
  94. cd ..\..\CPP\Socpp
  95. nmake %force% /f socpp.mak cfg="socpp - %ptkplatform%" all
  96. cd ..\..\..
  97.  
  98. goto end
  99.  
  100. :usage
  101. @echo Syntax:
  102. @echo BUILDALL {intel or alpha or mips or powerpc} {debug or release} {force}
  103. @echo.
  104.  
  105. :end
  106.