@echo off
CD..

copy ROM\OS.nb.payload temp\OS.nb.payload




rem cd tools
rem echo executing ROM_DSM_Patcher against xip Dumping...
rem rom_dsm_patcher -rom os.nb.payload -build 20959
rem cd..



cd temp

..\TOOLS\ImgfsFromNb OS.nb.payload imgfs.bin

..\TOOLS\ImgfsFromDump imgfs.bin imgfs-new.bin
..\TOOLS\ImgfsToNb imgfs-new.bin Os.nb.payload Os-new.nb.payload
..\TOOLS\NBMerge -kaiser os-new.nb

cd..

echo Copying OS-new.nb in \TOOLS Folder...
copy TEMP\OS-new.nb tools\OS-new.nb




cd tools

rem echo executing rom-protector against Dumping...
rem rom-protector.exe -protect os-new.nb
rem rom-unsigner.exe os-new.nb

echo 

echo executing NBHUtils to build nbh file...
htcrt

echo 

echo Executing PagePool Changer...

PagePool_Changer.exe

echo Executing ROMUpdateUtility.exe...


ROMUpdateUtility.exe



