home *** CD-ROM | disk | FTP | other *** search
/ Usenet 1994 January / usenetsourcesnewsgroupsinfomagicjanuary1994.iso / sources / misc / volume34 / vms_rtl_kbd / part01 / build.com next >
Encoding:
Text File  |  1992-12-19  |  6.4 KB  |  278 lines

  1.  
  2. $!------------------ Distribution and Copyright -----------------
  3. $!--
  4. $!- This software is copyright by the CENA/DGAC/FRANCE
  5. $!-- All rights reserved.
  6. $!--
  7. $!-- No part of the material protected by this copyright notice
  8. $!-- may be reproduced or utilized for commercial use in any form
  9. $!-- without written permission of the copyright owner.
  10. $!--
  11. $!-- It may be reproduced or utilized for R&D use in Non Profit
  12. $!-- Organization
  13. $!--
  14. $!---------------------------------------------------------------
  15.  
  16.  
  17. $!------------------ Disclaimer ---------------------------------
  18. $!--
  19. $!-- This software and its documentation are provided "AS IS" and
  20. $!-- without any expressed or implied warranties whatsoever.
  21. $!-- No warranties as to performance, merchantability, or fitness
  22. $!-- for a particular purpose exist.
  23. $!--
  24. $!-- Because of the diversity of conditions and hardware under
  25. $!-- which this software may be used, no warranty of fitness for
  26. $!-- a particular purpose is offered.  The user is advised to
  27. $!-- test the software thoroughly before relying on it.  The user
  28. $!-- must assume the entire risk and liability of using this
  29. $!-- software.
  30. $!--
  31. $!-- In no event shall any person or organization of people be
  32. $!-- held responsible for any direct, indirect, consequential
  33. $!-- or inconsequential damages or lost profits.
  34. $!--                                                           
  35. $!-------------------END-PROLOGUE--------------------------------
  36.  
  37.  
  38.  
  39.  
  40. $!++
  41. $!
  42. $! Titre:       BUILD
  43. $!
  44. $! Sujet:       Fichier de procedure pour la reconstruction d'un module
  45. $!           Pascal (interface + implementation) et son insertion dans
  46. $!           une librarie d'objets.
  47. $!
  48. $! Version:       1.3
  49. $!
  50. $! Description:       Le module doit en fait se decomposer en 2 fichiers, un pour
  51. $!           la partie interface et l'autre pour la partie
  52. $!           implementation.
  53. $!           Ils doivent respecter le format suivant: file_V_x_x.PAS
  54. $!
  55. $!           Si P1 = 1, alors compilation de l'interface
  56. $!           Si P1 = 2, alors compilation de l'implementation
  57. $!           Si P1 = 3, alors compilation de tout
  58. $!
  59. $!           Si P2 = F, alors phase finale
  60. $!
  61. $! Langage:       DCL
  62. $!
  63. $! Fichier:       BUILD.COM
  64. $!
  65. $! Environnement:  Machine cible:          VAX
  66. $!           Systeme d'exploitation: VMS Version 5.4-3
  67. $!
  68. $! Auteur:       Martin VICENTE (DGAC/CENA/SID)
  69. $!
  70. $!           E-mail: vicente@cenaath.cena.dgac.fr
  71. $!
  72. $!           Mail:   C.E.N.A.
  73. $!               Div. Support Informatique & Developpement
  74. $!               Orly Sud 205
  75. $!               94 542 ORLY AEROGARE CEDEX, FRANCE
  76. $!
  77. $! Creation:       19/05/92
  78. $!
  79. $! Modification:   01/07/92
  80. $!
  81. $!--
  82. $
  83. $
  84. $!====  PARAMETRES DU PROGRAMME  ==============================================
  85. $
  86. $ TIT     = "KBD$ROUTINES"        ! Titre
  87. $ FIC_INT = "PASCAL$KBD_ROUTINES"    ! Nom du fichier interface
  88. $ FIC_IMP = "KBD$ROUTINES"        ! Nom du fichier implementation
  89. $ VER     = ""                ! Version (respectez le format)
  90. $ LIB     = "MYLIB"            ! Librairie
  91. $
  92. $!====  LISTE DES ETIQUETTES  =================================================
  93. $!
  94. $! afp  AFFICHER PAVE NUMERIQUE
  95. $! gtm  GET TIME
  96. $! int  COMPILER INTERFACE
  97. $! imp  COMPILER IMPLEMENTATION
  98. $! tou  TOUT COMPILER
  99. $! cin  COMPILER INTERFACE
  100. $! cim  COMPILER IMPLEMENTATION
  101. $!
  102. $!====  DEFINITION DES SYMBOLES  ==============================================
  103. $
  104. $ AFFICHER   := write sys$output
  105. $ LIGNE_VIDE := "''AFFICHER' """
  106. $
  107. $ VC = "''VIDEO_C'"
  108. $ VI = "''VIDEO_I'"
  109. $ VB = "''VIDEO_B'"
  110. $ VN = "''VIDEO_N'"
  111. $
  112. $!====  DEBUT DU PROGRAMME  ===================================================
  113. $
  114. $ if p1 .eqs. "" then goto afp!AFFICHER PAVE NUMERIQUE
  115. $
  116. $ gosub gtm!GET TIME
  117. $
  118. $ DATE  = f$extract(0,11,TIME)
  119. $ HEURE = f$extract(12,5,TIME)
  120. $ TITRE = "''VI'BUILD DE ''TIT' LE ''DATE' A ''HEURE'''VN'"
  121. $
  122. $ EFFACER := delete/since='TIME'
  123. $
  124. $ if p2 .eqs. "F"
  125. $   then
  126. $     SOUSTITRE = "Version ''VER' - Phase finale"
  127. $     COMPILER := pascal/warning/nocheck/optimize=all
  128. $   else
  129. $     SOUSTITRE = "Version ''VER' - Phase de developpement"
  130. $     COMPILER := pascal/warning/check=all/nooptimize
  131. $ endif
  132. $
  133. $ if p1 .eqs. "1"
  134. $   then
  135. $     gosub int!COMPILER INTERFACE
  136. $   else
  137. $     if p1 .eqs. "2"
  138. $    then
  139. $         gosub imp!COMPILER IMPLEMENTATION
  140. $    else
  141. $         if p1 .eqs. "3"
  142. $        then
  143. $             gosub tou!TOUT COMPILER
  144. $        else
  145. $             AFFICHER "%BUILD-E-PARINV, parametre invalide"
  146. $          AFFICHER " \''p1'\"
  147. $      endif
  148. $     endif
  149. $ endif
  150. $
  151. $ exit
  152. $
  153. $ afp:!AFFICHER PAVE NUMERIQUE
  154. $
  155. $    DEF := define/key/terminate/nolog
  156. $
  157. $    DEF help "@ BUILD"
  158. $    DEF kp1  "@ BUILD 1"
  159. $    DEF kp2  "@ BUILD 2"
  160. $    DEF kp3  "@ BUILD 3"
  161. $
  162. $    set terminal/application_keypad
  163. $
  164. $    LIGNE_VIDE
  165. $    AFFICHER  "DEFINITION DU PAVE NUMERIQUE"
  166. $    LIGNE_VIDE
  167. $
  168. $    AFFICHER "    HELP -> DEFINITION DU PAVE NUMERIQUE"
  169. $    AFFICHER "    KP1  -> COMPILER L'INTERFACE"
  170. $    AFFICHER "    KP2  -> COMPILER L'IMPLEMENTATION"
  171. $    AFFICHER "    KP3  -> COMPILER TOUT"
  172. $
  173. $    LIGNE_VIDE
  174. $
  175. $    exit
  176. $
  177. $!====  FIN DU PROGRAMME  =====================================================
  178. $
  179. $ int:!COMPILER INTERFACE
  180. $
  181. $    AFFICHER  TITRE
  182. $    AFFICHER  SOUSTITRE
  183. $    LIGNE_VIDE
  184. $
  185. $    gosub cin!COMPILER INTERFACE
  186. $
  187. $ return
  188. $
  189. $ imp:!COMPILER IMPLEMENTATION
  190. $
  191. $    AFFICHER  TITRE
  192. $    AFFICHER  SOUSTITRE
  193. $    LIGNE_VIDE
  194. $
  195. $    gosub cim!COMPILER IMPLEMENTATION
  196. $
  197. $ return
  198. $
  199. $ tou:!TOUT COMPILER
  200. $
  201. $    AFFICHER  TITRE
  202. $    AFFICHER  SOUSTITRE
  203. $    LIGNE_VIDE
  204. $
  205. $    gosub cin!COMPILER INTERFACE
  206. $    gosub cim!COMPILER IMPLEMENTATION
  207. $
  208. $ return
  209. $
  210. $ cin:!COMPILER INTERFACE
  211. $
  212. $    AFFICHER  "''VB'COMPILATION DU MODULE ''FIC_INT'''VN'"
  213. $
  214. $    SRC = "''FIC_INT'''VER'.PAS"
  215. $    INT = "''FIC_INT'"
  216. $
  217. $    purge 'SRC'
  218. $
  219. $    AFFICHER "Compilation"
  220. $
  221. $    COMPILER/environment='INT'/object='INT'/nodiagnostics 'SRC'
  222. $
  223. $    purge 'INT'.PEN
  224. $    purge 'INT'.OBJ
  225. $
  226. $    define sys$output nl:
  227. $    define sys$error  nl:
  228. $    delete 'INT'.DIA;*
  229. $    deassign sys$error
  230. $    deassign sys$output
  231. $
  232. $    AFFICHER "Insertion dans la librairie"
  233. $
  234. $    library/replace 'LIB' 'FIC_INT'
  235. $
  236. $ return
  237. $
  238. $ cim:!COMPILER IMPLEMENTATION
  239. $
  240. $    AFFICHER "''VB'COMPILATION DU MODULE ''FIC_IMP'''VN'"
  241. $
  242. $    SRC = "''FIC_IMP'''VER'.PAS"
  243. $    IMP = "''FIC_IMP'"
  244. $
  245. $    purge 'SRC'
  246. $
  247. $    AFFICHER "Compilation"
  248. $
  249. $    COMPILER/noenvironment/object='IMP'/nodiagnostics 'SRC'
  250. $
  251. $    purge 'IMP'.OBJ
  252. $
  253. $    define sys$output nl:
  254. $    define sys$error  nl:
  255. $    delete 'INT'.DIA;*
  256. $    deassign sys$error
  257. $    deassign sys$output
  258. $
  259. $    AFFICHER "Insertion dans la librairie"
  260. $
  261. $    library/replace 'LIB' 'FIC_IMP'
  262. $
  263. $ return
  264. $
  265. $ gtm:!GET TIME
  266. $
  267. $    TIME  = f$time ()
  268. $    DATE  = f$extract(0,11,TIME)
  269. $    HEURE = f$extract(12,11,TIME)
  270. $
  271. $!    Conversion du format de time de  DD-MMM-YYYY HH:MM:SS.CC
  272. $!                     en  DD-MMM-YYYY:HH:MM:SS.CC
  273. $
  274. $    TIME = "''DATE':''HEURE'"
  275. $
  276. $ return
  277. $
  278.