[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Newsgroup Home]
[news.eclipse.platform] Re: Plug-in Installation messes up Ant Home Classpath

Hi Darin,

The plug-in is something that I wrote, so I know that does not pack an ant jar with it. The only connection that I could find so far is that my plug-in requires the org.eclipse.osgi to be present, and from there it points to a ant.jar file that is part of the eclipse configuration directory, rather that taking one from the plugins directory.

As I was trying to rule out conflicts with third party plug-ins or corrupt jar files, I tested and was able to duplicate the problem even on a fresh install on the 3.2.2 SDK. And I still have the problem, and the following error shows up on the log file.



!ENTRY org.eclipse.ant.core 4 2 2008-07-22 15:18:31.320
!MESSAGE Malformed URL.
!STACK 0
java.lang.NullPointerException
at org.eclipse.core.internal.runtime.Activator.getURLConverter(Activator.java:313)
at org.eclipse.core.runtime.FileLocator.toFileURL(FileLocator.java:163)
at org.eclipse.ant.core.AntCorePreferences.addLibraries(AntCorePreferences.java:834)
at org.eclipse.ant.core.AntCorePreferences.getDefaultAntHomeEntries(AntCorePreferences.java:440)
at org.eclipse.ant.core.AntCorePreferences.getDefaultAntHome(AntCorePreferences.java:301)
at org.eclipse.ant.core.AntCorePreferences.restoreAntHome(AntCorePreferences.java:289)
at org.eclipse.ant.core.AntCorePreferences.restoreCustomObjects(AntCorePreferences.java:194)
at org.eclipse.ant.core.AntCorePreferences.<init>(AntCorePreferences.java:160)
at org.eclipse.ant.core.AntCorePlugin.getPreferences(AntCorePlugin.java:219)
at org.eclipse.ant.internal.ui.preferences.AntTasksPage.initialize(AntTasksPage.java:123)
at org.eclipse.ant.internal.ui.preferences.AntRuntimePreferencePage.createContents(AntRuntimePreferencePage.java:83)
at org.eclipse.jface.preference.PreferencePage.createControl(PreferencePage.java:233)
at org.eclipse.jface.preference.PreferenceDialog.createPageControl(PreferenceDialog.java:1456)
at org.eclipse.jface.preference.PreferenceDialog$13.run(PreferenceDialog.java:1213)
at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:37)
at org.eclipse.core.runtime.Platform.run(Platform.java:857)
at org.eclipse.ui.internal.JFaceUtil$1.run(JFaceUtil.java:46)
at org.eclipse.jface.util.SafeRunnable.run(SafeRunnable.java:199)
at org.eclipse.jface.preference.PreferenceDialog.showPage(PreferenceDialog.java:1207)
at org.eclipse.ui.internal.dialogs.FilteredPreferenceDialog.showPage(FilteredPreferenceDialog.java:433)
at org.eclipse.jface.preference.PreferenceDialog$9.selectionChanged(PreferenceDialog.java:698)
at org.eclipse.jface.viewers.StructuredViewer$3.run(StructuredViewer.java:842)
at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:37)
at org.eclipse.core.runtime.Platform.run(Platform.java:857)
at org.eclipse.ui.internal.JFaceUtil$1.run(JFaceUtil.java:46)
at org.eclipse.jface.util.SafeRunnable.run(SafeRunnable.java:199)
at org.eclipse.jface.viewers.StructuredViewer.firePostSelectionChanged(StructuredViewer.java:840)
at org.eclipse.jface.viewers.StructuredViewer.handlePostSelect(StructuredViewer.java:1153)
at org.eclipse.jface.viewers.StructuredViewer$5.widgetSelected(StructuredViewer.java:1178)
at org.eclipse.jface.util.OpenStrategy.firePostSelectionEvent(OpenStrategy.java:250)
at org.eclipse.jface.util.OpenStrategy.access$4(OpenStrategy.java:244)
at org.eclipse.jface.util.OpenStrategy$3.run(OpenStrategy.java:418)
at org.eclipse.swt.widgets.RunnableLock.run(RunnableLock.java:35)
at org.eclipse.swt.widgets.Synchronizer.runAsyncMessages(Synchronizer.java:129)
at org.eclipse.swt.widgets.Display.runAsyncMessages(Display.java:3659)
at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3296)
at org.eclipse.jface.window.Window.runEventLoop(Window.java:820)
at org.eclipse.jface.window.Window.open(Window.java:796)
at org.eclipse.ui.internal.OpenPreferencesAction.run(OpenPreferencesAction.java:65)
at org.eclipse.jface.action.Action.runWithEvent(Action.java:498)
at org.eclipse.jface.action.ActionContributionItem.handleWidgetSelection(ActionContributionItem.java:546)
at org.eclipse.jface.action.ActionContributionItem.access$2(ActionContributionItem.java:490)
at org.eclipse.jface.action.ActionContributionItem$5.handleEvent(ActionContributionItem.java:402)
at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:66)
at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:938)
at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:3682)
at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3293)
at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java:2389)
at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:2353)
at org.eclipse.ui.internal.Workbench.access$4(Workbench.java:2219)
at org.eclipse.ui.internal.Workbench$4.run(Workbench.java:466)
at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:289)
at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:461)
at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:149)
at org.eclipse.ui.internal.ide.application.IDEApplication.start(IDEApplication.java:106)
at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:169)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:106)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:76)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:363)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:176)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:508)
at org.eclipse.equinox.launcher.Main.basicRun(Main.java:447)
at org.eclipse.equinox.launcher.Main.run(Main.java:1173)



Darin Swanson wrote:
Which plug-in are you installing?

It would appear that that plug-in is rolling out its own JARed version of Ant (1.5.2) and changing the Ant Home to point to it.
Doubly strange if it does not depend on Ant???


Darins
http://runnerwhocodes.blogspot.com

"Marcio DeBarros" <marcio.debarros@xxxxxxxxx> wrote in message news:g65597$jph$1@xxxxxxxxxxxxxxxxxxxx
Hi,

I have a 3.2.2 based plug-in that after installed, the value set for the Ant home under Window->Preferences->Ant->Run time->Classpath->Ant Home Entries(Default) is changed, causing Ant build to be broken.

After the installation is done the value previously set to the location of the org.apache_ant_1.7.0 plug-in (eclipse\plugins) is changed to (..configuration\org.eclipse.osgi\bundles\578\1\.cp\) which happens to be an older version of Ant (1.5.2).
Note that plug-in that is being installed, does not depent on ant itself, it only requires the org.eclipse.osgi plug-in.


Any ideas on how to prevent this from happening ?

Thanks,

-MD