Somebody may suggest that if he does not sell to the brewing company, other farmers will. If he accepts the offer, his earnings will be from a forbidden source. As such, they are not legitimate. My reader is in a very similar position. He does not gamble himself, but he is certainly helping and aiding a forbidden practice.
Horse racing is a major enterprise, indeed a complete industry in non-Muslim countries.
Getting involved with it so heavily is simply lending a helpful hand. That is not allowed to a Muslim. My reader knows that gambling is forbidden, and horse racing has become a major field of gambling. As such, everything designed to help this type of gambling flourish is forbidden. While there is nothing wrong with the breeding and riding of, and dealing with horses, but when that is geared toward serving a gambling sport, it becomes forbidden.