This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 270346 - MacOSX: IDE can't configure new project in many cases
Summary: MacOSX: IDE can't configure new project in many cases
Status: VERIFIED FIXED
Alias: None
Product: cnd
Classification: Unclassified
Component: Project Discovery (show other bugs)
Version: Dev
Hardware: PC Mac OS X
: P2 normal (vote)
Assignee: Alexander Simon
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2017-04-10 12:27 UTC by soldatov
Modified: 2017-05-18 20:12 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
test project (57.00 KB, application/x-tar)
2017-04-10 12:27 UTC, soldatov
Details

Note You need to log in before you can comment on or make changes to this bug.
Description soldatov 2017-04-10 12:27:01 UTC
Created attachment 164064 [details]
test project

Unpack test project

Bugs:
- Open project
- Call context menu on project's node
- Select Code Assistance|Configure Code Assistance...
==> I can't fix project (I expect AA=4) via "Explore Executable or Library File" or "Explore Object Files in Folder" modes.

Also I see such exception:
INFO [org.netbeans.modules.cnd.dwarfdiscovery.provider.DwarfSource]: Exception in file /Users/tester/tmp/test/newfile.o
java.lang.ClassCastException: org.netbeans.modules.cnd.dwarfdump.section.StringTableSection cannot be cast to org.netbeans.modules.cnd.dwarfdump.section.DwarfLineInfoSection
	at org.netbeans.modules.cnd.dwarfdump.CompilationUnit.initStatementList(CompilationUnit.java:547)
	at org.netbeans.modules.cnd.dwarfdump.CompilationUnit.getStatementList(CompilationUnit.java:424)
	at org.netbeans.modules.cnd.dwarfdiscovery.provider.DwarfSource.gatherIncludes(DwarfSource.java:741)
	at org.netbeans.modules.cnd.dwarfdiscovery.provider.DwarfSource.process(DwarfSource.java:518)
	at org.netbeans.modules.cnd.dwarfdiscovery.provider.BaseDwarfProvider.processUnit(BaseDwarfProvider.java:526)
[catch] at org.netbeans.modules.cnd.dwarfdiscovery.provider.BaseDwarfProvider.getSourceFilePropertiesLocal(BaseDwarfProvider.java:450)
	at org.netbeans.modules.cnd.dwarfdiscovery.provider.BaseDwarfProvider.getSourceFileProperties(BaseDwarfProvider.java:397)
	at org.netbeans.modules.cnd.dwarfdiscovery.provider.BaseProvider.processArtifactFile(BaseProvider.java:355)
	at org.netbeans.modules.cnd.dwarfdiscovery.provider.BaseProvider.access$400(BaseProvider.java:77)
	at org.netbeans.modules.cnd.dwarfdiscovery.provider.BaseProvider$MyRunnable.run(BaseProvider.java:466)
	at org.openide.util.RequestProcessor$Task.run(RequestProcessor.java:1443)
	at org.netbeans.modules.openide.util.GlobalLookup.execute(GlobalLookup.java:68)
	at org.openide.util.lookup.Lookups.executeWith(Lookups.java:303)
	at org.openide.util.RequestProcessor$Processor.run(RequestProcessor.java:2058)
INFO [org.netbeans.modules.cnd.dwarfdiscovery.provider.DwarfSource]: Exception in file /Users/tester/tmp/test/test.o
java.lang.ClassCastException: org.netbeans.modules.cnd.dwarfdump.section.StringTableSection cannot be cast to org.netbeans.modules.cnd.dwarfdump.section.DwarfLineInfoSection
	at org.netbeans.modules.cnd.dwarfdump.CompilationUnit.initStatementList(CompilationUnit.java:547)
	at org.netbeans.modules.cnd.dwarfdump.CompilationUnit.getStatementList(CompilationUnit.java:424)
	at org.netbeans.modules.cnd.dwarfdiscovery.provider.DwarfSource.gatherIncludes(DwarfSource.java:741)
	at org.netbeans.modules.cnd.dwarfdiscovery.provider.DwarfSource.process(DwarfSource.java:518)
	at org.netbeans.modules.cnd.dwarfdiscovery.provider.BaseDwarfProvider.processUnit(BaseDwarfProvider.java:526)
