@echo off
cls
rem makedisk batch file
rem created 6/23/99
rem last modified 08/24/00
rem minimum requirements DOS 6.22 or NT* 3.51 or Windows* 95 or newer

rem Check available environment space
set env_chk=0123456789abcdef
if %env_chk% == 0123456789abcdef goto env_ok
goto env_bad

:env_ok
set env_chk=
rem Check that OS (%1) and destination (%2) are supplied and valid
if "%1" == "" goto USAGE
set dest=
if "%2" == "" set dest=A:
if "%2" == "A:\" set dest=A:
if "%2" == "a:\" set dest=A:
if "%2" == "B:\" set dest=B:
if "%2" == "b:\" set dest=B:
if "%dest%" == "" goto setdest
goto dest_ok

:setdest
set dest=%2
goto dest_ok

:dest_ok
if not exist ..\NET82557.INF goto wrongdir
if "%1" == "nt" goto valid
if "%1" == "NT" goto valid
if "%1" == "w2k" goto valid
if "%1" == "W2K" goto valid
if "%1" == "w9x" goto valid
if "%1" == "W9X" goto valid
if "%1" == "nw" goto valid
if "%1" == "NW" goto valid
if "%1" == "dos" goto valid
if "%1" == "DOS" goto valid
if "%1" == "modem" goto valid
if "%1" == "MODEM" goto valid
goto invalid

:invalid
echo !!! COMMAND LINE PARAMETERS ARE NOT CORRECT !!!
goto usage

:valid

if "%dest%" == "a:" goto floppy
if "%dest%" == "b:" goto floppy
if "%dest%" == "A:" goto floppy
if "%dest%" == "B:" goto floppy
goto nofloppy

:nofloppy
set mode=nofloppy
cls
echo The destination you specified (%dest%) does not
echo appear to be a diskette. If you are trying to create a diskette,
echo press Control-C and answer Y. Then enter this command again, being sure
echo enter the drive letter without a trailing backslash (A: or B:).
echo.
echo If you do want the files copied to %dest%,
pause
goto continue

:floppy
set mode=floppy
cls
if exist %dest%\*.* echo !! THIS DISKETTE DOES NOT APPEAR TO BE FORMATTED !!
echo.
echo Please be sure that the disk in %dest% is 1.44 meg, formatted non-bootable and
echo has no pre-existing files. To format the diskette, press Control-C
echo and answer Y, then enter the command FORMAT %dest%. Otherwise,
pause
goto continue

:continue
if not exist ..\NET82557.INF goto wrongdir
if "%1" == "nt" goto nt
if "%1" == "NT" goto nt
if "%1" == "w2k" goto w2k
if "%1" == "W2K" goto w2k
if "%1" == "w9x" goto w9x
if "%1" == "W9X" goto w9x
if "%1" == "nw" goto nw
if "%1" == "NW" goto nw
if "%1" == "dos" goto dos
if "%1" == "DOS" goto dos
if "%1" == "modem" goto modem
if "%1" == "MODEM" goto modem
goto USAGE

:nt
rem     *** Start of the Windows NT section ***
rem Echo what we are about to do
cls
echo.
echo This batch file will copy the Microsoft Windows NT*
echo files to %dest%
echo press CTRL-C and answer Y if this is NOT correct,
echo otherwise,
pause

cls
echo.
echo Copying files to %dest%
echo.

if exist ..\makedisk\NT4\oemsetup.inf goto split
copy ..\oemsetup.inf %dest%\
goto nttestcopy

:split
copy ..\makedisk\NT4\oemsetup.inf %dest%\
goto nttestcopy

:nttestcopy
if not exist %dest%\oemsetup.inf goto NOCOPY
if exist ..\makedisk\NT4\IANSNT4.SY_ goto 3DES
if exist ..\makedisk\NT4\IANSNT4E.SY_ goto DES
if exist ..\makedisk\NT4\IANSNT4N.SY_ goto NOSEC
goto nt_copyfile

:3DES
copy ..\makedisk\NT4\IANSNT4.SY_ %dest%\
goto nt_copyfile

:DES
copy ..\makedisk\NT4\IANSNT4E.SY_ %dest%\
goto nt_copyfile

:NOSEC
copy ..\makedisk\NT4\IANSNT4N.SY_ %dest%\
goto nt_copyfile

