Questions tagged [tools.jar]
82 questions
2
votes
0 answers
After JEP 220 changes does tools.jar equivalent ship pre-installed with JRE?
Migration guide seems to state that after JEP 220 both JDK and JRE install in lib directory
dynamically linked libraries and the complete internal
implementation of the JDK.
Since it says "complete" does this mean, for example, tools.jar which…

Mario Galic
- 47,285
- 6
- 56
- 98
2
votes
2 answers
tools.jar dependency
Consider a Java program, launched from a main method, that needs something from tools.jar. In this case, some utility code for connecting to JMX services. Do we have any choice but to wrap it in a shell script that uses -cp to manage the class path?…

bmargulies
- 97,814
- 39
- 186
- 310
2
votes
2 answers
How to activate a pom.xml iff the os is not of a given family (eg. mac)?
From Maven's website:
...
default-tools.jar
java.vendor
Sun Microsystems Inc.
…

simpatico
- 10,709
- 20
- 81
- 126
2
votes
0 answers
Compiler error under maven due to missing tools.jar with jdk 10
The cobertura-maven-plugin version 2.7 complains not to find tools.jar!
The log tells me that the plugin is searching com.sun.tools.jar at specified path C:\Program Files\Java\jdk-10.0.1/../lib/tools.jar!
Of course at this location no tools.jar can…

juerg
- 381
- 4
- 18
2
votes
1 answer
LibGDX - HTML5 Run&Deploy
I'm using Android Studio.
I want to run and deploy my application on HTML5.
I'm entering the command "gradlew.bat html:superDev" on the Terminal, but it gives me that error message:
Execution failed for task ':core:compileJava'. Could not find…

ahgulum
- 71
- 4
2
votes
1 answer
java compiler with java.lang.NullPointerException: Inflater has been closed
I've googled around on internet, but haven't found a problem exactly matching mine. So, I decided to post here.
Recently, our ANT building is throwing the following exception intermittently. And it's becoming more and more frequent.
The issue…

lovelywib
- 559
- 6
- 10
2
votes
3 answers
How do I configure Eclipse and Maven to detect jdk.tools?
I have a maven project in Eclipse where I am using some hadoop libraries (hadoop-common, hadoop-auth, hadoop-hdfs) and these bring in a dependency on jdk.tools. When I check this project out on a different machine, it works fine, but on mine the…

Matt
- 3,303
- 5
- 31
- 53
1
vote
1 answer
Maven: Failed to resolve dependency: C:\Program Files\Java\lib\tools.jar
I'm trying to use the cargo plugin to run a web application in a local Jetty container from inside Eclipse. This seems to be working for other people with the exact same pom.xml, but I get this error:
[ERROR] Failed to execute goal…

AndiDog
- 68,631
- 21
- 159
- 205
1
vote
0 answers
I trying to convert .apk to .jar file in cmd it shows following error
I tried to convert .apk file to .jar file using dex2jar in cmd and it say "java.nio.file.nosuchfileexception:"
I was expecting it to convert into .jar file

Nandani Mishra
- 11
- 1
1
vote
1 answer
When will an object fail to cast to its parent class in Java?
I'm having the same issue as ClassCastException in ant schemagen task using jaxb-ri-2.2.7. However, my biggest question is not about the issue itself, but the exception in the error log:
java.lang.ClassCastException:…

johnlinp
- 853
- 6
- 22
1
vote
1 answer
How to use JavaCompiler from tools.jar without JDK
I am trying to create an application that can compile a provided .java file during runtime. I understand that there is a programmatical compiler available within the tools.jar of the JDK. However, I cannot guarantee that the user of the application…

rgoulazian
- 13
- 1
- 2
1
vote
3 answers
Adding com.sun.tools.jar in classpath of jar
I'm having trouble using tools.jar present in jdk1.8.0_121/lib/tools.jar.
My $JAVA_HOME is set to:
# echo $JAVA_HOME
/usr/local/java/jdk1.8.0_121
The path to tools.jar is :
# ls…

Pankaj Singhal
- 15,283
- 9
- 47
- 86
1
vote
2 answers
ToolProvider.getSystemJavaCompiler() always returning null using jdk
I read all the posts regarding this problem and no solution works for me, I get always null.
I use JRE and put the tools.jar in the lib directory, added it to the build path but when I want to jump to declaration Eclipse wants to jump into rt.jar…

Tokra
- 21
- 5
1
vote
2 answers
where to download the javadoc for tools.jar?
I'm referring to the jar with the Compiler Tree API, referred to here
It can be found here but not for download. Maybe I could download it from there with downthemall, but what are the alternatives?

simpatico
- 10,709
- 20
- 81
- 126
1
vote
2 answers
Maven: JAVA_HOME/lib/tools.jar as dependency
Im new to Maven. I must use class sun.security.tools.JarSigner in my project.Im trying add tools.jar as dependency.I proceeded by Maven's FAQ, other articles from stackowerflow and google but without some positive results.
My NetBean can "see"…

Krakonos
- 23
- 2
- 4