; We need to be sure that Processor archive has been installed too!
(set encoderdir
(cat "encoders"
))
(if (NOT (exists encoderdir))
(MESSAGE "\nUnable to locate MP3 Encoder archive files.\n\nMP3 mode will be disabled!")
)
; First we want a proper destination dir for the main files
(set @default-dest
(askdir
(prompt "Please select a destination directory for the Installation\nof SecondSpin. A directory called SecondSpin will be created there")
(help "No help as yet")
(newpath)
(default "Work:")
)
)
(set @default-dest
(tackon @default-dest "SecondSpin")
)
; Ask which CPU the user has
(set #cpu-version
(askchoice
(prompt "Please select the CPU version of SecondSpin you would like to install.")
(help "In order to provide the best speed when handling MPEG Audio, SecondSpin offers several different executables for different processors. If your machine does have an FPU, it's better to use one. If you have a 68000/68010, please upgrade your machine! If the encoder crashes violently, you might have installed FPU version, although your cpu doesn't have a FPU unit, or it isn't working properly.")
(choices "PPC" "060 with FPU" "040 with FPU" "030 with FPU" "030 without FPU" "020 with FPU" "020 without FPU")
))
; Now we need a few configuration details to set the ENV: labels
; First the device name
(set #cd-device
(askstring
(prompt "Please enter the AmigaDOS device name for your CD-Rom drive.")
(help "You should enter the AmigaDOS device name for the interface that your CD-Rom drive is connected to I.E scsi.device")
(default "scsi.device")
))
; Now the device unit
(set #cd-unit
(asknumber
(prompt "Please enter the Unit number for your CD-Rom drive.")
(help "You should enter the Unit number for your CD-Rom drive. For an IDE/ATAPI drive this may be 0 or 1, SCSI drives will typically be in the range 0-7.")
(default 0)
(range 0 15)
))
; Finally the CD-Rom type (for cdda_plan)
(set #cd-type
(askchoice
(prompt "Please select your CD-Rom type from the list below.")
(help "The CD-DA ripper that SecondSpin uses works slightly diferently depending on the make of CD-Rom drive. If you have an IDE/ATAPI drive you should select either 'ATAPI' or 'Old ATAPI' from the list. SCSI drive users should consult their manual, but 'ATAPI' might work fine with most SCSI devices.\n\nNote: Not all CD-Rom drives support CD-DA sampling. If you have such a drive, you may find that the Audio CD-DA quality is poor, or the drive gives eratic results when sampling. This is not caused by SecondSpin.")
(choices "Sony CDU 8003 and compatible" "Toshiba XM3401TA and compatible" "NEC 2X and 3X" "Some Grundig & Toshiba CD-ROM's" "Standard ATAPI / SCSI" "Old ATAPI" "None of the above")
))
; Do the bits here to check #cd-type and set #cd-plan acordingly
(select #cd-type
(set #cd-plan "a")
(set #cd-plan "b")
(set #cd-plan "c")
(set #cd-plan "d")
(set #cd-plan "e")
(set #cd-plan "f")
(set #cd-plan "n")
)
; Now we can start copying our files about
; Make the main dir & copy the files needed.
(makedir @default-dest
(prompt "Creating directory " @default-dest)
(help "No help as yet")
(infos)
)
; Now we can copy the remaining main files
(copyfiles
(source "bin/")
(dest @default-dest) ; Copy the main files to the dest-dir
(all)
(infos)
)
(copyfiles
(source "")
(pattern "SecondSpin.guide#?")
(dest @default-dest)
)
(set #tables-dest
(cat @default-dest "/mpeg_tables" ; We also need a sub-dir "mpeg_tables"
))
(makedir #tables-dest)
(copyfiles
(prompt "Copying the MPEG Tables to " #tables-dest)
(source "mpeg_tables/")
(dest #tables-dest)
(all)
)
; Do the C: S: and LIBS: files
(set #cmd-dest
(cat @default-dest "/external_commands" ; We need an external_commands directory
))
(set #docs-dest
(cat @default-dest "/docs" ; We need a docs directory
))
(set #catalogs-dest
(cat @default-dest "/Catalogs" ; We need a catalog directory (Now who changed this? Wasn't me, i would have got it right the first time ;) )
))
(makedir #cmd-dest)
(makedir #catalogs-dest)
(copyfiles
(source "external_commands")
(dest #cmd-dest)
(all)
)
(copyfiles
(source "Catalogs")
(dest #catalogs-dest)
(all)
)
; Now copy the correct CPU version of the encoder
; Note that this is a little bit neater than the older Installers ;)
(set #lamer-dest
(cat @default-dest "/external_commands/"
))
(if (exists encoderdir)
(select #cpu-version
(copyfiles
(source "encoders/SecondSpin_encoder.elf")
(dest #lamer-dest)
(newname "SecondSpin_encoder")
)
(copyfiles
(source "encoders/SecondSpin_encoder.060fpu")
(dest #lamer-dest)
(newname "SecondSpin_encoder")
)
(copyfiles
(source "encoders/SecondSpin_encoder.040fpu")
(dest #lamer-dest)
(newname "SecondSpin_encoder")
)
(copyfiles
(source "encoders/SecondSpin_encoder.030fpu")
(dest #lamer-dest)
(newname "SecondSpin_encoder")
)
(copyfiles
(source "encoders/SecondSpin_encoder.030")
(dest #lamer-dest)
(newname "SecondSpin_encoder")
)
(copyfiles
(source "encoders/SecondSpin_encoder.020fpu")
(dest #lamer-dest)
(newname "SecondSpin_encoder")
)
(copyfiles
(source "encoders/SecondSpin_encoder.020")
(dest #lamer-dest)
(newname "SecondSpin_encoder")
)
)
)
; Now the mpega-libs to libs:
(set #mpega-dest
(cat "Libs:"
))
(set mpegalib
(cat "Libs:mpega.library"
))
(if (NOT (exists mpegalib))
(select #cpu-version
((copyfiles
(source "libs-mpega/mpegaPPC.library") ; PPC
(dest #mpega-dest)
(newname "mpega.library")
)
(copyfiles
(source "libs-mpega/mpegappcFPU_library.elf") ; And another PPC library