The film was in development for many, many years. In its earliest stages, it was planned as a directorial project for Sam Peckinpah.
The battle at Palo Alto happened in real life. The rangers were ambushed, and one of the youngest rangers killed was 14. He was given full military honors, and is buried at Fort Ringgold near Brownsville, Texas.
John Milius, who wrote the original script, and Ehren Kruger, who rewrote Milius's script, opted to have their names removed from the final film.