(if (> (exists ("sys:libs/68060.library")) 0) (set cpu "68060"))
(if (= cpu "68000")
(
(set cpuid 0)
)
(
(set cpuid 1)
)
)
;
; Determine the document viewer
; -----------------------------
(if (< aos 39)
(set docv "AmigaGuide")
(set docv "MultiView")
)
;
; Determine the current TCP/IP package
; ------------------------------------
(set amia (getassign "AmiTCP" "a"))
(if amia
(
(set tcptype 1)
)
)
(set ineta (getassign "inet" "a"))
(if ineta
(
(set tcptype 0)
)
)
;
; Set the TCP/IP package to use with RexxNet
; ------------------------------------------
(set tcptype
(askchoice
(prompt "Which type of TCP/IP Package are you using?\n(Your current one has been auto-selected)")
(help "AS225 and AmiTCP are incompatible.\n\n"
"Choose AS225 if the package uses the\n"
"socket.library.\n\n"
"Choose AmiTCP if the package uses the\n"
"bsdsocket.library.")
(choices "AS225 (CPR,I-NET)" "AmiTCP")
(default tcptype)
)
)
(if (= tcptype 0)
(
(if ineta
(
(set dpath "inet:")
(set dcpath "inet:c")
(set dspath "inet:serv")
)
)
(set sbpath "Binaries/AS225/")
(set tcpname "_as225")
)
)
(if (= tcptype 1)
(
(if amia
(
(set dpath "AmiTCP:")
(set dcpath "AmiTCP:bin")
(set dspath "AmiTCP:serv")
)
)
(set sbpath "Binaries/AmiTCP/")
(set tcpname "_amitcp")
)
)
;
; Set the CPU type of RexxNet
; ---------------------------
(set cpuid
(askchoice
(prompt "Which CPU are using in this Amiga?\n(Your current CPU has been auto-selected)")
(help "Select 68000 for a stock 500, 600, 2000 or any\n"
"other Amiga that uses the 68000 CPU chip.\n\n"
"Select 68020+ for an Amiga that uses a\n"
"68020, 68030, 68040 or a 68060 CPU chip.")
(choices "68000" "68020+")
(default cpuid)
)
)
(if (= cpuid 0)
(
(set cpusuf ".000")
)
(
(set cpusuf ".020")
)
)
;
; Create the source path to the binaries
; --------------------------------------
(set rnstr
(cat sbpath "rexxnet" tcpname cpusuf)
)
(set rnstrinfo
(cat sbpath "rexxnet.info")
)
(set rndstr
(cat sbpath "rexxnetd" tcpname cpusuf)
)
(set rndstrinfo
(cat sbpath "rexxnetd.info")
)
;
; Copy the Client: rexxnet
; ------------------------
(set rn (askdir
(prompt "Where do you want the rexxnet copied to?\n(This is the 'Client' software)")
(help "Where do you want to execute the 'Client' from?")
(default dcpath)
)
)
(if rn
(
(copyfiles
(source rnstr)
(newname "rexxnet")
(dest rn)
)
(copyfiles
(source rnstrinfo)
(dest rn)
)
)
)
;
; Copy the Server: rexxnetd
; -------------------------
(set rnd (askdir
(prompt "Where do you want rexxnetd copied to?\n(This is the 'Server' software)")
(help "Where do you want to execute the 'Server' from?")
(default dspath)
)
)
(if rnd
(
(copyfiles
(source rndstr)
(newname "rexxnetd")
(dest rnd)
)
(copyfiles
(source rndstrinfo)
(dest rnd)
)
)
)
;
; Modify the Services file?
; -------------------------
(set servpath
(cat dpath "db/services")
)
(set msg1
(cat "Modify your " servpath " file?\n\nThis is required in order to run RexxNet.\n\nDon't modify this file more than once.\nIf you are re-installing RexxNet or taking\nan upgrade, just 'Skip This Part'. ")
)
(set msg2
(cat "This will modify your " servpath "\n")
)
(textfile
(prompt msg1)
(dest servpath)
(include servpath)
(append "rexxnetd 2001/tcp\n")
(confirm)
(help msg2
"file to contain an entry for rexxnetd.\n"
"\n"
"This line will be added to the end of the table:\n"
"\n"
"'rexxnetd 2001/tcp'\n\n"
"If RexxNet has been previously installed, don't do this again."
" It will add the entry again at the bottom of your file and you will"
"have to manually remove it."
)
)
;
; See if the user wants to automatically start rexxnetd