Compactness of viral genomes: Effect of disperse and localized random mutations