Smectic liquid crystals are a phase of matter in which the constituent molecules tend to align locally parallel to one another and to arrange themselves in layers. Experimental evidence shows that the configuration of the layers in smectic films may be rather complex, possibly with defects - that is, localised regions of sharp change in the orientation of the layers. Defects may occur at isolated points, along lines, or surfaces. In this talk, we discuss a free-discontinuity variational problem for smectic A liquid crystals in two dimensions. We focus on a specific form of the energy functional, which penalises dislocations of the layers along the defects and is lower semicontinuous, so that minimisers exist. The talk is based on joint work with John M. Ball (Heriot-Watt University, Edinburgh and Hong Kong Institute of Advanced Studies) and Bianca Stroffolini (Università Federico II, Napoli).