Details
-
Bug
-
Status: Resolved
-
Normal
-
Resolution: Invalid
-
None
-
None
-
All
-
None
Description
I'm unable to build Cassandra from source by running ant in the root directory on Windows 10, using AdoptOpenJDK 8 and Ant 1.10.11. The build fails with the following:
generate-jflex-java: BUILD FAILED C:\Users\Jonathon\IdeaProjects\cassandra\build.xml:438: java.lang.NoSuchMethodError: jflex.core.LexParse.getSymbolFactory()Ljava_cup/runtime/SymbolFactory; at jflex.core.LexParse$CUP$LexParse$actions.CUP$LexParse$do_action_part00000000(LexParse.java:1087) at jflex.core.LexParse$CUP$LexParse$actions.CUP$LexParse$do_action(LexParse.java:2257) at jflex.core.LexParse.do_action(LexParse.java:598) at java_cup.runtime.lr_parser.parse(lr_parser.java:569) at jflex.generator.LexGenerator.generate(LexGenerator.java:74) at jflex.anttask.JFlexTask.execute(JFlexTask.java:78) at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:299) at sun.reflect.GeneratedMethodAccessor4.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:498) at org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:99) at org.apache.tools.ant.Task.perform(Task.java:350) at org.apache.tools.ant.Target.execute(Target.java:449) at org.apache.tools.ant.Target.performTasks(Target.java:470) at org.apache.tools.ant.Project.executeSortedTargets(Project.java:1401) at org.apache.tools.ant.Project.executeTarget(Project.java:1374) at org.apache.tools.ant.helper.DefaultExecutor.executeTargets(DefaultExecutor.java:41) at org.apache.tools.ant.Project.executeTargets(Project.java:1264) at org.apache.tools.ant.Main.runBuild(Main.java:818) at org.apache.tools.ant.Main.startAnt(Main.java:223) at org.apache.tools.ant.launch.Launcher.run(Launcher.java:284) at org.apache.tools.ant.launch.Launcher.main(Launcher.java:101)
I've also tried doing it through Windows Subsystem for Linux (WSL 2) with the same versions of Java and Ant. I get the same error.
My environment:
- Windows 10 Pro (Version 20H2, build 19042.1110)
OpenJDK Runtime Environment (AdoptOpenJDK)(build 1.8.0_292-b10)
Apache Ant(TM) version 1.10.11 compiled on July 10 2021
Note: I should probably mention that I'm new to Cassandra and I've never been able to build it before. I'm trying to run an initial build before I run the script to generate Intellij IDEA files (since generate-jflex-java is executed during the generate-idea-files task, it fails there with the error above too). If I'm doing something wrong, please let me know.