Bug 472731

Summary: Autotools plugin denies access to project properties
Product: [Fedora] Fedora Reporter: Krisztian Kocsis <chrisloopenberg>
Component: eclipse-cdtAssignee: Jeff Johnston <jjohnstn>
Status: CLOSED NEXTRELEASE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: high Docs Contact:
Priority: medium    
Version: 10CC: jjohnstn
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2008-12-21 08:19:42 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Krisztian Kocsis 2008-11-24 07:28:17 UTC
Description of problem:
Autotools plugin denies acces to project properties when installed (Properties menu entry is missing). The menu entry is available in Project menu, but does not show the appropriate dialog.

Version-Release number of selected component (if applicable): 1.0.1

How reproducible:
Always

Steps to Reproduce:
1. Install the latest Autotools plugin
2. Create a C project
3. Check for Properties menu entry in Porject menu (via right click)
  
Actual results:

Expected results:

Additional info:

Comment 1 Jeff Johnston 2008-11-24 19:33:43 UTC
(In reply to comment #0)
> Description of problem:
> Autotools plugin denies acces to project properties when installed (Properties
> menu entry is missing). The menu entry is available in Project menu, but does
> not show the appropriate dialog.
> 
> Version-Release number of selected component (if applicable): 1.0.1
> 
> How reproducible:
> Always
> 
> Steps to Reproduce:
> 1. Install the latest Autotools plugin
> 2. Create a C project
> 3. Check for Properties menu entry in Porject menu (via right click)
> 

Krisztian, I am unable to reproduce this with eclipse-cdt-5.0.0-10 or eclipse-cdt-5.0.0-12 which was recently built.  I tried creating the template Ansi Hello World C template project and the template empty C project and for both, the properties menu works fine both from the top pulldown and right-clicking the project itself.

Note that if the project is not selected by the cursor (outlined in blue) and you hit the top-level project menu, the Properties menu item is greyed out.  Is this the problem you are reporting?

If not, I'm going to need some further information.

What eclipse rpms have you got installed?  (rpm -qa | grep eclipse)

and what exact C project did you create from the C Project menu?

Do you see any errors listed in the error log for the session? (top-level Help->About Fedora Eclipse->Configuration Details->View Error Log

Comment 2 Fedora Update System 2008-11-25 00:03:02 UTC
eclipse-changelog-2.6.3-2.fc10 has been submitted as an update for Fedora 10.
http://admin.fedoraproject.org/updates/eclipse-changelog-2.6.3-2.fc10

Comment 3 Jeff Johnston 2008-11-25 16:50:37 UTC
(In reply to comment #2)
> eclipse-changelog-2.6.3-2.fc10 has been submitted as an update for Fedora 10.
> http://admin.fedoraproject.org/updates/eclipse-changelog-2.6.3-2.fc10

Ignore this.  My bad.  I typed in the wrong bug number in Fedora updates.  It has been corrected and this bug should not be closed or altered by the ChangeLog plugin update.

Comment 4 Bug Zapper 2008-11-26 05:50:27 UTC
This bug appears to have been reported against 'rawhide' during the Fedora 10 development cycle.
Changing version to '10'.

More information and reason for this action is here:
http://fedoraproject.org/wiki/BugZappers/HouseKeeping

Comment 5 Krisztian Kocsis 2008-11-26 19:44:21 UTC
Hello again! 

Here is the info that you need:

I'v selected the project and the Properties menu item (at bottom) is not grayed, it is missing.
We I' clicked to Project -> Properties the dialog did not appear.

eclipse-cdt-5.0.0-12.fc10.i386
eclipse-rcp-3.4.1-5.fc10.i386
icu4j-eclipse-3.8.1-4.fc10.i386
eclipse-quickrex-3.5.0-9.fc10.noarch
eclipse-platform-3.4.1-5.fc10.i386
eclipse-ecj-3.4.1-5.fc10.i386
eclipse-subclipse-1.2.4-12.fc10.noarch
tomcat5-jasper-eclipse-5.5.27-4.9.fc10.noarch
eclipse-changelog-2.6.3-1.fc10.i386
eclipse-swt-3.4.1-5.fc10.i386

The C Project -> Executable -> Hello World ANSI C Project is OK (Properties is working),
but try to create a Makefile project -> Empty project (Linux GCC Toolchain). The menu item is missing from the right-click menu,
and also does not work in Project -> Properties menu (Main menu).

!SESSION 2008-11-25 20:12:18.398 -----------------------------------------------

eclipse.buildId=M20080911-1700
java.version=1.6.0_0
java.vendor=Sun Microsystems Inc.
BootLoader constants: OS=linux, ARCH=x86, WS=gtk, NL=en_US
Command-line arguments:  -os linux -ws gtk -arch x86

!ENTRY org.eclipse.cdt.core 1 0 2008-11-25 20:13:08.797

!MESSAGE Indexed 'test' (1 sources, 28 headers) in 1.74 sec: 909 declarations; 1,060 references; 0 unresolved inclusions; 0 syntax errors; 0 unresolved names (0.00%)

!ENTRY org.eclipse.cdt.core 1 0 2008-11-25 20:13:45.438

!MESSAGE Indexed 'sample' (0 sources, 20 headers) in 0.36 sec: 256 declarations; 420 references; 0 unresolved inclusions; 0 syntax errors; 0 unresolved names (0.00%)

!ENTRY org.eclipse.ui.navigator 4 0 2008-11-25 20:13:47.575

!MESSAGE No message.
!STACK 0
java.lang.NullPointerException
	at org.eclipse.linuxtools.cdt.autotools.AutotoolsMakefileBuilder.hasTargetBuilder(AutotoolsMakefileBuilder.java:80)
	at org.eclipse.linuxtools.cdt.autotools.AutotoolsProjectPropertyTester.test(AutotoolsProjectPropertyTester.java:28)

	at org.eclipse.core.internal.expressions.Property.test(Property.java:58)
	at org.eclipse.core.internal.expressions.TestExpression.evaluate(TestExpression.java:99)
	at org.eclipse.core.internal.expressions.CompositeExpression.evaluateAnd(CompositeExpression.java:53)

	at org.eclipse.core.internal.expressions.AndExpression.evaluate(AndExpression.java:29)
	at org.eclipse.ui.internal.dialogs.RegistryPageContributor.failsEnablement(RegistryPageContributor.java:260)
	at org.eclipse.ui.internal.dialogs.RegistryPageContributor.isApplicableTo(RegistryPageContributor.java:209)

	at org.eclipse.ui.internal.dialogs.PropertyPageContributorManager.getApplicableContributors(PropertyPageContributorManager.java:220)
	at org.eclipse.ui.dialogs.PropertyDialogAction.hasPropertyPagesFor(PropertyDialogAction.java:104)

	at org.eclipse.ui.dialogs.PropertyDialogAction.isApplicableForSelection(PropertyDialogAction.java:146)
	at org.eclipse.ui.dialogs.PropertyDialogAction.isApplicableForSelection(PropertyDialogAction.java:126)
	at org.eclipse.ui.internal.navigator.resources.actions.PropertiesActionProvider.fillContextMenu(PropertiesActionProvider.java:62)

	at org.eclipse.ui.navigator.NavigatorActionService.addCommonActionProviderMenu(NavigatorActionService.java:205)
	at org.eclipse.ui.navigator.NavigatorActionService.fillContextMenu(NavigatorActionService.java:172)
	at org.eclipse.ui.internal.navigator.CommonNavigatorManager.fillContextMenu(CommonNavigatorManager.java:258)

	at org.eclipse.ui.internal.navigator.CommonNavigatorManager$3.menuAboutToShow(CommonNavigatorManager.java:273)
	at org.eclipse.jface.action.MenuManager.fireAboutToShow(MenuManager.java:335)
	at org.eclipse.jface.action.MenuManager.handleAboutToShow(MenuManager.java:463)

	at org.eclipse.jface.action.MenuManager.access$1(MenuManager.java:459)
	at org.eclipse.jface.action.MenuManager$2.menuShown(MenuManager.java:485)
	at org.eclipse.swt.widgets.TypedListener.handleEvent(TypedListener.java:235)

	at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:84)
	at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1158)
	at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1182)
	at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1163)

	at org.eclipse.swt.widgets.Menu._setVisible(Menu.java:195)
	at org.eclipse.swt.widgets.Display.runPopups(Display.java:3427)
	at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3030)
	at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java:2382)

	at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:2346)
	at org.eclipse.ui.internal.Workbench.access$4(Workbench.java:2198)
	at org.eclipse.ui.internal.Workbench$5.run(Workbench.java:493)
	at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:288)

	at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:488)
	at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:149)
	at org.eclipse.ui.internal.ide.application.IDEApplication.start(IDEApplication.java:113)

	at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:193)
	at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:110)
	at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:79)

	at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:386)
	at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:179)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.lang.reflect.Method.invoke(Method.java:616)

	at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:549)
	at org.eclipse.equinox.launcher.Main.basicRun(Main.java:504)
	at org.eclipse.equinox.launcher.Main.run(Main.java:1236)

