mkbootimg: support custom offsets
unpack_bootimg: write base and cmdline to file [+fixed operation on windows]