home *** CD-ROM | disk | FTP | other *** search
/ Amiga ISO Collection / AmigaUtilCD1.iso / FileMover / HF-OM1.DMS / in.adf / Install_Opus_Magellan < prev    next >
Encoding:
Text File  |  1997-05-11  |  5.5 KB  |  260 lines

  1. ; Script to install Directory Opus Magellan version 
  2. ;
  3. ; Directory Opus Install Version $VER: Install-Opus 60  (11.05.97)
  4. ; COPYRIGHT ©1996 GP SOFTWARE, AUSTRALIA
  5. ; note uses Opus<Alt-Shift>5
  6. ; now installs new catalogs if they are on the disk.
  7.  
  8.  
  9.  
  10. (complete 0)
  11.  
  12. ;
  13. ;check user has Dos 2
  14. ;
  15.  
  16. (set #DOSTYPE (/ (getversion) 65536))
  17. (if
  18.     (NOT (>= #DOSTYPE 37))
  19.     (abort "Directory Opus 5 requires AmigaDOS 2.04 or higher."
  20.         " If you have an earlier version of AmigaDOS you must purchase an upgrade before using Opus 5.")
  21. )
  22.  
  23.  
  24. (set @default-dest "work:")
  25.  
  26. (set #Dopus_prog "DOpus5:DirectoryOpus")
  27. (set #DName "Opus_Magellan_Install")
  28. (set #Disk_Name (cat #DName ":"))
  29. (set #CatalogFiles "CatFiles.lha")
  30.  
  31.  
  32. (set #Go "Proceed")
  33. (set #Skip "Skip this part")
  34.  
  35.  
  36. ;
  37. ; Procedure signal
  38. ; incase Opus is re-installed. The notification on the modules
  39. ; directory can cause problems so signal Opus to turn off notifications
  40.  
  41. (procedure signal_opus
  42.  
  43.     (get_disk)
  44.     (set #Sigs (tackon #Disk_Name "dopusmsg"))
  45.     (if (exists #Sigs (noreq))
  46.         (run (cat #Sigs " DOPUS.1 \"command set notify off\""))
  47.     )
  48. )
  49.  
  50.  
  51. ;
  52. ; Procedure get_lhex 
  53. ;
  54.  
  55.  
  56. (procedure get_lhex
  57.  
  58.     (if ( = (exists "ram:lhex" (noreq)) 0)
  59.         (
  60.         (get_disk)
  61.         (working #Title_msg
  62.             "Reading the Install disk for Directory Opus files.")
  63.         (copyfiles (source (tackon #Disk_Name "lhex")) (dest "ram:"))
  64.         )
  65.     )
  66. )
  67.  
  68. ;
  69. ; Procedure get_disk 
  70. ; get the correct disk for a program
  71. ;
  72.  
  73. (procedure get_disk
  74.  
  75.     (askdisk
  76.         (prompt #Title_msg
  77.             "\nPlease insert the disk labeled \""#DName"\".")
  78.         (help "Insert this disk in a floppy drive to continue the installation.")
  79.         (assigns)
  80.         (dest #DName)
  81.     )
  82. )
  83.  
  84.     
  85. ;
  86. ; Procedure install_core
  87. ; install the program files and new bits
  88. ; MUST HAVE A VALID DOPUSDEST ;
  89.  
  90. (procedure install_core
  91.  
  92.     (set #Title_msg "Directory Opus 5.5 Magellan Update.\n\n")
  93.  
  94.     (message #Title_msg
  95.         "This procedure will update your existing version of"
  96.         " Directory Opus 5.5 to the Opus 5 Magellan version.\n\n"
  97.         "You MUST have installed Opus 5.5 before"
  98.         " attempting this procedure.\n\n"
  99.         "When finished, you will need to reboot your Amiga and"
  100.         " RE-SERIALISE the new version with your\n"
  101.         " registration No from your ORIGINAL OPUS 5.5.\n\n"
  102.         " If you do not have this available,"
  103.         " look in the About Request of Opus NOW and write"
  104.         " down the details!\n\n")
  105.  
  106.  
  107.     (if (exists #Dopus_prog (noreq))
  108.         (
  109.         (set #Vernum (getversion #Dopus_prog))
  110.         (set #Dop_ver (/ #Vernum 65536))
  111.         (set #Dop_rev (- #Vernum (* #Dop_ver 65536) ) )
  112.         )
  113.     )
  114.  
  115.     (if    (OR (<> #dop_ver 5 ) (<> #dop_rev 5 ))
  116.         (
  117.         (message 
  118.             "Sorry, your version of DirectoryOpus is INCORRECT\n\n"
  119.             "DirectoryOpus version is "#dop_ver"."#dop_rev".\n\n"
  120.             "This upgrade will NOT WORK for your version and will"
  121.             " corrupt your Opus 5 installation.\n\n"
  122.             " You MUST upgrade to version 5.5 BEFORE you using"
  123.             " this Magellan upgrade!\n")
  124.  
  125.  
  126.         (delete "ram:lhex")
  127.         (exit "Instalation terminated!")
  128.         )
  129.  
  130.     ); else
  131.     (if    (
  132.         (get_disk)
  133.         (get_lhex)
  134.         (if    (> (+ (database "total-mem")) 1000000)
  135.             (
  136.             (working #Title_msg 
  137.                 "Copying Files.")
  138.             (copyfiles (source (tackon #Disk_Name "CoreMagellan.lha")) (dest "ram:"))
  139.             (set #SRC "ram:")
  140.             )
  141.             (set #SRC #Disk_Name)
  142.         )
  143.         (working #Title_msg
  144.              "Dearchiving and installing the main program components.\n\n"
  145.              "This will take a minute or so....")
  146.  
  147.         (run (cat "ram:lhex >NIL: <NIL: -qfw=DOpus5: x "#SRC"CoreMagellan.lha "))
  148.         (delete "ram:CoreMagellan.lha" (safe))
  149.  
  150.         (complete 90)
  151.         
  152.     ;
  153.     ; install non-english catalogs
  154.     ;
  155.         (if    (exists (tackon #Disk_Name #CatalogFiles) (noreq))
  156.             (run (cat "ram:lhex >NIL: <NIL: -qfw=DOpus5: x "#Disk_Name #CatalogFiles))
  157.         )
  158.  
  159.         (complete 95)
  160.     
  161.     ;
  162.     ; tidyup
  163.     ;
  164.     ; make sure update module is re-initialised
  165.  
  166.         (run "C:Delete DOpus5:system/update-history FORCE")
  167.     
  168.     
  169.     ;Install the other bits
  170.         
  171.     
  172.         (copyfiles 
  173.             (source (tackon #Disk_Name "ReadMe_Magellan"))
  174.             (dest "DOpus5:")
  175.             (infos)
  176.             (files)
  177.         )
  178.         )
  179.     )
  180. )
  181.  
  182.     
  183.  
  184. (procedure install_complete
  185.  
  186.     (signal_opus)
  187.     (install_core)
  188. )
  189.  
  190.  
  191. ;
  192. ; Real not procedure at last! ;
  193. ;
  194.  
  195.  
  196. (if    (
  197.     (set #Title_msg "Directory Opus 5.5 Magellan Installation.\n\n")
  198.     (askchoice
  199.         (prompt #Title_msg
  200.             "Please select one of following:-")
  201.         (help     "Update current Opus 5.5 to Magellan version "
  202.               "Updates Opus 5 Magellan on your hard disk\n\n")
  203.         (choices
  204.             "Done"                ; 0
  205.             "Update Opus 5 to Magellan ")    ; 1
  206.         (default 0)
  207.     )
  208.     
  209.     )
  210.     (
  211.     (install_complete)
  212.     (message #Title_msg
  213.         "Serialise Directory Opus 5 Magellan\n"
  214.         "---------------------------\n"
  215.  
  216.         "Now the update is completed, please"
  217.         " REBOOT your Amiga and RE-SERIALISE the new"
  218.         " Opus 5 Magellan version with your ORIGINAL"
  219.         " OPUS 5.5 serial number.\n\n"
  220.         " We did tell you to write it down earlier ;-)\n"
  221.         "By the way, if you have not done so, now is"
  222.         " a good time to complete your original"
  223.         " registration card and return it to us."
  224.         " Technical support and warranty will only"
  225.         " be honoured if a valid registration card has"
  226.         " been received.")
  227.  
  228.  
  229.  
  230.     ;
  231.     ;Please please ReadMe 
  232.     ;
  233.  
  234.     (if    (askbool (prompt #Title_msg
  235.             "All things change including software.\n\n"
  236.             "Any changes are noted in the ReadMe"
  237.             " file on the installation disk.\n\n"
  238.             "Do you wish to read the ReadMe file now?\n\n")
  239.         (help "go on, read it now.")
  240.         )
  241.         (if (> (run "Sys:Utilities/MultiView DOpus5:ReadMe_Magellan") 0)
  242.             (if (> (run "Sys:Utilities/AmigaGuide DOpus5:ReadMe_Magellan") 0)
  243.                 (if (> (run "More DOpus5:ReadMe_Magellan") 0)
  244.                     (
  245.                     (get_disk)
  246.                     (run "Opus55_Install:More DOpus5:ReadMe_Magellan")
  247.                     )
  248.                 )
  249.             )
  250.         )
  251.     )
  252.     )
  253. )    
  254.  
  255. (complete 100)
  256.  
  257. (delete "ram:lhex")
  258. (exit "Directory Opus 5 Magellan Install script finished.")
  259.  
  260.