QNX4 boot loader files.

Hi all:
This question involves QNX6 and QNX4, but here goes.

My aim is to be able to duplicate a QNX4 runtime system onto a CompactFlash but doing it in QNX6. I have an image of the QNX4 partition, which is mountable in QNX6 and therefore easily manageable.

I want to use QNX6 to fdisk and dinit the CF then copy the QNX4 files onto the CF and all done. However the QNX6 fdisk and dinits put the QNX6 primary and secondary loaders on and sadly the CF wont boot.

I need a way for QNX6 to be able to put the QNX4 loaders onto the CF. dloader should do this for me but I dont have the QNX4 loader files.

Ive tried cutting data from the first sectors of a QNX4 disk and partition and using that as the loader data, but I dont seem to be able to get the sizes right.

Has anyone done this or know how to go about it? Any other solution would also be welcome.

Thanks,
Andy

Maybe i have the same errors as your when i use dinit utility to initialize my flashdisk.
I think the problem is lack of path to the bootloader file when using dinit
#dinit -h -B path_to_bootloader_file /dev/hd0xxx
I hope it works

Update:

I’ve found that the QNX6 primary loader works for booting either 4 or 6.

However the secondary loader is more of a problem. I used dd to extract the first 512 bytes of hd10t77 (the QNX4 loader) in QNX4 then in QNX6 used dd to put them back after having done a QNX6 dinit. It worked. But only works for the same sized compact flash.

The contents of the QNX4 secondary loader is different depending on the device. :frowning:

Any ideas?