cuba-platform / cuba-gradle-plugin

Gradle plugin for building CUBA platform and applications
https://www.cuba-platform.com
Apache License 2.0
15 stars 18 forks source link

Migrate to Gradle 6 to get rid of "path too long" widgetset building problem #146

Closed alexbudarov closed 3 years ago

alexbudarov commented 3 years ago

Environment

Description of the bug or enhancement

Actual: building project fails, because of the "Error 206 path too long" problem. This is really a blocker for Windows users.

Problem is known for a long time: #14.

Workaround is tedious: https://doc.cuba-platform.com/manual-7.2/widgetset_win_path_too_long.html

According to some Haulmont developers, you can get rid of this problem by upgrading project to Gradle 6.1.

However, there may be some incompatibilities, so we must be careful.

If implemented, also to be done in CUBA Studio project template.

andreysubbotin commented 3 years ago

Gradle doesn't fix the problem withBuildWidgetSet and long classpath. So update to Gradle 6 was reverted. The original problem is fixed in #14

alexbudarov commented 3 years ago

Haha, why then devs from Custom Solutions told us it helped them?

andreysubbotin commented 3 years ago

This may work for other Java processes but not for widgetSet. Using class-path with a MANIFEST file have constraints, which are not compatible with GwtCompiler. As I understand, GWT uses the system variable java.class.path. If it refers to JAR with the MANIFEST file, it doesn't work. Possible solutions with long class path: http://maven.apache.org/surefire/maven-surefire-plugin/examples/class-loading.html Widgetset building task should use Isolated Class Loader with setting java.class.path variable.