What do you mean by dynamic? You can replace those at build/package time using Ant or Maven filtering.
That is not completely 'dynamic', but will do if you just want different configurations (testing, release, etc.)
In my current seam application I have an external components.xml (located in jboss/server/default/conf) file to configure the application for a particular environment.
By 'dynamic' I mean a similar configuration possibility.
I use jboss-4.2.3-GA and seam 2.1.1-GA
Well JPA looks for persistence.xml on the classpath, to you could probably externalize it, like you did with components.xml.
Depending on your application structure, you may run into problems, though.
So if have different environments, a separate build for each one would be the safest thing.
Well, I think u need to create persistence class manuallly as a java class and register it.
Here i found some example, but u need to find it in google how to create persistence provider.