Bug 388658 - Defining a Symbol for GNU C moves Includes to Assembly type and after reopening project entries are deleted
Summary: Defining a Symbol for GNU C moves Includes to Assembly type and after reopeni...
Status: NEW
Alias: None
Product: CDT
Classification: Tools
Component: cdt-build (show other bugs)
Version: 8.1.0   Edit
Hardware: PC Windows XP
: P3 major (vote)
Target Milestone: ---   Edit
Assignee: cdt-build-inbox@eclipse.org CLA
QA Contact: Jonah Graham CLA
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: 275779
  Show dependency tree
 
Reported: 2012-09-03 02:56 EDT by Tamas Kleiber CLA
Modified: 2020-09-04 15:20 EDT (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Tamas Kleiber CLA 2012-09-03 02:56:15 EDT
The issue could be reproduced using Eclipse C/C++ Development Tools Version: 7.0.2.201102110609 Build id: 201102110609 running under Helios Service Release 2
Build id: 20110218-0911; and also using Eclipse Platform Version: 4.2.0 Build id: I20120608-1400 with Eclipse C/C++ Development Tools Version: 8.1.0.201206111645.

My Java runtime environment version is java.version=1.6.0_33 and I cannot update or change this due to corporate policies.

The issue is that whenever I try to define a symbol in "C/C++ General"/"Paths and Symbols" for GNU C after pushing Apply and switching between Includes and Symbols tabs all my include and symbol definitions move to Assembly pane and after saving, closing, reopening the project every definition disappears from the Includes tab IF the active configuration is [ All configurations ]. The checkbox on the Add symbol popup window is not checked when I add the new symbol to [ All configurations ] Configuration.


I have a C makefile project where I have defined the following build variables:

<stringMacro name="EFM32LIB_PATH" type="VALUE_TEXT" value="${ProjDirPath}../../../../lib/EFM32Libs/V2.0.0"/>
<stringMacro name="SWPF_PATH" type="VALUE_TEXT" value="${ProjDirPath}../../../../tags/_SwPfV1.1.0"/>
<stringMacro name="FREERTOS_PATH" type="VALUE_TEXT" value="${ProjDirPath}../../../../lib/FreeRTOS/V7.0.1"/>
<stringMacro name="COMPINCL_PATH" type="VALUE_TEXT" value="${ProjDirPath}../../../../tools/CodeSourcery/V2011.03-42"/>

I have in "C/C++ General"/"Paths and Symbols" e.g. the following Includes definition for GNU C with active configuration set to [ All configurations ]:

<tool id="org.eclipse.cdt.build.core.settings.holder.902029631" name="GNU C" superClass="org.eclipse.cdt.build.core.settings.holder">
<option id="org.eclipse.cdt.build.core.settings.holder.incpaths.1560554049" name="Include Paths" superClass="org.eclipse.cdt.build.core.settings.holder.incpaths" valueType="includePath">
<listOptionValue builtIn="false" value="&quot;${SWPF_PATH}/Mgr/SEM_SensorMgr&quot;"/>

I navigate to Symbols tab and define a symbol as follows with Configuration set to [ All configurations ] and "Add to all configurations" checkbox unchecked in the popup window of "Add symbol":
<listOptionValue builtIn="false" value="DEVICE=EFM32G222F128"/>

After pushing the Apply button after the symbol is added and switch between Includes and Symbols tabs to see the updated contents, all definitions are moved from GNU C to Assembly pane in the GUI and after closing eclipse than reopening the project all my symbol and include declarations disappear.

I set severity to major as this bug corrupts the configuration file and if user has no version control system or backups the configuration is lost permanently.