Skip to content

Commit 9f72e6a

Browse files
tyrone-sudeiumfacebook-github-bot
authored andcommitted
Fix duplicate symbols linker error in xcodeproj (#23284)
Summary: When using building React Native using the `.xcodeproj` (either via linked projects in Xcode, or precompiling React Native, which is what we do), you'll get a duplicate symbol error: ``` duplicate symbol __ZN8facebook5react10IInspectorD0Ev ... ``` And a few more. This is because the `InspectorInterfaces.cpp` file is included in _both_ the `React` target _and_ the `jsinspector` target, and since the `jsinspector` target gets linked into the `React` target, this means the symbols from `InspectorInterfaces.cpp` end up in `libReact.a` twice. <img width="187" alt="screen shot 2019-02-04 at 11 43 39 am" src="https://user-images.githubusercontent.com/819705/52189088-93190880-288a-11e9-8411-b44b59e8e461.png"> This PR removes `InspectorInterfaces.cpp` from the `React` target, as I believe was the original intent. Since this bug is in the `xcodeproj` it only affects builds that use that, so CocoaPods and Buck users are unaffected. [iOS][Fixed] - Fix potential linker issues when using xcode project Pull Request resolved: #23284 Differential Revision: D13941777 Pulled By: cpojer fbshipit-source-id: 8a3ffb4fc916ff6570bbff8794b4515b48055667
1 parent 7ee13cc commit 9f72e6a

File tree

1 file changed

+0
-4
lines changed

1 file changed

+0
-4
lines changed

React/React.xcodeproj/project.pbxproj

-4
Original file line numberDiff line numberDiff line change
@@ -1101,13 +1101,11 @@
11011101
E223624420875A8000108244 /* JSExecutor.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E223624320875A8000108244 /* JSExecutor.cpp */; };
11021102
E9B20B7B1B500126007A2DA7 /* RCTAccessibilityManager.m in Sources */ = {isa = PBXBuildFile; fileRef = E9B20B7A1B500126007A2DA7 /* RCTAccessibilityManager.m */; };
11031103
EBF21BBC1FC498270052F4D5 /* InspectorInterfaces.h in Headers */ = {isa = PBXBuildFile; fileRef = EBF21BBA1FC498270052F4D5 /* InspectorInterfaces.h */; };
1104-
EBF21BBD1FC498270052F4D5 /* InspectorInterfaces.cpp in Sources */ = {isa = PBXBuildFile; fileRef = EBF21BBB1FC498270052F4D5 /* InspectorInterfaces.cpp */; };
11051104
EBF21BBE1FC498630052F4D5 /* InspectorInterfaces.h in Headers */ = {isa = PBXBuildFile; fileRef = EBF21BBA1FC498270052F4D5 /* InspectorInterfaces.h */; };
11061105
EBF21BFB1FC498FC0052F4D5 /* InspectorInterfaces.h in Copy Headers */ = {isa = PBXBuildFile; fileRef = EBF21BBA1FC498270052F4D5 /* InspectorInterfaces.h */; };
11071106
EBF21BFC1FC4990B0052F4D5 /* InspectorInterfaces.cpp in Sources */ = {isa = PBXBuildFile; fileRef = EBF21BBB1FC498270052F4D5 /* InspectorInterfaces.cpp */; };
11081107
EBF21BFE1FC499840052F4D5 /* InspectorInterfaces.h in Copy Headers */ = {isa = PBXBuildFile; fileRef = EBF21BBA1FC498270052F4D5 /* InspectorInterfaces.h */; };
11091108
EBF21BFF1FC4998E0052F4D5 /* InspectorInterfaces.cpp in Sources */ = {isa = PBXBuildFile; fileRef = EBF21BBB1FC498270052F4D5 /* InspectorInterfaces.cpp */; };
1110-
EBF21C001FC499A80052F4D5 /* InspectorInterfaces.cpp in Sources */ = {isa = PBXBuildFile; fileRef = EBF21BBB1FC498270052F4D5 /* InspectorInterfaces.cpp */; };
11111109
ED296F82214C973700B7C4FE /* libjsinspector-tvOS.a in Frameworks */ = {isa = PBXBuildFile; fileRef = EBF21BFA1FC4989A0052F4D5 /* libjsinspector-tvOS.a */; };
11121110
ED296F83214C974A00B7C4FE /* libyoga.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 3D3C06751DE3340C00C268FA /* libyoga.a */; };
11131111
ED296FB7214C9A9A00B7C4FE /* JSIDynamic.cpp in Sources */ = {isa = PBXBuildFile; fileRef = EDEBC6DA214B3F6800DD5AC8 /* JSIDynamic.cpp */; };
@@ -4231,7 +4229,6 @@
42314229
13134C871E296B2A00B9F3CB /* RCTCxxBridge.mm in Sources */,
42324230
CF2731C31E7B8DF30044CA4F /* RCTDeviceInfo.m in Sources */,
42334231
599FAA3F1FB274980058CCF6 /* RCTSurfaceRootShadowView.m in Sources */,
4234-
EBF21C001FC499A80052F4D5 /* InspectorInterfaces.cpp in Sources */,
42354232
597633371F4E021D005BE8A4 /* RCTShadowView+Internal.m in Sources */,
42364233
2D3B5EB11D9B090100451313 /* RCTAppState.m in Sources */,
42374234
59E604A31FE9CCE300BD90C5 /* RCTScrollContentViewManager.m in Sources */,
@@ -4511,7 +4508,6 @@
45114508
59D031F71F8353D3008361F0 /* RCTSafeAreaViewLocalData.m in Sources */,
45124509
13E067571A70F44B002CDEE1 /* RCTView.m in Sources */,
45134510
3D7749441DC1065C007EC8D8 /* RCTPlatform.m in Sources */,
4514-
EBF21BBD1FC498270052F4D5 /* InspectorInterfaces.cpp in Sources */,
45154511
59EDBCAF1FDF4E0C003573DE /* RCTScrollContentView.m in Sources */,
45164512
13D9FEEE1CDCD93000158BD7 /* RCTKeyboardObserver.m in Sources */,
45174513
B233E6EA1D2D845D00BC68BA /* RCTI18nManager.m in Sources */,

0 commit comments

Comments
 (0)