Problem compiling the 1.3 Framework SDK into a project

I have an existing project into which I want to add the Estimote SDK.
I copied the Framework file into the right directory, and added it to the project, but get the following compile error:

Undefined symbols for architecture arm64:
  "_OBJC_CLASS_$_ESTBeaconRegionWrapper", referenced from:
      objc-class-ref in EstimoteSDK(ESTSecureBeaconManager.o)
ld: symbol(s) not found for architecture arm64
clang: error: linker command failed with exit code 1 (use -v to see invocation)

I can’t really see what I am doing wrong.

The error above was due to a linker flag -ObjC. However removing that still gives problems, now I get:

Ld /Users/.../iDomsPortalDev normal arm64
    cd "/Users/.../idoms-portal"
    export IPHONEOS_DEPLOYMENT_TARGET=7.0
    export PATH="/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin:/Applications/Xcode.app/Contents/Developer/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin"
    /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang -arch arm64 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS8.2.sdk -L/Users/.../Products/Debug-iphoneos -F/Users/.../Products/Debug-iphoneos -FiDoms/frameworks -F/Applications/Xcode.app/Contents/Developer/Library/Frameworks -filelist /Users/.../Debug-iphoneos/iDoms\ Dev.build/Objects-normal/arm64/iDomsPortalDev.LinkFileList -Xlinker -rpath -Xlinker @executable_path/Frameworks -dead_strip -lxml2 -lc++ -fobjc-arc -fobjc-link-runtime -miphoneos-version-min=7.0 -framework CrashReporter -framework EstimoteSDK -weak_framework Accelerate -weak_framework Social -weak_framework Twitter -framework MessageUI -framework MapKit -framework AVFoundation -framework SystemConfiguration -framework MediaPlayer -framework QuartzCore -framework UIKit -framework Foundation -framework CoreGraphics -framework CoreData -framework CoreLocation -Xlinker -dependency_info -Xlinker /Users/.../Debug-iphoneos/iDoms\ Dev.build/Objects-normal/arm64/iDomsPortalDev_dependency_info.dat -o /Users/.../iDomsPortalDev

