Or you could optimize for happiness-truth product. This would lead you to lifestyles, philosophies, and religions which remove any negative correlation between happiness and truth (which I would argue have no inherent, unavoidable relationship with each other).