The primary/secondary weapon labels are only used by the game to decide which weapon is being shown.
Hit and miss/damage is calculated using the stats from all the txt files, so it doesn't really matter what you name the weapon (if the model only has one weapon). The spear thing is because of collision detection, units with short spears will even back up if they bump into another unit when they aren't attacking it. Try changing the soldier model for a unit with one that doesn't have primary/secondary weapon labeled and you'll see what I mean.