Skip to content

Add more system paths to the reject list. #4082

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged

Conversation

adrian-prantl
Copy link

Some versions of macOS install frameworks in these places, but LLDB
should never import modules from there and instead prefer the SDK.

rdar://89836973

@adrian-prantl
Copy link
Author

@swift-ci test

1 similar comment
@adrian-prantl
Copy link
Author

@swift-ci test

@adrian-prantl
Copy link
Author

@swift-ci test

@adrian-prantl
Copy link
Author

@swift-ci test

1 similar comment
@adrian-prantl
Copy link
Author

@swift-ci test

@adrian-prantl
Copy link
Author

@swift-ci test macOS

@jimingham
Copy link

jimingham commented Mar 17, 2022

/Library/Developer seems like a fairly generic directory within /Library and /Library is where external packages are supposed to install their artifacts. If we have to block that out as well we have to, but it doesn't feel right.

@kastiglione
Copy link

Is /Library/Developer/PrivateFrameworks for external packages too? Or only system?

@adrian-prantl
Copy link
Author

@swift-ci test macOS

@adrian-prantl
Copy link
Author

One other thing to note is that this is only about additional auto-discovered framework paths. If the application was built with -F/Library/Developer.... the path would still be accessible.

@adrian-prantl
Copy link
Author

adrian-prantl commented Mar 17, 2022

Is /Library/Developer/PrivateFrameworks for external packages too? Or only system?

I was operating under the assumption that that is specifically a path reserved by the system.

I haven't seen us explicitly claim that. For instance we did add ~/Library/Developer but everything gets put in subdirectories of that (Xcode, CoreDevice, etc.) so it could coexist with other packages.

@jimingham
Copy link

Is /Library/Developer/PrivateFrameworks for external packages too? Or only system?

/Library is where external packages put their code. External packages are free to have PrivateFrameworks. Normally you would install just in /Library/Frameworks or /Library/PrivateFrameworks but it makes sense to cordon your package off from others (presumably why we are putting stuff in Developer...) and I don't think we've claimed Developer formally.

@jimingham
Copy link

One other thing to note is that this is only about additional auto-discovered framework paths. If the application was built with -F/Library/Developer.... the path would still be accessible.

Clients of a library wouldn't link directly to PrivateFrameworks, however. So for a client they will always link to a public framework, which would then link to the PrivateFramework, so I think PrivateFrameworks are primarily going to be auto-discovered ones, right?

@adrian-prantl
Copy link
Author

I verified that with #4083 we don't actually need to remove this path, because it gets added at the end of the path list and the desired path comes before it.

Some versions of macOS install frameworks in these places, but LLDB
should never import modules from there and instead prefer the SDK.

rdar://89836973
@adrian-prantl
Copy link
Author

@swift-ci test

@adrian-prantl adrian-prantl merged commit 50d0b45 into swiftlang:stable/20211026 Mar 18, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants