updated generate script to inject extra.qrc before end tag