• Announcements

    • xper

      MSFN Sponsorship and AdBlockers!   07/10/2016

      Dear members, MSFN is made available via subscriptions, donations and advertising revenue. The use of ad-blocking software hurts the site. Please disable ad-blocking software or set an exception for MSFN. Alternatively, become a site sponsor and ads will be disabled automatically and by subscribing you get other sponsor benefits.
Acheron

Driver Compressor

135 posts in this topic

Driver Compressor

Compress drivers to save space on removable media

Program is open source, so open for improvement. Suggestions are welcome.

Info:

Compressed drivers can get installed as any normal driver:

  • OemPnPDriversPath
  • nLite
  • manual installation
  • WHQL kept

Benefits:

  • Smaller files on installation media
  • Seperate drivers from the extra's.

Usage:

Copy compress.cmd to the driver dir and execute it.

The detected driver files are created in new subdirectories, so make sure you have write-access.

When you receive errors running the batch or the result is not as expected please tell me on which driver this behaviour occured and if possible provide me a downloadlink to the driver package

Limitations

- Driver Compressor only processes inf's in the directory it's working directory.

Download :

drv_comp.cmd

Last update 27 october 2005:

-Fixed truncated extension on decompress (minor)

25 october 2005:

- Added Long File Name support

- Added Subdir-reference support

- Improved dependant files check (minor)

- End of line detection added to tagscanner (minor)

28 august 2005:

- Minor GUI fixes

- Fixed invalid call causing strange behaviour in specific situations (minor)

03 may 2005:

- Changed detection of Driver class

- Added Tab as delimiter in inf parser

13 march 2005:

- Changed handling of inf's containing no driver signature

- Windows NT detection added (batch won't run on 9x systems)

- Fixed issue about driver files got placed into subfoldertree

- Minor GUI changes

8 march 2005:

- Fixed bug when driver-inf doesn't contain any files to install (Intel Inf drivers)

- Added PAUSE at program exit.

Edited by hp38guser
0

Share this post


Link to post
Share on other sites

Very nice!

I guess you want Windows to be able to decompress these drivers without problems, so you are using cab compression? So this program's main goal is to simplify the compression of driver files for in the I386 directory?

P.S.: never heard of VC++ :P but it does exist apparently :P

EDIT: is it difficult?

0

Share this post


Link to post
Share on other sites

Yes, I decided to create such a tool for additional drivers I need for my unattended cd. I use nLite, but I prefer to use the winnt.sif method for adding extra drivers. nVidia drivers are known to be over 40 MB, but then I noticed the setup.inf method Windows uses during hardware installation copies less files than the nVidia installer.

Now you can trim down your nVidia drivers to less than 10 MB.

Note. this batch file doesn't support multiple inf's per directory yet. It used the first one detected now. I'm fixing this now.

P.S. VC++ is Microsoft Visual C++. I'm using the 2005 Express beta variant which doesn't have MFC anymore. In stead the .NET 2.0 Framework is used.

0

Share this post


Link to post
Share on other sites

Nice script !

I like people sharing their knowledge in batch scripting. It help me to improve my own batch files and create new one.

And i agree with you with the huge size of NVidia drivers.

Does it mean that i can use the compressed folder to install my Nvidia board just adding the path to WINNT.SIF OemPnPDriversPath=

I have made some modifications to your batch file in order to put the result in

a new subdir using variables set at start of the batch file or assigned by reading the INF file:

::Select Package Source Dir
SET PV=nvidia_Quadro4_41_04_w2k_wxp\WinXP
::SET PV=ad_198x_v5_12_01_3621_w2k_wxp\SMAXWDM\W2K_XP
::SET PV=FSC_1001614\PRO1000\WS03XP2K
::Manufacturer Source Dir
SET SRCPATH="C:\fsc.tmp\Display\%PV%"
::SET SRCPATH="C:\fsc.tmp\sound\%PV%"
::SET SRCPATH="C:\fsc.tmp\network\%PV%"
::Default Destination Dir Root
SET DESTDIR="C:\PnPDrvrs"

../..

PUSHD %SRCPATH%
FOR /F "tokens=1,2 delims=:= " %%i IN ('TYPE %INFNAME% ^| FIND "Class" ^| FIND /I /V "GUID" ^| FIND /I /V "Name" ^| FIND /I /V "= Class section ="') DO (
SET CLASSNAME=%%j
)
POPD

both .INF and .CAT + Compressed files are copied to:

::Create FQ Destination Dir
IF NOT EXIST == "%DESTDIR%\%INFDIR%\" (MD %DESTDIR%\%INFDIR%)

Note. this batch file doesn't support multiple inf's per directory yet. It used the first one detected now. I'm fixing this now.

Intel Corporation graphics adapter is one of this annoying driver with more than one inf and cat file.

How to check which one is the real inf installer, for example i830mnt5.inf for an Intel 865 integrated display and to set the destination to \PnPDrvrs\Display\i830mnt5

Thanks hp38user.

0

Share this post


Link to post
Share on other sites

I have uploaded a new batch file:

It now handles multiple inf's per dir, and makes subdirs like %class%\%infname%

Please let me know if it works ;)

