Fórumok

Building Plugin with another project reference

Kan Kon, módosítva 11 év-val korábban

Building Plugin with another project reference

New Member Bejegyzések: 23 Csatlakozás dátuma: 2011.09.13. Legújabb bejegyzések
How do I include another project for building a project? For example, I have a portlet project available. When building a new plugin project, how can i include the other portlet project? From IDE, I could add the build path, but at the time of compilation it fails as though the referred classes are not available in the classpath. Any ideas? Thanks.
thumbnail
David H Nebinger, módosítva 11 év-val korábban

RE: Building Plugin with another project reference

Liferay Legend Bejegyzések: 14916 Csatlakozás dátuma: 2006.09.02. Legújabb bejegyzések
You cannot do this.

As separate plugins they are deployed as separate artifacts (WAR files). The application container will not allow you to share classes between WAR files.

For shared code, you have a couple of options:

1. build separate jar and put into global lib (i.e. tomcat's lib/ext directory).
2. build separate jar and deploy as part of EXT plugin (other plugins can access the code by including the jar in liferay-plugin-package.properties file).
3. build separate EXT plugin and put code there (results in a separate jar file to include in liferay-plugin-package.properties file).
4. manually copy code between the plugins.
thumbnail
Roberto Díaz, módosítva 11 év-val korábban

RE: Building Plugin with another project reference

New Member Bejegyzések: 24 Csatlakozás dátuma: 2012.10.30. Legújabb bejegyzések
Paste the .jar from the first project available on the lib folder from the second one and add this jar to the build path.