fix a bug in building ruby