johnno1962 / injectionforxcode

Runtime Code Injection for Objective-C & Swift
MIT License
6.55k stars 565 forks source link

** BUILD FAILED ** framework not found Fabric for architecture x86_64 #95

Open crespoxiao opened 8 years ago

crespoxiao commented 8 years ago

Hey there! i use CocoaPods to import Fabric framework, when injection source,it build failed. If i remove Fabric dependency, injection would be ok.

in podfile: pod 'Fabric', :inhibit_warnings => true pod 'Crashlytics', :inhibit_warnings => true

error info :

ld: framework not found Fabric for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)

GenerateDSYMFile build/Debug-iphonesimulator/InjectionBundle.bundle.dSYM build/Debug-iphonesimulator/InjectionBundle.bundle/InjectionBundle
 cd /didi/ios/DDRentCarBusiness/iOSInjectionProject
 export PATH="/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin:/Applications/Xcode.app/Contents/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/dsymutil /didi/ios/DDRentCarBusiness/iOSInjectionProject/build/Debug-iphonesimulator/InjectionBundle.bundle/InjectionBundle -o /didi/ios/DDRentCarBusiness/iOSInjectionProject/build/Debug-iphonesimulator/InjectionBundle.bundle.dSYM
error: cannot parse the debug map for "/didi/ios/DDRentCarBusiness/iOSInjectionProject/build/Debug-iphonesimulator/InjectionBundle.bundle/InjectionBundle": No such file or directory

Touch build/Debug-iphonesimulator/InjectionBundle.bundle
 cd /didi/ios/DDRentCarBusiness/iOSInjectionProject
 export PATH="/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin:/Applications/Xcode.app/Contents/Developer/usr/bin:/Applications/Xcode.app/Contents/Developer/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin"
 /usr/bin/touch -c /didi/ios/DDRentCarBusiness/iOSInjectionProject/build/Debug-iphonesimulator/InjectionBundle.bundle

* BUILD FAILED 


The following build commands failed:
 Ld build/Debug-iphonesimulator/InjectionBundle.bundle/InjectionBundle normal x86_64
 GenerateDSYMFile build/Debug-iphonesimulator/InjectionBundle.bundle.dSYM build/Debug-iphonesimulator/InjectionBundle.bundle/InjectionBundle
(2 failures)

\ Build Failed with status: 65. You may need to open and edit the bundle project to resolve issues with either header include paths or Frameworks the bundle links against. _

 at /Users/xiaochengfei/Library/Application Support/Developer/Shared/Xcode/Plug-ins/InjectionPlugin.xcplugin/Contents/Resources/common.pm line 57.
 main::error('Build Failed with status: 65. You may need to open and edit t...') called at /Users/xiaochengfei/Library/Application Support/Developer/Shared/Xcode/Plug-ins/InjectionPlugin.xcplugin/Contents/Resources/injectSource.pl line 460
_ Bundle build failed ***

Any other solution ? My project need to use Fabric framework.It would be boring to delete Fabric dependency when injection source for each time.

Thank you !

johnno1962 commented 8 years ago

Hi, this should work. Can you send me more of your console output. I need to see the linker command. injection at johnholdsworth.com. Also, check if your scheme is named “Debug"

speeddream commented 8 years ago

I have the same error.

johnno1962 commented 8 years ago

Is your scheme something other than Debug?

speeddream commented 8 years ago

Yes, it is debug. The following build commands failed:
 CompileC build/InjectionBundle.build/Debug-iphonesimulator/InjectionBundle.build/Objects-normal/x86_64/BundleContents.o BundleContents.m normal x86_64 objective-c com.apple.compilers.llvm.clang.10.compiler
(1 failure)

* Build Failed with status: 65. You may need to open and edit the bundle project to resolve issues with either header include paths or Frameworks the bundle links against. 

 at /Users/hairun/Library/Application Support/Developer/Shared/Xcode/Plug-ins/InjectionPlugin.xcplugin/Contents/Resources/common.pm line 57.
 main::error('Build Failed with status: 65. You may need to open and edit t...') called at /Users/hairun/Library/Application Support/Developer/Shared/Xcode/Plug-ins/InjectionPlugin.xcplugin/Contents/Resources/injectSource.pl line 460
**_ Bundle build failed ***

taher-mosbah commented 8 years ago

Same here

The following build commands failed:
 Ld build/Debug-iphonesimulator/InjectionBundle.bundle/InjectionBundle normal x86_64
(1 failure)

*** Build Failed with status: 65. You may need to open and edit the bundle project to resolve issues with either header include paths or Frameworks the bundle links against. ***

 at /Users/mohamed/Library/Application Support/Developer/Shared/Xcode/Plug-ins/InjectionPlugin.xcplugin/Contents/Resources/common.pm line 57.
 main::error('Build Failed with status: 65. You may need to open and edit t...') called at /Users/mohamed/Library/Application Support/Developer/Shared/Xcode/Plug-ins/InjectionPlugin.xcplugin/Contents/Resources/injectSource.pl line 461
*** Bundle build failed ***

KillingOML commented 8 years ago

same here xcode7.3

The following build commands failed:
 CompileC build/InjectionBundle.build/Debug-iphonesimulator/InjectionBundle.build/Objects-normal/x86_64/BundleContents.o BundleContents.m normal x86_64 objective-c com.apple.compilers.llvm.clang.10.compiler
(1 failure)

* Build Failed with status: 65. You may need to open and edit the bundle project to resolve issues with either header include paths or Frameworks the bundle links against. 

 at /Users/benssng/Library/Application Support/Developer/Shared/Xcode/Plug-ins/InjectionPlugin.xcplugin/Contents/Resources/common.pm line 57.
 main::error('Build Failed with status: 65. You may need to open and edit t...') called at /Users/benssng/Library/Application Support/Developer/Shared/Xcode/Plug-ins/InjectionPlugin.xcplugin/Contents/Resources/injectSource.pl line 461
**_ Bundle build failed ***

youngshook commented 8 years ago

You need to set the framework search path of your iOSInjectionProject “Project/Injection Plugin/Open BundleProject” to include the directory where this framework can be found.

kamwysoc commented 7 years ago

Do you have installed Fabric desktop app? It resolved the problem for me