The only time that I'm aware this is discomforting to a guy is if it's an embarrassment or if there is something medically wrong with him (like he just had surgery, for example). I'm, of course, not a male so I cannot answer that with entirely truthful information. It's only a gathering of information I've taken in over the years.
So, if you want to give your guy-friend an erection then dress proactively and speak sexually. You can caress him, kiss him, and engage in sexual stimuli to cause him to become sexually aroused. His body will follow through with that arousal and a boner will probably appear rather quickly then.
The thing about this is that teasing often leads further. You can't just get a guy hard and walk away, pretending that all will be well. He may be disappointed, upset, or even angry at the flirting with no follow-through. Some guys, usually not very close to a person and that are aggressive in nature, may even pressure you to go further or force himself upon you. It's wise to only act sexually to someone you are planning to have sex WITH. Nobody likes a tease. [ Peeps's advice column | Ask Peeps A Question ]
Attention: NOTHING on this site may be reproduced in any fashion whatsoever without explicit consent (in writing) of the owner of said material, unless otherwise stated on the page where the content originated. Search engines are free to index and cache our content. Users who post their account names or personal information in their questions have no expectation of privacy beyond that point for anything they disclose. Questions are otherwise considered anonymous to the general public.