home *** CD-ROM | disk | FTP | other *** search
- @echo off
- rem install.bat
- rem C-scape library installation batch file - By Ted 9/27/90
- rem
- rem C-scape 3.2
- rem Copyright (c) 1986-1989, by Oakland Group, Inc.
- rem ALL RIGHTS RESERVED.
- rem
- rem Revision History:
- rem -----------------
- rem 11/06/90 mla killed point 1, added argument instructions, changed example
- rem 11/07/90 mla added error handling
- rem 11/08/90 ted tweaked docs and backslash positions.
- rem 11/10/90 ted added section to support the 5-disk 3.5" disk set.
- rem 12/17/90 mla added \'s to instances of %1cscape..., %2cscape...
- rem 12/31/90 jmd removed incorrect instruction to put '\' at end of command line
-
- if %2x==x goto banner
- if %1==call2 goto call2start
- goto start1
- :banner
-
- echo . INSTALLATION BATCH FILE FOR CSCAPE 3.2 - INSTRUCTIONS:
- echo . 1) Change to the drive and directory with the C-scape distribution files.
- echo . (Normally drive A: with C-scape disk 1 in it.)
- echo . 2) Enter the INSTALL command with options as follows:
- echo .
- echo . The first parameter specifies the drive and directory below which you wish to
- echo . install the C-scape directory (Normally C:).
- echo .
- echo . The second parameter is a code for which version of C-scape to install:
- echo . C-scape for Microsoft C 5.1 : M51
- echo . C-scape for Microsoft C 6 : M6
- echo . C-scape for Borland Turbo C 2.0 : TC2
- echo . C-scape for Borland Turbo C++ 1.0 : TCPP
- echo . C-scape for Zortech C++ 2.0 : ZCPP
- echo .
- echo . Use 'LIBS' as the third argument if you have already installed a version of
- echo . C-scape and want to install only the libraries for another version without
- echo . re-installing the source code and examples.
- echo .
- echo . USAGE EXAMPLES:
- echo . To install Microsoft C 6 version in drive C:, directory \CSCAPE :
- echo . INSTALL C: M6
- echo . To install Turbo C 2.0 version libraries only in G:\TOOLS\CSCAPE :
- echo . INSTALL G:\TOOLS TC2 LIBS
-
- goto end
-
- :start1
-
- if %3x==x goto start2
- if %3==libs goto libinstall
- if %3==LIBS goto libinstall
-
- :start2
-
- echo :
- echo . About to install C-scape documents in %1\cscape
- echo . About to install C-scape headers in %1\cscape\include
- echo . About to install C-scape examples in %1\cscape\examples
- echo . About to install field function source in %1\cscape\source
- pause
-
- rem Create directory to put the C-scape files into.
- md %1\cscape
-
- rem Copy the non-zipped documents to the destination drive.
- copy read.me %1\cscape >nul
- copy *.txt %1\cscape >nul
-
- rem Execute the self-unzipping C-scape files w/ output to the destination drive.
- cshead -d %1\cscape\include
- owlhead -d %1\cscape\include
- example -d %1\cscape\examples
- funcs -d %1\cscape\source
-
- echo :
- echo . Installed C-scape documents in %1\cscape
- echo . Installed C-scape headers in %1\cscape\include
- echo . Installed C-scape examples in %1\cscape\examples
- echo . Installed C-scape field function source in %1\cscape\source
- echo :
-
- :libinstall
-
- echo : --------------------------------------------------------------------
- echo :
- echo . About to install C-scape %2 libraries in %1\cscape\lib
-
- rem NOTE: In order to be able to swap floppies when this batch file is only on
- rem Disk1, this batch file copies itself to the destination drive and then
- rem invokes that version of itself with "call2" inserted as the new first
- rem parameter. That way it can continue to execute when disk1 is removed.
-
- copy install.bat %1\cscape >nul
- %1\cscape\install.bat call2 %1 %2 %3
- goto end
-
- :call2start
- rem NOTE: This is now the second invocation of this batch file and all
- rem parameters are numbered 1 higher.
-
- rem -----------------------------------------------------------------------
- rem First, decide which compiler's libs to install
- rem -----------------------------------------------------------------------
- rem NOTE: the following library installation works for either the 3-disk
- rem set of 5 1/4" disks or the 5-disk set of 3 1/2" disks. It depends
- rem on the fact that disk 1 of the 3-disk set contains the Zortech libs
- rem and disk1 of the 5-disk set doesn't.
-
- if NOT EXIST z2lcscap.exe goto 5set
- rem -----------------------------------------------------------------------
- rem The 3-disk 5 1/4" set
- rem -----------------------------------------------------------------------
-
- if %3==tc2 goto tc20
- if %3==TC2 goto tc20
-
- if %3==tcpp goto tcp1
- if %3==TCPP goto tcp1
-
- if %3==m51 goto ms51
- if %3==M51 goto ms51
-
- if %3==m6 goto ms6
- if %3==M6 goto ms6
-
- if %3==zcpp goto zcp2
- if %3==ZCPP goto zcp2
-
- echo :
- echo . Unrecognized C-scape version specifier: '%3'. Type 'INSTALL' for instructions.
- echo :
-
- rem -----------------------------------------------------------------------
- rem Execute the self-unzipping C-scape files w/ output to the destination drive.
- rem -----------------------------------------------------------------------
-
- :ms51
- echo . Remove disk1 and insert disk3 to install the libraries.
- echo :
- pause
- if NOT EXIST m1lcscap.exe goto ms51
- m1lcscap -d %2\cscape\lib
- m1lowl -d %2\cscape\lib
- m1mcscap -d %2\cscape\lib
- m1mowl -d %2\cscape\lib
- echo :
- echo . Installed libraries for Microsoft C 5.1 in %2\cscape\lib
- echo :
- goto end
-
- rem ----------------------------------------------------------
- :ms6
- echo . Remove disk1 and insert disk3 to install the libraries.
- echo :
- pause
- if NOT EXIST m6lcscap.exe goto ms6
- m6lcscap -d %2\cscape\lib
- m6lowl -d %2\cscape\lib
- m6mcscap -d %2\cscape\lib
- m6mowl -d %2\cscape\lib
- echo :
- echo . Installed libraries for Microsoft C 6 in %2\cscape\lib
- echo :
- goto end
-
- rem ----------------------------------------------------------
- :tc20
- echo . Remove disk1 and insert disk2 to install the libraries.
- echo :
- pause
- if NOT EXIST t2lcscap.exe goto tc20
- t2lcscap -d %2\cscape\lib
- t2lowl -d %2\cscape\lib
- t2mcscap -d %2\cscape\lib
- t2mowl -d %2\cscape\lib
- echo :
- echo . Installed libraries for Borland Turbo C 2.0 in %2\cscape\lib
- echo :
- goto end
-
- rem ----------------------------------------------------------
- :tcp1
- echo . Remove disk1 and insert disk2 to install the libraries.
- echo :
- pause
- if NOT EXIST tplcscap.exe goto tcp1
- tplcscap -d %2\cscape\lib
- tplowl -d %2\cscape\lib
- tpmcscap -d %2\cscape\lib
- tpmowl -d %2\cscape\lib
- echo :
- echo . Installed libraries for Borland Turbo C++ in %2\cscape\lib
- echo :
- goto end
-
- rem ----------------------------------------------------------
- :zcp2
- rem Zortech libs are already on disk1. No need to change disks.
- echo :
- z2lcscap -d %2\cscape\lib
- z2lowl -d %2\cscape\lib
- echo :
- echo . Installed libraries for Zortech C++ in %2\cscape\lib
- echo :
- goto end
-
- rem ----------------------------------------------------------
-
- :5set
- rem -----------------------------------------------------------------------
- rem The 5-disk 3 1/2" set
- rem ----------------------------------------------------------
-
- if %3==tc2 goto tc20_5
- if %3==TC2 goto tc20_5
-
- if %3==tcpp goto tcp1_5
- if %3==TCPP goto tcp1_5
-
- if %3==m51 goto ms51_5
- if %3==M51 goto ms51_5
-
- if %3==m6 goto ms6_5
- if %3==M6 goto ms6_5
-
- if %3==zcpp goto zcp2_5
- if %3==ZCPP goto zcp2_5
-
- echo :
- echo . Unrecognized C-scape version specifier: '%3'. Type 'INSTALL' for instructions.
- echo :
-
- rem -----------------------------------------------------------------------
- rem Execute the self-unzipping C-scape files w/ output to the destination drive.
- rem -----------------------------------------------------------------------
-
- :ms51_5
- echo . Remove disk1 and insert disk3 to install the libraries.
- echo :
- pause
- if NOT EXIST m1lcscap.exe goto ms51_5
-
- m1lcscap -d %2\cscape\lib
- m1lowl -d %2\cscape\lib
- m1mcscap -d %2\cscape\lib
- m1mowl -d %2\cscape\lib
- echo :
- echo . Installed libraries for Microsoft C 5.1 in %2\cscape\lib
- echo :
- goto end
-
- rem ----------------------------------------------------------
- :ms6_5
- echo . Remove disk1 and insert disk4 to install the libraries.
- echo :
- pause
- if NOT EXIST m6lcscap.exe goto ms6_5
-
- m6lcscap -d %2\cscape\lib
- m6lowl -d %2\cscape\lib
- m6mcscap -d %2\cscape\lib
- m6mowl -d %2\cscape\lib
- echo :
- echo . Installed libraries for Microsoft C 6 in %2\cscape\lib
- echo :
- goto end
-
- rem ----------------------------------------------------------
- :tc20_5
- echo . Remove disk1 and insert disk2 to install the libraries.
- echo :
- pause
- if NOT EXIST t2lcscap.exe goto tc20_5
-
- t2lcscap -d %2\cscape\lib
- t2lowl -d %2\cscape\lib
- t2mcscap -d %2\cscape\lib
-
- :tc20_5a
- echo . Remove disk2 and insert disk3 to finish installing the libraries.
- echo :
- pause
- if NOT EXIST t2mowl.exe goto tc20_5a
-
- t2mowl -d %2\cscape\lib
- echo :
- echo . Installed libraries for Borland Turbo C 2.0 in %2\cscape\lib
- echo :
- goto end
-
- rem ----------------------------------------------------------
- :tcp1_5
- echo . Remove disk1 and insert disk2 to install the libraries.
- echo :
- pause
- if NOT EXIST tplcscap.exe goto tcp1_5
-
- tplcscap -d %2\cscape\lib
- tplowl -d %2\cscape\lib
-
- :tcp1_5a
- echo . Remove disk2 and insert disk5 to finish installing the libraries.
- echo :
- pause
- if NOT EXIST tpmcscap.exe goto tcp1_5a
-
- tpmcscap -d %2\cscape\lib
- tpmowl -d %2\cscape\lib
-
- echo :
- echo . Installed libraries for Borland Turbo C++ in %2\cscape\lib
- echo :
- goto end
-
- rem ----------------------------------------------------------
- :zcp2_5
- echo . Remove disk1 and insert disk5 to install the libraries.
- echo :
- pause
- if NOT EXIST z2lcscap.exe goto zcp2_5
-
- z2lcscap -d %2\cscape\lib
- z2lowl -d %2\cscape\lib
- echo :
- echo . Installed libraries for Zortech C++ in %2\cscape\lib
- echo :
- goto end
-
- rem ----------------------------------------------------------
-
- :end
-
-