Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 556984 - dev-java/antlr-3.1.3-r3 fails to compile with Java 8: "building v3 grammars failed"
Summary: dev-java/antlr-3.1.3-r3 fails to compile with Java 8: "building v3 grammars f...
Status: RESOLVED DUPLICATE of bug 506678
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Java team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: 552764
  Show dependency tree
 
Reported: 2015-08-07 22:31 UTC by Sebastian Pipping
Modified: 2015-08-08 01:56 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments
Build log (dev-java:antlr-3.1.3-r3:20150807-222654.log,12.59 KB, text/plain)
2015-08-07 22:31 UTC, Sebastian Pipping
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Sebastian Pipping gentoo-dev 2015-08-07 22:31:25 UTC
Created attachment 408502 [details]
Build log

[..]
 * ERROR: dev-java/antlr-3.1.3-r3::gentoo failed (compile phase):
 *   building v3 grammars failed
 * 
 * Call stack:
 *     ebuild.sh, line   93:  Called src_compile
 *   environment, line 3926:  Called antlr3 'tool/src/main/antlr/org/antlr/grammar/v3//ActionAnalysis.g' 'tool/src/main/antlr/org/antlr/grammar/v3//ActionTranslator.g' 'tool/src/main/antlr/org/antlr/grammar/v3//ANTLRv3.g' 'tool/src/main/antlr/org/antlr/grammar/v3//ANTLRv3Tree.g'
[..]
Comment 1 Sebastian Pipping gentoo-dev 2015-08-08 00:22:45 UTC
The problem is know upstream and related to use of Java 8:
https://github.com/antlr/antlr3/issues/151

So for a workaround, forcing compilation to use oracle-jdk-bin-1.7 makes it compile (e.g. JAVA_PKG_FORCE_VM=...).

Something like https://github.com/antlr/antlr3/commit/e88907c259c43d42fa5e9f5ad0e486a2c1e004bb could work for us, but to my current understanding it would need to be applied against antlr:0 since that is called to generate v3 grammars.  I could try to making a patch for antlr:0.
Comment 2 Sebastian Pipping gentoo-dev 2015-08-08 00:26:17 UTC
PS: We could also add a check for

  $(java-pkg_get-vm-version) == 1.8

if there is need for a different solution.
Comment 3 Sebastian Pipping gentoo-dev 2015-08-08 01:56:33 UTC

*** This bug has been marked as a duplicate of bug 506678 ***