he can purchase any long gun (legal to own in home state) he wants from a FFL. handguns however he cannot purchase w/out an in state ID. there is nothing illegal with you buying him a gift PROVIDING he is able to own a firearm and it's legal in his state of residence. However going into a store with him looking/handling a gun then you buying it (if i was at the counter) would constitute a straw purchase and you would be in violation of the law.

another option would be to buy off paper. there is nothing illegal with receiving a gift.