issues with Parse framework and iOS 7 - ios

I'm trying to integrate Parse framework in my project built in iOS 7. I done in another project with iOS 6 and there wasn't any problem. With the new iOS, the project doesn't compile. It seems that the problem is Parsse framework isn't built for armv7s architecture. I don't know how to solve this problem.
I attach the problems that xcode 5 shows:
Undefined symbols for architecture armv7s: "_sqlite3_reset", referenced from:
_initializeStatement in Parse(PF_FBCacheIndex.o)
"_sqlite3_column_int", referenced from:
-[PF_FBCacheIndex _createCacheEntityInfo:] in Parse(PF_FBCacheIndex.o)
-[PF_FBCacheIndex _fetchCurrentDiskUsage] in Parse(PF_FBCacheIndex.o)
-[PF_FBCacheIndex _trimDatabase] in Parse(PF_FBCacheIndex.o)
"_sqlite3_bind_int", referenced from:
-[PF_FBCacheIndex _updateEntryInDatabaseForKey:entry:] in Parse(PF_FBCacheIndex.o)
-[PF_FBCacheIndex _writeEntryInDatabase:] in Parse(PF_FBCacheIndex.o)
-[PF_FBCacheIndex _trimDatabase] in Parse(PF_FBCacheIndex.o)
"_sqlite3_column_text", referenced from:
-[PF_FBCacheIndex _createCacheEntityInfo:] in Parse(PF_FBCacheIndex.o)
-[PF_FBCacheIndex _trimDatabase] in Parse(PF_FBCacheIndex.o)
"_sqlite3_bind_text", referenced from:
-[PF_FBCacheIndex _updateEntryInDatabaseForKey:entry:] in Parse(PF_FBCacheIndex.o)
-[PF_FBCacheIndex _writeEntryInDatabase:] in Parse(PF_FBCacheIndex.o)
-[PF_FBCacheIndex _readEntryFromDatabase:] in Parse(PF_FBCacheIndex.o)
-[PF_FBCacheIndex _readEntriesFromDatabase:excludingFragment:] in Parse(PF_FBCacheIndex.o)
-[PF_FBCacheIndex _removeEntryFromDatabaseForKey:] in Parse(PF_FBCacheIndex.o)
"_sqlite3_column_double", referenced from:
-[PF_FBCacheIndex _createCacheEntityInfo:] in Parse(PF_FBCacheIndex.o)
"_sqlite3_bind_double", referenced from:
-[PF_FBCacheIndex _updateEntryInDatabaseForKey:entry:] in Parse(PF_FBCacheIndex.o)
-[PF_FBCacheIndex _writeEntryInDatabase:] in Parse(PF_FBCacheIndex.o)
"_sqlite3_step", referenced from:
-[PF_FBCacheIndex _updateEntryInDatabaseForKey:entry:] in Parse(PF_FBCacheIndex.o)
-[PF_FBCacheIndex _writeEntryInDatabase:] in Parse(PF_FBCacheIndex.o)
-[PF_FBCacheIndex _createCacheEntityInfo:] in Parse(PF_FBCacheIndex.o)
-[PF_FBCacheIndex _fetchCurrentDiskUsage] in Parse(PF_FBCacheIndex.o)
-[PF_FBCacheIndex _removeEntryFromDatabaseForKey:] in Parse(PF_FBCacheIndex.o)
-[PF_FBCacheIndex _dropTrimmingTable] in Parse(PF_FBCacheIndex.o)
-[PF_FBCacheIndex _trimDatabase] in Parse(PF_FBCacheIndex.o)
...
"_sqlite3_prepare_v2", referenced from:
_initializeStatement in Parse(PF_FBCacheIndex.o)
"_sqlite3_open_v2", referenced from:
___39-[PF_FBCacheIndex initWithCacheFolder:]_block_invoke in Parse(PF_FBCacheIndex.o)
"_sqlite3_errmsg", referenced from:
_releaseStatement in Parse(PF_FBCacheIndex.o)
-[PF_FBCacheIndex _updateEntryInDatabaseForKey:entry:] in Parse(PF_FBCacheIndex.o)
_initializeStatement in Parse(PF_FBCacheIndex.o)
-[PF_FBCacheIndex _writeEntryInDatabase:] in Parse(PF_FBCacheIndex.o)
-[PF_FBCacheIndex _readEntryFromDatabase:] in Parse(PF_FBCacheIndex.o)
-[PF_FBCacheIndex _readEntriesFromDatabase:excludingFragment:] in Parse(PF_FBCacheIndex.o)
-[PF_FBCacheIndex _fetchCurrentDiskUsage] in Parse(PF_FBCacheIndex.o)
...
"_sqlite3_finalize", referenced from:
_releaseStatement in Parse(PF_FBCacheIndex.o)
"_sqlite3_close", referenced from:
___26-[PF_FBCacheIndex dealloc]_block_invoke in Parse(PF_FBCacheIndex.o)
"_sqlite3_exec", referenced from:
___39-[PF_FBCacheIndex initWithCacheFolder:]_block_invoke in Parse(PF_FBCacheIndex.o)
ld: symbol(s) not found for architecture armv7s clang: error: linker command failed with exit code 1 (use -v to see invocation)

I've solved the problem: what worked for me was to include the libraries:
libsqlite.3dylib
libz.dylib
They can be found in the Parse PushNotificationTutorial project. You can download it from the web of Parse.

Related

Strange Link errors on iOS with CMake

