question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Build Failed: Undefined symbols for architecture x86_64

See original GitHub issue

The app crashes due to react-native-image-filter-kit, this is the crash log:

Xcode build failed > Error:

Undefined symbols for architecture x86_64:
  "_OBJC_CLASS_$_RCTImageView", referenced from:
      objc-class-ref in IFKImageFilter.o
      __OBJC_$_CATEGORY_RCTImageView_$_CacheKey in RCTImageView+CacheKey.o
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)

Terminal Error:

The following build commands failed:
        .../Library/Developer/Xcode/DerivedData/MY_PROJECT-dxmgqdxborzhroajvyivtvivrlsi/Build/Products/Debug-iphonesimulator/react-native-image-filter-kit/react_native_image_filter_kit.framework/react_native_image_filter_kit normal x86_64
(1 failure)

react_native_image_filter_kit was installed properly based on documentation via: pod install

what I’ve done to fix the issue with no success:

  • Upgrading macOs from Mojave to Catalina
  • Upgrading Xcode from 10.2 to 11.4
  • Adding javaScriptCore.framework > Build Phases > Link Binary and Libraries (for both my_project & my_projectTests)

Current System Info: OS: macOS 10.15.5 CPU: (4) x64 Intel® Core™ i5-7360U CPU @ 2.30GHz Memory: 234.01 MB / 8.00 GB Shell: 5.7.1 - /bin/zsh Binaries: Node: 10.15.1 - /usr/local/bin/node npm: 6.9.0 - /usr/local/bin/npm Watchman: 4.9.0 - /usr/local/bin/watchman SDKs: iOS SDK: Platforms: iOS 13.4, DriverKit 19.0, macOS 10.15, tvOS 13.4, watchOS 6.2 Android SDK: API Levels: 28, 29 Build Tools: 28.0.3, 29.0.2, 29.0.3 System Images: android-28 | Intel x86 Atom_64, android-28 | Google Play Intel x86 Atom IDEs: Android Studio: 4.0 AI-193.6911.18.40.6514223 Xcode: 11.4/11N132i - /usr/bin/xcodebuild npmPackages: react: ^16.9.0 => 16.9.0 react-native: ^0.61.5 => 0.61.5 npmGlobalPackages: react-native-cli: 2.0.1

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Reactions:1
  • Comments:6 (2 by maintainers)

github_iconTop GitHub Comments

2reactions
iyegoroffcommented, Jul 5, 2020

That error means that native part of the module can’t be accessed - e.g. it was not installed properly.

1reaction
abdelhedydevcommented, Apr 26, 2021

Add this line in your react-native-image-filter-kit.podspec , this file exist in node_modules / react-native-image-filter-kit s.static_framework = true your entire file should be :

require 'json'

package = JSON.parse(File.read(File.join(__dir__, 'package.json')))

Pod::Spec.new do |s|
  s.name             = package['name']
  s.version          = package['version']
  s.summary          = package['description']
  s.homepage         = package['homepage']
  s.license          = package['license']
  s.author           = package['author']
  s.platform         = :ios, '9.0'
  s.source           = { :git => 'https://github.com/iyegoroff/react-native-image-filter-kit.git', :tag => 'v#{s.version}' }
  s.source_files     = 'ios/**/*.{h,m}'
  s.resource_bundles = { 'bundle' => ['ios/Resources/*.cikernel'] }
  s.requires_arc     = true

  s.dependency 'React'
  s.static_framework = true
  s.dependency 'Bolts/Tasks', '1.9.0'
end

don’t forget : cd ios && pod install

Thx to https://github.com/bbeldame

Read more comments on GitHub >

github_iconTop Results From Across the Web

Xcode build failure "Undefined symbols for architecture x86_64"
I am trying to write a very simple console program, that searches for paired BT devices and prints them to an NSLog. It...
Read more >
Undefined symbols for architecture x86_64 - Apple Developer
I'm trying to create an application that sends keystrokes to another process and I keep getting this error: Undefined symbols for architecture x86_64:....
Read more >
Undefined symbols for architecture x86_64 Xcode 12 #213
build phase 2. Try to compile to the simulator 3. Get error Undefined symbols for architecture x86_64: "_OBJC_CLASS_$_FlurryWatch", ...
Read more >
Fixing React Native build error: Undefined symbols ... - Medium
While running yarn ios for React Native v0.64.2 on my mac machine (macOS 11.6, XCode 13) i've encountered following error: Undefined symbols ......
Read more >
64316 (gcc9 @9.4.0_1 & gcc10 @10.3.0_1: build failure
:info:build Undefined symbols for architecture x86_64: :info:build "_cfun", referenced from: :info:build ___cxx_global_var_init.99 in gencondmd.o ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found