You said you created %99.9 same only 2 bytes of ID different. For me same means hexadecimally comparation of cabs different only 2 bytes. Now you say they do not match totaly different. How can it be original packing. If you find the right packing way. Just extracting and packing should hexadecimally same files maybe just ID different. If not it is not right way of making cab. I have not checked on my pc yet. After check i will decide how original they are. Edit: I have checked. It can succesfully creates cabs. Could not succed to patch cabs. Patched 4 bytes i was suspicious gave cab error. Making cab changes more than i think.
Looks like what I had to do for floppy version : Code: .Set DiskLabel1=1 .Set DiskLabel2=2 .Set DiskLabel3=3 Yes this is what we have, exact same files except the ID, that is supposed to be random, but so far I always got the same, even after regenerating the same archive.
It just list filesize of first file (precopy1.cab) and echo this value to directive, you don't need too look up with cabarc.
Your script did not work for me. Can you update the script without dragging and dropping files? Windows did not let me to drag and drop the files in CMD screen. (Maybe I'm on terminal rather than CMD itself.) Especially this part: Code: Microsoft (R) File Expansion Utility Copyright (c) Microsoft Corporation. All rights reserved. Expanding File precopy2.cab Incomplete, Error Code=0x80070032
No, you just drop the files directly on "1. Unpack and create directive.bat" Keep all files in same folder. I did'nt made it "advanced"
For the floppy version with 3 precopy cab's Code: @echo off if (%~nx1) neq (PRECOPY1.CAB) (echo Drag and drop PRECOPY1.CAB+PRECOPY2.CAB+PRECOPY3.CAB & pause & exit /b) if (%~nx2) neq (PRECOPY2.CAB) (echo Drag and drop PRECOPY1.CAB+PRECOPY2.CAB+PRECOPY3.CAB & pause & exit /b) if (%~nx3) neq (PRECOPY3.CAB) (echo Drag and drop PRECOPY1.CAB+PRECOPY2.CAB+PRECOPY3.CAB & pause & exit /b) del "Diamond Directive.ddf" rmdir /S /Q PRECOPY1 7z.exe x -aos -o%~n1 %1 echo ; Diamond Directive File >> "Diamond Directive.ddf" echo ; >> "Diamond Directive.ddf" echo .Option Explicit >> "Diamond Directive.ddf" echo .Set SourceDir=".\PRECOPY1" >> "Diamond Directive.ddf" echo .Set DiskDirectoryTemplate=".\" >> "Diamond Directive.ddf" echo .Set DiskLabel1=1 >> "Diamond Directive.ddf" echo .Set DiskLabel2=2 >> "Diamond Directive.ddf" echo .Set DiskLabel3=3 >> "Diamond Directive.ddf" echo .Set CabinetName1=PRECOPY1.CAB >> "Diamond Directive.ddf" echo .Set CabinetName2=PRECOPY2.CAB >> "Diamond Directive.ddf" echo .Set CabinetName3=PRECOPY3.CAB >> "Diamond Directive.ddf" echo .Set MaxDiskSize1=%~z1 >> "Diamond Directive.ddf" echo .Set MaxDiskSize2=%~z2 >> "Diamond Directive.ddf" echo .Set CabinetFileCountThreshold=0 >> "Diamond Directive.ddf" echo .Set FolderFileCountThreshold=0 >> "Diamond Directive.ddf" echo .Set FolderSizeThreshold=1000000 >> "Diamond Directive.ddf" echo .Set UniqueFiles=OFF >> "Diamond Directive.ddf" echo .Set RptFileName=nul >> "Diamond Directive.ddf" echo .Set InfFileName=nul >> "Diamond Directive.ddf" echo .Set cabinet=ON >> "Diamond Directive.ddf" echo .Set Compress=ON >> "Diamond Directive.ddf" echo .Set CompressionType=lzx >> "Diamond Directive.ddf" echo .Set CompressionMemory=21 >> "Diamond Directive.ddf" echo ; PRECOPY1.CAB>> "Diamond Directive.ddf" for /f "usebackq EOL=. skip=3 delims=: tokens=3" %%i IN (`"expand.exe -D %1"`) do echo%%i>> "Diamond Directive.ddf" echo ; PRECOPY2.CAB>> "Diamond Directive.ddf" for /f "usebackq EOL=. skip=3 delims=: tokens=3" %%i IN (`"expand.exe -D %2"`) do echo%%i>> "Diamond Directive.ddf" echo ; PRECOPY3.CAB>> "Diamond Directive.ddf" for /f "usebackq EOL=. skip=3 delims=: tokens=3" %%i IN (`"expand.exe -D %3"`) do echo%%i>> "Diamond Directive.ddf" for /f "delims=" %%a in ('wmic OS Get localdatetime ^| find "."') do set dt=%%a set YYYY=%dt:~0,4% set MM=%dt:~4,2% set DD=%dt:~6,2% set HH=%dt:~8,2% set Min=%dt:~10,2% set Sec=%dt:~12,2% set ts=%YYYY%%MM%%DD%T%HH%%Min%%Sec% ren %1 "%~nx1.bak.%ts%.CAB" ren %2 "%~nx2.bak.%ts%.CAB" ren %3 "%~nx3.bak.%ts%.CAB"
A bit out of topic, but do you know how to replicate 2000/XP files ? I mean, decompress a random file and recompress it with LZX:21 and get 100% the exact same file ?
Released v0.2. This release no longer combines precopy1.cab and precopy2.cab in Windows 98 conversions. @Sajjo, @liliactr You can test this release. Also I'd like to have a suggestion for Windows 95.
Microsoft internal ( bypass key for win95 ) ProductType=1 CCP=0 OEMUP=0 Edit setuppp.inf setting is found in setuppp.inf, usually located in precopy2.cab.
0.2 has a bug for some language versions of Windows 98. For example, Chinese version of Windows 98 has three Precopy cab files. But after conversion, makecab only processed precopy1&2, caused an error message
To be honest, I didn't expect some language versions of Windows 98 to have three precopyX.cab files instead of two. Thanks for the report. I'll pull the version 0.2, make a 0.2a.
and 0.2 can't convert Windows Me Chinese version at all. only extracts precopy1.cab to a temp folder. no conversion files generated. I didn't test other language versions of Windows Me yet.
and 0.2 can't convert Windows Me Chinese version at all. only extracts precopy1.cab to a temp folder. no conversion files generated. I didn't test other language versions of Windows Me yet.
SETUPPP.INF stores the value: ProductType= , UPI= , OEMUP= SETUPC.INF stores the value: CCP= Retail/OEM "CCP=" (Compliance Checking Program (upgrade)) is Bossman and overrides "OEMUP=" OEM FPP (Full Packaged Product) can omit "UPI=" and "OEMUP=" Far as i know...
In addition to every product types, you only need to remember that CCP=1 has Setup perform an upgrade check and CCP=0 ignores this check. But I don't know what "UPI=" does.