DfE funding announcement comes after school buildings have been left ‘on the point of collapse’, warns heads’ union