!ENTRY org.eclipse.cdt.core 1 0 2008-11-25 20:14:52.948

!MESSAGE Indexed 'fika' (0 sources, 20 headers) in 0.27 sec: 256 declarations; 420 references; 0 unresolved inclusions; 0 syntax errors; 0 unresolved names (0.00%)

!ENTRY org.eclipse.ui.navigator 4 0 2008-11-25 20:14:54.544

!MESSAGE No message.
!STACK 0
java.lang.NullPointerException
	at org.eclipse.linuxtools.cdt.autotools.AutotoolsMakefileBuilder.hasTargetBuilder(AutotoolsMakefileBuilder.java:80)
	at org.eclipse.linuxtools.cdt.autotools.AutotoolsProjectPropertyTester.test(AutotoolsProjectPropertyTester.java:28)

	at org.eclipse.core.internal.expressions.Property.test(Property.java:58)
	at org.eclipse.core.internal.expressions.TestExpression.evaluate(TestExpression.java:99)
	at org.eclipse.core.internal.expressions.CompositeExpression.evaluateAnd(CompositeExpression.java:53)

	at org.eclipse.core.internal.expressions.AndExpression.evaluate(AndExpression.java:29)
	at org.eclipse.ui.internal.dialogs.RegistryPageContributor.failsEnablement(RegistryPageContributor.java:260)
	at org.eclipse.ui.internal.dialogs.RegistryPageContributor.isApplicableTo(RegistryPageContributor.java:209)

	at org.eclipse.ui.internal.dialogs.PropertyPageContributorManager.getApplicableContributors(PropertyPageContributorManager.java:220)
	at org.eclipse.ui.dialogs.PropertyDialogAction.hasPropertyPagesFor(PropertyDialogAction.java:104)

	at org.eclipse.ui.dialogs.PropertyDialogAction.isApplicableForSelection(PropertyDialogAction.java:146)
	at org.eclipse.ui.dialogs.PropertyDialogAction.isApplicableForSelection(PropertyDialogAction.java:126)
	at org.eclipse.ui.internal.navigator.resources.actions.PropertiesActionProvider.fillContextMenu(PropertiesActionProvider.java:62)

	at org.eclipse.ui.navigator.NavigatorActionService.addCommonActionProviderMenu(NavigatorActionService.java:205)
	at org.eclipse.ui.navigator.NavigatorActionService.fillContextMenu(NavigatorActionService.java:172)
	at org.eclipse.ui.internal.navigator.CommonNavigatorManager.fillContextMenu(CommonNavigatorManager.java:258)

	at org.eclipse.ui.internal.navigator.CommonNavigatorManager$3.menuAboutToShow(CommonNavigatorManager.java:273)
	at org.eclipse.jface.action.MenuManager.fireAboutToShow(MenuManager.java:335)
	at org.eclipse.jface.action.MenuManager.handleAboutToShow(MenuManager.java:463)

	at org.eclipse.jface.action.MenuManager.access$1(MenuManager.java:459)
	at org.eclipse.jface.action.MenuManager$2.menuShown(MenuManager.java:485)
	at org.eclipse.swt.widgets.TypedListener.handleEvent(TypedListener.java:235)

	at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:84)
	at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1158)
	at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1182)
	at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1163)

	at org.eclipse.swt.widgets.Menu._setVisible(Menu.java:195)
	at org.eclipse.swt.widgets.Display.runPopups(Display.java:3427)
	at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3030)
	at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java:2382)

	at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:2346)
	at org.eclipse.ui.internal.Workbench.access$4(Workbench.java:2198)
	at org.eclipse.ui.internal.Workbench$5.run(Workbench.java:493)
	at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:288)

	at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:488)
	at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:149)
	at org.eclipse.ui.internal.ide.application.IDEApplication.start(IDEApplication.java:113)

	at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:193)
	at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:110)
	at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:79)

	at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:386)
	at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:179)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.lang.reflect.Method.invoke(Method.java:616)

	at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:549)
	at org.eclipse.equinox.launcher.Main.basicRun(Main.java:504)

	at org.eclipse.equinox.launcher.Main.run(Main.java:1236)