Undefined symbols for architecture arm64:
  "_CBAdvertisementDataServiceDataKey", referenced from:
      +[ESTDeviceDataHelper parseAdvertisingData:] in EstimoteSDK(ESTDeviceDataHelper.o)
  "_OBJC_CLASS_$_CBCentralManager", referenced from:
      objc-class-ref in EstimoteSDK(ESTBeaconDevice.o)
  "_kSecAttrService", referenced from:
      -[ESTKeychain dataForKey:] in EstimoteSDK(ESTKeychain.o)
      -[ESTKeychain setObject:forKey:] in EstimoteSDK(ESTKeychain.o)
      +[ESTKeychain bundleSeedID] in EstimoteSDK(ESTKeychain.o)
  "_kSecAttrAccessibleAfterFirstUnlock", referenced from:
      -[ESTKeychain setObject:forKey:] in EstimoteSDK(ESTKeychain.o)
  "_OBJC_CLASS_$_CBUUID", referenced from:
      objc-class-ref in EstimoteSDK(ESTBeaconDevice.o)
      objc-class-ref in EstimoteSDK(ESTBluetoothServiceAuth.o)
      objc-class-ref in EstimoteSDK(ESTBluetoothServiceEstimote.o)
      objc-class-ref in EstimoteSDK(ESTBluetoothServiceOta.o)
      objc-class-ref in EstimoteSDK(ESTBluetoothServiceSoftware.o)
      objc-class-ref in EstimoteSDK(ETBluetoothMath.o)
  "_kSecAttrAccessibleWhenUnlocked", referenced from:
      -[ESTKeychain setObject:forKey:] in EstimoteSDK(ESTKeychain.o)
  "_kSecReturnAttributes", referenced from:
      +[ESTKeychain bundleSeedID] in EstimoteSDK(ESTKeychain.o)
  "_kSecAttrAccessible", referenced from:
      -[ESTKeychain setObject:forKey:] in EstimoteSDK(ESTKeychain.o)
  "_kSecAttrAccessibleAlways", referenced from:
      -[ESTKeychain setObject:forKey:] in EstimoteSDK(ESTKeychain.o)
  "_CBCentralManagerScanOptionAllowDuplicatesKey", referenced from:
      -[ESTBeaconDevice startScanning] in EstimoteSDK(ESTBeaconDevice.o)
  "_SecItemDelete", referenced from:
      -[ESTKeychain setObject:forKey:] in EstimoteSDK(ESTKeychain.o)
  "_kSecAttrAccessibleAfterFirstUnlockThisDeviceOnly", referenced from:
      -[ESTKeychain setObject:forKey:] in EstimoteSDK(ESTKeychain.o)
  "_kSecAttrAccessibleAlwaysThisDeviceOnly", referenced from:
      -[ESTKeychain setObject:forKey:] in EstimoteSDK(ESTKeychain.o)
  "_SecItemUpdate", referenced from:
      -[ESTKeychain setObject:forKey:] in EstimoteSDK(ESTKeychain.o)
  "_kSecAttrAccessibleWhenUnlockedThisDeviceOnly", referenced from:
      -[ESTKeychain setObject:forKey:] in EstimoteSDK(ESTKeychain.o)
  "_SecItemAdd", referenced from:
      -[ESTKeychain setObject:forKey:] in EstimoteSDK(ESTKeychain.o)
      +[ESTKeychain bundleSeedID] in EstimoteSDK(ESTKeychain.o)
  "_SecItemCopyMatching", referenced from:
      -[ESTKeychain dataForKey:] in EstimoteSDK(ESTKeychain.o)
      +[ESTKeychain bundleSeedID] in EstimoteSDK(ESTKeychain.o)
  "_kSecClass", referenced from:
      -[ESTKeychain dataForKey:] in EstimoteSDK(ESTKeychain.o)
      -[ESTKeychain setObject:forKey:] in EstimoteSDK(ESTKeychain.o)
      +[ESTKeychain bundleSeedID] in EstimoteSDK(ESTKeychain.o)
  "_kSecClassGenericPassword", referenced from:
      -[ESTKeychain dataForKey:] in EstimoteSDK(ESTKeychain.o)
      -[ESTKeychain setObject:forKey:] in EstimoteSDK(ESTKeychain.o)
      +[ESTKeychain bundleSeedID] in EstimoteSDK(ESTKeychain.o)
  "_kSecAttrAccount", referenced from:
      -[ESTKeychain dataForKey:] in EstimoteSDK(ESTKeychain.o)
      -[ESTKeychain setObject:forKey:] in EstimoteSDK(ESTKeychain.o)
      +[ESTKeychain bundleSeedID] in EstimoteSDK(ESTKeychain.o)
  "_kSecValueData", referenced from:
      -[ESTKeychain setObject:forKey:] in EstimoteSDK(ESTKeychain.o)
  "_kSecAttrAccessGroup", referenced from:
      -[ESTKeychain dataForKey:] in EstimoteSDK(ESTKeychain.o)
      -[ESTKeychain setObject:forKey:] in EstimoteSDK(ESTKeychain.o)
      +[ESTKeychain bundleSeedID] in EstimoteSDK(ESTKeychain.o)
  "_kSecMatchLimitOne", referenced from:
      -[ESTKeychain dataForKey:] in EstimoteSDK(ESTKeychain.o)
  "_kSecMatchLimit", referenced from:
      -[ESTKeychain dataForKey:] in EstimoteSDK(ESTKeychain.o)
  "_kSecReturnData", referenced from:
      -[ESTKeychain dataForKey:] in EstimoteSDK(ESTKeychain.o)
ld: symbol(s) not found for architecture arm64
clang: error: linker command failed with exit code 1 (use -v to see invocation)

I found the problem. My project is three years old, so some settings are not as new projects are defined.
For me the build option ‘Enable modules’ was set to ‘No’, and it is supposed to be ‘Yes’.

1 Like

We’ve just pushed an SDK 3.0.2 to our GitHub, which actually resolves this issue without having to tinker with any settings. :smiley: