I write each one down, along with the date and time of the statement. If possibly I use quotes in my record.
Then I forward all the statements he made in front of multiple people to HR, anonymously.
He should be fired any day now, since he hasn't stopped after three warnings.
OP, it doesn't matter that your boss is ignorant in thinking his offensive comments are just funny, or he's just a jovial guy. Irrelevant. You can be jovial and funny without being offensive.