It's curious, but there is no philological connection between javelin and javelina, despite the spellings. Javelin comes from the Celtic javelot, or the Old Irish gabul, forked stick. Javelina comes from the Spanish jabalina, or "wild pig."
I suppose it makes sense, though. Who's going to want to throw a wild pig for a sporting event?