:nt_copyfile
copy ..\E100BNT.SYS %dest%\
copy ..\makedisk\NT4\CBMODEM.SY_ %dest%\
copy ..\makedisk\NT4\NMSCFG.SY_ %dest%\
copy ..\makedisk\NT4\NMSDD.SY_ %dest%\
copy ..\makedisk\NT4\NMSSVCPS.DL_ %dest%\
copy ..\makedisk\NT4\NMSMSG.DL_ %dest%\
copy ..\makedisk\NT4\PROMON.EX_ %dest%\
copy ..\makedisk\NT4\PROSetp.cn_ %dest%\
copy ..\makedisk\NT4\PROSetp.cp_ %dest%\
copy ..\makedisk\NT4\RegSvr32.ex_ %dest%\
copy ..\makedisk\NT4\NMSAPI.DL_ %dest%\
copy ..\makedisk\NT4\PROSetp.hl_ %dest%\
copy ..\makedisk\NT4\NMSSVC.EX_ %dest%\
echo.
echo.
echo Please label your diskette
echo Intel(R) PRO/100 LAN Adapter Configuration and Microsoft Windows NT*
echo Drivers (Release # from your CD)
echo.
echo *  Third party trademarks or brand names are the property of their owners.
goto end

:w2k
rem     *** Start of the Windows 2000 section ***
rem Echo what we are about to do
cls
echo.
echo This batch file will copy the Microsoft Windows 2000* driver
echo files to %dest%
echo.
echo press CTRL-C and answer Y if this is NOT correct, otherwise
pause

cls
echo.
echo Copying files to %dest%
echo.
copy ..\NET82557.INF %dest%\
if not exist %dest%\NET82557.INF goto NOCOPY
goto w2k_copyfile

:w2k_copyfile
copy ..\NET82557.DIN %dest%\
copy ..\E100BW2K.CAT %dest%\
copy ..\E100BNT5.SYS %dest%\
copy ..\DIAG100.EXE %dest%\
copy ..\Prounstl.exe %dest%\
copy ..\IntelNic.dll %dest%\
echo. 
echo Base driver files and DOS diagnostic copied to diskette. 
echo Advanced Networking Features must be installed from
echo a CD-ROM drive, or over the network after a connection
echo to your network file service is established.
echo.
echo PLEASE LABEL YOUR DISKETTE
echo Intel(R) PRO/100 LAN Adapter Configuration and
echo Microsoft Windows 2000* Drivers (Release # from your CD)
echo.
echo *  Third party trademarks or brand names are the property of their owners.
goto end

:w9x
rem     *** Start of the Windows 9x section ***
rem Echo what we are about to do
cls
echo.
echo.
echo This batch file will copy the driver files for Microsoft
echo Windows* 95, 98 and Windows ME* operating systems
echo to %dest%
echo.
echo press CTRL-C and answer Y if this is NOT correct,
echo otherwise,
pause

cls
echo.
echo Copying files to %dest%
echo.

:testcopy
copy ..\net82557.inf %dest%\
if not exist %dest%\net82557.inf goto NOCOPY
goto w9x_copyfile

:w9x_copyfile
copy ..\net82557.din %dest%\
copy ..\8255XDEL.EXE %dest%\
copy ..\8255XNDI.DLL %dest%\
copy ..\E100B.CAT %dest%\
copy ..\E100B.SYS %dest%\
copy ..\E100BNT.SYS %dest%\
copy ..\E100BNT5.SYS %dest%\
copy ..\WOL558.VXD %dest%\
copy ..\DIAG100.EXE %dest%\
copy ..\DOS\e100bodi.com %dest%\
copy ..\Prounstl.exe %dest%\
copy ..\IntelNic.dll %dest%\
echo. 
echo Base driver files and DOS diagnostic copied to diskette. 
echo Advanced Networking Features must be installed from
echo a CD-ROM drive, or over the network after a connection
echo to your network file service is established.
echo.
echo PLEASE LABEL YOUR DISKETTE
echo Intel(R) PRO/100 LAN Adapter Configuration and
echo Microsoft Windows* Drivers (Release # from your CD)
echo.
echo *  Third party trademarks or brand names are the property of their owners.
goto end

:nw
rem     *** Start of the NetWare section ***
echo.
rem Echo what we are about to do
cls
echo.
echo This batch file will copy the NetWare* server and client
echo driver files to %dest%
echo press CTRL-C and answer Y if this is NOT correct,
echo otherwise,
pause

cls
echo.
echo Copying files to %dest%
echo.

:TESTCOPY
copy ..\DIAG100.EXE %dest%\
if not exist %dest%\DIAG100.EXE goto nocopy
goto nw_copyfiles

:nw_copyfiles
md %dest%\NWSERVER
copy ..\NWSERVER\*.* %dest%\NWSERVER
md %dest%\OS2
md %dest%\DOS
copy ..\README.TXT %dest%\
copy ..\CARDBUS\DOS\CBCOMBO.EXE %dest%\
copy ..\DOS\*.* %dest%\DOS
copy ..\OS2\*.* %dest%\OS2

echo.
echo PLEASE LABEL YOUR DISKETTE
echo Intel(R) PRO/100 LAN Adapter Configuration
echo and Novell Drivers (Release # from your CD)
echo.
echo *  Third party trademarks or brand names are the property of their owners.
goto END

:dos
rem     *** Start of the DOS and OS2 section ***
rem Echo what we are about to do
cls
echo.
echo This batch file will copy the driver files for Microsoft
echo DOS* and IBM OS/2* operating systems
echo to %dest%
echo press CTRL-C and answer Y if this is NOT correct,
echo otherwise,
pause

cls
echo.
echo Copying files to %dest%
echo.

:testcopy
copy ..\DIAG100.EXE %dest%\
if not exist %dest%\DIAG100.EXE goto NOCOPY
goto dos_makedirs

:dos_makedirs
md %dest%\DOS
md %dest%\OS2
goto dos_copyfile

:dos_copyfile
copy ..\README.TXT %dest%\
copy ..\CARDBUS\DOS\CBCOMBO.EXE %dest%\
copy ..\DOS\*.* %dest%\DOS\*.*
copy ..\OS2\*.* %dest%\OS2\*.*

echo.
echo PLEASE LABEL YOUR DISKETTE
echo Intel(R) PRO/100 LAN Adapter Configuration
echo and DOS* - OS/2* Drivers (Release # from your CD)
echo.
echo *  Third party trademarks or brand names are the property of their owners.
goto END

:modem
rem     *** Start of the CardbusII modem files section ***
rem Echo what we are about to do
cls
echo.
echo This batch file will copy the Intel(R) PRO/100 Mobile 
echo Adapter Modem driver files for all operating systems
echo to %dest%
echo press CTRL-C and answer Y if this is NOT correct,
echo otherwise,
pause

cls
echo.
echo Copying files to %dest%
echo.

:testcopy
copy ..\CARDBUS\DOS\CBCOMBO.EXE %dest%\
if not exist %dest%\CBCOMBO.EXE goto NOCOPY
goto modem_makedirs

:modem_makedirs
md %dest%\CARDBUS

md %dest%\CARDBUS\SCRIPTS
md %dest%\CARDBUS\UTILITIES
goto modem_copyfile

:modem_copyfile
if exist ..\MDME100B.CAT copy ..\MDME100B.CAT %dest%\
if exist ..\MDME100BW2K.CAT copy ..\MDME100BW2K.CAT %dest%\
copy ..\CARDBUS\SCRIPTS\*.* %dest%\CARDBUS\SCRIPTS
copy ..\CARDBUS\UTILITIES\TELSEL.EXE %dest%\CARDBUS\UTILITIES
copy ..\CARDBUS\UTILITIES\MDMTEST.EXE %dest%\CARDBUS\UTILITIES
copy ..\CARDBUS\UTILITIES\COMSEL.EXE %dest%\CARDBUS\UTILITIES
copy ..\CBMODEM.SYS %dest%\
copy ..\MDME100B.INF %dest%\
copy ..\E100BCFG.EXE %dest%\

echo.
echo PLEASE LABEL YOUR DISKETTE
echo Intel(R) PRO/100 Mobile Adapter Modem drivers 
echo (Release # from your CD)
echo.
echo *  Third party trademarks or brand names are the property of their owners.
goto END



:env_bad
set env_chk=
cls
echo ERROR: Your computer does not have sufficient environment space to
echo run this batch file. Please increase the available environment space
echo and run this batch file again. To increase the avaiable environment
echo space, please do the following;
echo.
echo                                  DOS
echo If you are running DOS, edit the CONFIG.SYS file and find the statement
echo COMMAND=C:\(PATH)\COMMAND.COM /e:(number)
echo where (path) is the directory path to your COMMAND.COM file and (number)
echo is a numerical value. Increase the numerical value by at least 32.
echo If this line does not exist, add the following line;
echo COMMAND=C:\COMMAND.COM /E:512
echo Reboot the computer before running this batch file again.
echo.
echo                        Windows* 2000 and Windows NT*
echo Click Start, then Run, then enter "CMD /E:4096" (without the quotes) to
echo open a DOS window, and then re-run this batch file in that window.
echo.
echo                    Windows* 95, Windows 98 and Windows ME
echo Click Start, then Run, then enter "COMMAND /E:4096" (without the quotes) to
echo open a DOS window, and then re-run this batch file in that window.
goto end

:WRONGDIR
cls
echo You must run this utility from the \MAKEDISK directory.
goto usage

:NOCOPY
cls
echo.
echo Can not copy to %dest%.
echo Please check your syntax and try again
goto usage

:usage
echo.
echo usage rules;
echo MAKEDISK [operating system] [destination (optional, A: if not specified)]
echo.
echo where [operating system] is the OS family you are creating the diskette for
echo W2K   = Microsoft Windows* 2000
echo NT    = Microsoft Windows NT*
echo W9X   = Microsoft Windows 95, Windows 98 and Windows ME*
echo NW    = Novell NetWare* servers and clients
echo DOS   = Microsoft DOS* and IBM OS/2*
echo Modem = Modem drivers for the PRO/100 Mobile Adapter (All Microsoft OS)
echo.
echo and where [destination] is the drive letter and path (such as A:)
echo Do not add a trailing backslash (\) to the destination path. 
echo [destination] (will be A: if none specified) is expected to be formatted media. 
echo This utility MUST be run from the \MAKEDISK directory.
echo. 
echo EXAMPLE:
echo. 
echo To create a Windows NT install diskette in A:, from the MAKEDISK directory run;
echo        MAKEDISK NT
echo.
echo *  Third party trademarks or brand names are the property of their owners.
pause
goto END

:END
set dest=
set mode=
