Showing posts with label Eclipse. Show all posts
Showing posts with label Eclipse. Show all posts

Tuesday, May 8, 2018

Run Eclipse Neon macOS on any Java JDK version

Starting Eclipse Neon 3 on macOS High Sierra using JDK 10 produces the following error during startup:

View Eclipse error log
$ vi ~/Documents/workspace/.metadata/.log

!SESSION 2018-05-09 08:09:01.603 -----------------------------------------------
eclipse.buildId=4.6.3.M20170301-0400
java.version=10.0.1
java.vendor=Oracle Corporation
BootLoader constants: OS=macosx, ARCH=x86_64, WS=cocoa, NL=en_US
Framework arguments:  -product org.eclipse.epp.package.jee.product -keyring /Users/xxxx/.eclipse_keyring
Command-line arguments:  -os macosx -ws cocoa -arch x86_64 -product org.eclipse.epp.package.jee.product -keyring /Users/xxxx/.eclipse_keyring

!ENTRY org.eclipse.osgi 4 0 2018-05-09 08:09:05.117
!MESSAGE Application error
!STACK 1
org.eclipse.e4.core.di.InjectionException: java.lang.NoClassDefFoundError: javax/annotation/PostConstruct
        at org.eclipse.e4.core.internal.di.InjectorImpl.internalMake(InjectorImpl.java:386)
        at org.eclipse.e4.core.internal.di.InjectorImpl.make(InjectorImpl.java:294)
        at org.eclipse.e4.core.contexts.ContextInjectionFactory.make(ContextInjectionFactory.java:162)

        at org.eclipse.e4.ui.internal.workbench.swt.E4Application.createDefaultH

Get full path list of available Java Runtimes
$ /usr/libexec/java_home --verbose
Matching Java Virtual Machines (2):
    10.0.1, x86_64: "Java SE 10.0.1" /Library/Java/JavaVirtualMachines/jdk-10.0.1.jdk/Contents/Home
    1.8.0_172, x86_64: "Java SE 8" /Library/Java/JavaVirtualMachines/jdk1.8.0_172.jdk/Contents/Home

/Library/Java/JavaVirtualMachines/jdk-10.0.1.jdk/Contents/Home


Edit eclipse .ini
$ vi /Applications/Eclipse.app/Contents/Eclipse/eclipse.ini

Add the following to the start of the line, replace with appropriate java version
-vm
/Library/Java/JavaVirtualMachines/jdk1.8.0_172.jdk/Contents/Home/bin

Monday, April 21, 2014

Eclipse : Unbound classpath container: JRE System Library [JavaSE-1.7]

Eclipse Errors:

The project cannot be buoilt until build path errors are resolved.
Unbound classpath container: 'JRE System Library [JavaSE-1.7]' in project

Resolution:

Add Java 1.7 JREs to Eclipse's JRE definitions.

Eclipse->Window->Preferences->Java->Installed JREs->Search.. Point to directory of Java

Monday, January 13, 2014

Eclipse Error Build path entry is missing: .. JavaSE-1.7

Error :
Build path entry is missing: org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.7

Open Eclipse->Preferences->Java->Installed JREs->Search..

Wednesday, June 26, 2013

Download Eclipse Kepler with Friends of Eclipse login

Goto http://download.eclipse.org/eclipse/downloads/

Find the Latest Stable version (not RC) i.e. Eclipse version 4.3

Wednesday, May 15, 2013

Install PDT (PHP Development Tools) on Eclipse Juno

Eclipse->Help->Install New Software...

Add site:
http://download.eclipse.org/tools/pdt/updates/nightly

Saturday, December 10, 2011

Count Number of Lines of Code in an Eclipse Project

Use Search ->File
Containing Text:  \n[\s]*
File name patterns: *.java (filename extension of source code)
Check Regular expression

Friday, February 5, 2010

Eclipse on MacOS X

Wonder which of the available downloads from eclipse.org is right for you?

  1. Mac Carbon 32bit
  2. Mac Cocoa 32bit
  3. Mac Cocoa 64bit
For my Snow Leopard, i chose #3 since Java that comes with the MacOS is 64bit but you need to tweak settings since it consumes memory that it's 32bit counterpart.