NOVELTY - Producing a compound semiconductor comprising pentanary kesterite or stannite compound, comprises (i) producing at least one precursor layer stack (11) containing a first precursor layer (5) and a second precursor layer, (ii) thermally treating the precursor layer stack in a process chamber (13) such that the metals of the first precursor layer and at least one chalcogen of the second precursor layer are reactively converted into the compound semiconductor, and (iii) supplying at least one process gas into the process chamber during the thermal treatment of the precursor layer stack.    USE - The method is useful for producing an absorber of a thin film solar cell or a thin film solar module (claimed).    DETAILED DESCRIPTION - Producing a compound semiconductor comprising pentanary kesterite or stannite compound, comprises (i) producing at least one precursor layer stack (11) containing a first precursor layer (5) and a second precursor layer, where the first precursor layer is produced by depositing copper, zinc and tin onto a body (12), in a first stage, and the second precursor layer is produced by depositing the chalcogens sulfur and/or selenium on the first precursor layer, in a second stage, (ii) thermally treating the precursor layer stack in a process chamber (13) such that the metals of the first precursor layer and at least one chalcogen of the second precursor layer are reactively converted into the compound semiconductor, and (iii) supplying at least one process gas into the process chamber during the thermal treatment of the precursor layer stack. The process gas contains the respective other chalcogen and/or a compound containing the respective other chalcogen, when the second precursor layer contains chalcogen comprising sulfur or selenium, or the process gas contains sulfur, selenium, a compound containing sulfur and/or a compound containing selenium, when the second precursor layer contains the two chalcogens comprising sulfur and selenium. An INDEPENDENT CLAIM is also included for a thin-film solar cell comprising an absorber arranged on the body, which is made of the compound semiconductor. The compound semiconductor comprises a predeterminable sulfur depth profile from a surface of the compound semiconductor to an interface (10) towards the body, where the sulfur-depth profile is formed such that (a) the sulfur content has a maximum value at the surface that decreases towards the interface, and has a minimum value at the interface, (b) the sulfur content has a minimum value at the surface that increases towards the interface, and has a maximum value at the interface, (c) the sulfur content has a first maximum value at the surface that decreases towards the interface to a minimum value and then increases at the interface, and has a second maximum value at the interface, or (d) the sulfur content has a first minimum value at the surface that increases towards the interface to a maximum value and then decreases at the interface, and has a second minimum value at the interface.    DESCRIPTION OF DRAWING(S) - The drawing shows a schematic process flow for producing the absorber of the thin film solar cell.    Precursor layer (5)    Interface (10)    Precursor layer stack (11)    Body (12)    Process chamber (13)