Practically everything humans do is done with other people in mind. We are social primates after all.
ok you've been saying this threw this whole post and i just kinda let it go by but i'm gonna say it now. you've got this concept backwards.
being a social animal doesn't mean you seek out pleasing others, this means you search out others who are pleased in the same ways. you seek out people of similar interest to be social with, a common bond, kindred spirits, social clicks. you do not listen to a certain kind of music so people like you, nor eat a certain type of food or like a certain color. you also don't attract friends and social groups, you seek them out by how you convey your interests. these things are primarily done for personal pleasure.
then you add in "for mating purposes" which is another entirely different standard that people do which is mostly physical. people working out, being healthy and fit, ripped abs, good perfume, nice clothes. these are things people do to attract others not make music.
making music was never done to to attract others, music was invented as an entertaining way of passing on history and beliefs from one generation to another. you keep saying primate, well look at how primates attract others. they fight, they intimidate the others just like teenagers do huh? i've yet to see a monkey break out into song to get a female in the mood.
then you ask how did music suddenly escape these rules. well your rules are a little misconstrued for one. 2 music was never out of the rules, it's still being used in the same ways it was original conceived, to pass on ideas, history and beliefs not to stand out and be accepted.
there are a certain amount of women who would find a musician sexy, and just as many musicians who do it knowing this fact. there are also some who do it to stand out and be remembered. but for the most part people make music as a personal interest and entertainment and they will continue to do so rather people enjoy it or not, prime example? i don't see the village people retiring and their pretty much a laughing stock anymore. this why retired musicians still play, why terrible musicians still play, why people learn, why others give up before they even get any good. simply because it's a personal interest. people will not spend years and years honing skills in the possibility that 'somebody MIGHT like them' or they 'COULD be accepted'.
would people drop a song others boo at from a set list? i can name hundreds of songs that should have been dropped long before the stage yet they keep getting played. not only are people social animals their also arrogant and selfish and i can guarantee their own interests and desires take priority over the audience so yeah if a musician likes a song enough he'll endure constant booing to play it and he'll just tell himself they have no taste. the only time this isn't going happen is when they desire money more and whoever is paying them don't like it or they desperately need approval and give up because it's not going well.
ok, i'm not going to take this any further. but i will add, this is a lot like Freud thinking everybody wants to sleep with their mother simply cuz he did.....