The expression in v. 5, “that which pertaineth,” or, anything that pertains to a man or a woman means clothing, weapons, utensils, and tools. Then and now, transvestism is associated with homosexuality, and it has always had anti-biblical religious connotations. Verses 1-4 set forth the God-declared fact of property as His ordination. Now, in v. 5, we see that our sexuality is a property that we must not attempt to divest ourselves of, for to do so is an abomination in God’s sight. It is filthy behavior.
The first law, in v. 5, prohibits cross-dressing at the very least, and this is declared as “abomination unto the Lord.” Where the word “abomination” is used, we know that we are on serious grounds. This law can mean:
a) that transvestite dressing is barred, whatever the reason for it;
b) that some pagan cults, celebrating chaos, required cross-dressing and perverse sexual acts as a part of worship, and God’s people are not to imitate them in any way;
c) and that not only cross-dressing but also engaging in work that properly belongs to the other sex is forbidden. (It was long ago seen as barring combatant war roles to women);
d) the law of v. 5 means all these things and more.
God has created us male and female, and we must honor the God-ordained distinction. This was an anti-Canaanite law, among other things, because Canaanite practice was hostile to the distinctive places of men and women.
Rushdoony, R.J. (2008). Deuteronomy, Volume V of Commentaries on the Pentateuch. Ross House Books, Vallecito, p. 327