It seems absurd how it is possible for a single person to incorporate the innumerable components required for functionality in a personal system that does not crash 100% of the time due to countless incompatibility errors that come with doing something like this.
It’s really just the package manager. Every package has a description that tells the package manager what it provides and what it needs(called dependencies). So if you tell it to install X, and X needs y and z to function the package manager will automatically pull them in as well as their dependencies. It’ll also know to avoid incompatibilities the same way, the packages themselves contain the information.
90% of the real work in making a new distro is packaging, I.e. finding a way of feeding the package manager the information it needs to do its job by creating the packages. 0.1% of arch users deal with that shit.