Skip to content

Commit

Permalink
Remove searching of Xcode private paths in build
Browse files Browse the repository at this point in the history
Summary:
This was needed a while back when we weak-linked particular frameworks.

Since then we've removed the need to do this:
1) There's no weak-linking of any Xcode frameworks. All Xcode frameworks are linked at runtime, as such they don't need to be referenced in the build.
2) Headers for any of Xcode's private libraries are resident in `PrivateHeaders`, part of the project.

This also breaks test targets in Xcode 13.2 since the search path for XCTest.framework is overridden. The Framework doesn't contain headers anymore:

```
note: did not find header 'XCTest.h' in framework 'XCTest' (loaded from '/Applications/xcode_13_2_1.app/Contents/SharedFrameworks'
``

Reviewed By: jbardini

Differential Revision: D33581989

fbshipit-source-id: efe2475b465cb9a4112ca200d5564efbd13ab891
  • Loading branch information
lawrencelomax authored and facebook-github-bot committed Jan 14, 2022
1 parent 17281d0 commit 020cae8
Showing 1 changed file with 1 addition and 7 deletions.
8 changes: 1 addition & 7 deletions Configuration/Shared.xcconfig
Original file line number Diff line number Diff line change
Expand Up @@ -55,15 +55,9 @@ GCC_WARN_UNUSED_VALUE = YES
GCC_WARN_UNUSED_VARIABLE = YES
ONLY_ACTIVE_ARCH = YES

// Inferred Directories. Important for the linker to be able to find and weak-link private symbols.
APPLE_FRAMEWORKS_DIR = $(DEVELOPER_DIR)/../Frameworks
APPLE_OTHER_FRAMEWORKS_DIR = $(DEVELOPER_DIR)/../OtherFrameworks
APPLE_PLUGINS_DIR = $(DEVELOPER_DIR)/../PlugIns
APPLE_SHARED_FRAMEWORKS_DIR = $(DEVELOPER_DIR)/../SharedFrameworks

// Search Paths for Frameworks & Headers
ALWAYS_SEARCH_USER_PATHS = NO
FRAMEWORK_SEARCH_PATHS = $(inherited) $(APPLE_FRAMEWORKS_DIR) $(APPLE_PLUGINS_DIR) $(APPLE_OTHER_FRAMEWORKS_DIR) $(APPLE_SHARED_FRAMEWORKS_DIR) $(DEVELOPER_LIBRARY_DIR)/PrivateFrameworks $(SDKROOT)/System/Library/PrivateFrameworks /Library/Developer/PrivateFrameworks
FRAMEWORK_SEARCH_PATHS = $(inherited) $(DEVELOPER_LIBRARY_DIR)/PrivateFrameworks $(SDKROOT)/System/Library/PrivateFrameworks /Library/Developer/PrivateFrameworks
HEADER_SEARCH_PATHS = $(inherited) $(SRCROOT)/PrivateHeaders

// SDK & OS Versions
Expand Down

0 comments on commit 020cae8

Please sign in to comment.