(abridged) We present STARDUST, a new self-consistent modelling of the spectral energy distributions (SEDs) of galaxies from far-UV to radio wavelengths. In order to derive the SEDs in this broad spectral range, we first couple spectrophotometric and (closed-box) chemical evolutions to account for metallicity effects on the spectra of synthetic stellar populations. We then use a phenomenological fit for the metal-dependent extinction curve and a simple geometric distribution of the dust to compute the optical depth of galaxies and the corresponding obscuration curve. This enables us to calculate the fraction of stellar light reprocessed in the infrared range. In a final step, we define a dust model with various components and we fix the weights of these components in order to reproduce the IRAS correlation of IR colours with total IR luminosities. This allows us to compute far-IR SEDs that phenomenologically mimic observed trends. We are able to predict the spectral evolution of galaxies in a broad wavelength range, and we can reproduce the observed SEDs of local spirals, starbursts, luminous infrared galaxies (LIRGs) and ultra luminous infrared galaxies (ULIRGs). This modelling is so far kept as simple as possible and depends on a small number of free parameters, namely the initial mass function (IMF), star formation rate (SFR) time scale, gas density, and galaxy age, as well as on more refined assumptions on dust properties and the presence (or absence) of gas inflows/outflows.