In the output it also says use the -F flag to over ride the check. Using this I got through that command OK. I have attached the output from the console.
Moving to the second command, I get the following: (I copied the hex file to the root directory to shorten the path)
C:\Program Files\arduino-1.6.9\hardware\tools\avr\bin>avrdude -B 8 -C"C:\Program
Files\arduino-1.6.9\hardware\tools\avr/etc/avrdude.conf" -v -patmega1284p -cstk
500v1 -PCOM5 -b19200 -e -Uflash:w:C:\ATmegaBOOT_1284P.hex
avrdude: invalid file format '\ATmegaBOOT_1284P.hex' in update specifier
avrdude: error parsing update operation 'flash:w:C:\ATmegaBOOT_1284P.hex'
Moving to the second command, I get the following: (I copied the hex file to the root directory to shorten the path)
C:\Program Files\arduino-1.6.9\hardware\tools\avr\bin>avrdude -B 8 -C"C:\Program
Files\arduino-1.6.9\hardware\tools\avr/etc/avrdude.conf" -v -patmega1284p -cstk
500v1 -PCOM5 -b19200 -e -Uflash:w:C:\ATmegaBOOT_1284P.hex
avrdude: invalid file format '\ATmegaBOOT_1284P.hex' in update specifier
avrdude: error parsing update operation 'flash:w:C:\ATmegaBOOT_1284P.hex'