I'm about to make changes to the ant build that require to also be
done to the gradle build. However there is no active developer for
gradle in the YaCy project right now.
The motivation to introduce gradle was primarily to manage dependencies
and not commit them to git anymore. This has been solved by using
ivy.
Additionally, there were (to my understanding) still open tasks to
be completed for the gradle migration, e.g. the Windows build.
I came to YaCy with the intention of packaging it for Debian. It
is currently not feasible use gradle in Debian:
"If you have a choice, we recommend to use a different build system
like Ant or Maven which are better supported in Debian and are more
stable when it comes to Debian Java packaging."
-- https://wiki.debian.org/Java/Packaging/Gradle
It seems Fedora has completely given up on packaging gradle. The
last activity seems to be from 2017:
https://bugzilla.redhat.com/show_bug.cgi?id=1191535
This commit also shows how many files are necessary for gradle while
ant just needs build.xml and ivy.xml. It is also ironic that gradle
was introduced here to get rid of binary files in Git (jars) but
apparently gradle itself needs jar files in the repo to work.
- added multiproject in libbuild to compile and install all needed jars (reproduceing old maven build)
- adjusted GitComInf (use a project version, build script with less hardcoded strings)
- adjusted J7Zip-modified
- include common version number for output jar
- add task installJarToRoot to copy output jar to yacycore /lib
- adjust main build with updated jar names
as files are the same - updated also old build.xml
And the Eclipse specific .classpath (with shall be deleted until complete move to gradle)
commit dfc7a23e60 uncomments the fake additional Gradle sourceSet (to make htroot in IDE visible), resulting in build error in IntelliJ IDEA if one uses just the IDE build button (and the old Ant build.xml is not available ... what is to expect soon).
This button runs as to expect the default Gradle task
> Task :htrootClasses (not our task compileHtrootServlets)
result :
htroot\processing\domaingraph\applet\domaingraph.java:1: error: package processing.core does not exist
import processing.core.*; import traer.physics.*; import traer.animation.*; import processing.net.*; import java.applet.*; import java.awt.*; import java.awt.image.*; import java.awt.event.*; import java.io.*; import java.net.*; import java.text.*; import java.util.*; import java.util.zip.*; public class domaingraph extends PApplet {// Domain visualization graph for YaCy
- Gradle task to execute "packageDist"
- this will create *.tar.gz and *.zip archive
- with legacy file name convention
- archive is created in build/distributions
- for the libbuild J7Zip-modified.jar use fallback as file dependency in lib
as Gradle/Groovy use internal just the classes from subprojects with result
that in above no jar is included in lib but a bunch of *.class files
- added also the option to publish J7Zip-modified.jar to mavenLocal() repo.