Working with our dev team to get apple push notifications working and I need some help getting a jar into the java bootclass path. We are running RHEL 6.9 and java8.
when I try to do the normal: java -Xbootclasspath/p:/opt/batch/lib/pathtojar.jar I dont seem to be getting any confirmation nor errors. simply prints our the java help page.
I've also confirmed we are using the correct alpn-boot jar for our java version. I'm probably just running into a wall I cant see at the moment, so any help would be appreciated.
answer to problem:
the script we run for this job is not continuous, therefore I simply had to add the -Xbootclasspath/p:/opt/batch/lib/pathtojar.jar to the calls in the script. whereas i thought the command was supposed to be passed to change a value to a configuration file.
simply me misunderstanding something I had never done before.
Related
Trying to get JUnit working on my computer. I'm using windows but I have also installed git bash as well (don't know if that makes a difference).
Anyway I've followed this tutorial linked below:
https://www.tutorialspoint.com/junit/junit_environment_setup.htm
I'm trying to set the environment variables manually on windows but the instructions above aren't working for me.
https://imgur.com/a/NaqFiue
^Here is a photo of my user variables after making the changes in the tutorial. On the above tutorial it says to link the JDK to a variable called JAVA_HOME, and mine worked perfectly with Path as seen in the image but it did not work with JAVA_HOME.
I'm honestly so confused, lost and frustrated. Any help would be appreciated.
Why does your classpath settings has so many semi-colons?
You haven't set JAVA_HOME yet. Usually it's necessary to set
JAVA_HOME, as it's assumed by most Java libraries. You can set the
Java path by %JAVA_HOME%\bin.
What is your commmand line to run Junit? Have you compiled
successfully?
JUnit has its own Getting Started. Can you try it instead of the tutorial that you used. It does not rely on environment variables. Therefore it should be easier to run it.
Actually I have solved the problem but I don't understand why it works.
I have been developing under a change root environment, which was configured by someone else. I tried to use java command, but got that error message in the title.
After searching for solutions to this problem, I found no one works for my situation. Then I downloaded the newest java package from Oracle website and put it somewhere in my change root environment. By running ./java in .../jre.../bin, I tried test whether this new one works and it did work.
Then the thing I cannot understand happened. After testing the new jre, the old java command is fixed and I don't get the error message any more. I have used "java -version" to check the version of the java command and it was the old version.
Can someone explain?
I am following the instructions here (http://lemur.sourceforge.net/indri/index.html) for installing Indri version 5.7 on my mac. It says about the option of using --enable-java which will produce a lib file called /lib/libindri_jni.so in the install directory. However, after trying many times, even though it installs successfully, libindri_jni.so is never created.
Has anyone faced the same problem before and knows a solution.
thanks in advance,
Amit
I encountered the same problem while ago and I simply copy and pasted that file in the specified location. To get the complete overview on the details of what I have done, you can take a look at this post.
I'm using Mac for the first time and I'm assuming this is a OS specific error, because the same code worked well on Ubuntu.
I'm trying to compile this code and Eclipse is showing me a lot of errors like this one:
Access restriction: The method invokeLater(Runnable) from the type
SwingUtilities is not accessible due to restriction on required
library
/Library/Java/JavaVirtualMachines/jdk1.8.0_05.jdk/Contents/Home/jre/lib/rt.jar
This is the first time I facing something like this and I don't know how to continue.
I'm using Java 8.
I honestly have no clue why this happens, and it's a pain when I can't remember how I fixed it last time. Some Eclipse quirk, I suppose.
I usually fix this by removing the JRE System Library from the build path and then adding it back.
I guess is that Mac does not support System Trays. You should check if support exists using the method java.awt.SystemTray.isSupported(). Does this return true?
EDIT: I guess the problem is more at the Eclipse IDE level? Try reinstalling Java.
I've installed Eclipse and tried to do the "Hello World" program a couple of times and for some reason it never seems to work, could anyone help me out with this because I'm quite lost seeing as I've never used Eclipse before, heres a screenshot of my UI and what I get as an error:
Also I may have forgotten something very basic knowing me, seeing as it's been months since I last programmed, feel free to mention it nonetheless.
You are trying to run a program full of compiler errors, so no wonder it doesn't work. In your case it's the JRE configuration—you need to bind your installed JRE to the Eclipse's JRE setup. You can type Ctrl-3, jre, enter and you'll be able to go directly to the proper preference page.
Eclipse is not able to find HelloWorld.class file. Might be due to compile time problems.
You can check in the output directory of your project, weather .class file is there or not.