I'm linking a CMake generated framework to an iOS test Bundle application, in order to execute the tests contained in the framework over an iOS platform.
When building, I have an very strange errors in the link stage:
ld: warning: directory not found for option '-L/Users/fporcarelli/GIT/iOSApp/iGeoMobile/smartsdk-middleware/smartsdk-core/Unit-Tests/iOS/SmartSDK-core-tester/../../build/NavNetwork/smartsdk-core/External/lib'
Undefined symbols for architecture x86_64:
"_strchr", referenced from:
_lprofFindFirstDirSeparator in libclang_rt.profile_iossim.a(InstrProfilingUtil.c.o)
"_open", referenced from:
_lprofOpenFileEx in libclang_rt.profile_iossim.a(InstrProfilingUtil.c.o)
"_uname", referenced from:
_lprofGetHostName in libclang_rt.profile_iossim.a(InstrProfilingUtil.c.o)
"_ftell", referenced from:
_getProfileFileSizeForMerging in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
"_strncpy", referenced from:
_createProfileDir in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
_lprofGetHostName in libclang_rt.profile_iossim.a(InstrProfilingUtil.c.o)
"_setenv", referenced from:
_truncateCurrentFile in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
"_fwrite", referenced from:
_fileWriter in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
"_atexit", referenced from:
___llvm_profile_register_write_file_atexit in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
(maybe you meant: ___llvm_profile_register_write_file_atexit)
"_fopen", referenced from:
_writeFile in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
_truncateCurrentFile in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
_initializeProfileForContinuousMode in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
"_mmap", referenced from:
_initializeProfileForContinuousMode in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
_mmapProfileForMerging in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
"_munmap", referenced from:
_writeFile in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
_initializeProfileForContinuousMode in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
_mmapProfileForMerging in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
"_ftruncate", referenced from:
_writeFile in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
"_fseek", referenced from:
_writeFile in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
_fileWriter in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
_getProfileFileSizeForMerging in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
"_fprintf", referenced from:
_parseAndSetFilename in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
___llvm_profile_write_file in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
_writeFile in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
_initializeProfileForContinuousMode in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
_getProfileFileSizeForMerging in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
_mmapProfileForMerging in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
_lprofOpenFileEx in libclang_rt.profile_iossim.a(InstrProfilingUtil.c.o)
...
"_strerror", referenced from:
___llvm_profile_write_file in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
_writeFile in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
_initializeProfileForContinuousMode in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
_getProfileFileSizeForMerging in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
_mmapProfileForMerging in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
"_fclose", referenced from:
_writeFile in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
_truncateCurrentFile in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
"_free", referenced from:
_parseAndSetFilename in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
_writeFile in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
___llvm_profile_instrument_target_value in libclang_rt.profile_iossim.a(InstrProfilingValue.c.o)
"_strcmp", referenced from:
_parseAndSetFilename in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
"_fileno", referenced from:
_writeFile in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
_initializeProfileForContinuousMode in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
_mmapProfileForMerging in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
_lprofLockFileHandle in libclang_rt.profile_iossim.a(InstrProfilingUtil.c.o)
_lprofUnlockFileHandle in libclang_rt.profile_iossim.a(InstrProfilingUtil.c.o)
"_fflush", referenced from:
_writeFile in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
"_exit", referenced from:
_exitSignalHandler in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
"_getenv", referenced from:
___llvm_profile_initialize_file in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
_parseAndSetFilename in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
_writeFile in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
_truncateCurrentFile in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
_lprofSetupValueProfiler in libclang_rt.profile_iossim.a(InstrProfilingValue.c.o)
"_calloc", referenced from:
_writeFile in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
___llvm_profile_instrument_target_value in libclang_rt.profile_iossim.a(InstrProfilingValue.c.o)
"_sigaction", referenced from:
_lprofInstallSignalHandler in libclang_rt.profile_iossim.a(InstrProfilingUtil.c.o)
"_strdup", referenced from:
_parseAndSetFilename in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
"_memset", referenced from:
_parseAndSetFilename in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
_writeOneValueProfData in libclang_rt.profile_iossim.a(InstrProfilingWriter.c.o)
"_fdopen", referenced from:
_lprofOpenFileEx in libclang_rt.profile_iossim.a(InstrProfilingUtil.c.o)
"_atoi", referenced from:
_writeFile in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
_lprofSetupValueProfiler in libclang_rt.profile_iossim.a(InstrProfilingValue.c.o)
"___stderrp", referenced from:
_parseAndSetFilename in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
___llvm_profile_write_file in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
_writeFile in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
_initializeProfileForContinuousMode in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
_getProfileFileSizeForMerging in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
_mmapProfileForMerging in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
_lprofOpenFileEx in libclang_rt.profile_iossim.a(InstrProfilingUtil.c.o)
...
"_snprintf", referenced from:
_getCurFilename in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
_parseAndSetFilename in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
"_strlen", referenced from:
_getCurFilename in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
___llvm_profile_write_file in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
_truncateCurrentFile in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
_initializeProfileForContinuousMode in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
_createProfileDir in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
"_fcntl", referenced from:
_lprofLockFileHandle in libclang_rt.profile_iossim.a(InstrProfilingUtil.c.o)
_lprofUnlockFileHandle in libclang_rt.profile_iossim.a(InstrProfilingUtil.c.o)
_lprofOpenFileEx in libclang_rt.profile_iossim.a(InstrProfilingUtil.c.o)
"_mkdir", referenced from:
___llvm_profile_recursive_mkdir in libclang_rt.profile_iossim.a(InstrProfilingUtil.c.o)
(maybe you meant: ___llvm_profile_recursive_mkdir)
"___error", referenced from:
___llvm_profile_write_file in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
_writeFile in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
_initializeProfileForContinuousMode in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
_getProfileFileSizeForMerging in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
_mmapProfileForMerging in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
_lprofLockFileHandle in libclang_rt.profile_iossim.a(InstrProfilingUtil.c.o)
_lprofUnlockFileHandle in libclang_rt.profile_iossim.a(InstrProfilingUtil.c.o)
...
"_getpid", referenced from:
_getCurFilename in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
_parseAndSetFilename in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
_lprofLockFileHandle in libclang_rt.profile_iossim.a(InstrProfilingUtil.c.o)
_lprofUnlockFileHandle in libclang_rt.profile_iossim.a(InstrProfilingUtil.c.o)
_lprofOpenFileEx in libclang_rt.profile_iossim.a(InstrProfilingUtil.c.o)
"_ftello", referenced from:
_initializeProfileForContinuousMode in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
"__Unwind_Resume", referenced from:
-[SmartSDK_core_tests testALL] in SmartSDK_core_tests.o
"___stack_chk_guard", referenced from:
-[SmartSDK_core_tests testALL] in SmartSDK_core_tests.o
_getCurFilename in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
___llvm_profile_write_file in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
_truncateCurrentFile in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
_initializeProfileForContinuousMode in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
_createProfileDir in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
_lprofBufferIOWrite in libclang_rt.profile_iossim.a(InstrProfilingWriter.c.o)
...
"_memcpy", referenced from:
_getCurFilename in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
_lprofBufferWriter in libclang_rt.profile_iossim.a(InstrProfilingWriter.c.o)
_lprofBufferIOWrite in libclang_rt.profile_iossim.a(InstrProfilingWriter.c.o)
"___stack_chk_fail", referenced from:
-[SmartSDK_core_tests testALL] in SmartSDK_core_tests.o
_getCurFilename in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
___llvm_profile_write_file in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
_truncateCurrentFile in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
_initializeProfileForContinuousMode in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
_createProfileDir in libclang_rt.profile_iossim.a(InstrProfilingFile.c.o)
_lprofBufferIOWrite in libclang_rt.profile_iossim.a(InstrProfilingWriter.c.o)
...
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
The error is very strange, since the unresolved symbols do not belong to my code, but to clang-related static libraries...
Thanks in advance for any help
I found the issue. One of the CMake targets in my framework was named "System". So, the correspondent output file was a "libSystem.a" static library. Swift framework must link to every target an homonym library which contains all standard libraries. For some reasons, the linker found my library in place of the correct one, and so every framework was not able to find the symbols defined in standard libraries (since they are not defined in my System lib).

How to build React Native package in Swift?

