Liferay Portal is not buildable from sources

Hello, we have a problem when trying to build Liferay Portal from sources.

We followed the tutorial here: Building Liferay Source - Liferay Official Documentation - Liferay Learn

We were able to run the steps until the following command:
ant snapshot-bundle

This command runs but gives following error:

BUILD FAILED
C:\liferayfromsource\liferay-portal\build.xml:984: java.io.FileNotFoundException: https://releases-cdn.liferay.com/portal/snapshot-master/latest/liferay-portal-tomcat-master.7z.sha256
        at java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)

It seems that the https://releases-cdn.liferay.com/portal/snapshot-master/latest/liferay-portal-tomcat-master.7z.sha256 or any of its mirrors are not available. Trying to access the URL gives an error Cannot GET /portal/snapshot-master/latest/liferay-portal-tomcat-master.7z.sha256. The folder /latest/ is not available in listing directory /portal/snapshot-master/

Thank you for your time

Are you building master, e.g. the current latest one, or are you building a previously released version? Background: since the source base moved to jakarta-ee, there was no release for portal (ce) yet. Though, I'd have expected the CI to have run this build and detect problems. Anyway, feels like a reasonable low hanging fruit to check first

2 Answers

2

Hello, we are building from master branch forked from the latest version. Source files we used are available in github repository /liferay/liferay-portal

Could you try executing the 'ant all' and validate if the 'bundle' folder is generated successfully?

Hi, we managed to run ant all and it succeeded in about 1h. This also generated a C:\liferayfromsource\bundles folder, which has Liferay bundle folders like \tomcat-10.1.48\ and \osgi\ .

It seems the command goes through and /bundles is generated correctly when using ant all, but fails when using tutorial Building Liferay Source - Liferay Official Documentation - Liferay Learn command ant snapshot-bundle