小记录:如何编译打版本自己的项目

 我们现在的项目中修改或者扩展了liferay 的某些东西,主要模块就是

portal-kernal / portal-service/portal-impl / ext-serivce/ext-impl

编译顺序 ext-service / portal-service/ portal-kernel/portal-impl/ ext-impl

porta-service 依赖 ext-service ,因此需要修改的文件 portal/build-common.xml 中的

<path id="web.classpath">
  <pathelement location="${project.dir}/portal-kernel/classes" />
  <pathelement location="${project.dir}/portal-service/classes" />
  <pathelement location="${project.dir}/../ext/ext-service/classes" /> 增加对ext-service 的引用

portal-impl 依赖portal-kernal ,所以 portal-kernal 要先编译,只要在portal-impl 前面就可以了

一种方式是把编译生成的jar包copy到 lib/global 下面,另外一种如果有必要的话,也可以修改builder.**.properties 中的classpath 中,例如在build.***.properties 中

classpath=${env.JAVA_HOME}/lib/tools.jar;${project.dir}/../ext/ext-service/classes;${project.dir}/../ext/ext-impl/classes;${project.dir}/applets/calculator/classes;${project.dir}/applets/chat/classes;${project.dir}/applets/editor/classes;${project.dir}/applets/lawt/classes;${project.dir}/classes;${project.dir}/counter-impl/classes;${project.dir}/documentlibrary-impl/classes;${project.dir}/jdbc/classes;${project.dir}/lock-impl/classes;${project.dir}/mail-impl/classes;${project.dir}/portal-client/portal-client.jar;${project.dir}/portal-impl/classes;${project.dir}/portal-impl/test-classes;${project.dir}/portal-kernel/classes;${project.dir}/portal-service/classes;${project.dir}/portal-web/docroot/WEB-INF/classes;${project.dir}/portal-web/test-classes;${project.dir}/util-bridges/classes;${project.dir}/util-java/classes;${project.dir}/util-java/test-classes;${project.dir}/util-taglib/classes;${project.dir}/util-wsrp/classes

 

你可能感兴趣的:(jar,扩展,Path)