1
我已經將包含上述文件的名爲util-java.jar的jar添加到構建.gradle文件中。在編譯時沒有錯誤。但在執行該項目時,我得到一個NoClassDefFoundError
。錯誤java.lang.NoClassDefFoundError:com/liferay/util/dao/orm/CustomSQLUtil
請告訴我如何根除這個問題。我的build.gradle如下: -
dependencies {
compile group: "biz.aQute.bnd", name: "biz.aQute.bndlib", version: "3.1.0"
compile group: "com.liferay", name: "com.liferay.osgi.util", version: "3.0.0"
compile group: "com.liferay", name: "com.liferay.portal.spring.extender", version: "2.0.0"
compile group: "com.liferay.portal", name: "com.liferay.portal.kernel", version: "2.6.0"
compile project(":modules:customuser:customuser-api")
compile group: 'com.liferay.portal', name: 'portal-kernel', version: '5.2.3'
runtime group: 'com.liferay.portal', name: 'portal-kernel', version: '5.2.3'
compile group: 'com.liferay.portal', name: 'util-java', version: '6.2.4'
runtime group: 'com.liferay.portal', name: 'util-java', version: '6.2.4'
}
你的包是否導入'com.liferay.util.dao.orm'包? –