0

Share this post


Link to post
Share on other sites

I have just edited my previous post with a code to solve my need to set a CLASSNAME variable EQUAL to the Class value in the inf file.

Need only one FOR /F command line where you use two FOR /F command lines :)

First attempt with your new batch file:

trying to compress Intel display Drivers with a302.inf to a314.inf (12 inf files) + ialmnt5.inf ; ikch8xx.inf ; isb8xx.inf ; Vch.inf ; wa301a.inf ; wa301b.inf (6 inf files) + various exe, dll and sys files.

if we take a look at the inside, only ialmnt5.inf has a Class=display and is used to install the driver. Others inf's are copied by ialmnt5.inf copy sections, like exe sys and dll.

The batch create a DisplayCodec dir and a302 subdir and copy a302.sys and a302.cat uncompressed and a302.sy_ (compressed) in subdir and then exit.

Can you add a check on the Class value to determine which inf file to use?

0

Share this post


Link to post
Share on other sites

Nice try Bilou_Gateux, but I have used an alternative method to do the same thing which work with all setup files

0

Share this post


Link to post
Share on other sites
Nice try Bilou_Gateux, but I have used an alternative method to do the same thing which work with all setup iles

I don't understand "iles". It is a typo error or should i go back to school to learn English :lol:

The other problem i would like to fix: set the folder name to the first eight chars for drivers with Class name longer than 8 like Class=SmartCardReader

0

Share this post


Link to post
Share on other sites

BTW, I said I was gonna fix that, no need for help

0

Share this post


Link to post
Share on other sites

Fixed the file, it did not work properly. It should work now defenitely.

Man, it's a hard work to get it foolproof :wacko:

0

Share this post


Link to post
Share on other sites
nVidia drivers are known to be over 40 MB, but then I noticed the setup.inf method Windows uses during hardware installation copies less files than the nVidia installer.

Now you can trim down your nVidia drivers to less than 10 MB.

Do you mean compressed or decompressed?

After using your batch on nVidiadrivers, three directories were created:

1. A maindirectory called Display

2. Two subdirectories in Display called nv4_disp and nv4disp2

Which directory do I need for my Unattended Disc?

They both have almost the same files but nv4_disp is a little bigger (about 0.02mb).

BTW, I have a Geforce4 TI4200 8x AGP

EDIT:

What is installed by nVidia-installer that isn't installed by windows-setup.inf-method?

0

Share this post


Link to post
Share on other sites

