jaws75 Posted November 19, 2006 Share Posted November 19, 2006 (edited) Ok I really disliked the fact that during driver decompression using the drivers from CD or driverpacks.net method the screen would stay blank for up to 5 minutes.It looks like the installation is frozen.The solution is here.If you use a self extracting 7zip file with the right switches it will display a progress bar during extraction.code for the self extracting archive is DPdriverpack-name.exe x -y -aoa -o"%SystemDrive%"put the commandFOR %%h IN (%CDDRIVE%\OEM\Drivers\DP*.exe) DO "%%h" x -y -aoa -o"%SystemDrive%"in your presetup.cmd file and the driverpacks will extract showing a progress bar.no more blank screen. Make sure the path reflects the path to your files.Note: Your driverpack files must begin with "DP" for it to work. Or change the batch file.To take it one step further I wrote a batch file to convert your driverpacks (.7z files) to sfx files (.exe).It modifies the dialog for each file so it will say "Extracting 3 of 10 > DP_driverpack_name..."ExampleHow it works is...1) makes a list of all the .7z archives in the current folder2) counts them3) creates a resource script (.rc) based on file number and name4) compiles the resource script (.rc) into a resource file (.res)5) uses reshacker to update the .sfx file with the new dialog (.res file)6) converts the .7z file to a .exe self extracting file (via copy. NO recompression)7) repeats 3-6 until all files are convertedThe original .7z files are not deleted and the creation of the .exe files is very quick.Note: NO recompression is done to the driverpacks. All it does is add the sfx module via the copy command. It runs as fast as your PC can copy a file. About 10 seconds or so for the 10 archives I used (223mb).After conversion just put the .exe files in your OEM\drivers folder and add the above line to your presetup.cmd file and that's it.Download the DP_files.zip file and extract it. put the files in the folder with your .7z driver files.you will have the modify.bat file and the bin folder in there.Run the modify.bat file.You no longer need the .7z files, just the .exe files.Download filesmodify.bat@echo offset x=1set z=0dir /b /a-d DP*.7z > temp.txtfor /F "tokens=* delims= " %%h in (temp.txt) do call :countfor /F "tokens=* delims= " %%J in (temp.txt) do call :sub %%Jdel /q temp.txtdel /q bin\ResHacker.inidel /q bin\ResHacker.loggoto :eof:sub>diag.rc echo 500 DIALOG 0, 0, 195, 30>>diag.rc echo STYLE DS_FIXEDSYS ^| DS_MODALFRAME ^| DS_CENTER ^| WS_POPUP>>diag.rc echo CAPTION "Extracting">>diag.rc echo LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_US>>diag.rc echo FONT 8, "MS Shell Dlg">>diag.rc echo {>>diag.rc echo CONTROL "Extracting %x% of %z% > %~n1", 69, STATIC, SS_LEFT ^| WS_CHILD ^| WS_VISIBLE, 5, 2, 185, 8 >>diag.rc echo CONTROL "Progress1", 1000, "msctls_progress32", PBS_SMOOTH ^| WS_CHILD ^| WS_VISIBLE ^| WS_BORDER, 5, 12, 185, 13 >>diag.rc echo }bin\gorc.exe /r diag.rcbin\ResHacker.exe -addoverwrite bin\custom.sfx, bin\custom.sfx, diag.res,,,copy /b bin\custom.sfx + %~nx1 %~n1.exedel /q diag.rcdel /q diag.resset /A x=%x%+1goto :eof:countset /A z=%z%+1goto :eofTested works with Pyron's, ile5's and BTS's setup.ex_I use the program gorc.exe to compile the .rc files to .res files from belowSourceThe background in my pic is achieved with this methodhereAny feedback would be great.Thanks.:EDIT: I removed the underscore "_" from the batch file to match the way BTS renames the files. Edited December 2, 2006 by jaws75 Link to comment Share on other sites More sharing options...
Sonic Posted November 19, 2006 Share Posted November 19, 2006 Good job ! Link to comment Share on other sites More sharing options...
jaws75 Posted November 19, 2006 Author Share Posted November 19, 2006 (edited) Thanks for the feedback.If anyone has any ideas on how to improve this or advice on cleaning up the code please offer it.Thanks.I modified the above extraction code to...FOR %%h IN (%CDDRIVE%\OEM\Drivers\DP_*.exe) DO "%%h" x -y -aoa -o"%SystemDrive%"fromFOR %%h IN (%CDDRIVE%\OEM\Drivers\DP_*.exe) DO "%%h" e -y -o"%SystemDrive%"While the original did not seem to present a problem I figured this makes it more robust.It tested fine the new way.ciao Edited November 19, 2006 by jaws75 Link to comment Share on other sites More sharing options...
Gyppie Posted November 20, 2006 Share Posted November 20, 2006 Hey!I realy love this. Great job!I also like your background in the example. Are you willing to share that too?Thanx, and keep up the good workGyppie B) Link to comment Share on other sites More sharing options...
jaws75 Posted November 20, 2006 Author Share Posted November 20, 2006 I also like your background in the example. Are you willing to share that too?Here is the original Link to comment Share on other sites More sharing options...
jaws75 Posted November 22, 2006 Author Share Posted November 22, 2006 (edited) For some reason I write my batch file with...STYLE DS_FIXEDSYS | DS_MODALFRAME | DS_CENTER | WS_POPUPBut the final result always ends up like thisSTYLE DS_FIXEDSYS | DS_MODALFRAME | DS_CENTER | WS_POPUP | WS_CAPTIONThe script is written correctly but gorc.exe when compiling is adding it. The difference is the addition of the title bar. It works without it and that's the way I like it but........Is it improper not to have the title bar?Should it always be there?Is it bad code without it?Should I add it back in to the code since it get's put there anyway?Or should I not under protest?Based on the lack of feedback maybe I should just let this project fade into obscurity. Edited November 22, 2006 by jaws75 Link to comment Share on other sites More sharing options...
gospeed Posted December 2, 2006 Share Posted December 2, 2006 (edited) Note: Your driverpack files must begin with "DP_" for it to work.Any way around this? My driver packs were renamed along the way (for example, DPGC609.7Z) and since its a multiboot with quite a few O/S's on it sharing the one OEM file, it would take some work to rename them. I am not quite sure when they got renamed along the way but if they can be changed back I would need to know what documents reference to them to change the wording back I guess. I looked in presetup.cmd, but it doesnt appear to be referencing them by their names specifically? Is it really just as simple as renaming them back?Wish I would have read about this method before I started! Progress bars would rock!Thanks in advance!----Jeff Edited December 2, 2006 by gospeed Link to comment Share on other sites More sharing options...
jaws75 Posted December 2, 2006 Author Share Posted December 2, 2006 (edited) Note: Your driverpack files must begin with "DP_" for it to work.Any way around this? My driver packs were renamed along the way Simple fix.In the batch file change the linedir /b /a-d DP_*.7z > temp.txttodir /b /a-d *.7z > temp.txtand in your presetup.cmd changeFOR %%h IN (%CDDRIVE%\OEM\Drivers\DP_*.exe) DO "%%h" x -y -aoa -o"%SystemDrive%"toFOR %%h IN (%CDDRIVE%\OEM\Drivers\*.exe) DO "%%h" x -y -aoa -o"%SystemDrive%"I don't like using *.exe just because any .exe in that folder will be executed.If they all start with DP like your example without the underscore "_" then just delete that from the two locations. IE... change DP_ to just DPOn another note if you find the progress bar too large you can make it smaller by changing>>diag.rc echo FONT 10, "MS Shell Dlg"to>>diag.rc echo FONT 8, "MS Shell Dlg"I hope that helps. Edited December 2, 2006 by jaws75 Link to comment Share on other sites More sharing options...
gospeed Posted December 2, 2006 Share Posted December 2, 2006 WOW! now that is fast service! I will give it a shot here in just a sec. Thanks! Link to comment Share on other sites More sharing options...
gospeed Posted December 2, 2006 Share Posted December 2, 2006 (edited) Well, I guess I should ask, what method if driverpack install is this meant for? I used BTS driverpacks, and used driverpacks base to install them into each of my individual O/S's. I am using the method #2 where they create a fake setup that is executed before actual setup. My DVD works fine as it sits, but I notice that your folder structure is different than mine (your driver pack sits in OEM\Drivers, where mine is directly in OEM) and I am not sure if that makes a difference. I did modify the command to delete the _ and also edited my presetup.cmd to delete the _ and change the folder structure (deleted \Drivers). It skips right over where the drivers once were being installed, like it cant find the files. Is there any problem with the folder structure being different? This is the contents of my OEM folder:BINATICCP.INSDPC6091.7ZDPCP6091.7ZDPGA6011.7Zetc...There is no driver folder inside. Edited December 2, 2006 by gospeed Link to comment Share on other sites More sharing options...
jaws75 Posted December 2, 2006 Author Share Posted December 2, 2006 I use the driverpacks from BTS as well as the fake setup.exe from driverpack base but I do not use the driverpack base installer. I just do it manually instead.Do you have...FOR %%h IN (%CDDRIVE%\OEM\DP*.exe) DO "%%h" x -y -aoa -o"%SystemDrive%"in you presetup.cmd file (notice the changes to reflect your info)Is the OEM folder in the root of the CD? eg. D:\OEMafter running my batch file are all the .exe files created?they should be put in your OEM folder instead of the .7z files.Did you put them in the OEM folder?If still not working show me the contents of your presetup.cmd to better help you. Link to comment Share on other sites More sharing options...
gospeed Posted December 2, 2006 Share Posted December 2, 2006 Yes to all My Presetup wording is exactly that...it was only modified to add your line to itmy OEM folder is in the root...there is only one OEM folder but 6 O/S's that point to itI performed the batch file within my OEM folder, and it seems to have created and edited just as designed- and then I deleted the .7z driverpacks. Here is my presetup.cmdThanks for taking a look!REM +==========================================================================+REM | |REM | This presetup.cmd file was dynamically generated by the DriverPacks |REM | BASE, to work with the DriverPacks without any further editing. |REM | However, if you would like to add some custom functionality, you can |REM | edit this file without any problems. Just take into record that this |REM | file will be erased if you run the DriverPacks BASE on these Windows |REM | installation files again! |REM | |REM | With special thanks to: |REM | -Pyron, a06lp and iLE for their help with this method; |REM | -schalti for the optional 'Keep the Drivers' system and Pyron (again) |REM | for turning it into an executable. |REM | |REM +==========================================================================+REM +==========================================================================+REM | Showing the progress bar |REM |--------------------------------------------------------------------------|FOR %%h IN (%CDDRIVE%\OEM\DP*.exe) DO "%%h" x -y -aoa -o"%SystemDrive%"REM +==========================================================================+REM | Finding CD/DVD driveletter. |REM |--------------------------------------------------------------------------|SET TAGFILE=\OEMFOR %%i IN (C D E F G H I J K L M N O P Q R S T U V W X Y) DO IF EXIST "%%i:%TAGFILE%" SET CDDRIVE=%%i:REM +==========================================================================+REM | Decompressing the DriverPacks to the harddisk. |REM |--------------------------------------------------------------------------|%CDDRIVE%\OEM\bin\7z.exe x -y -aoa %CDDRIVE%\OEM\DP*.7z -o"%SystemDrive%"REM +==========================================================================+REM | Copying/decompressing the files to finish the installation. |REM |--------------------------------------------------------------------------|%CDDRIVE%\OEM\bin\7z.exe x -y -aoa %CDDRIVE%\OEM\bin\DPsFnshr.7z -o"%SystemDrive%"COPY /Y %CDDRIVE%\OEM\bin\DPsFnshr.ini %SystemDrive%\IF EXIST %CDDRIVE%\OEM\*.ins COPY /Y %CDDRIVE%\OEM\*.ins %SystemDrive%\REM +==========================================================================+REM | Scanning for driverdirectories. |REM |--------------------------------------------------------------------------|%CDDRIVE%\OEM\bin\DevPath.exe %SystemDrive%\DREM +==========================================================================+REM | Disable Driver Signing Policy and keep it disabled. |REM |--------------------------------------------------------------------------|START %SystemDrive%\DSPdsblr.exeEXIT Link to comment Share on other sites More sharing options...
Camarade_Tux Posted December 2, 2006 Share Posted December 2, 2006 @jaws75, have you posted this on DP's forum ? Link to comment Share on other sites More sharing options...
jaws75 Posted December 2, 2006 Author Share Posted December 2, 2006 (edited) @jaws75, have you posted this on DP's forum ?Yes I have.gospeedThe problem is in your presetup.cmd fileThe "showing the progress bar" section must go AFTER the "finding the CD/DVD drive letter" section. It has not determined the %CDDRIVE% variable yet for it to work before. Also the original "Decompressing the DriverPacks to the harddisk." section can be commented out as it's not needed any more (add REM before the line) or you can remove the section.The whole thing should look like this.REM +==========================================================================+REM | |REM | This presetup.cmd file was dynamically generated by the DriverPacks |REM | BASE, to work with the DriverPacks without any further editing. |REM | However, if you would like to add some custom functionality, you can |REM | edit this file without any problems. Just take into record that this |REM | file will be erased if you run the DriverPacks BASE on these Windows |REM | installation files again! |REM | |REM | With special thanks to: |REM | -Pyron, a06lp and iLE for their help with this method; |REM | -schalti for the optional 'Keep the Drivers' system and Pyron (again) |REM | for turning it into an executable. |REM | |REM +==========================================================================+REM +==========================================================================+REM | Finding CD/DVD driveletter. |REM |--------------------------------------------------------------------------|SET TAGFILE=\OEMFOR %%i IN (C D E F G H I J K L M N O P Q R S T U V W X Y) DO IF EXIST "%%i:%TAGFILE%" SET CDDRIVE=%%i:REM +==========================================================================+REM | Showing the progress bar |REM |--------------------------------------------------------------------------|FOR %%h IN (%CDDRIVE%\OEM\DP*.exe) DO "%%h" x -y -aoa -o"%SystemDrive%"REM +==========================================================================+REM | Decompressing the DriverPacks to the harddisk. |REM |--------------------------------------------------------------------------|REM %CDDRIVE%\OEM\bin\7z.exe x -y -aoa %CDDRIVE%\OEM\DP*.7z -o"%SystemDrive%"REM +==========================================================================+REM | Copying/decompressing the files to finish the installation. |REM |--------------------------------------------------------------------------|%CDDRIVE%\OEM\bin\7z.exe x -y -aoa %CDDRIVE%\OEM\bin\DPsFnshr.7z -o"%SystemDrive%"COPY /Y %CDDRIVE%\OEM\bin\DPsFnshr.ini %SystemDrive%\IF EXIST %CDDRIVE%\OEM\*.ins COPY /Y %CDDRIVE%\OEM\*.ins %SystemDrive%\REM +==========================================================================+REM | Scanning for driverdirectories. |REM |--------------------------------------------------------------------------|%CDDRIVE%\OEM\bin\DevPath.exe %SystemDrive%\DREM +==========================================================================+REM | Disable Driver Signing Policy and keep it disabled. |REM |--------------------------------------------------------------------------|START %SystemDrive%\DSPdsblr.exeEXITLet me know how it worked. Edited December 2, 2006 by jaws75 Link to comment Share on other sites More sharing options...
gospeed Posted December 2, 2006 Share Posted December 2, 2006 (edited) works perfectly now, thank you so much! No more blank screen This really shouldnt even be an option though, progress bars are 110% necessary! Edited December 2, 2006 by gospeed Link to comment Share on other sites More sharing options...
Recommended Posts
Please sign in to comment
You will be able to leave a comment after signing in
Sign In Now