Is this the correct way to go about this?

The line in question causes a fatal error when the device in question has to build the recovery and kernel in a zImage and the chargerimages are built into the zImage (SGSIIE4GT)