Deuteronomy 27:5

27:5 Then you must build an altar there to the Lord your God, an altar of stones – do not use an iron tool on them.

Deuteronomy 20:20

20:20 However, you may chop down any tree you know is not suitable for food, and you may use it to build siege works against the city that is making war with you until that city falls.