[catch] at org.netbeans.modules.cnd.dwarfdiscovery.provider.BaseDwarfProvider.getSourceFilePropertiesLocal(BaseDwarfProvider.java:450)
	at org.netbeans.modules.cnd.dwarfdiscovery.provider.BaseDwarfProvider.getSourceFileProperties(BaseDwarfProvider.java:397)
	at org.netbeans.modules.cnd.dwarfdiscovery.provider.BaseProvider.processArtifactFile(BaseProvider.java:355)
	at org.netbeans.modules.cnd.dwarfdiscovery.provider.BaseProvider.access$400(BaseProvider.java:77)
	at org.netbeans.modules.cnd.dwarfdiscovery.provider.BaseProvider$MyRunnable.run(BaseProvider.java:466)
	at org.openide.util.RequestProcessor$Task.run(RequestProcessor.java:1443)
	at org.netbeans.modules.openide.util.GlobalLookup.execute(GlobalLookup.java:68)
	at org.openide.util.lookup.Lookups.executeWith(Lookups.java:303)
	at org.openide.util.RequestProcessor$Processor.run(RequestProcessor.java:2058)
INFO [org.netbeans.modules.cnd.dwarfdiscovery.provider.DwarfSource]: Exception in file /Users/tester/tmp/test/test
java.lang.ClassCastException: org.netbeans.modules.cnd.dwarfdump.section.StringTableSection cannot be cast to org.netbeans.modules.cnd.dwarfdump.section.DwarfLineInfoSection
	at org.netbeans.modules.cnd.dwarfdump.CompilationUnit.initStatementList(CompilationUnit.java:547)
	at org.netbeans.modules.cnd.dwarfdump.CompilationUnit.getStatementList(CompilationUnit.java:424)
	at org.netbeans.modules.cnd.dwarfdiscovery.provider.DwarfSource.gatherIncludes(DwarfSource.java:741)
	at org.netbeans.modules.cnd.dwarfdiscovery.provider.DwarfSource.process(DwarfSource.java:518)
	at org.netbeans.modules.cnd.dwarfdiscovery.provider.BaseDwarfProvider.processUnit(BaseDwarfProvider.java:526)
[catch] at org.netbeans.modules.cnd.dwarfdiscovery.provider.BaseDwarfProvider.getSourceFilePropertiesLocal(BaseDwarfProvider.java:450)
	at org.netbeans.modules.cnd.dwarfdiscovery.provider.BaseDwarfProvider.getSourceFileProperties(BaseDwarfProvider.java:397)
	at org.netbeans.modules.cnd.dwarfdiscovery.provider.BaseProvider.processArtifactFile(BaseProvider.java:355)
	at org.netbeans.modules.cnd.dwarfdiscovery.provider.BaseProvider.access$400(BaseProvider.java:77)
	at org.netbeans.modules.cnd.dwarfdiscovery.provider.BaseProvider$MyRunnable.run(BaseProvider.java:466)
	at org.openide.util.RequestProcessor$Task.run(RequestProcessor.java:1443)
	at org.netbeans.modules.openide.util.GlobalLookup.execute(GlobalLookup.java:68)
	at org.openide.util.lookup.Lookups.executeWith(Lookups.java:303)
	at org.openide.util.RequestProcessor$Processor.run(RequestProcessor.java:2058)
Comment 1 Alexander Simon 2017-04-11 14:09:07 UTC
Fixed class cast exception in enum, branch release82, changeset 44842af0b14c
Attached binary does not contain macro table.
Comment 2 soldatov 2017-04-11 14:50:39 UTC
In http://stackoverflow.com/questions/15330423/lldb-debugger-how-to-evaluate-c-macros I see:
Unfortunately this is not gonna happen because we get no debug info for macros from the compiler, which kinda makes sense because macros disappear after the preprocessor does its deed and before the compiler converts your sources to machine code.

Need to investigate
Comment 3 ilia 2017-04-12 12:44:59 UTC
https://netbeans.org/bugzilla/show_bug.cgi?id=270346 Changesets:
    http://hg.netbeans.org/releases/rev/44842af0b14c # fixed Bug #270346 MacOSX: IDE can't configure new project in many cases
Comment 4 Quality Engineering 2017-04-14 01:54:00 UTC
Integrated into 'main-silver', will be available in build *201704140002* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)

Changeset: http://hg.netbeans.org/main-silver/rev/7d8d4edb1f2b
User: Alexander Simon <alexvsimon@netbeans.org>
Log: fixed Bug #270346 MacOSX: IDE can't configure new project in many cases
- fixed class cast exception
(transplanted from 44842af0b14c45f5b06dd2b6f7526b16a5aa2331)
Comment 5 soldatov 2017-04-19 14:09:25 UTC
Verified in NetBeans IDE 8.2 (Build 201704181436)

Exception has been fixed only.
Comment 6 soldatov 2017-05-18 20:12:58 UTC
I found 2 links.

1) https://reviews.llvm.org/D16135
-fdebug-macro has been added, but on my MacOSX I see such error:
clang: error: unknown argument: '-fdebug-macro'

2) https://bugs.llvm.org/show_bug.cgi?id=31945
Some people uses -fdebug-macro flag