Phase transition in the SmχGd-χS system: sulphur XANES and X-ray emission analysis