Closed g2graman closed 9 years ago
hmm...what does the bild.log say?
Here it is:
[04/28/15 22:17:46 <module> ./bild.py:42 bilder.py:124] platform=linux2
[04/28/15 22:17:46 <module> ./bild.py:42 bilder.py:125] jdk={'1.6': '/usr/lib/jvm/java-1.6.0-openjdk-amd64', '1.7': '/usr/lib/jvm/java-1.7.0-openjdk-amd64'}
[04/28/15 22:17:46] require compile
[04/28/15 22:17:46 require ./bild.py:91 bilder.py:422] require compile
[04/28/15 22:17:46] require parsers
[04/28/15 22:17:46 require ./bild.py:77 bilder.py:422] require parsers
[04/28/15 22:17:46 antlr3 ./bild.py:70 bilder.py:454] java -cp /home/g2graman/.bild/jars/antlr-3.5.1-complete.jar org.antlr.Tool -o /home/g2graman/Desktop/translateJS/tmp/antlr4/gen3/org/antlr/v4/parse /home/g2graman/Desktop/translateJS/tmp/antlr4/tool/src/org/antlr/v4/parse/BlockSetTransformer.g /home/g2graman/Desktop/translateJS/tmp/antlr4/tool/src/org/antlr/v4/parse/ActionSplitter.g /home/g2graman/Desktop/translateJS/tmp/antlr4/tool/src/org/antlr/v4/parse/ANTLRLexer.g /home/g2graman/Desktop/translateJS/tmp/antlr4/tool/src/org/antlr/v4/parse/LeftRecursiveRuleWalker.g /home/g2graman/Desktop/translateJS/tmp/antlr4/tool/src/org/antlr/v4/parse/ANTLRParser.g /home/g2graman/Desktop/translateJS/tmp/antlr4/tool/src/org/antlr/v4/parse/ATNBuilder.g /home/g2graman/Desktop/translateJS/tmp/antlr4/tool/src/org/antlr/v4/parse/GrammarTreeVisitor.g
[04/28/15 22:17:52 antlr3 ./bild.py:72 bilder.py:454] java -cp /home/g2graman/.bild/jars/antlr-3.5.1-complete.jar org.antlr.Tool -o /home/g2graman/Desktop/translateJS/tmp/antlr4/gen3/org/antlr/v4/codegen -lib /home/g2graman/Desktop/translateJS/tmp/antlr4/gen3/org/antlr/v4/parse /home/g2graman/Desktop/translateJS/tmp/antlr4/tool/src/org/antlr/v4/codegen/SourceGenTriggers.g
[04/28/15 22:17:53 antlr4 ./bild.py:74 bilder.py:474] java -cp /home/g2graman/.bild/jars/antlr-4.5-complete.jar org.antlr.v4.Tool -package org.antlr.v4.runtime.tree.xpath -o /home/g2graman/Desktop/translateJS/tmp/antlr4/gen4/org/antlr/v4/runtime/tree/xpath /home/g2graman/Desktop/translateJS/tmp/antlr4/runtime/Java/src/org/antlr/v4/runtime/tree/xpath/XPathLexer.g4
[04/28/15 22:17:54] build compile
[04/28/15 22:17:54 require ./bild.py:77 bilder.py:430] build compile
[04/28/15 22:17:54 javac ./bild.py:84 bilder.py:503] 1.6.0_35
[04/28/15 22:17:54 javac ./bild.py:84 bilder.py:511] javac -d /home/g2graman/Desktop/translateJS/tmp/antlr4/out -cp /home/g2graman/Desktop/translateJS/tmp/antlr4/out:/home/g2graman/.bild/jars/antlr-3.5.1-complete.jar:runtime/Java/lib/org.abego.treelayout.core.jar: -source 1.6 -target 1.6 -Xlint -Xlint:-serial -g -sourcepath gen3:gen4:runtime/Java/src:tool/src /home/g2graman/Desktop/translateJS/tmp/antlr4/gen3/org/antlr/v4/codegen/SourceGenTriggers.java /home/g2graman/Desktop/translateJS/tmp/antlr4/gen3/org/antlr/v4/parse/ActionSplitter.java /home/g2graman/Desktop/translateJS/tmp/antlr4/gen3/org/antlr/v4/parse/LeftRecursiveRuleWalker.java /home/g2graman/Desktop/translateJS/tmp/antlr4/gen3/org/antlr/v4/parse/ANTLRParser.java /home/g2graman/Desktop/translateJS/tmp/antlr4/gen3/org/antlr/v4/parse/GrammarTreeVisitor.java /home/g2graman/Desktop/translateJS/tmp/antlr4/gen3/org/antlr/v4/parse/BlockSetTransformer.java /home/g2graman/Desktop/translateJS/tmp/antlr4/gen3/org/antlr/v4/parse/ANTLRLexer.java /home/g2graman/Desktop/translateJS/tmp/antlr4/gen3/org/antlr/v4/parse/ATNBuilder.java
[04/28/15 22:18:04 javac ./bild.py:84 bilder.py:511] warning: [options] bootstrap class path not set in conjunction with -source 1.6
1 warning
[04/28/15 22:18:04 javac ./bild.py:84 bilder.py:503] 1.6.0_35
[04/28/15 22:18:04 javac ./bild.py:84 bilder.py:511] javac -d /home/g2graman/Desktop/translateJS/tmp/antlr4/out -cp /home/g2graman/Desktop/translateJS/tmp/antlr4/out:/home/g2graman/.bild/jars/antlr-3.5.1-complete.jar:runtime/Java/lib/org.abego.treelayout.core.jar: -source 1.6 -target 1.6 -Xlint -Xlint:-serial -g -sourcepath gen3:gen4:runtime/Java/src:tool/src /home/g2graman/Desktop/translateJS/tmp/antlr4/runtime/Java/src/org/antlr/v4/runtime/tree/ParseTreeProperty.java /home/g2graman/Desktop/translateJS/tmp/antlr4/runtime/Java/src/org/antlr/v4/runtime/UnbufferedTokenStream.java /home/g2graman/Desktop/translateJS/tmp/antlr4/runtime/Java/src/org/antlr/v4/runtime/TokenStreamRewriter.java /home/g2graman/Desktop/translateJS/tmp/antlr4/runtime/Java/src/org/antlr/v4/runtime/UnbufferedCharStream.java /home/g2graman/Desktop/translateJS/tmp/antlr4/runtime/Java/src/org/antlr/v4/runtime/DiagnosticErrorListener.java /home/g2graman/Desktop/translateJS/tmp/antlr4/runtime/Java/src/org/antlr/v4/runtime/ANTLRFileStream.java /home/g2graman/Desktop/translateJS/tmp/antlr4/runtime/Java/src/org/antlr/v4/runtime/tree/AbstractParseTreeVisitor.java /home/g2graman/Desktop/translateJS/tmp/antlr4/runtime/Java/src/org/antlr/v4/runtime/misc/TestRig.java
[04/28/15 22:18:05 javac ./bild.py:84 bilder.py:511] warning: [options] bootstrap class path not set in conjunction with -source 1.6
1 warning
[04/28/15 22:18:05 javac ./bild.py:84 bilder.py:503] 1.6.0_35
[04/28/15 22:18:05 javac ./bild.py:84 bilder.py:511] javac -d /home/g2graman/Desktop/translateJS/tmp/antlr4/out -cp /home/g2graman/Desktop/translateJS/tmp/antlr4/out:/home/g2graman/.bild/jars/antlr-3.5.1-complete.jar:runtime/Java/lib/org.abego.treelayout.core.jar: -source 1.6 -target 1.6 -Xlint -Xlint:-serial -g -sourcepath gen3:gen4:runtime/Java/src:tool/src /home/g2graman/Desktop/translateJS/tmp/antlr4/tool/src/org/antlr/v4/automata/ATNPrinter.java /home/g2graman/Desktop/translateJS/tmp/antlr4/tool/src/org/antlr/v4/codegen/model/dbg.java /home/g2graman/Desktop/translateJS/tmp/antlr4/tool/src/org/antlr/v4/codegen/model/ThrowEarlyExitException.java /home/g2graman/Desktop/translateJS/tmp/antlr4/tool/src/org/antlr/v4/codegen/LexerFactory.java /home/g2graman/Desktop/translateJS/tmp/antlr4/tool/src/org/antlr/v4/codegen/JavaTarget.java /home/g2graman/Desktop/translateJS/tmp/antlr4/tool/src/org/antlr/v4/codegen/model/decl/ElementListDecl.java /home/g2graman/Desktop/translateJS/tmp/antlr4/tool/src/org/antlr/v4/codegen/model/Sync.java /home/g2graman/Desktop/translateJS/tmp/antlr4/tool/src/org/antlr/v4/codegen/model/ArgAction.java /home/g2graman/Desktop/translateJS/tmp/antlr4/tool/src/org/antlr/v4/codegen/model/CaptureNextToken.java
[04/28/15 22:18:06 javac ./bild.py:84 bilder.py:511] warning: [options] bootstrap class path not set in conjunction with -source 1.6
1 warning
[04/28/15 22:18:06 javac ./bild.py:87 bilder.py:503] 1.6.0_35
[04/28/15 22:18:06 javac ./bild.py:87 bilder.py:511] javac -d /home/g2graman/Desktop/translateJS/tmp/antlr4/out -cp /home/g2graman/Desktop/translateJS/tmp/antlr4/out:/home/g2graman/.bild/jars/antlr-3.5.1-complete.jar:runtime/Java/lib/org.abego.treelayout.core.jar: -source 1.6 -target 1.6 -Xlint -Xlint:-serial -g -sourcepath gen3:gen4:runtime/Java/src:tool/src /home/g2graman/Desktop/translateJS/tmp/antlr4-csharp/tool/src/org/antlr/v4/codegen/CSharpTarget.java /home/g2graman/Desktop/translateJS/tmp/antlr4-csharp/tool/src/org/antlr/v4/codegen/GenerateLexer.java
[04/28/15 22:18:07 javac ./bild.py:87 bilder.py:511] warning: [options] bootstrap class path not set in conjunction with -source 1.6
1 warning
[04/28/15 22:18:07 javac ./bild.py:87 bilder.py:503] 1.6.0_35
[04/28/15 22:18:07 javac ./bild.py:87 bilder.py:511] javac -d /home/g2graman/Desktop/translateJS/tmp/antlr4/out -cp /home/g2graman/Desktop/translateJS/tmp/antlr4/out:/home/g2graman/.bild/jars/antlr-3.5.1-complete.jar:runtime/Java/lib/org.abego.treelayout.core.jar: -source 1.6 -target 1.6 -Xlint -Xlint:-serial -g -sourcepath gen3:gen4:runtime/Java/src:tool/src /home/g2graman/Desktop/translateJS/tmp/antlr4-python2/tool/src/org/antlr/v4/codegen/Python2Target.java
[04/28/15 22:18:08 javac ./bild.py:87 bilder.py:511] warning: [options] bootstrap class path not set in conjunction with -source 1.6
1 warning
[04/28/15 22:18:08 javac ./bild.py:87 bilder.py:503] 1.6.0_35
[04/28/15 22:18:08 javac ./bild.py:87 bilder.py:511] javac -d /home/g2graman/Desktop/translateJS/tmp/antlr4/out -cp /home/g2graman/Desktop/translateJS/tmp/antlr4/out:/home/g2graman/.bild/jars/antlr-3.5.1-complete.jar:runtime/Java/lib/org.abego.treelayout.core.jar: -source 1.6 -target 1.6 -Xlint -Xlint:-serial -g -sourcepath gen3:gen4:runtime/Java/src:tool/src /home/g2graman/Desktop/translateJS/tmp/antlr4-python3/tool/src/org/antlr/v4/codegen/Python3Target.java
[04/28/15 22:18:09 javac ./bild.py:87 bilder.py:511] warning: [options] bootstrap class path not set in conjunction with -source 1.6
1 warning
[04/28/15 22:18:09 javac ./bild.py:87 bilder.py:503] 1.6.0_35
[04/28/15 22:18:09 javac ./bild.py:87 bilder.py:511] javac -d /home/g2graman/Desktop/translateJS/tmp/antlr4/out -cp /home/g2graman/Desktop/translateJS/tmp/antlr4/out:/home/g2graman/.bild/jars/antlr-3.5.1-complete.jar:runtime/Java/lib/org.abego.treelayout.core.jar: -source 1.6 -target 1.6 -Xlint -Xlint:-serial -g -sourcepath gen3:gen4:runtime/Java/src:tool/src /home/g2graman/Desktop/translateJS/tmp/antlr4-javascript/tool/src/org/antlr/v4/codegen/JavaScriptTarget.java
[04/28/15 22:18:10 javac ./bild.py:87 bilder.py:511] warning: [options] bootstrap class path not set in conjunction with -source 1.6
1 warning
[04/28/15 22:18:10] build mkjar_complete
[04/28/15 22:18:10 require ./bild.py:91 bilder.py:430] build mkjar_complete
[04/28/15 22:18:10 processargs ./bild.py:444 bilder.py:860] [Errno 2] No such file or directory
Traceback (most recent call last):
File "/home/g2graman/Desktop/translateJS/tmp/antlr4/bilder.py", line 857, in processargs
target()
File "./bild.py", line 435, in all
_mkjar()
File "./bild.py", line 165, in _mkjar
mkjar_complete()
File "./bild.py", line 103, in mkjar_complete
manifest = manifest % (VERSION, os.getlogin())
OSError: [Errno 2] No such file or directory
I also have versions 1.6, 1.7, and 1.8 installed of the jdk and have tried all three of them using my alias
alias switch_java='sudo update-alternatives --config java'
for the build to no avail.
@parrt, any idea how to fix this?
Hi. can you pull again and try bild.py? I fixed a bunch of little things.
$ ./bild.py mkjar
bootstrapping; downloading bilder.py
target mkjar
require compile
require parsers
build compile
build mkjar_complete
Generated dist/antlr4-4.5.1-complete.jar
rebuilding XPath with 4.5.1
require compile
Generated dist/antlr4-4.5.1-complete.jar
Generated dist/antlr4-4.5.1.jar
Made jar OSGi-ready dist/antlr4-4.5.1.jar
bild succeeded
@parrt same issue:
$mkdir tmp && cd tmp
$git clone https://github.com/antlr/antlr4.git && cd antlr4 && ./bild.py -debug mkjar
Cloning into 'antlr4'...
remote: Counting objects: 44145, done.
remote: Compressing objects: 100% (46/46), done.
remote: Total 44145 (delta 14), reused 0 (delta 0), pack-reused 44077
Receiving objects: 100% (44145/44145), 19.13 MiB | 2.23 MiB/s, done.
Resolving deltas: 100% (22950/22950), done.
Checking connectivity... done.
...
[05/19/15 21:30:30 javac ./bild.py:87 bilder.py:503] 1.6.0_35
[05/19/15 21:30:30 javac ./bild.py:87 bilder.py:511] javac -d /home/g2graman/Desktop/tmp/antlr4/out -cp /home/g2graman/Desktop/tmp/antlr4/out:/home/g2graman/.bild/jars/antlr-3.5.2-complete.jar:runtime/Java/lib/org.abego.treelayout.core.jar: -source 1.6 -target 1.6 -Xlint -Xlint:-serial -g -sourcepath gen3:gen4:runtime/Java/src:tool/src /home/g2graman/Desktop/tmp/antlr4-javascript/tool/src/org/antlr/v4/codegen/JavaScriptTarget.java
[05/19/15 21:30:31 javac ./bild.py:87 bilder.py:511] warning: [options] bootstrap class path not set in conjunction with -source 1.6
1 warning
build mkjar_complete
[05/19/15 21:30:31 require ./bild.py:91 bilder.py:430] build mkjar_complete
Traceback (most recent call last):
File "/home/g2graman/Desktop/tmp/antlr4/bilder.py", line 857, in processargs
target()
File "./bild.py", line 161, in mkjar
_mkjar()
File "./bild.py", line 165, in _mkjar
mkjar_complete()
File "./bild.py", line 103, in mkjar_complete
manifest = manifest % (VERSION, os.getlogin())
OSError: [Errno 2] No such file or directory
[05/19/15 21:30:31 processargs ./bild.py:444 bilder.py:860] [Errno 2] No such file or directory
bild succeeded
I suspect this is because of the following line from the above output:
[04/28/15 22:18:10 javac ./bild.py:87 bilder.py:511] warning: [options] bootstrap class path not set in conjunction with -source 1.6
which is especially strange because, as you can see from the output, I built it with version 1.6.0_35
. So it looks like for whatever reason my build is bypassing the bootstrap
oh. can you try with java 1.7 not 1.6? Ter On May 19, 2015, at 6:36 PM, Francesco notifications@github.com wrote:
@parrt same issue:
$mkdir tmp && cd tmp $git clone https://github.com/antlr/antlr4.git && cd antlr4 && ./bild.py -debug mkjar Cloning into 'antlr4'... remote: Counting objects: 44145, done. remote: Compressing objects: 100% (46/46), done. remote: Total 44145 (delta 14), reused 0 (delta 0), pack-reused 44077 Receiving objects: 100% (44145/44145), 19.13 MiB | 2.23 MiB/s, done. Resolving deltas: 100% (22950/22950), done. Checking connectivity... done.
[05/19/15 21:30:30 javac ./bild.py:87 bilder.py:503] 1.6.0_35 [05/19/15 21:30:30 javac ./bild.py:87 bilder.py:511] javac -d /home/g2graman/Desktop/tmp/antlr4/out -cp /home/g2graman/Desktop/tmp/antlr4/out:/home/g2graman/.bild/jars/antlr-3.5.2-complete.jar:runtime/Java/lib/org.abego.treelayout.core.jar: -source 1.6 -target 1.6 -Xlint -Xlint:-serial -g -sourcepath gen3:gen4:runtime/Java/src:tool/src /home/g2graman/Desktop/tmp/antlr4-javascript/tool/src/org/antlr/v4/codegen/JavaScriptTarget.java [05/19/15 21:30:31 javac ./bild.py:87 bilder.py:511] warning: [options] bootstrap class path not set in conjunction with -source 1.6 1 warning build mkjar_complete [05/19/15 21:30:31 require ./bild.py:91 bilder.py:430] build mkjar_complete Traceback (most recent call last): File "/home/g2graman/Desktop/tmp/antlr4/bilder.py", line 857, in processargs target() File "./bild.py", line 161, in mkjar _mkjar() File "./bild.py", line 165, in _mkjar mkjar_complete() File "./bild.py", line 103, in mkjar_complete manifest = manifest % (VERSION, os.getlogin()) OSError: [Errno 2] No such file or directory [05/19/15 21:30:31 processargs ./bild.py:444 bilder.py:860] [Errno 2] No such file or directory bild succeeded
I suspect this is because of the following line from the above output:
[04/28/15 22:18:10 javac ./bild.py:87 bilder.py:511] warning: [options] bootstrap class path not set in conjunction with -source 1.6
so it looks like for whatever reason my build is bypassing the bootstrap
� Reply to this email directly or view it on GitHub.
Different output but now bild
is reporting itself as failing:
...
[05/19/15 21:39:25 javac ./bild.py:87 bilder.py:503] 1.7.0_79
[05/19/15 21:39:25 javac ./bild.py:87 bilder.py:511] javac -d /home/g2graman/Desktop/tmp/antlr4/out -cp /home/g2graman/Desktop/tmp/antlr4/out:/home/g2graman/.bild/jars/antlr-3.5.2-complete.jar:runtime/Java/lib/org.abego.treelayout.core.jar: -source 1.6 -target 1.6 -Xlint -Xlint:-serial -g -sourcepath gen3:gen4:runtime/Java/src:tool/src /home/g2graman/Desktop/tmp/antlr4-javascript/tool/src
[05/19/15 21:39:25 javac ./bild.py:87 bilder.py:511] javac: invalid flag: /home/g2graman/Desktop/tmp/antlr4-javascript/tool/src
Usage: javac <options> <source files>
use -help for a list of possible options
skipping mkjar_complete
[05/19/15 21:39:25 require ./bild.py:91 bilder.py:433] error building mkjar_complete
Traceback (most recent call last):
File "/home/g2graman/Desktop/tmp/antlr4/bilder.py", line 857, in processargs
target()
File "./bild.py", line 161, in mkjar
_mkjar()
File "./bild.py", line 165, in _mkjar
mkjar_complete()
File "./bild.py", line 91, in mkjar_complete
require(compile)
File "/home/g2graman/Desktop/tmp/antlr4/bilder.py", line 434, in require
raise Exception()
Exception
bild failed
wowser. can you attach or point to the whole bild.log?
I get same warning. no prob.
[05/19/15 18:51:44 javac ./bild.py:87 bilder.py:503] 1.8.0
[05/19/15 18:51:44 javac ./bild.py:87 bilder.py:511] javac -d /Users/parrt/antlr/code/antlr4/out -cp /Users/parrt/antlr/code/antlr4/out:/Users/parrt/.bild/jars/antlr-3.5.2-complete.jar:runtime/Java/lib/org.abego.treelayout.core.jar: -source 1.6 -target 1.6 -Xlint -Xlint:-serial -g -sourcepath gen3:gen4:runtime/Java/src:tool/src /Users/parrt/antlr/code/antlr4-python2/tool/src/org/antlr/v4/codegen/Python2Target.java
[05/19/15 18:51:45 javac ./bild.py:87 bilder.py:511] warning: [options] bootstrap class path not set in conjunction with -source 1.6
1 warning
Francesco is getting this though:
javac ./bild.py:87 bilder.py:511] javac: invalid flag: /home/g2graman/Desktop/tmp/antlr4-javascript/tool/src
I also get:
warning: [options] bootstrap class path not set in conjunction with -source 1.6
After which I get:
[05/20/15 09:59:45 javac ./bild.py:87 bilder.py:511] javac -d
/home/jimi/tmp/antlr4/out -cp
/home/jimi/tmp/antlr4/out:/home/jimi/.bild/jars/antlr-3.5.2-complete.jar:runtime/Java/lib/org.abego.treelayout.core.jar:
-source 1.6 -target 1.6 -Xlint -Xlint:-serial -g -sourcepath
gen3:gen4:runtime/Java/src:tool/src
/home/jimi/tmp/antlr4-csharp/tool/src
javac: invalid flag: /home/jimi/tmp/antlr4-csharp/tool/src
Usage: javac
But I am using the 1.8 compiler. So the script must be setting -source 1.6
I attach the full log, but now I will go read the build instructions ;)
Jim.
On Wed, May 20, 2015 at 9:52 AM, Terence Parr notifications@github.com wrote:
I get same warning. no prob.
[05/19/15 18:51:44 javac ./bild.py:87 bilder.py:503] 1.8.0 [05/19/15 18:51:44 javac ./bild.py:87 bilder.py:511] javac -d /Users/parrt/antlr/code/antlr4/out -cp /Users/parrt/antlr/code/antlr4/out:/Users/parrt/.bild/jars/antlr-3.5.2-complete.jar:runtime/Java/lib/org.abego.treelayout.core.jar: -source 1.6 -target 1.6 -Xlint -Xlint:-serial -g -sourcepath gen3:gen4:runtime/Java/src:tool/src /Users/parrt/antlr/code/antlr4-python2/tool/src/org/antlr/v4/codegen/Python2Target.java [05/19/15 18:51:45 javac ./bild.py:87 bilder.py:511] warning: [options] bootstrap class path not set in conjunction with -source 1.6 1 warning
— Reply to this email directly or view it on GitHub https://github.com/antlr/antlr4/issues/864#issuecomment-103719840.
cool. i just pushed antlr4-python* as something borked up, but it's ok again for me.
@jimidle seems can't attach logs. hmm...wow. my first gist: https://gist.github.com/parrt/57c2243823a1098128fe cool.
Do you guys have other targets cloned? Probably not:
cd /tmp
git clone https://github.com/antlr/antlr4.git
git clone git@github.com:antlr/antlr4-csharp.git
git clone git@github.com:antlr/antlr4-javascript.git
git clone git@github.com:antlr/antlr4-python2.git
git clone git@github.com:antlr/antlr4-python3.git
Updated doc :)
I think that this might be to do with the Python versions. Most installations only install 2.6.xx and the build says it needs 2.7 and 3.5 as well as node.js and mono installed.
However, with alias python=/usr/bin/python2.7
I just get:
[ec2-user@ tmp]$ git clone https://github.com/antlr/antlr4.git && cd
antlr4 && ./bild.py -debug mkjar
Cloning into 'antlr4'...
remote: Counting objects: 44145, done.
remote: Compressing objects: 100% (46/46), done.
remote: Total 44145 (delta 14), reused 0 (delta 0), pack-reused 44077
Receiving objects: 100% (44145/44145), 19.13 MiB | 2.71 MiB/s, done.
Resolving deltas: 100% (22950/22950), done.
Checking connectivity... done.
Traceback (most recent call last):
File "./bild.py", line 4, in
So I think that you have to switch alternatives or install a downloaded 2.7 in /usr/local and use that.
This is why things like python are not such a great choice for building things (IMO of course). I think that I will build a new pom.xml etc as a shadow build -it's a lot easier than trying to manage three version of Python that are all incompatible with each other.
Jim
On Wed, May 20, 2015 at 10:05 AM, Jim Idle jimi@temporal-wave.com wrote:
Francesco is getting this though:
javac ./bild.py:87 bilder.py:511] javac: invalid flag: /home/g2graman/Desktop/tmp/antlr4-javascript/tool/src
I also get:
warning: [options] bootstrap class path not set in conjunction with -source 1.6
After which I get:
[05/20/15 09:59:45 javac ./bild.py:87 bilder.py:511] javac -d /home/jimi/tmp/antlr4/out -cp /home/jimi/tmp/antlr4/out:/home/jimi/.bild/jars/antlr-3.5.2-complete.jar:runtime/Java/lib/org.abego.treelayout.core.jar: -source 1.6 -target 1.6 -Xlint -Xlint:-serial -g -sourcepath gen3:gen4:runtime/Java/src:tool/src /home/jimi/tmp/antlr4-csharp/tool/src javac: invalid flag: /home/jimi/tmp/antlr4-csharp/tool/src Usage: javac
But I am using the 1.8 compiler. So the script must be setting -source 1.6
I attach the full log, but now I will go read the build instructions ;)
Jim.
On Wed, May 20, 2015 at 9:52 AM, Terence Parr notifications@github.com wrote:
I get same warning. no prob.
[05/19/15 18:51:44 javac ./bild.py:87 bilder.py:503] 1.8.0 [05/19/15 18:51:44 javac ./bild.py:87 bilder.py:511] javac -d /Users/parrt/antlr/code/antlr4/out -cp /Users/parrt/antlr/code/antlr4/out:/Users/parrt/.bild/jars/antlr-3.5.2-complete.jar:runtime/Java/lib/org.abego.treelayout.core.jar: -source 1.6 -target 1.6 -Xlint -Xlint:-serial -g -sourcepath gen3:gen4:runtime/Java/src:tool/src /Users/parrt/antlr/code/antlr4-python2/tool/src/org/antlr/v4/codegen/Python2Target.java [05/19/15 18:51:45 javac ./bild.py:87 bilder.py:511] warning: [options] bootstrap class path not set in conjunction with -source 1.6 1 warning
— Reply to this email directly or view it on GitHub https://github.com/antlr/antlr4/issues/864#issuecomment-103719840.
Yes - that is the issue.
Install python versions 2.7 and 3.4 using yum or whatever
alternatives --config python
Select version 2.7
Then the build will work
Jim
On Wed, May 20, 2015 at 10:22 AM, Jim Idle jimi@temporal-wave.com wrote:
I think that this might be to do with the Python versions. Most installations only install 2.6.xx and the build says it needs 2.7 and 3.5 as well as node.js and mono installed.
However, with alias python=/usr/bin/python2.7
I just get:
[ec2-user@ tmp]$ git clone https://github.com/antlr/antlr4.git && cd antlr4 && ./bild.py -debug mkjar Cloning into 'antlr4'... remote: Counting objects: 44145, done. remote: Compressing objects: 100% (46/46), done. remote: Total 44145 (delta 14), reused 0 (delta 0), pack-reused 44077 Receiving objects: 100% (44145/44145), 19.13 MiB | 2.71 MiB/s, done. Resolving deltas: 100% (22950/22950), done. Checking connectivity... done. Traceback (most recent call last): File "./bild.py", line 4, in
from collections import OrderedDict So I think that you have to switch alternatives or install a downloaded 2.7 in /usr/local and use that.
This is why things like python are not such a great choice for building things (IMO of course). I think that I will build a new pom.xml etc as a shadow build -it's a lot easier than trying to manage three version of Python that are all incompatible with each other.
Jim
On Wed, May 20, 2015 at 10:05 AM, Jim Idle jimi@temporal-wave.com wrote:
Francesco is getting this though:
javac ./bild.py:87 bilder.py:511] javac: invalid flag: /home/g2graman/Desktop/tmp/antlr4-javascript/tool/src
I also get:
warning: [options] bootstrap class path not set in conjunction with -source 1.6
After which I get:
[05/20/15 09:59:45 javac ./bild.py:87 bilder.py:511] javac -d /home/jimi/tmp/antlr4/out -cp /home/jimi/tmp/antlr4/out:/home/jimi/.bild/jars/antlr-3.5.2-complete.jar:runtime/Java/lib/org.abego.treelayout.core.jar: -source 1.6 -target 1.6 -Xlint -Xlint:-serial -g -sourcepath gen3:gen4:runtime/Java/src:tool/src /home/jimi/tmp/antlr4-csharp/tool/src javac: invalid flag: /home/jimi/tmp/antlr4-csharp/tool/src Usage: javac
But I am using the 1.8 compiler. So the script must be setting -source 1.6
I attach the full log, but now I will go read the build instructions ;)
Jim.
On Wed, May 20, 2015 at 9:52 AM, Terence Parr notifications@github.com wrote:
I get same warning. no prob.
[05/19/15 18:51:44 javac ./bild.py:87 bilder.py:503] 1.8.0 [05/19/15 18:51:44 javac ./bild.py:87 bilder.py:511] javac -d /Users/parrt/antlr/code/antlr4/out -cp /Users/parrt/antlr/code/antlr4/out:/Users/parrt/.bild/jars/antlr-3.5.2-complete.jar:runtime/Java/lib/org.abego.treelayout.core.jar: -source 1.6 -target 1.6 -Xlint -Xlint:-serial -g -sourcepath gen3:gen4:runtime/Java/src:tool/src /Users/parrt/antlr/code/antlr4-python2/tool/src/org/antlr/v4/codegen/Python2Target.java [05/19/15 18:51:45 javac ./bild.py:87 bilder.py:511] warning: [options] bootstrap class path not set in conjunction with -source 1.6 1 warning
— Reply to this email directly or view it on GitHub https://github.com/antlr/antlr4/issues/864#issuecomment-103719840.
I do now when I worked out what python was trying to tell me in a useless way.
Jim
On Wed, May 20, 2015 at 10:14 AM, Terence Parr notifications@github.com wrote:
Do you guys have other targets cloned? Probably not:
cd /tmp git clone https://github.com/antlr/antlr4.git git clone git@github.com:antlr/antlr4-csharp.git git clone git@github.com:antlr/antlr4-javascript.git git clone git@github.com:antlr/antlr4-python2.git git clone git@github.com:antlr/antlr4-python3.git
Updated doc :)
— Reply to this email directly or view it on GitHub https://github.com/antlr/antlr4/issues/864#issuecomment-103727503.
@jimidle Strange that you think it's because my Python version needs to be 2.7 or 3.4 because:
$ python -V
Python 2.7.6
@parrt
And here is my bild.log
in the form of a gist
You have to sync those other repos as well, then it will work
On Wed, May 20, 2015 at 12:48 PM, Francesco notifications@github.com wrote:
@jimidle https://github.com/jimidle Strange that you think it's because my Python version needs to be 2.7 or 3.4 because:
$ python -V Python 2.7.6
@parrt https://github.com/parrt And here is my bild.log in the form of a gist https://gist.github.com/g2graman/5c089dc43b59f0d97fb4
— Reply to this email directly or view it on GitHub https://github.com/antlr/antlr4/issues/864#issuecomment-103754393.
@jimidle Could you explain what you mean by that?
Sure
[ec2-user@ ~]$ cd tmp [ec2-user@ tmp]$ git clone https://github.com/antlr/antlr4-csharp.git Cloning into 'antlr4-csharp'... ... [ec2-user@ tmp]$ git clone https://github.com/antlr/antlr4-javascript.git Cloning into 'antlr4-javascript'... ... [ec2-user@ tmp]$ git clone https://github.com/antlr/antlr4-python2.git Cloning into 'antlr4-python2'... ... [ec2-user@ tmp]$ git clone https://github.com/antlr/antlr4-python3.git Cloning into 'antlr4-python3'... ... [ec2-user@ tmp]$ ls antlr4 antlr4-csharp antlr4-javascript antlr4-python2 antlr4-python3
Now you can do the build from the antlr4 directory.
Jim
On Wed, May 20, 2015 at 1:33 PM, Francesco notifications@github.com wrote:
@jimidle https://github.com/jimidle Could you explain what you mean by that?
— Reply to this email directly or view it on GitHub https://github.com/antlr/antlr4/issues/864#issuecomment-103766184.
@jimidle I'm back to the original issue now:
$./bild.py -debug mkjar
build mkjar_complete
[05/20/15 11:07:27 require ./bild.py:91 bilder.py:430] build mkjar_complete
Traceback (most recent call last):
File "/home/g2graman/Desktop/tmp/antlr4/bilder.py", line 857, in processargs
target()
File "./bild.py", line 161, in mkjar
_mkjar()
File "./bild.py", line 165, in _mkjar
mkjar_complete()
File "./bild.py", line 103, in mkjar_complete
manifest = manifest % (VERSION, os.getlogin())
OSError: [Errno 2] No such file or directory
[05/20/15 11:07:27 processargs ./bild.py:444 bilder.py:860] [Errno 2] No such file or directory
bild succeeded
can you add some print statements for manifest, os.getlogin() etc... in bild.py at line 103 ish?
Can you show me what is in /home/g2graman/Desktop/tmp/antlr4-javascript/tool/src
? Can you verify that you have all of the repositories cloned at the same level with antlr4 dir?
@parrt
$ ls
antlr4 antlr4-csharp antlr4-javascript antlr4-python2 antlr4-python3
$ find antlr4-javascript/tool/src
antlr4-javascript/tool/src
antlr4-javascript/tool/src/org
antlr4-javascript/tool/src/org/antlr
antlr4-javascript/tool/src/org/antlr/v4
antlr4-javascript/tool/src/org/antlr/v4/codegen
antlr4-javascript/tool/src/org/antlr/v4/codegen/JavaScriptTarget.java
ooops. I'm an idiot. I meant the one for C# that gave you this error:
javac: invalid flag: /home/jimi/tmp/antlr4-csharp/tool/src
Any chance we could share a screen with Skype or something briefly so I can solve the problem? if you are having this problem I'm sure others are.
@parrt
$ find antlr4-csharp/tool/src
antlr4-csharp/tool/src
antlr4-csharp/tool/src/org
antlr4-csharp/tool/src/org/antlr
antlr4-csharp/tool/src/org/antlr/v4
antlr4-csharp/tool/src/org/antlr/v4/codegen
antlr4-csharp/tool/src/org/antlr/v4/codegen/GenerateLexer.java
antlr4-csharp/tool/src/org/antlr/v4/codegen/CSharpTarget.java
Sure, how we would coordinate a time?
I'm in San Francisco and available from, say, 10:30-12noon. would anything in there work for you?
@parrt For the next few days I can't make myself available at those times, but I might have found a better way to replicate the error using vagrant
. Only, in trying to replicate the bug in the VM from my system (using a box which should have closely resembled my system) I ran into another bug.
After downloading and installing vagrant
for your system (based on instructions from the website) save the contents of this gist as Vagrantfile
and in that directory invoke
vagrant up
and it'll import the box for ubuntu/trusty64, and the Vagrantfile will also have it install git
and java
(version 7). You can ssh into the VM (after invoking vagrant up
) with
vagrant ssh
and from there you can clone the repositories and start the build. And when you're done you can either just halt the vm with
vagrant halt
or destroy the VM (though, the box will stay on your system globally unless you follow a few other steps) with
vagrant destroy
wow some cool stuff. trying now. PS: why not docker? supposed to be lighterweight.
Did you see this error?
$ git clone git@github.com:antlr/antlr4-csharp.git
Cloning into 'antlr4-csharp'...
Warning: Permanently added the RSA host key for IP address '192.30.252.130' to the list of known hosts.
Permission denied (publickey).
fatal: Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists.
Ah. Doc uses ssh for that not https. changed doc to:
...
git clone https://github.com/antlr/antlr4-csharp.git
git clone https://github.com/antlr/antlr4-javascript.git
git clone https://github.com/antlr/antlr4-python2.git
git clone https://github.com/antlr/antlr4-python3.git
Build now failing with no javac
vagrant@vagrant-ubuntu-trusty-64:/tmp/antlr4$ javac
The program 'javac' can be found in the following packages:
* default-jdk
* ecj
* gcj-4.8-jdk
* openjdk-7-jdk
* gcj-4.6-jdk
* openjdk-6-jdk
Ask your administrator to install one of them
$ sudo apt-get install default-jdk
build works:
...
[05/22/15 18:00:58 javac ./bild.py:130 bilder.py:503] 1.7.0_79
[05/22/15 18:00:58 javac ./bild.py:130 bilder.py:511] javac -d /tmp/antlr4/out/runtime -cp /tmp/antlr4/out/runtime:runtime/Java/lib/org.abego.treelayout.core.jar -source 1.6 -target 1.6 -nowarn -Xlint -Xlint:-serial -g -sourcepath gen4:runtime/Java/src /tmp/antlr4/runtime/Java/src/org/antlr/v4/runtime/UnbufferedTokenStream.java /tmp/antlr4/runtime/Java/src/org/antlr/v4/runtime/misc/TestRig.java /tmp/antlr4/runtime/Java/src/org/antlr/v4/runtime/UnbufferedCharStream.java /tmp/antlr4/runtime/Java/src/org/antlr/v4/runtime/TokenStreamRewriter.java /tmp/antlr4/runtime/Java/src/org/antlr/v4/runtime/misc/Triple.java /tmp/antlr4/runtime/Java/src/org/antlr/v4/runtime/tree/AbstractParseTreeVisitor.java /tmp/antlr4/runtime/Java/src/org/antlr/v4/runtime/ANTLRFileStream.java /tmp/antlr4/runtime/Java/src/org/antlr/v4/runtime/misc/OrderedHashSet.java /tmp/antlr4/runtime/Java/src/org/antlr/v4/runtime/misc/LogManager.java /tmp/antlr4/runtime/Java/src/org/antlr/v4/runtime/DiagnosticErrorListener.java /tmp/antlr4/runtime/Java/src/org/antlr/v4/runtime/LexerInterpreter.java /tmp/antlr4/runtime/Java/src/org/antlr/v4/runtime/tree/ParseTreeProperty.java
Generated dist/antlr4-4.5.1.jar
[05/22/15 18:01:00 download /tmp/antlr4/bilder.py:546 bilder.py:677] download https://github.com/bndtools/bnd/releases/download/2.4.0.REL/biz.aQute.bnd-2.4.0.jar
[05/22/15 18:01:03 make_osgi_ready ./bild.py:154 bilder.py:548] java -jar /home/vagrant/.bild/jars/biz.aQute.bnd-2.4.0.jar wrap --output dist/antlr4-4.5.1-osgi.jar dist/antlr4-4.5.1.jar
[05/22/15 18:01:05 make_osgi_ready ./bild.py:154 bilder.py:548] -----------------
Warnings
000: Using defaults for wrap, which means no export versions
Made jar OSGi-ready dist/antlr4-4.5.1.jar
[05/22/15 18:01:05 print_and_log ./bild.py:156 bilder.py:760] Made jar OSGi-ready dist/antlr4-4.5.1.jar
bild succeeded
Aside: Docker is a VE (virtual environment) tool, and builds on LxC; it creates a container that doesn't emulate the same hardware, which is why it's more lightweight. I used vagrant because I wanted to emulate hardware since my suspicion of the issue was VM-dependent. It's cool to note that Vagrant has built-in support for Docker as a provider
Oops, forgot to add javac
to the provisions (I updated that Vagrantfile to reflect it. This baffles me even more now. The box is the closest thing to my OS version. Could it somehow be an issue that I have multiple versions of java installed?
could be. java/javac/classpath must all be consistent
Based on instructions for building ANTLR from scratch, I used the following commands in bash
But when it got to making the jar, I get:
Was there a missing step to generate the according manifest file for
mkjar
?