I'm not sure about that. I haven't seen any statements by Kubrick that would indicate he hoped it would be an "anti-war" movie.
Kubrick's war films: Paths Of Glory, Barry Lyndon, Dr. Strangelove, and Full Metal Jacket all carry the same basic message: that wars are futile.
In POG the French and Germans fight and fight to gain or lose a few inches of territory in grueling trench warfare and thousands of men die in an hour in a botched attack).
In BL, Barry Lyndon wanders through Europe serving in the British army, then deserting and being captured by the German army, which forces him into service until he can desert them in turn, all the while taking part in battles he doesn't even understand the purpose of.
In DS, Lionel Mandrake is the lone voice of reason, trying to figure out the point of a military strategy dreamed up by apparently mentally unbalanced generals that he believes will inevitably result in the destruction of both sides.
In FMJ, Private Joker is an ambivalent participant in combat during a war whose aims he does not see as particularly meaningful to him or to the Vietnamese.