I wanna build React Native iOS PhotoEditor module in Swift.
I simply created a new library using react-native-create-library and modified the iOS module like this.
For now, I just wanna push a simple UIViewController.
I followed Native Modules Guideline of React Native but I am getting error while launching the app.
I attached the screenshot of the structure, full codes and error logs.
// RNPhotoEditor.swift
// RNPhotoEditor
//
// Created by Gang on 2/13/19.
// Copyright © 2019 Facebook. All rights reserved.
//
import Foundation
import UIKit
#objc(RNPhotoEditor)
class RNPhotoEditor: NSObject {
#objc func Edit(props: NSDictionary, onDone: RCTResponseSenderBlock, onCancel: RCTResponseSenderBlock) -> Void {
let editorVC = PhotoEditorViewController()
getRootVC().present(editorVC, animated: true, completion: nil)
}
func getRootVC() -> UIViewController {
var root = UIApplication.shared.keyWindow?.rootViewController
while root?.presentedViewController != nil {
root = root?.presentedViewController
}
return root!
}
}
//
// RNPhotoEditorBridge.m
// RNPhotoEditor
//
// Created by Gang on 2/13/19.
// Copyright © 2019 Facebook. All rights reserved.
//
#import <React/RCTBridgeModule.h>
#interface RCT_EXTERN_MODULE(RNPhotoEditor, NSObject)
RCT_EXTERN_METHOD(Edit:(nonnull NSDictionary *)props onDone:(RCTResponseSenderBlock)onDone onCancel:(RCTResponseSenderBlock)onCancel)
#end
//
// RNPhotoEditor-Bridging-Header.h
// RNPhotoEditor-Bridging-Header
//
// Created by Gang on 2/13/19.
// Copyright © 2019 Facebook. All rights reserved.
// Use this file to import your target's public headers that you would like to expose to Swift.
//
#import <React/RCTBridgeModule.h>
Here is the error log.
ld: warning: directory not found for option '-L/Users/gang/Library/Developer/Xcode/DerivedData/app-ezczldbbkpyqcxaeyxheyjdtqbth/Build/Products/Debug-iphoneos/React'
ld: warning: object file (/Users/gang/Library/Developer/Xcode/DerivedData/app-ezczldbbkpyqcxaeyxheyjdtqbth/Build/Products/Debug-iphoneos/libLRDRCTSimpleToast.a(UIView+Toast.o)) was built for newer iOS version (9.3) than being linked (9.0)
ld: warning: object file (/Users/gang/Library/Developer/Xcode/DerivedData/app-ezczldbbkpyqcxaeyxheyjdtqbth/Build/Products/Debug-iphoneos/libLRDRCTSimpleToast.a(LRDRCTSimpleToast.o)) was built for newer iOS version (9.3) than being linked (9.0)
ld: warning: Could not find auto-linked library 'swiftCoreGraphics'
ld: warning: Could not find auto-linked library 'swiftFoundation'
ld: warning: Could not find auto-linked library 'swiftMetal'
ld: warning: Could not find auto-linked library 'swiftDarwin'
ld: warning: Could not find auto-linked library 'swiftUIKit'
ld: warning: Could not find auto-linked library 'swiftObjectiveC'
ld: warning: Could not find auto-linked library 'swiftCoreFoundation'
ld: warning: Could not find auto-linked library 'swiftDispatch'
ld: warning: Could not find auto-linked library 'swiftCoreImage'
ld: warning: Could not find auto-linked library 'swiftQuartzCore'
ld: warning: Could not find auto-linked library 'swiftCore'
ld: warning: Could not find auto-linked library 'swiftSwiftOnoneSupport'
Undefined symbols for architecture arm64:
"value witness table for Builtin.UnknownObject", referenced from:
full type metadata for RNPhotoEditor.PhotoEditorViewController in libRNPhotoEditor.a(PhotoEditorViewController.o)
full type metadata for RNPhotoEditor.RNPhotoEditor in libRNPhotoEditor.a(RNPhotoEditor.o)
"(extension in Foundation):Swift.String._bridgeToObjectiveC() -> __C.NSString", referenced from:
RNPhotoEditor.PhotoEditorViewController.init(nibName: Swift.String?, bundle: __C.NSBundle?) -> RNPhotoEditor.PhotoEditorViewController in libRNPhotoEditor.a(PhotoEditorViewController.o)
"static (extension in Foundation):Swift.String._unconditionallyBridgeFromObjectiveC(__C.NSString?) -> Swift.String", referenced from:
#objc RNPhotoEditor.PhotoEditorViewController.init(nibName: Swift.String?, bundle: __C.NSBundle?) -> RNPhotoEditor.PhotoEditorViewController in libRNPhotoEditor.a(PhotoEditorViewController.o)
"(extension in Foundation):Swift.Array._bridgeToObjectiveC() -> __C.NSArray", referenced from:
reabstraction thunk helper from #callee_unowned #convention(block) (#unowned __C.NSArray?) -> () to #escaping #callee_guaranteed (#guaranteed [Any]?) -> () in libRNPhotoEditor.a(RNPhotoEditor.o)
"Swift._fatalErrorMessage(_: Swift.StaticString, _: Swift.StaticString, file: Swift.StaticString, line: Swift.UInt, flags: Swift.UInt32) -> Swift.Never", referenced from:
RNPhotoEditor.RNPhotoEditor.getRootVC() -> __C.UIViewController in libRNPhotoEditor.a(RNPhotoEditor.o)
"type metadata for Any", referenced from:
reabstraction thunk helper from #callee_unowned #convention(block) (#unowned __C.NSArray?) -> () to #escaping #callee_guaranteed (#guaranteed [Any]?) -> () in libRNPhotoEditor.a(RNPhotoEditor.o)
"__swift_FORCE_LOAD_$_swiftCoreFoundation", referenced from:
__swift_FORCE_LOAD_$_swiftCoreFoundation_$_RNPhotoEditor in libRNPhotoEditor.a(PhotoEditorViewController.o)
__swift_FORCE_LOAD_$_swiftCoreFoundation_$_RNPhotoEditor in libRNPhotoEditor.a(RNPhotoEditor.o)
(maybe you meant: __swift_FORCE_LOAD_$_swiftCoreFoundation_$_RNPhotoEditor)
"__swift_FORCE_LOAD_$_swiftCoreGraphics", referenced from:
__swift_FORCE_LOAD_$_swiftCoreGraphics_$_RNPhotoEditor in libRNPhotoEditor.a(PhotoEditorViewController.o)
__swift_FORCE_LOAD_$_swiftCoreGraphics_$_RNPhotoEditor in libRNPhotoEditor.a(RNPhotoEditor.o)
(maybe you meant: __swift_FORCE_LOAD_$_swiftCoreGraphics_$_RNPhotoEditor)
"__swift_FORCE_LOAD_$_swiftCoreImage", referenced from:
__swift_FORCE_LOAD_$_swiftCoreImage_$_RNPhotoEditor in libRNPhotoEditor.a(PhotoEditorViewController.o)
__swift_FORCE_LOAD_$_swiftCoreImage_$_RNPhotoEditor in libRNPhotoEditor.a(RNPhotoEditor.o)
(maybe you meant: __swift_FORCE_LOAD_$_swiftCoreImage_$_RNPhotoEditor)
"__swift_FORCE_LOAD_$_swiftDarwin", referenced from:
__swift_FORCE_LOAD_$_swiftDarwin_$_RNPhotoEditor in libRNPhotoEditor.a(PhotoEditorViewController.o)
__swift_FORCE_LOAD_$_swiftDarwin_$_RNPhotoEditor in libRNPhotoEditor.a(RNPhotoEditor.o)
(maybe you meant: __swift_FORCE_LOAD_$_swiftDarwin_$_RNPhotoEditor)
"__swift_FORCE_LOAD_$_swiftDispatch", referenced from:
__swift_FORCE_LOAD_$_swiftDispatch_$_RNPhotoEditor in libRNPhotoEditor.a(PhotoEditorViewController.o)
__swift_FORCE_LOAD_$_swiftDispatch_$_RNPhotoEditor in libRNPhotoEditor.a(RNPhotoEditor.o)
(maybe you meant: __swift_FORCE_LOAD_$_swiftDispatch_$_RNPhotoEditor)
"__swift_FORCE_LOAD_$_swiftFoundation", referenced from:
__swift_FORCE_LOAD_$_swiftFoundation_$_RNPhotoEditor in libRNPhotoEditor.a(PhotoEditorViewController.o)
__swift_FORCE_LOAD_$_swiftFoundation_$_RNPhotoEditor in libRNPhotoEditor.a(RNPhotoEditor.o)
(maybe you meant: __swift_FORCE_LOAD_$_swiftFoundation_$_RNPhotoEditor)
"__swift_FORCE_LOAD_$_swiftMetal", referenced from:
__swift_FORCE_LOAD_$_swiftMetal_$_RNPhotoEditor in libRNPhotoEditor.a(PhotoEditorViewController.o)
__swift_FORCE_LOAD_$_swiftMetal_$_RNPhotoEditor in libRNPhotoEditor.a(RNPhotoEditor.o)
(maybe you meant: __swift_FORCE_LOAD_$_swiftMetal_$_RNPhotoEditor)
"__swift_FORCE_LOAD_$_swiftObjectiveC", referenced from:
__swift_FORCE_LOAD_$_swiftObjectiveC_$_RNPhotoEditor in libRNPhotoEditor.a(PhotoEditorViewController.o)
__swift_FORCE_LOAD_$_swiftObjectiveC_$_RNPhotoEditor in libRNPhotoEditor.a(RNPhotoEditor.o)
(maybe you meant: __swift_FORCE_LOAD_$_swiftObjectiveC_$_RNPhotoEditor)
"__swift_FORCE_LOAD_$_swiftQuartzCore", referenced from:
__swift_FORCE_LOAD_$_swiftQuartzCore_$_RNPhotoEditor in libRNPhotoEditor.a(PhotoEditorViewController.o)
__swift_FORCE_LOAD_$_swiftQuartzCore_$_RNPhotoEditor in libRNPhotoEditor.a(RNPhotoEditor.o)
(maybe you meant: __swift_FORCE_LOAD_$_swiftQuartzCore_$_RNPhotoEditor)
"__swift_FORCE_LOAD_$_swiftUIKit", referenced from:
__swift_FORCE_LOAD_$_swiftUIKit_$_RNPhotoEditor in libRNPhotoEditor.a(PhotoEditorViewController.o)
__swift_FORCE_LOAD_$_swiftUIKit_$_RNPhotoEditor in libRNPhotoEditor.a(RNPhotoEditor.o)
(maybe you meant: __swift_FORCE_LOAD_$_swiftUIKit_$_RNPhotoEditor)
"_swift_allocObject", referenced from:
#objc RNPhotoEditor.RNPhotoEditor.Edit(props: __C.NSDictionary, onDone: ([Any]?) -> (), onCancel: ([Any]?) -> ()) -> () in libRNPhotoEditor.a(RNPhotoEditor.o)
"_swift_bridgeObjectRelease", referenced from:
RNPhotoEditor.PhotoEditorViewController.init(nibName: Swift.String?, bundle: __C.NSBundle?) -> RNPhotoEditor.PhotoEditorViewController in libRNPhotoEditor.a(PhotoEditorViewController.o)
outlined consume of Swift.String? in libRNPhotoEditor.a(PhotoEditorViewController.o)
reabstraction thunk helper from #callee_unowned #convention(block) (#unowned __C.NSArray?) -> () to #escaping #callee_guaranteed (#guaranteed [Any]?) -> () in libRNPhotoEditor.a(RNPhotoEditor.o)
"_swift_bridgeObjectRetain", referenced from:
outlined copy of Swift.String? in libRNPhotoEditor.a(PhotoEditorViewController.o)
reabstraction thunk helper from #callee_unowned #convention(block) (#unowned __C.NSArray?) -> () to #escaping #callee_guaranteed (#guaranteed [Any]?) -> () in libRNPhotoEditor.a(RNPhotoEditor.o)
"_swift_deallocObject", referenced from:
l_objectdestroy in libRNPhotoEditor.a(RNPhotoEditor.o)
l_objectdestroy.2 in libRNPhotoEditor.a(RNPhotoEditor.o)
"_swift_getInitializedObjCClass", referenced from:
type metadata accessor for RNPhotoEditor.PhotoEditorViewController in libRNPhotoEditor.a(PhotoEditorViewController.o)
RNPhotoEditor.RNPhotoEditor.getRootVC() -> __C.UIViewController in libRNPhotoEditor.a(RNPhotoEditor.o)
type metadata accessor for RNPhotoEditor.RNPhotoEditor in libRNPhotoEditor.a(RNPhotoEditor.o)
"_swift_getObjCClassFromMetadata", referenced from:
__C.UIViewController.__allocating_init() -> __C.UIViewController in libRNPhotoEditor.a(RNPhotoEditor.o)
"_swift_isaMask", referenced from:
RNPhotoEditor.RNPhotoEditor.Edit(props: __C.NSDictionary, onDone: ([Any]?) -> (), onCancel: ([Any]?) -> ()) -> () in libRNPhotoEditor.a(RNPhotoEditor.o)
"_swift_release", referenced from:
#objc RNPhotoEditor.RNPhotoEditor.Edit(props: __C.NSDictionary, onDone: ([Any]?) -> (), onCancel: ([Any]?) -> ()) -> () in libRNPhotoEditor.a(RNPhotoEditor.o)
"_swift_retain", referenced from:
#objc RNPhotoEditor.RNPhotoEditor.Edit(props: __C.NSDictionary, onDone: ([Any]?) -> (), onCancel: ([Any]?) -> ()) -> () in libRNPhotoEditor.a(RNPhotoEditor.o)
ld: symbol(s) not found for architecture arm64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
I am really not sure what the following error means.
ld: symbol(s) not found for architecture arm64
Also, how can I clear this kind of warnings?
ld: warning: Could not find auto-linked library 'swiftUIKit'
Can someone please tell me how to write Swift iOS library for React Native? I am struggling for a couple of days but no luck.
I'd appreciate any help! Thanks.

