What is the simplest way to specify a directory (and all jars underneath this directory) to be in the maven classpath when it compiles .java classes and builds a .jar?
The directory is not in my git repo or any directory under my IDE project files. I have a requirement to create a pom.xml that will reference the current project, and external jars in a /lib/ directory. ------------------------------ The requirement is to put together a pom.xml for a maven build that depends on jars in: $TOMCAT_HOME/webapps/<web-context>/WEB-INF/lib/ I want to reference that location directly in the maven pom.xml file and not copy the /lib/*.jar files to another directory under my git repo. The .../WEB-INF/lib/ contains .jar files that contains classes that my project imports. The jar that is then built will be put into: $TOMCAT_HOME/webapps/<web-context>/WEB-INF/lib/ to extend the product as per the vendor instructions. ------------------------------ If anyone has had this exact issue, and has a reference pom.xml that can be pasted here, it would be extremely helpful and get me going quickly. ------------------------------ Irrespective of the deployment part where I copy the jar to /webapps/<web-context>/WEB-INF/lib/, I would be happy to just get files under /src/com/.../.java/ compiled and put into a jar in the /target/ directory