Try this on for size: Trump follows Texas's lead, and declares them to be invaders. Enemy combatants aren't subject to the laws of the nation they are invading.
Trump can argue that Border Patrol is performing a military role, rather than a law enforcement role.
It was the state's burden to prove otherwise.