RxTest: Undefined symbols for architecture x86_64 and arm64

I am trying to run the following test from Chapter 16: Testing with RxTest of Raywenderlich RxSwift book:
import XCTest
import RxSwift
import RxTest
#testable import Testing
class TestingViewModel : XCTestCase {
var viewModel: ViewModel!
var scheduler: ConcurrentDispatchQueueScheduler!
override func setUp() {
super.setUp()
viewModel = ViewModel()
scheduler = ConcurrentDispatchQueueScheduler(qos: .default)
}
func testColorNameIsRayWenderlichGreenWhenHexStringIs006636() {
// 1
let colorNameObservable = viewModel.colorName.asObservable().subscribeOn(scheduler)
// 2
viewModel.hexString.value = "#006636"
// 3
XCTAssertEqual("rayWenderlichGreen", try! colorNameObservable.toBlocking().first()!)
}
}
But I get this error on the simulator:
Undefined symbols for architecture x86_64:
"type metadata for RxCocoa.DriverSharingStrategy", referenced from:
TestingTests.TestingViewModel.testColorNameIsRayWenderlichGreenWhenHexStringIs006636() -> () in TestingViewModel.o
"protocol witness table for RxCocoa.DriverSharingStrategy : RxCocoa.SharingStrategyProtocol in RxCocoa", referenced from:
TestingTests.TestingViewModel.testColorNameIsRayWenderlichGreenWhenHexStringIs006636() -> () in TestingViewModel.o
"RxCocoa.SharedSequence.asObservable() -> RxSwift.Observable", referenced from:
TestingTests.TestingViewModel.testColorNameIsRayWenderlichGreenWhenHexStringIs006636() -> () in TestingViewModel.o
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
And This one on iPhone 6s:
Undefined symbols for architecture arm64:
"type metadata for RxCocoa.DriverSharingStrategy", referenced from:
TestingTests.TestingViewModel.testColorNameIsRayWenderlichGreenWhenHexStringIs006636() -> () in TestingViewModel.o
"protocol witness table for RxCocoa.DriverSharingStrategy : RxCocoa.SharingStrategyProtocol in RxCocoa", referenced from:
TestingTests.TestingViewModel.testColorNameIsRayWenderlichGreenWhenHexStringIs006636() -> () in TestingViewModel.o
"RxCocoa.SharedSequence.asObservable() -> RxSwift.Observable", referenced from:
TestingTests.TestingViewModel.testColorNameIsRayWenderlichGreenWhenHexStringIs006636() -> () in TestingViewModel.o
ld: symbol(s) not found for architecture arm64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
Unfortunately, there is no support for this issue in Raywenderlich's forums.
After a lot of searches, As somebody suggests here for another similar issue I found that this error will be solved by importing RxCocoa.

