  Important tasks in cavity quantum electrodynamics include the generation and
control of quantum states of spatially-separated particles distributed in
different cavities. An interesting question in this context is how to prepare
entanglement among particles located in different cavities, which are important
for large-scale quantum information processing. We here consider a multi-cavity
system where cavities are coupled to a superconducting (SC) qubit and each
cavity hosts many SC qubits. We show that all intra-cavity SC qubits plus the
coupler SC qubit can be prepared in an entangled Greenberger-Horne-Zeilinger
(GHZ) state, by using a single operation and without the need of measurements.
The GHZ state is created without exciting the cavity modes; thus greatly
suppressing the decoherence caused by the cavity-photon decay and the effect of
unwanted inter-cavity crosstalk on the operation. We also introduce two simple
methods for entangling the intra-cavity SC qubits in a GHZ state. As an
example, our numerical simulations show that it is feasible, with current
circuit-QED technology, to prepare high-fidelity GHZ states, for up to nine SC
qubits by using SC qubits distributed in two cavities. This proposal can in
principle be used to implement a GHZ state for {\it an arbitrary number} of SC
qubits distributed in multiple cavities. The proposal is quite general and can
be applied to a wide range of physical systems, with the intra-cavity qubits
being either atoms, NV centers, quantum dots, or various SC qubits.
