Scenarios in which a third-party commercialization SDK may be required in some projects may not be included in the MAVEN central repository, so the local Lib package needs to be referenced during the compilation package process.
1. Referencing local jar package compilation
<Dependency> <groupId>Org. XX (Custom)</groupId> <Artifactid>XX (Custom)</Artifactid> <version>1.0</version> <Scope>System</Scope> <Systempath>${project.basedir}/libs/xx.jar</systempath</dependency>
2. Package The local jar package into the war
<plugin> <Artifactid>Maven-war-plugin</Artifactid> <version>2.6</version> <Configuration> <webresources> <Resource> <TargetPath>web-inf/lib/</TargetPath>
<Directory>${project.basedir}/libs/</Directory> <includes> <include>*.jar</include> </includes> </Resource> </webresources> </Configuration></plugin>
How MAVEN will package the local LIB file into the war in a Web project