We provide a rigorous solution to the problem of constructing a structural evolution for a network of coupled identical dynamical units that switches between specified topologies without constraints on their structure. The evolution of the structure is determined indirectly from a carefully built transformation of the eigenvector matrices of the coupling Laplacians, which are guaranteed to change smoothly in time. In turn, this allows one to extend the master stability function formalism, which can be used to assess the stability of a synchronized state. This approach is independent from the particular topologies that the network visits, and is not restricted to commuting structures. Also, it does not depend on the time scale of the evolution, which can be faster than, comparable to, or even secular with respect to the dynamics of the units.