Report on check with NVidia display Drivers (i'm not using the latest available version but a customized version from my OEM):

No problem. One Display dir with a subdir containing one inf, one cat file and all others files compressed.

Report on check with Intel display Drivers:

1/ DisplayCodec dir is created with one subdir for each a3xx.inf, vch.inf, wa301x.inf file with Class=DisplayCodec in [Version] section. Each subdir content is an inf file, a cat file and a sy_ file.

2/ Display dir is created with an ialmnt5 subdir in it.

The content is exactly what is expected: both ialmnt5.inf and ialmnt5.cat non compressed + all others exe, dll sys compressed. Even inf and sy_ from Class=Displaycodec and Class=IntelUnifiedDisplayDriver are present. Only cat files are missing.

3/ IntelUnifiedDisplayDriver is created with one subdir for both ikch8xx.inf and isb8xx.inf file with Class=IntelUnifiedDisplayDriver in [Version] section. Each subdir content is an inf file, a cat file and a sy_ file.

How to avoid creation of dirs for infs with Class that aren't used for base driver install? Inf files containing a [ClassInstall32] section should not been parsed.

Their Class= in [Version] section isn't a predefined classes used by class installer.

Some infos come from here

0

Share this post


Link to post
Share on other sites

I missed some GOTO :EOF, and increased the compression (LZX CAB).

If something not working as expected report it here

0

Share this post


Link to post
Share on other sites

Fixed some more stuff by adding extra checks. It should work now for every driver

0

Share this post


Link to post
Share on other sites

Brilliant work, been looking for somthing like this for while, having trouble with my drivers though!

I get error "file not found" or it just goes into a loop?

Here they are incase you want to take a look

Cheers

Epson Stylus Colour 670

Audio, VGA, Chipset Drivers

SpeedTouch 330 ADSL

Also, is there any way to find out if there are any extra files that arent needed, the audio drivers are 34MB uncompressed! Obvious files are help files but there must be more. Any ideas?

0

Share this post


Link to post
Share on other sites

I looked on your Epson Stylus Colour drivers, these files uses a different kind of compression (MSZZ), however it's not supported yet. I'll look at it. Also the class isn't detected properly, gonna fix that soon.

The Realtec Drivers just compress fine, but why do you have so many inf's? It looks like a loop but it isn't. It just ends it loop after the 26th pass :wacko:

You must find out which inf your Realtec Audio card really uses during Windows Hardware Installation. The compressed size should be around 8 MB.

Currently fixed your problem having with the VIA VGA Drivers, you now will have a folder of just 2.1 MB's instead of 10.2 MB :hello:

VIA HyperION drivers are known to be obsolete for Windows XP SP2, however on older systems you can use the compress.cmd on each subfolder. Make sure there's some inf in it!

Your SpeedTouch uses Installshield for its installation. Google the net for some installshield decompressor to extract the driver files. After thats done you can use my batch to compress it to be used during Windows Hardware Installation.

Thanks for giving me this bugreport and providing me the files

Edited by hp38guser
0

Share this post


Link to post
Share on other sites
The Realtec Drivers just compress fine, but why do you have so many inf's? It looks like a loop but it isn't. It just ends it loop after the 26th pass wacko.gif
oh so its the inf`s making it repeat itself :lol: dont know why there are so many, these drivers are from my mobo driver page here.

i intergrate all drivers accept speetouch with nlite, with the audio drivers i point it to Alcxwdm.inf. so i removed all the other inf`s out of directory and now the file size is 7.58MB :thumbup havent tested them yet though.

Currently fixed your problem having with the VIA VGA Drivers, you now will have a folder of just 2.1 MB's instead of 10.2 MB welcome.gif

10 to 2MB wow! Where have you and your batch file been all my life hp38guser :lol: never thought that much compresion was ever possible.

VIA HyperION drivers are known to be obsolete for Windows XP SP2, however on older systems you can use the compress.cmd on each subfolder. Make sure there's some inf in it!

just read this thread you only need a few files but when i use your batch it copys even less which is good but when i try to move them into one folder to intergrate with nlite it asks to overwrite one of the .cat files. is this ok? what are .cat files for?

as for modem drivers, thats a bit complicated for me, i will have to tackle that another day :D

Cheers

0

Share this post


Link to post
Share on other sites

Last update tonight:

Handles now the Class even if tabs are used in driver infs and support added for files which are compressed yet.

Even the Epson drivers ( 3.75 MB compressed with SZDD ) goes down to 2.40 MB's :thumbup

0

Share this post


Link to post
Share on other sites

Yes sixpack, that will do fine to decompress installshield cabs.

@Ionit, the cat-file is the digital signature Microsoft uses to check the drivers. If this file is missing Windows won't install the driver during Hardware installation Setup unless you specify:

[Unattended]
DriverSigningPolicy=Ignore

in your winnt.sif

Updated the batch with some tag-detector. Lines with ";" won't be parsed now.

0

Share this post


Link to post
Share on other sites

:thumbup Nice tool. I made a unattended cd with lots and lots of drivers on it (many friends ask me to install and configure their pc) but I can't use it for all of them.

example if used on nvidia drivers it installs only in english and some functions aren't available (the pre-settings for most common games etc )

But an inf install during setup from the full map does it right.

There are no diffrences in the inf so why ???? I realy don't know.

Never the less awsome tool

0

Share this post


Link to post
Share on other sites

nVidia's using the coinstaller to setup additional components.

However I'm creating a minimalistic XP setup and don't need those extra's. They just consume lots of memory when used.

With the minimal nVidia drivers I can play all 3D-games without any problems B)

@Hoppy, tell me which drivers are causing problems and I'll take a look at it.

0

Share this post


Link to post
Share on other sites

Thanx sixpack for the link, cant seem to get the cabs to extract though, most likely i`m doing somthing wrong. I have no experience doing this :unsure: maybe somone can point me in the right direction.

Even the Epson drivers ( 3.75 MB compressed with SZDD ) goes down to 2.40 MB's thumbup.gif

Great work.

BTW, have done nlite install with these drivers and all seems well, have got rid of cat files aswell & saved another half a meg :D I thank you. :thumbup

0

Share this post


Link to post
Share on other sites

i have a question to

i use ati drivers, and when i exstract the setup.exe there are subfolders.

is it the best way to copy all of the contense of every subfolder in to one and then run your driver batch?

0

Share this post


Link to post
Share on other sites

Version: 66.93 (Got rid of the setup exe en stuff but kept other dll's)

I myself don't need the extra's as I know you don't need them, but the biggest isue is the language (dutch) isn't selected. It's for the people I install windows for.

0

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now

  • Recently Browsing   0 members

    No registered users viewing this page.