Long-term stellar activity variations and their effect on radial-velocity measurements