Skip to content

Including headers from a sub-framework #10796

Open

Description

@bobbrow

My code just has #include <Accelerate/Accelerate.h>, to which Intellisense gives the error cannot open source file "cblas.h"
I have the macFrameworkPath set to the same as you posted above and that helps resolve all the frameworks I'm using in this project (CoreFoundation, CoreAudio, Accelerate).

I have also tried adding the sub-framework to macFrameworkPath like
"/Applications/Xcode.app/Contents/Developer//Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Accelerate.framework/Versions/A/Frameworks"
hoping that would help but it didn't.

My entire c_cpp_properties is

{
    "configurations": [
        {
            "name": "Mac",
            "includePath": [
                "/Users/lucianthorr/dev/myproject/**",
                "/Applications/Xcode.app/Contents/Developer//Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Accelerate.framework/Versions/A/Frameworks/vecLib.framework/Headers"
            ],
            "defines": [],
            "macFrameworkPath": [
                "/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks"
            ],
            "cStandard": "c11",
            "cppStandard": "c++17",
            "intelliSenseMode": "macos-clang-arm64",
            "mergeConfigurations": false,
            "compilerPath": "/usr/bin/clang",
            "browse": {
                "limitSymbolsToIncludedHeaders": true,
                "path": [
                    "${workspaceFolder}/**"
                ]
            }
        }
    ],
    "version": 4
}

Originally posted by Jason Aylward (@lucianthorr) in microsoft/vscode-cmake-tools#3094 (comment)

Activity

  1. bobbrow commented on Apr 10, 2023

    @bobbrow
    ContributorAuthor

    More context can be found in the CMake Tools issue that this is coming from. Basically, there is a framework called veclib defined within the Accelerate framework. I was thinking we pre-processed the framework paths to include any child frameworks (maybe it was just for code browsing), but I don't have a mac to test this out anymore and can't inspect the chain of includes.

  2. Zingam commented on Apr 22, 2023

    @Zingam

    Bob Brown (@bobbrow) I also experienced such issues with frameworks and reported them.
    For example: Here is another one by another user
    #10840

    I feel that these issues with macOS Frameworks are all connected and should be addressed globally.

    Since I started using VSCode with Xcode, the development experience on macOS improved significantly but there are still a few issues and missing pieces/features in cpptiols and cmake-tools to make the experience perfect and complete.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    • Status
      No status

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions