aspose file tools*
The moose likes Ant, Maven and Other Build Tools and the fly likes How to create APP-INF/lib structure in ear Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Java 8 in Action this week in the Java 8 forum!
JavaRanch » Java Forums » Engineering » Ant, Maven and Other Build Tools
Bookmark "How to create APP-INF/lib structure in ear" Watch "How to create APP-INF/lib structure in ear" New topic

How to create APP-INF/lib structure in ear

Sowbakia Nagaraj

Joined: Jan 04, 2005
Posts: 6
How to create APP-INF/lib structure? and How to put the jar inside of APP-INF/lib folder? while making the ear file with ant scripts.
Martijn Verburg

Joined: Jun 24, 2003
Posts: 3274

Are you sure its the APP-INF directory you want to create? I would think either a META-INF or WEB-INF is what you're after...

Cheers, Martijn - Blog,
Twitter, PCGen, Ikasan, My The Well-Grounded Java Developer book!,
My start-up.
Peter Johnson

Joined: May 14, 2008
Posts: 5779

Here's what I do. I first build my EAR structure on disk, usually in target/xxx.ear. Then I use the jar task to create the EAR. This provides several benefits:

* I know exactly what is in my EAR
* I can choose to deploy the EAR as either an archive file, or as the exploded directory
* I don't have to unpack my ear to verify that its structure is correct

JBoss In Action
Carol Enderlin
Ranch Hand

Joined: Oct 10, 2000
Posts: 1364
Take a look at the code examples for the war task in the ant manual. They include a zipfileset with a prefix specified (for your 'APP-INF/lib'). As I recall, WebLogic server uses or used APP-INF/lib.

I agree. Here's the link:
subject: How to create APP-INF/lib structure in ear
Similar Threads
Third party jar
application packaging for wehsphere 7-application and framework classes referred in both EJB and Web
NoClassDefFoundError when deploying application on weblogic 10.3.4
Maven - Compile dependency on Jar(s) inside EAR
How do you add a classpath to an EAR file?