home *** CD-ROM | disk | FTP | other *** search
/ Liren Large Software Subsidy 7 / 07.iso / c / c220 / 3.ddi / BIN / DEMO.BAT < prev    next >
Encoding:
DOS Batch File  |  1990-10-19  |  3.8 KB  |  83 lines

  1. @echo         ┌──────────────────────────────────────────────┐
  2. @echo         │                                              │
  3. @echo         │           A small demonstration              │
  4. @echo         │                                              │
  5. @echo         │                                              │
  6. @echo         │    YOU MUST HAVE Phar Lap software version   │
  7. @echo         │        1.1 or greater to run programs.       │
  8. @echo         └──────────────────────────────────────────────┘
  9. @echo         ┌──────────────────────────────────────────────┐
  10. @echo         │                                              │
  11. @echo         │     Compile and link "Hello world".          │
  12. @echo         │     (also produces an assembly listing)      │
  13. @echo         │                                              │
  14. @echo         └──────────────────────────────────────────────┘
  15. @if exist bin\hcdriver.exe goto nodrv
  16. bin\hc386 demos\hello.c -Hon=list -Hon=asm
  17. @goto driv
  18. :nodrv
  19. bin\hcd386 demos/hello -on list asm
  20. link hello,,,small\hcse
  21. :driv
  22. @echo         ┌──────────────────────────────────────────────┐
  23. @echo         │                                              │
  24. @echo         │     Run the "Hello World" program.           │
  25. @echo         │                                              │
  26. @echo         └──────────────────────────────────────────────┘
  27. run386 hello
  28. pause
  29. @echo         ┌──────────────────────────────────────────────┐
  30. @echo         │                                              │
  31. @echo         │     Compile the prime number sieve program.  │
  32. @echo         │     Then link and run the result.            │
  33. @echo         │                                              │
  34. @echo         └──────────────────────────────────────────────┘
  35. @if exist bin\hcdriver.exe goto nodrv2
  36. bin\hc386 demos\sieve.c -Hpro=demos\hc.pro
  37. @goto driv2
  38. :nodrv2
  39. bin\hcd386 demos/sieve -pro demos/hc.pro
  40. link sieve,,,small\hcse
  41. :driv2
  42. @echo         ┌──────────────────────────────────────────────┐
  43. @echo         │                                              │
  44. @echo         │     Run the prime number sieve program.      │
  45. @echo         │                                              │
  46. @echo         └──────────────────────────────────────────────┘
  47. pause
  48. run386 sieve
  49. @echo         ┌──────────────────────────────────────────────┐
  50. @echo         │                                              │
  51. @echo         │     Compile and link a program that          │
  52. @echo         │     computes greycodes.                      │
  53. @echo         │                                              │
  54. @echo         └──────────────────────────────────────────────┘
  55. @if exist bin\hcdriver.exe goto nodrv3
  56. bin\hc386 demos\greycode.c -Hpro=demos\hc.pro
  57. @goto driv3
  58. :nodrv3
  59. bin\hcd386 demos/greycode -pro demos/hc.pro
  60. link greycode,,,small\hcse
  61. :driv3
  62. @echo         ┌──────────────────────────────────────────────┐
  63. @echo         │                                              │
  64. @echo         │     Run greycode, run.                       │
  65. @echo         │                                              │
  66. @echo         └──────────────────────────────────────────────┘
  67. pause
  68. run386 greycode
  69. @if exist hello.ex?     del hello.ex?
  70. @if exist hello.obj     del hello.obj
  71. @if exist hello.map     del hello.map
  72. @if exist sieve.ex?     del sieve.ex?
  73. @if exist sieve.obj     del sieve.obj
  74. @if exist sieve.map     del sieve.map
  75. @if exist greycodes.ex? del greycodes.ex?
  76. @if exist greycodes.obj del greycodes.obj
  77. @if exist greycodes.map del greycodes.map
  78. @echo         ┌──────────────────────────────────────────────┐
  79. @echo         │                                              │
  80. @echo         │             End of demonstration.            │
  81. @echo         │                                              │
  82. @echo         └──────────────────────────────────────────────┘
  83.