google admob showing following error?

I have added latest 6.9.2 google admob to my project ,and when i add admob codes i got lots of errors bcoz i didnt add any framework fro that.But after that am getting 1 error
please check error
Ld /Users/apple/Library/Developer/Xcode/DerivedData/iFix-bbdyzggojkuirifhdwktfnpnlnnj/Build/Products/Debug-iphonesimulator/iFix.app/iFix normal x86_64
cd /Users/apple/Documents/myApp/iFix
export IPHONEOS_DEPLOYMENT_TARGET=7.1
export PATH="/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.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 x86_64 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator7.1.sdk -L/Users/apple/Library/Developer/Xcode/DerivedData/iFix-bbdyzggojkuirifhdwktfnpnlnnj/Build/Products/Debug-iphonesimulator -L/Users/apple/Documents/myApp/iFix/GoogleMobileAdsSdkiOS-6.9.2/Add-ons/GoogleAnalyticsServicesiOS_3.06 -L/Users/apple/Documents/myApp/iFix/GoogleMobileAdsSdkiOS-6.9.2 -F/Users/apple/Library/Developer/Xcode/DerivedData/iFix-bbdyzggojkuirifhdwktfnpnlnnj/Build/Products/Debug-iphonesimulator -filelist /Users/apple/Library/Developer/Xcode/DerivedData/iFix-bbdyzggojkuirifhdwktfnpnlnnj/Build/Intermediates/iFix.build/Debug-iphonesimulator/iFix.build/Objects-normal/x86_64/iFix.LinkFileList -Xlinker -objc_abi_version -Xlinker 2 -fobjc-arc -fobjc-link-runtime -Xlinker -no_implicit_dylibs -mios-simulator-version-min=7.1 -lsqlite3 -framework CoreTelephony -framework AudioToolbox -lz -lGoogleAnalyticsServices -framework CoreData -framework SystemConfiguration -framework AdSupport -framework StoreKit -framework MessageUI -lAdIdAccess -lGoogleAdMobAds -framework QuartzCore -framework CoreGraphics -framework Accelerate -framework UIKit -framework Foundation -Xlinker -dependency_info -Xlinker /Users/apple/Library/Developer/Xcode/DerivedData/iFix-bbdyzggojkuirifhdwktfnpnlnnj/Build/Intermediates/iFix.build/Debug-iphonesimulator/iFix.build/Objects-normal/x86_64/iFix_dependency_info.dat -o /Users/apple/Library/Developer/Xcode/DerivedData/iFix-bbdyzggojkuirifhdwktfnpnlnnj/Build/Products/Debug-iphonesimulator/iFix.app/iFix
duplicate symbol _OBJC_IVAR_$_RootViewController._delegate in:
/Users/apple/Library/Developer/Xcode/DerivedData/iFix-bbdyzggojkuirifhdwktfnpnlnnj/Build/Intermediates/iFix.build/Debug-iphonesimulator/iFix.build/Objects-normal/x86_64/RootViewController-7D747D9B193AB571.o
/Users/apple/Library/Developer/Xcode/DerivedData/iFix-bbdyzggojkuirifhdwktfnpnlnnj/Build/Intermediates/iFix.build/Debug-iphonesimulator/iFix.build/Objects-normal/x86_64/RootViewController-484D37809EE9EA65.o
duplicate symbol _OBJC_IVAR_$_RootViewController._tableView in:
/Users/apple/Library/Developer/Xcode/DerivedData/iFix-bbdyzggojkuirifhdwktfnpnlnnj/Build/Intermediates/iFix.build/Debug-iphonesimulator/iFix.build/Objects-normal/x86_64/RootViewController-7D747D9B193AB571.o
/Users/apple/Library/Developer/Xcode/DerivedData/iFix-bbdyzggojkuirifhdwktfnpnlnnj/Build/Intermediates/iFix.build/Debug-iphonesimulator/iFix.build/Objects-normal/x86_64/RootViewController-484D37809EE9EA65.o
duplicate symbol _OBJC_IVAR_$_RootViewController._items in:
/Users/apple/Library/Developer/Xcode/DerivedData/iFix-bbdyzggojkuirifhdwktfnpnlnnj/Build/Intermediates/iFix.build/Debug-iphonesimulator/iFix.build/Objects-normal/x86_64/RootViewController-7D747D9B193AB571.o
/Users/apple/Library/Developer/Xcode/DerivedData/iFix-bbdyzggojkuirifhdwktfnpnlnnj/Build/Intermediates/iFix.build/Debug-iphonesimulator/iFix.build/Objects-normal/x86_64/RootViewController-484D37809EE9EA65.o
duplicate symbol _OBJC_CLASS_$_RootViewController in:
/Users/apple/Library/Developer/Xcode/DerivedData/iFix-bbdyzggojkuirifhdwktfnpnlnnj/Build/Intermediates/iFix.build/Debug-iphonesimulator/iFix.build/Objects-normal/x86_64/RootViewController-7D747D9B193AB571.o
/Users/apple/Library/Developer/Xcode/DerivedData/iFix-bbdyzggojkuirifhdwktfnpnlnnj/Build/Intermediates/iFix.build/Debug-iphonesimulator/iFix.build/Objects-normal/x86_64/RootViewController-484D37809EE9EA65.o
duplicate symbol _OBJC_METACLASS_$_RootViewController in:
/Users/apple/Library/Developer/Xcode/DerivedData/iFix-bbdyzggojkuirifhdwktfnpnlnnj/Build/Intermediates/iFix.build/Debug-iphonesimulator/iFix.build/Objects-normal/x86_64/RootViewController-7D747D9B193AB571.o
/Users/apple/Library/Developer/Xcode/DerivedData/iFix-bbdyzggojkuirifhdwktfnpnlnnj/Build/Intermediates/iFix.build/Debug-iphonesimulator/iFix.build/Objects-normal/x86_64/RootViewController-484D37809EE9EA65.o
duplicate symbol _OBJC_CLASS_$_ImageViewController in:
/Users/apple/Library/Developer/Xcode/DerivedData/iFix-bbdyzggojkuirifhdwktfnpnlnnj/Build/Intermediates/iFix.build/Debug-iphonesimulator/iFix.build/Objects-normal/x86_64/ImageViewController-4F03FFF23E5AE975.o
/Users/apple/Library/Developer/Xcode/DerivedData/iFix-bbdyzggojkuirifhdwktfnpnlnnj/Build/Intermediates/iFix.build/Debug-iphonesimulator/iFix.build/Objects-normal/x86_64/ImageViewController-842B460CB8ABB481.o
duplicate symbol _OBJC_METACLASS_$_ImageViewController in:
/Users/apple/Library/Developer/Xcode/DerivedData/iFix-bbdyzggojkuirifhdwktfnpnlnnj/Build/Intermediates/iFix.build/Debug-iphonesimulator/iFix.build/Objects-normal/x86_64/ImageViewController-4F03FFF23E5AE975.o
/Users/apple/Library/Developer/Xcode/DerivedData/iFix-bbdyzggojkuirifhdwktfnpnlnnj/Build/Intermediates/iFix.build/Debug-iphonesimulator/iFix.build/Objects-normal/x86_64/ImageViewController-842B460CB8ABB481.o
duplicate symbol _OBJC_IVAR_$_CategoryViewController._category in:
/Users/apple/Library/Developer/Xcode/DerivedData/iFix-bbdyzggojkuirifhdwktfnpnlnnj/Build/Intermediates/iFix.build/Debug-iphonesimulator/iFix.build/Objects-normal/x86_64/CategoryViewController-85440B24E1A926F.o
/Users/apple/Library/Developer/Xcode/DerivedData/iFix-bbdyzggojkuirifhdwktfnpnlnnj/Build/Intermediates/iFix.build/Debug-iphonesimulator/iFix.build/Objects-normal/x86_64/CategoryViewController-4147041320096859.o
duplicate symbol _OBJC_IVAR_$_CategoryViewController._delegate in:
/Users/apple/Library/Developer/Xcode/DerivedData/iFix-bbdyzggojkuirifhdwktfnpnlnnj/Build/Intermediates/iFix.build/Debug-iphonesimulator/iFix.build/Objects-normal/x86_64/CategoryViewController-85440B24E1A926F.o
/Users/apple/Library/Developer/Xcode/DerivedData/iFix-bbdyzggojkuirifhdwktfnpnlnnj/Build/Intermediates/iFix.build/Debug-iphonesimulator/iFix.build/Objects-normal/x86_64/CategoryViewController-4147041320096859.o
duplicate symbol _OBJC_IVAR_$_CategoryViewController._tableView in:
/Users/apple/Library/Developer/Xcode/DerivedData/iFix-bbdyzggojkuirifhdwktfnpnlnnj/Build/Intermediates/iFix.build/Debug-iphonesimulator/iFix.build/Objects-normal/x86_64/CategoryViewController-85440B24E1A926F.o
/Users/apple/Library/Developer/Xcode/DerivedData/iFix-bbdyzggojkuirifhdwktfnpnlnnj/Build/Intermediates/iFix.build/Debug-iphonesimulator/iFix.build/Objects-normal/x86_64/CategoryViewController-4147041320096859.o
duplicate symbol _OBJC_IVAR_$_CategoryViewController._items in:
/Users/apple/Library/Developer/Xcode/DerivedData/iFix-bbdyzggojkuirifhdwktfnpnlnnj/Build/Intermediates/iFix.build/Debug-iphonesimulator/iFix.build/Objects-normal/x86_64/CategoryViewController-85440B24E1A926F.o
/Users/apple/Library/Developer/Xcode/DerivedData/iFix-bbdyzggojkuirifhdwktfnpnlnnj/Build/Intermediates/iFix.build/Debug-iphonesimulator/iFix.build/Objects-normal/x86_64/CategoryViewController-4147041320096859.o
duplicate symbol _OBJC_CLASS_$_CategoryViewController in:
/Users/apple/Library/Developer/Xcode/DerivedData/iFix-bbdyzggojkuirifhdwktfnpnlnnj/Build/Intermediates/iFix.build/Debug-iphonesimulator/iFix.build/Objects-normal/x86_64/CategoryViewController-85440B24E1A926F.o
/Users/apple/Library/Developer/Xcode/DerivedData/iFix-bbdyzggojkuirifhdwktfnpnlnnj/Build/Intermediates/iFix.build/Debug-iphonesimulator/iFix.build/Objects-normal/x86_64/CategoryViewController-4147041320096859.o
duplicate symbol _OBJC_METACLASS_$_CategoryViewController in:
/Users/apple/Library/Developer/Xcode/DerivedData/iFix-bbdyzggojkuirifhdwktfnpnlnnj/Build/Intermediates/iFix.build/Debug-iphonesimulator/iFix.build/Objects-normal/x86_64/CategoryViewController-85440B24E1A926F.o
/Users/apple/Library/Developer/Xcode/DerivedData/iFix-bbdyzggojkuirifhdwktfnpnlnnj/Build/Intermediates/iFix.build/Debug-iphonesimulator/iFix.build/Objects-normal/x86_64/CategoryViewController-4147041320096859.o
duplicate symbol _main in:
/Users/apple/Library/Developer/Xcode/DerivedData/iFix-bbdyzggojkuirifhdwktfnpnlnnj/Build/Intermediates/iFix.build/Debug-iphonesimulator/iFix.build/Objects-normal/x86_64/main-C7855F1C6FD2F976.o
/Users/apple/Library/Developer/Xcode/DerivedData/iFix-bbdyzggojkuirifhdwktfnpnlnnj/Build/Intermediates/iFix.build/Debug-iphonesimulator/iFix.build/Objects-normal/x86_64/main-FCACA536EA23C482.o
duplicate symbol _OBJC_METACLASS_$_NavController in:
/Users/apple/Library/Developer/Xcode/DerivedData/iFix-bbdyzggojkuirifhdwktfnpnlnnj/Build/Intermediates/iFix.build/Debug-iphonesimulator/iFix.build/Objects-normal/x86_64/NavController-13F0601C84D2856E.o
/Users/apple/Library/Developer/Xcode/DerivedData/iFix-bbdyzggojkuirifhdwktfnpnlnnj/Build/Intermediates/iFix.build/Debug-iphonesimulator/iFix.build/Objects-normal/x86_64/NavController-B8881D70D2C31978.o
duplicate symbol _OBJC_CLASS_$_NavController in:
/Users/apple/Library/Developer/Xcode/DerivedData/iFix-bbdyzggojkuirifhdwktfnpnlnnj/Build/Intermediates/iFix.build/Debug-iphonesimulator/iFix.build/Objects-normal/x86_64/NavController-13F0601C84D2856E.o
/Users/apple/Library/Developer/Xcode/DerivedData/iFix-bbdyzggojkuirifhdwktfnpnlnnj/Build/Intermediates/iFix.build/Debug-iphonesimulator/iFix.build/Objects-normal/x86_64/NavController-B8881D70D2C31978.o
duplicate symbol _main in:
/Users/apple/Library/Developer/Xcode/DerivedData/iFix-bbdyzggojkuirifhdwktfnpnlnnj/Build/Intermediates/iFix.build/Debug-iphonesimulator/iFix.build/Objects-normal/x86_64/main-C7855F1C6FD2F976.o
/Users/apple/Library/Developer/Xcode/DerivedData/iFix-bbdyzggojkuirifhdwktfnpnlnnj/Build/Intermediates/iFix.build/Debug-iphonesimulator/iFix.build/Objects-normal/x86_64/main-BA62C00639C12D74.o
duplicate symbol _OBJC_IVAR_$_AppDelegate._window in:
/Users/apple/Library/Developer/Xcode/DerivedData/iFix-bbdyzggojkuirifhdwktfnpnlnnj/Build/Intermediates/iFix.build/Debug-iphonesimulator/iFix.build/Objects-normal/x86_64/AppDelegate-2A03492D855AA76D.o
/Users/apple/Library/Developer/Xcode/DerivedData/iFix-bbdyzggojkuirifhdwktfnpnlnnj/Build/Intermediates/iFix.build/Debug-iphonesimulator/iFix.build/Objects-normal/x86_64/AppDelegate-1751825DEB2A726D.o
duplicate symbol _OBJC_IVAR_$_AppDelegate._navController in:
/Users/apple/Library/Developer/Xcode/DerivedData/iFix-bbdyzggojkuirifhdwktfnpnlnnj/Build/Intermediates/iFix.build/Debug-iphonesimulator/iFix.build/Objects-normal/x86_64/AppDelegate-2A03492D855AA76D.o
/Users/apple/Library/Developer/Xcode/DerivedData/iFix-bbdyzggojkuirifhdwktfnpnlnnj/Build/Intermediates/iFix.build/Debug-iphonesimulator/iFix.build/Objects-normal/x86_64/AppDelegate-1751825DEB2A726D.o
duplicate symbol _OBJC_IVAR_$_AppDelegate._viewController in:
/Users/apple/Library/Developer/Xcode/DerivedData/iFix-bbdyzggojkuirifhdwktfnpnlnnj/Build/Intermediates/iFix.build/Debug-iphonesimulator/iFix.build/Objects-normal/x86_64/AppDelegate-2A03492D855AA76D.o
/Users/apple/Library/Developer/Xcode/DerivedData/iFix-bbdyzggojkuirifhdwktfnpnlnnj/Build/Intermediates/iFix.build/Debug-iphonesimulator/iFix.build/Objects-normal/x86_64/AppDelegate-1751825DEB2A726D.o
duplicate symbol _OBJC_IVAR_$_AppDelegate._images in:
/Users/apple/Library/Developer/Xcode/DerivedData/iFix-bbdyzggojkuirifhdwktfnpnlnnj/Build/Intermediates/iFix.build/Debug-iphonesimulator/iFix.build/Objects-normal/x86_64/AppDelegate-2A03492D855AA76D.o
/Users/apple/Library/Developer/Xcode/DerivedData/iFix-bbdyzggojkuirifhdwktfnpnlnnj/Build/Intermediates/iFix.build/Debug-iphonesimulator/iFix.build/Objects-normal/x86_64/AppDelegate-1751825DEB2A726D.o
duplicate symbol _OBJC_METACLASS_$_AppDelegate in:
/Users/apple/Library/Developer/Xcode/DerivedData/iFix-bbdyzggojkuirifhdwktfnpnlnnj/Build/Intermediates/iFix.build/Debug-iphonesimulator/iFix.build/Objects-normal/x86_64/AppDelegate-2A03492D855AA76D.o
/Users/apple/Library/Developer/Xcode/DerivedData/iFix-bbdyzggojkuirifhdwktfnpnlnnj/Build/Intermediates/iFix.build/Debug-iphonesimulator/iFix.build/Objects-normal/x86_64/AppDelegate-1751825DEB2A726D.o
duplicate symbol _OBJC_CLASS_$_AppDelegate in:
/Users/apple/Library/Developer/Xcode/DerivedData/iFix-bbdyzggojkuirifhdwktfnpnlnnj/Build/Intermediates/iFix.build/Debug-iphonesimulator/iFix.build/Objects-normal/x86_64/AppDelegate-2A03492D855AA76D.o
/Users/apple/Library/Developer/Xcode/DerivedData/iFix-bbdyzggojkuirifhdwktfnpnlnnj/Build/Intermediates/iFix.build/Debug-iphonesimulator/iFix.build/Objects-normal/x86_64/AppDelegate-1751825DEB2A726D.o
ld: 23 duplicate symbols for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
Please check my frameworks
And the code am using for admob is
enter code here
- (GADRequest *)createRequest {
GADRequest *request = [GADRequest request];
// Make the request for a test ad. Put in an identifier for the simulator as
// well as any devices you want to receive test ads.
request.testDevices =
[NSArray arrayWithObjects:
// TODO: Add your device/simulator test identifiers here. They are
// printed to the console when the app is launched.
nil];
return request;
}
#pragma mark GADBannerViewDelegate impl
// We've received an ad successfully.
- (void)adViewDidReceiveAd:(GADBannerView *)adView {
NSLog(#"Received ad successfully");
}
- (void)adView:(GADBannerView *)view
didFailToReceiveAdWithError:(GADRequestError *)error {
NSLog(#"Failed to receive ad with error: %#", [error localizedFailureReason]);
}
-(void)viewDidAppear:(BOOL)animated{
if([GMMConnectivity hasConnectivity]){
// [self loadAds];
NSTimer* myTimer = [NSTimer scheduledTimerWithTimeInterval: 15.0 target: self
selector: #selector(callAfterSixtySecond:) userInfo: nil repeats: YES];
}
}
-(void) callAfterSixtySecond:(NSTimer*) t
{
if([GMMConnectivity hasConnectivity]){
[self.adBanner removeFromSuperview];
[self loadAdmob];
}
}
-(void)loadAdmob{
CGPoint origin;
if(IS_RETINA){
if([[UIScreen mainScreen] bounds].size.height >500){
// NSLog(#"5");
origin = CGPointMake(0.0,
568-
CGSizeFromGADAdSize(kGADAdSizeSmartBannerPortrait).height);
}else{
// NSLog(#"4");
origin = CGPointMake(0.0,
(480)-
CGSizeFromGADAdSize(kGADAdSizeSmartBannerPortrait).height);
}
}else{
// NSLog(#"3");
origin = CGPointMake(0.0,
(460)-
CGSizeFromGADAdSize(kGADAdSizeSmartBannerPortrait).height);
}
// Use predefined GADAdSize constants to define the GADBannerView.
self.adBanner = [[GADBannerView alloc] initWithAdSize:kGADAdSizeSmartBannerPortrait
origin:origin]
;
// Note: Edit SampleConstants.h to provide a definition for kSampleAdUnitID
// before compiling.
self.adBanner.adUnitID = MY_BANNER_UNIT_ID;
self.adBanner.delegate = self;
[self.adBanner setRootViewController:self];
[self.view addSubview:self.adBanner];
self.adBanner.center =
CGPointMake(self.view.center.x, self.adBanner.center.y);
[self.adBanner loadRequest:[self createRequest]];
[self.view addSubview:adBanner_];
}
I had a similar issue when I added Google Analytics SDK. You should remove the example code in the AdMob SDK package, and build again. Let me know if it solves your problem.
i added -ObjC i other linker flags and its working now

adding sound to uibutton

I am trying to play a sound when a uibutton is pressed..
this is my code
-(IBAction) playSound:(id)sender{
NSString *path = [[NSBundle mainBundle] pathForResource:#"SQUEEK" ofType:#"wav"];
AVAudioPlayer* theAudio=[[AVAudioPlayer alloc] initWithContentsOfURL:[NSURL fileURLWithPath:path] error:NULL];
theAudio.delegate=self;
[theAudio play];
}
this is the output when the button is pressed
2012-07-13 16:41:02.803 squeek[1475:12103] Error loading /System/Library/Extensions/AudioIPCDriver.kext/Contents/Resources/AudioIPCPlugIn.bundle/Contents/MacOS/AudioIPCPlugIn: dlopen(/System/Library/Extensions/AudioIPCDriver.kext/Contents/Resources/AudioIPCPlugIn.bundle/Contents/MacOS/AudioIPCPlugIn, 262): Symbol not found: ___CFObjCIsCollectable
Referenced from: /System/Library/Frameworks/Security.framework/Versions/A/Security
Expected in: /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.1.sdk/System/Library/Frameworks/CoreFoundation.framework/CoreFoundation
in /System/Library/Frameworks/Security.framework/Versions/A/Security
2012-07-13 16:41:02.811 squeek[1475:12103] Error loading /System/Library/Extensions/AudioIPCDriver.kext/Contents/Resources/AudioIPCPlugIn.bundle/Contents/MacOS/AudioIPCPlugIn: dlopen(/System/Library/Extensions/AudioIPCDriver.kext/Contents/Resources/AudioIPCPlugIn.bundle/Contents/MacOS/AudioIPCPlugIn, 262): Symbol not found: ___CFObjCIsCollectable
Referenced from: /System/Library/Frameworks/Security.framework/Versions/A/Security
Expected in: /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.1.sdk/System/Library/Frameworks/CoreFoundation.framework/CoreFoundation
in /System/Library/Frameworks/Security.framework/Versions/A/Security
2012-07-13 16:41:03.389 squeek[1475:12103] Error loading /System/Library/Extensions/AppleHDA.kext/Contents/PlugIns/AppleHDAHALPlugIn.bundle/Contents/MacOS/AppleHDAHALPlugIn: dlopen(/System/Library/Extensions/AppleHDA.kext/Contents/PlugIns/AppleHDAHALPlugIn.bundle/Contents/MacOS/AppleHDAHALPlugIn, 262): Symbol not found: ___CFObjCIsCollectable
Referenced from: /System/Library/Frameworks/Security.framework/Versions/A/Security
Expected in: /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.1.sdk/System/Library/Frameworks/CoreFoundation.framework/CoreFoundation
in /System/Library/Frameworks/Security.framework/Versions/A/Security
2012-07-13 16:41:03.396 squeek[1475:12103] Error loading /System/Library/Extensions/AppleHDA.kext/Contents/PlugIns/AppleHDAHALPlugIn.bundle/Contents/MacOS/AppleHDAHALPlugIn: dlopen(/System/Library/Extensions/AppleHDA.kext/Contents/PlugIns/AppleHDAHALPlugIn.bundle/Contents/MacOS/AppleHDAHALPlugIn, 262): Symbol not found: ___CFObjCIsCollectable
Referenced from: /System/Library/Frameworks/Security.framework/Versions/A/Security
Expected in: /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.1.sdk/System/Library/Frameworks/CoreFoundation.framework/CoreFoundation
in /System/Library/Frameworks/Security.framework/Versions/A/Security
2012-07-13 16:41:03.409 squeek[1475:12103] Error loading /System/Library/Extensions/AppleHDA.kext/Contents/PlugIns/AppleHDAHALPlugIn.bundle/Contents/MacOS/AppleHDAHALPlugIn: dlopen(/System/Library/Extensions/AppleHDA.kext/Contents/PlugIns/AppleHDAHALPlugIn.bundle/Contents/MacOS/AppleHDAHALPlugIn, 262): Symbol not found: ___CFObjCIsCollectable
Referenced from: /System/Library/Frameworks/Security.framework/Versions/A/Security
Expected in: /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.1.sdk/System/Library/Frameworks/CoreFoundation.framework/CoreFoundation
in /System/Library/Frameworks/Security.framework/Versions/A/Security
2012-07-13 16:41:03.417 squeek[1475:12103] Error loading /System/Library/Extensions/AppleHDA.kext/Contents/PlugIns/AppleHDAHALPlugIn.bundle/Contents/MacOS/AppleHDAHALPlugIn: dlopen(/System/Library/Extensions/AppleHDA.kext/Contents/PlugIns/AppleHDAHALPlugIn.bundle/Contents/MacOS/AppleHDAHALPlugIn, 262): Symbol not found: ___CFObjCIsCollectable
Referenced from: /System/Library/Frameworks/Security.framework/Versions/A/Security
Expected in: /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.1.sdk/System/Library/Frameworks/CoreFoundation.framework/CoreFoundation
in /System/Library/Frameworks/Security.framework/Versions/A/Security
2012-07-13 16:41:03.431 squeek[1475:12103] Error loading /System/Library/Extensions/AppleHDA.kext/Contents/PlugIns/AppleHDAHALPlugIn.bundle/Contents/MacOS/AppleHDAHALPlugIn: dlopen(/System/Library/Extensions/AppleHDA.kext/Contents/PlugIns/AppleHDAHALPlugIn.bundle/Contents/MacOS/AppleHDAHALPlugIn, 262): Symbol not found: ___CFObjCIsCollectable
Referenced from: /System/Library/Frameworks/Security.framework/Versions/A/Security
Expected in: /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.1.sdk/System/Library/Frameworks/CoreFoundation.framework/CoreFoundation
in /System/Library/Frameworks/Security.framework/Versions/A/Security
2012-07-13 16:41:03.440 squeek[1475:12103] Error loading /System/Library/Extensions/AppleHDA.kext/Contents/PlugIns/AppleHDAHALPlugIn.bundle/Contents/MacOS/AppleHDAHALPlugIn: dlopen(/System/Library/Extensions/AppleHDA.kext/Contents/PlugIns/AppleHDAHALPlugIn.bundle/Contents/MacOS/AppleHDAHALPlugIn, 262): Symbol not found: ___CFObjCIsCollectable
Referenced from: /System/Library/Frameworks/Security.framework/Versions/A/Security
Expected in: /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.1.sdk/System/Library/Frameworks/CoreFoundation.framework/CoreFoundation
in /System/Library/Frameworks/Security.framework/Versions/A/Security
the IBAction is hooked up to the UIButton with the touch up inside feature, also I have added the avfoundation framework.
any help would be greatly appreciated.
#HurkNburkS
You just need a little more search in Stack Overflow before asking the same question. Whatever check the below question and try the solutions given in that.
Sound not playing with AVAudioPlayer
Supported Audio file formats in iPhone
Check out your audio format could be a problem or your "theAudio" instance should be deallocated.
Try like this and print your error...
NSError *error;
audioPlayer = [[AVAudioPlayer alloc]
initWithContentsOfURL:url
error:&error];
if (error)
{
NSLog(#"Error in audioPlayer: %#",
[error localizedDescription]);
} else {
audioPlayer.delegate = self;
[audioPlayer prepareToPlay];
}

Resources