Announcement Announcement Module
Collapse
No announcement yet.
eclipse is running in a jre, but a jdk is required Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • eclipse is running in a jre, but a jdk is required

    I tried multiple ways and I could not get rid of the Console warning:

    Eclipse is running in a JRE, but a JDK is required
    Some Maven plugins may not work when importing projects or updating source folders.


    1. I have my java_home point to my JDK
    2. I have my STS Eclipse "Installed JRE" configured with JDK JRE
    3. I tried to include -vm C:/MyPrograms/jdk1.6.0_18/bin/javaw in the STS.ini
    4. I tried to bring it up directly using one of the commands. I got an error: Could not find the main class: -v C:\Program. Program will exit. Could not figure out why it is referencing C:\Program because I have been trying to reference everything to C:/MyPrograms.
    stsc -vm C:/MyPrograms/jdk1.6.0_18/bin/javaw.exe
    stsc -vm C:/MyPrograms/jdk1.6.0_18/bin/javaw
    sts -vm C:/MyPrograms/jdk1.6.0_18/bin/javaw.exe
    sts -vm C:/MyPrograms/jdk1.6.0_18/bin/javaw

    Sharing your thoughts are appreciated.

    Thanks,
    Benl

  • #2
    I'm also having this problem. I haven't been able to resolve this and gave up on using STS months ago. I just tried again hoping that it had been resolved.

    I've followed the instructions in the prompts, editing STS.ini to point to a working jdk's javaw.exe file, to just the root of the jdk etc. to no avail.

    I have also configured my installed jre to point to the same jdk. This problem persists.

    Comment


    • #3
      I continue working with the warnings. It appears that the Maven error is somewhat working. I was able to run some of the apps under Dashboard. However, I ran into some problems and don't know if they are related to the warnings.

      Comment


      • #4
        I had the problem, and after some digging around found a solution. Put these two lines in your STS.ini:

        -vm
        G:/dev/jdk1.6.0_19/bin/javaw.exe

        Where the second line points to the javaw.exe from your installed JDK. I tried these two lines at the end of the file STS.ini, but that did not work. So they have to be at the beginning, before all the other lines of the .ini file.

        Hope it helps.

        Comment


        • #5
          Hi,

          if you download the STS platform specific installer, this will be handled for you by the installer and you don't need to mess around with the ini file yourself.

          Regards, Christian

          Comment


          • #6
            In order to make it work, I had to write in STS.ini:

            Code:
            --launcher.XXMaxPermSize
            256M
            -vm
            C:/apps/Java/jdk1.6.0_20/bin/javaw.exe
            -vmargs
            Pay attention to:
            - The position of -vm (after --launcher and before -vmargs)
            - the architecture of your OS... make sure you have an x64 JVM if you are running an x64 STS
            Last edited by gletare; Jun 24th, 2010, 03:55 PM.

            Comment


            • #7
              Solved: m2eclipse: Eclipse is running in a JRE, but a JDK is required

              G:\study\eclipse-jee-galileo-SR2-win32\eclipse\eclipse.exe -vm "E:\Program Files\Java\jdk1.6.0_23\bin\javaw.exe"

              This works fine.

              Regards,
              Anadi KUMAR
              Architecture and R2ds, Channels and Framework, Software Engineer | HSBC Technology and Services - Global Technology
              HSBC Software Development (India)Limited
              GLT 4.0 - Panchshil Tech. Park, Block D, S.No. 19, Hissa 2A/11/2, Yerawada, Pune, 411006.
              India.

              Mobile. +91 9822622054
              Email. [email protected]
              Email. [email protected]

              Comment


              • #8
                Thank You gletare. Your solution worked for me.

                Comment

                Working...
                X