Comment 6 Jeff Johnston 2008-11-26 21:59:21 UTC
Thanks for the info.  The autotools plugin code had a check for Managed nature and then retrieves the ManagedProject and uses it to find the project type.  Unexpectedly from the autotools view, the empty Makefile project passes the Managed Nature check, but understandably doesn't have a ManagedProject so the Autotools code which tries to use the ManagedProject to access the project type gets a Null pointer exception.  This code was being accessed in a plugin extension and caused the missing properties menu item.

A fix has been made to the repository and this will appear in the next release.

Comment 7 Fedora Update System 2008-11-28 23:22:28 UTC
eclipse-cdt-5.0.1-1.fc10 has been submitted as an update for Fedora 10.
http://admin.fedoraproject.org/updates/eclipse-cdt-5.0.1-1.fc10

Comment 8 Fedora Update System 2008-12-03 01:27:25 UTC
eclipse-cdt-5.0.1-1.fc10 has been pushed to the Fedora 10 testing repository.  If problems still persist, please make note of it in this bug report.
 If you want to test the update, you can install it with 
 su -c 'yum --enablerepo=updates-testing update eclipse-cdt'.  You can provide feedback for this update here: http://admin.fedoraproject.org/updates/F10/FEDORA-2008-10674

Comment 9 Fedora Update System 2008-12-21 08:19:38 UTC
eclipse-cdt-5.0.1-1.fc10 has been pushed to the Fedora 10 stable repository.  If problems still persist, please make note of it in this bug report.