Well it's not that simple. Because if you have your own app with its own dependencies, there could be some dependencies clashing.
you should follow what is inside the installer. Using maven you can see the dependency tree and then exclude the jars provieded by the Application Server modules