Igneous rock fragments under pressures and/or temperatures much greater than those at the earth’s surface transform into metamorphic (“changed” + “form”) rock. Over time igneous rock particles can accumulate in layers.
If these layers become compacted and cemented together they become sedimentary (formed from sediment) rock. Fossils and other traces of the past might be preserved in sedimentary rocks. Any rock exposed to “weathering” can fragment becoming the foundation of soil.