Skip to content

Successful debug builds, release build fails (symbols not found for arch i386) #17666

@DeadPackets

Description

@DeadPackets

Is this a bug report?

Yes

Have you read the Contributing Guidelines?

Yes

Environment

Environment:
OS: macOS High Sierra 10.13.1
Node: 8.9.1
Yarn: 1.3.2
npm: 5.6.0
Watchman: Not Found
Xcode: Xcode 9.2 Build version 9C40b
Android Studio: 3.0 AI-171.4443003

Packages: (wanted => installed)
react: 16.2.0 => 16.2.0
react-native: 0.52.0 => 0.52.0

Steps to Reproduce

Can't seem to replicate issue on new projects.

Expected Behavior

A successful build.

Actual Behavior

Failure to build, and XCode gives the following error.

Undefined symbols for architecture i386:
  "_OBJC_CLASS_$_RCTBridge", referenced from:
      l_OBJC_$_CATEGORY_RCTBridge_$_RCTImageLoader in libRCTImage.a(RCTImageLoader.o)
      l_OBJC_$_CATEGORY_RCTBridge_$_RCTImageStoreManager in libRCTImage.a(RCTImageStoreManager.o)
      l_OBJC_$_CATEGORY_RCTBridge_$_RCTNetworking in libRCTNetwork.a(RCTNetworking.o)
      l_OBJC_$_CATEGORY_RCTBridge_$_RCTWebSocketModule in libRCTWebSocket.a(RCTWebSocketModule.o)
  "_OBJC_CLASS_$_RCTBundleURLProvider", referenced from:
      objc-class-ref in AppDelegate.o
  "_OBJC_CLASS_$_RCTConvert", referenced from:
      objc-class-ref in libRCTBlob.a(RCTBlobManager.o)
      objc-class-ref in libRCTAnimation.a(RCTSpringAnimation.o)
      objc-class-ref in libRCTAnimation.a(RCTNativeAnimatedNodesManager.o)
      objc-class-ref in libRCTAnimation.a(RCTFrameAnimation.o)
      objc-class-ref in libRCTAnimation.a(RCTDecayAnimation.o)
      objc-class-ref in libRCTActionSheet.a(RCTActionSheetManager.o)
      objc-class-ref in libRCTGeolocation.a(RCTLocationObserver.o)
      ...
  "_OBJC_CLASS_$_RCTEventEmitter", referenced from:
      _OBJC_CLASS_$_RCTNativeAnimatedModule in libRCTAnimation.a(RCTNativeAnimatedModule.o)
      _OBJC_CLASS_$_RCTLocationObserver in libRCTGeolocation.a(RCTLocationObserver.o)
      _OBJC_CLASS_$_RCTLinkingManager in libRCTLinking.a(RCTLinkingManager.o)
      _OBJC_CLASS_$_RCTNetworking in libRCTNetwork.a(RCTNetworking.o)
      _OBJC_CLASS_$_RCTNetInfo in libRCTNetwork.a(RCTNetInfo.o)
      _OBJC_CLASS_$_RCTWebSocketModule in libRCTWebSocket.a(RCTWebSocketModule.o)
      _OBJC_CLASS_$_SafariViewManager in libSafariViewManager.a(SafariViewManager.o)
      ...
  "_OBJC_CLASS_$_RCTFont", referenced from:
      objc-class-ref in libRCTText.a(RCTShadowText.o)
      objc-class-ref in libRCTText.a(RCTFontAttributes.o)
     (maybe you meant: _OBJC_CLASS_$_RCTFontAttributes)
  "_OBJC_CLASS_$_RCTRootView", referenced from:
      objc-class-ref in AppDelegate.o
  "_OBJC_CLASS_$_RCTShadowView", referenced from:
      _OBJC_CLASS_$_RCTImageShadowView in libRCTImage.a(RCTImageShadowView.o)
      _OBJC_CLASS_$_RCTShadowTextView in libRCTText.a(RCTShadowTextView.o)
      _OBJC_CLASS_$_RCTShadowText in libRCTText.a(RCTShadowText.o)
      _OBJC_CLASS_$_RCTShadowRawText in libRCTText.a(RCTShadowRawText.o)
      _OBJC_CLASS_$_RCTShadowTextField in libRCTText.a(RCTShadowTextField.o)
  "_OBJC_CLASS_$_RCTView", referenced from:
      _OBJC_CLASS_$_RCTTextInput in libRCTText.a(RCTTextInput.o)
      _OBJC_CLASS_$_BVLinearGradient in libBVLinearGradient.a(BVLinearGradient.o)
  "_OBJC_CLASS_$_RCTViewManager", referenced from:
      _OBJC_CLASS_$_RCTImageViewManager in libRCTImage.a(RCTImageViewManager.o)
      _OBJC_CLASS_$_RCTTextManager in libRCTText.a(RCTTextManager.o)
      _OBJC_CLASS_$_RCTTextViewManager in libRCTText.a(RCTTextViewManager.o)
      _OBJC_CLASS_$_RCTTextFieldManager in libRCTText.a(RCTTextFieldManager.o)
      _OBJC_CLASS_$_RCTRawTextManager in libRCTText.a(RCTRawTextManager.o)
      _OBJC_CLASS_$_BVLinearGradientManager in libBVLinearGradient.a(BVLinearGradientManager.o)
      _OBJC_CLASS_$_RNSpinkitManager in libRNSpinkit.a(RNSpinkitManager.o)
      ...
  "_OBJC_METACLASS_$_RCTEventEmitter", referenced from:
      _OBJC_METACLASS_$_RCTNativeAnimatedModule in libRCTAnimation.a(RCTNativeAnimatedModule.o)
      _OBJC_METACLASS_$_RCTLocationObserver in libRCTGeolocation.a(RCTLocationObserver.o)
      _OBJC_METACLASS_$_RCTLinkingManager in libRCTLinking.a(RCTLinkingManager.o)
      _OBJC_METACLASS_$_RCTNetworking in libRCTNetwork.a(RCTNetworking.o)
      _OBJC_METACLASS_$_RCTNetInfo in libRCTNetwork.a(RCTNetInfo.o)
      _OBJC_METACLASS_$_RCTWebSocketModule in libRCTWebSocket.a(RCTWebSocketModule.o)
      _OBJC_METACLASS_$_SafariViewManager in libSafariViewManager.a(SafariViewManager.o)
      ...
  "_OBJC_METACLASS_$_RCTShadowView", referenced from:
      _OBJC_METACLASS_$_RCTImageShadowView in libRCTImage.a(RCTImageShadowView.o)
      _OBJC_METACLASS_$_RCTShadowTextView in libRCTText.a(RCTShadowTextView.o)
      _OBJC_METACLASS_$_RCTShadowText in libRCTText.a(RCTShadowText.o)
      _OBJC_METACLASS_$_RCTShadowRawText in libRCTText.a(RCTShadowRawText.o)
      _OBJC_METACLASS_$_RCTShadowTextField in libRCTText.a(RCTShadowTextField.o)
  "_OBJC_METACLASS_$_RCTView", referenced from:
      _OBJC_METACLASS_$_RCTTextInput in libRCTText.a(RCTTextInput.o)
      _OBJC_METACLASS_$_BVLinearGradient in libBVLinearGradient.a(BVLinearGradient.o)
  "_OBJC_METACLASS_$_RCTViewManager", referenced from:
      _OBJC_METACLASS_$_RCTImageViewManager in libRCTImage.a(RCTImageViewManager.o)
      _OBJC_METACLASS_$_RCTTextManager in libRCTText.a(RCTTextManager.o)
      _OBJC_METACLASS_$_RCTTextViewManager in libRCTText.a(RCTTextViewManager.o)
      _OBJC_METACLASS_$_RCTTextFieldManager in libRCTText.a(RCTTextFieldManager.o)
      _OBJC_METACLASS_$_RCTRawTextManager in libRCTText.a(RCTRawTextManager.o)
      _OBJC_METACLASS_$_BVLinearGradientManager in libBVLinearGradient.a(BVLinearGradientManager.o)
      _OBJC_METACLASS_$_RNSpinkitManager in libRNSpinkit.a(RNSpinkitManager.o)
      ...
  "_RCTAccessibilityManagerDidUpdateMultiplierNotification", referenced from:
      -[RCTFontAttributes initWithAccessibilityManager:] in libRCTText.a(RCTFontAttributes.o)
  "_RCTCeilPixelValue", referenced from:
      -[RCTUITextField intrinsicContentSize] in libRCTText.a(RCTUITextField.o)
      -[RCTUITextView placeholderSize] in libRCTText.a(RCTUITextView.o)
      _RCTMeasure in libRCTText.a(RCTShadowText.o)
  "_RCTConvertEnumValue", referenced from:
      +[RCTConvert(RCTResizeMode) RCTResizeMode:] in libRCTImage.a(RCTResizeMode.o)
  "_RCTErrorUnspecified", referenced from:
      -[RCTLinkingManager openURL:resolve:reject:] in libRCTLinking.a(RCTLinkingManager.o)
  "_RCTErrorWithMessage", referenced from:
      ___64-[RCTImageLoader _loadURLRequest:progressBlock:completionBlock:]_block_invoke in libRCTImage.a(RCTImageLoader.o)
      ___64-[RCTImageLoader _loadURLRequest:progressBlock:completionBlock:]_block_invoke.229 in libRCTImage.a(RCTImageLoader.o)
      -[RCTImageLoader decodeImageData:size:scale:clipped:resizeMode:completionBlock:] in libRCTImage.a(RCTImageLoader.o)
      ___80-[RCTImageLoader decodeImageData:size:scale:clipped:resizeMode:completionBlock:]_block_invoke_3.295 in libRCTImage.a(RCTImageLoader.o)
      ___75-[RCTImageEditingManager cropImage:cropData:successCallback:errorCallback:]_block_invoke_2 in libRCTImage.a(RCTImageEditingManager.o)
      -[RCTImageStoreManager getBase64ForTag:successCallback:errorCallback:] in libRCTImage.a(RCTImageStoreManager.o)
      ___73-[RCTImageStoreManager addImageFromBase64:successCallback:errorCallback:]_block_invoke in libRCTImage.a(RCTImageStoreManager.o)
      ...
  "_RCTExecuteOnMainQueue", referenced from:
      -[RCTNativeAnimatedModule eventDispatcherWillDispatchEvent:] in libRCTAnimation.a(RCTNativeAnimatedModule.o)
      -[RCTImageView imageLoaderLoadedImage:error:forImageSource:partial:] in libRCTImage.a(RCTImageView.o)
      ___68-[RCTImageView imageLoaderLoadedImage:error:forImageSource:partial:]_block_invoke.107 in libRCTImage.a(RCTImageView.o)
      -[RCTLocalAssetImageLoader loadImageForURL:size:scale:resizeMode:progressHandler:partialLoadHandler:completionHandler:] in libRCTImage.a(RCTLocalAssetImageLoader.o)
  "_RCTGetUIManagerQueue", referenced from:
      -[RCTNativeAnimatedModule methodQueue] in libRCTAnimation.a(RCTNativeAnimatedModule.o)
  "_RCTGzipData", referenced from:
      ___46-[RCTNetworking buildRequest:completionBlock:]_block_invoke.236 in libRCTNetwork.a(RCTNetworking.o)
  "_RCTImageFromLocalAssetURL", referenced from:
      ___119-[RCTLocalAssetImageLoader loadImageForURL:size:scale:resizeMode:progressHandler:partialLoadHandler:completionHandler:]_block_invoke in libRCTImage.a(RCTLocalAssetImageLoader.o)
  "_RCTIsBundleAssetURL", referenced from:
      -[RCTFileRequestHandler canHandleRequest:] in libRCTNetwork.a(RCTFileRequestHandler.o)
  "_RCTIsLocalAssetURL", referenced from:
      -[RCTLocalAssetImageLoader canLoadImageURL:] in libRCTImage.a(RCTLocalAssetImageLoader.o)
  "_RCTIsMainQueue", referenced from:
      ___118-[RCTImageLoader _loadImageOrDataWithURLRequest:size:scale:resizeMode:progressBlock:partialLoadBlock:completionBlock:]_block_invoke in libRCTImage.a(RCTImageLoader.o)
      ___80-[RCTImageLoader decodeImageData:size:scale:clipped:resizeMode:completionBlock:]_block_invoke_2 in libRCTImage.a(RCTImageLoader.o)
  "_RCTJSONClean", referenced from:
      -[RCTSettingsManager constantsToExport] in libRCTSettings.a(RCTSettingsManager.o)
      -[RCTSettingsManager userDefaultsDidChange:] in libRCTSettings.a(RCTSettingsManager.o)
  "_RCTJavaScriptDidFailToLoadNotification", referenced from:
      +[SplashScreen show] in libSplashScreen.a(SplashScreen.o)
  "_RCTPresentedViewController", referenced from:
      -[RCTActionSheetManager showActionSheetWithOptions:callback:] in libRCTActionSheet.a(RCTActionSheetManager.o)
      -[RCTActionSheetManager showShareActionSheetWithOptions:failureCallback:successCallback:] in libRCTActionSheet.a(RCTActionSheetManager.o)
  "_RCTRegisterModule", referenced from:
      +[RCTBlobManager load] in libRCTBlob.a(RCTBlobManager.o)
      +[RCTNativeAnimatedModule load] in libRCTAnimation.a(RCTNativeAnimatedModule.o)
      +[RCTActionSheetManager load] in libRCTActionSheet.a(RCTActionSheetManager.o)
      +[RCTLocationObserver load] in libRCTGeolocation.a(RCTLocationObserver.o)
      +[RCTImageLoader load] in libRCTImage.a(RCTImageLoader.o)
      +[RCTGIFImageDecoder load] in libRCTImage.a(RCTGIFImageDecoder.o)
      +[RCTImageEditingManager load] in libRCTImage.a(RCTImageEditingManager.o)
      ...
  "_RCTRoundPixelValue", referenced from:
      ___74-[RCTShadowText applyLayoutToChildren:viewsWithNewFrame:absolutePosition:]_block_invoke in libRCTText.a(RCTShadowText.o)
      -[RCTShadowText updateStorage:toFitFrame:] in libRCTText.a(RCTShadowText.o)
  "_RCTRunningInAppExtension", referenced from:
      -[RCTActionSheetManager showActionSheetWithOptions:callback:] in libRCTActionSheet.a(RCTActionSheetManager.o)
      -[RCTActionSheetManager showShareActionSheetWithOptions:failureCallback:successCallback:] in libRCTActionSheet.a(RCTActionSheetManager.o)
      -[RCTLinkingManager canOpenURL:resolve:reject:] in libRCTLinking.a(RCTLinkingManager.o)
  "_RCTScreenScale", referenced from:
      -[RCTImageView imageSourceForSize:] in libRCTImage.a(RCTImageView.o)
      -[RCTImageView reloadImage] in libRCTImage.a(RCTImageView.o)
      -[RCTImageView reactSetFrame:] in libRCTImage.a(RCTImageView.o)
      -[RNVectorIconsManager getImageForFont:withGlyph:withFontSize:withColor:callback:] in libRNVectorIcons.a(RNVectorIconsManager.o)
      _RCTDecodeImageWithData in libRCTImage.a(RCTImageUtils.o)
  "_RCTSharedApplication", referenced from:
      -[RCTLinkingManager openURL:resolve:reject:] in libRCTLinking.a(RCTLinkingManager.o)
      -[RCTLinkingManager canOpenURL:resolve:reject:] in libRCTLinking.a(RCTLinkingManager.o)
  "_RCTSizeInPixels", referenced from:
      _RCTDecodeImageWithData in libRCTImage.a(RCTImageUtils.o)
  "_RCTTextUpdateLagWarningThreshold", referenced from:
      -[RCTTextField setText:] in libRCTText.a(RCTTextField.o)
      -[RCTTextView setText:] in libRCTText.a(RCTTextView.o)
      -[RCTTextInput setSelection:] in libRCTText.a(RCTTextInput.o)
      -[RCTTextField setText:] in libRCTText.a(RCTTextField.o)
      -[RCTTextView setText:] in libRCTText.a(RCTTextView.o)
      -[RCTTextInput setSelection:] in libRCTText.a(RCTTextInput.o)
      -[RCTTextField setText:] in libRCTText.a(RCTTextField.o)
      -[RCTTextView setText:] in libRCTText.a(RCTTextView.o)
      -[RCTTextInput setSelection:] in libRCTText.a(RCTTextInput.o)
  "_RCTUIManagerWillUpdateViewsDueToContentSizeMultiplierChangeNotification", referenced from:
      -[RCTShadowText init] in libRCTText.a(RCTShadowText.o)
      -[RCTShadowRawText init] in libRCTText.a(RCTShadowRawText.o)
      -[RCTShadowText init] in libRCTText.a(RCTShadowText.o)
      -[RCTShadowRawText init] in libRCTText.a(RCTShadowRawText.o)
  "_YGFloatIsUndefined", referenced from:
      ___74-[RCTShadowText applyLayoutToChildren:viewsWithNewFrame:absolutePosition:]_block_invoke in libRCTText.a(RCTShadowText.o)
      -[RCTShadowText _attributedStringWithFontFamily:fontSize:fontWeight:fontStyle:letterSpacing:useBackgroundColor:foregroundColor:backgroundColor:opacity:] in libRCTText.a(RCTShadowText.o)
  "_YGNodeGetContext", referenced from:
      _RCTMeasure in libRCTText.a(RCTShadowText.o)
  "_YGNodeMarkDirty", referenced from:
      -[RCTShadowText contentSizeMultiplierDidChange:] in libRCTText.a(RCTShadowText.o)
      -[RCTShadowText _attributedStringWithFontFamily:fontSize:fontWeight:fontStyle:letterSpacing:useBackgroundColor:foregroundColor:backgroundColor:opacity:] in libRCTText.a(RCTShadowText.o)
  "_YGNodeSetMeasureFunc", referenced from:
      -[RCTShadowText init] in libRCTText.a(RCTShadowText.o)
  "_YGNodeStyleGetHeight", referenced from:
      ___74-[RCTShadowText applyLayoutToChildren:viewsWithNewFrame:absolutePosition:]_block_invoke in libRCTText.a(RCTShadowText.o)
      -[RCTShadowText _attributedStringWithFontFamily:fontSize:fontWeight:fontStyle:letterSpacing:useBackgroundColor:foregroundColor:backgroundColor:opacity:] in libRCTText.a(RCTShadowText.o)
  "_YGNodeStyleGetWidth", referenced from:
      ___74-[RCTShadowText applyLayoutToChildren:viewsWithNewFrame:absolutePosition:]_block_invoke in libRCTText.a(RCTShadowText.o)
      -[RCTShadowText _attributedStringWithFontFamily:fontSize:fontWeight:fontStyle:letterSpacing:useBackgroundColor:foregroundColor:backgroundColor:opacity:] in libRCTText.a(RCTShadowText.o)
  "__RCTLogNativeInternal", referenced from:
      -[RCTNativeAnimatedNodesManager createAnimatedNode:config:] in libRCTAnimation.a(RCTNativeAnimatedNodesManager.o)
      -[RCTNativeAnimatedNodesManager restoreDefaultValues:] in libRCTAnimation.a(RCTNativeAnimatedNodesManager.o)
      -[RCTNativeAnimatedNodesManager setAnimatedNodeValue:value:] in libRCTAnimation.a(RCTNativeAnimatedNodesManager.o)
      -[RCTNativeAnimatedNodesManager setAnimatedNodeOffset:offset:] in libRCTAnimation.a(RCTNativeAnimatedNodesManager.o)
      -[RCTNativeAnimatedNodesManager flattenAnimatedNodeOffset:] in libRCTAnimation.a(RCTNativeAnimatedNodesManager.o)
      -[RCTNativeAnimatedNodesManager extractAnimatedNodeOffset:] in libRCTAnimation.a(RCTNativeAnimatedNodesManager.o)
      -[RCTNativeAnimatedNodesManager startAnimatingNode:nodeTag:config:endCallback:] in libRCTAnimation.a(RCTNativeAnimatedNodesManager.o)
      ...
  "__RCTNotImplementedException", referenced from:
      -[RCTSpringAnimation init] in libRCTAnimation.a(RCTSpringAnimation.o)
      -[RCTFrameAnimation init] in libRCTAnimation.a(RCTFrameAnimation.o)
      -[RCTAnimatedNode init] in libRCTAnimation.a(RCTAnimatedNode.o)
      -[RCTDecayAnimation init] in libRCTAnimation.a(RCTDecayAnimation.o)
      -[RCTImageView init] in libRCTImage.a(RCTImageView.o)
      -[RCTNetworkTask init] in libRCTNetwork.a(RCTNetworkTask.o)
      -[RCTTextField initWithFrame:] in libRCTText.a(RCTTextField.o)
      ...
ld: symbol(s) not found for architecture i386
clang: error: linker command failed with exit code 1 (use -v to see invocation)

Reproducible Demo

My app is here: https://github.com/DeadPackets/CRNotify-App

Metadata

Metadata

Assignees

No one assigned

    Labels

    Ran CommandsOne of our bots successfully processed a command.Resolution: LockedThis issue was locked by the bot.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions