merging livelihoods_farmland code