![]() ![]() ![]() ![]() ![]() ![]() |
||||||||||||||||
![]() |
||||||||||||||||
Created on March 10, 2023
This page is only useful for those working with Windows 95 and 98, and has no relevance in Windows NT. You can skip this page if desired. Windows 95's 16-bit setup engine has the capability of altering the AUTOEXEC.BAT and CONFIG.SYS files that were used to initialize MS-DOS. The setup routines in Windows 95 and 98 primarily use this to remove some real mode drivers and TSRs from startup in favor of new 32-bit protected mode drivers. Some drivers make use of this feature as well by adding in some lines to aid in compatibility with MS-DOS programs. For example, a sound driver may load some programs to ensure ideal operation of a sound card when the user is running software in MS-DOS mode. You may not be using these often, so I'll only go over them briefly. UpdateAutoBatUnder this type of section, you'd write down multiple fields or keys containing data just as would be applied in an ordinary INI file. You can use this section to add or remove commands from AUTOEXEC.BAT or unset environment variables. The usage of this section works like this, taken straight out of the Windows 95 Resource Kit:
Multiple CmdAdd, CmdDelete, and UnSet entries can be specified in a section, but the rest can only be used once. CmdDelete entries are processed before CmdAdd entries. We'll apply this in our INF with the following text:
What this will basically do is load the MS-DOS Editor bundled with Windows 95 during bootup. This program is located in the Command directory, which is usually C:\WINDOWS\COMMAND (where most of the DOS programs went after MS-DOS 6.x). Running the editor in AUTOEXEC.BAT is useless and annoying, but you can't ignore it, so it at least makes a good indicator that the entry worked. But I really don't want this program to annoy me like that every time I reboot. So, in the uninstallation section, we should remove this command with this line:
It works just like that. However, CmdDelete has an undocumented flag you can use to REM, or comment out a line containing the command instead.
This will change the line to look like this:
This flag is mostly used by Windows 95 Setup for certain commands where commenting out a command in AUTOEXEC.BAT may be better than deleting it outright, such as when a real mode network driver is replaced with a brand new enhanced mode driver and an experienced user ought to know why their real mode network initiator no longer starts. The other options that can be used in this section are really not made clear and don't look useful either way. For example, PreFixPath is only used twice in all of the INF files used by Windows 95 Setup, specifically SETUPC.INF. Mostly you'll only want to add and remove commands, so we'll leave it at that. UpdateCfgSysA section of this type is used to modify CONFIG.SYS, as the name would imply. The types of entries that can be used here are as listed in the Windows 95 Resource Kit:
This functionality really would've been a lot more useful had it existed during the prime of MS-DOS, but in any case, let's get the file populated...
This sets a couple of performance optimizations for MS-DOS mode, as well as load a real mode IDE CD-ROM driver OAKCDROM.SYS. It's assumed that this driver file is located in the root directory. DevAddDev is poorly explained in the Resource Kit, so I'm going to deconstruct it: the line we're going for is DEVICE=oakcdrom.sys /d:mscd0001, which is accomplished by first specifying the driver name, OAKCDROM.SYS, then the keyword the driver is prefixed with, DEVICE. No flags are set, and the parameter /D:MSCD0001 is given to it so MSCDEX.EXE can call upon it to finish loading the CD-ROM driver. For good measure, let's ensure the real mode driver is unloaded from our startup files when uninstalling:
You cannot comment out devices using UpdateCfgSys; the lines can only be removed. Unfortunately, this function was poorly thought out, as the program won't even allocate enough bytes to print out, say, a complete path to your device. I've tried loading the CD-ROM driver from the Windows and Command directories, didn't work. UpdateAutoBat and UpdateCfgSys existed more as tools for transitioning away from MS-DOS, and are not suited for the DOS enthusiast. Furthermore, those lines I specified for buffers and what not seem to have not appeared in CONFIG.SYS when I ran it. I don't know if it just sets them somewhere else or the entries really have no effect at all. In practice, most INFs will only be deleting a bunch of startup lines to make room for good 32-bit stuff.
Comments
There are a few specification documents on the compression algorithm which in theory would let me be able to build a replacement that scales better on modern systems but I am so busy in college at the time I am typing this... 1 comment on this page Sort: Ascending | Descending Leave a Comment |
||||||||||||||||
|