johnno1962 / injectionforxcode

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

Build Failed with status: 65 #101

Closed jb522185660 closed 8 years ago

jb522185660 commented 8 years ago

ctr;+=, * 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/JackLi/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/JackLi/Library/Application Support/Developer/Shared/Xcode/Plug-ins/InjectionPlugin.xcplugin/Contents/Resources/injectSource.pl line 460
 Bundle build failed *

jb522185660 commented 8 years ago

* 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/JackLi/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/JackLi/Library/Application Support/Developer/Shared/Xcode/Plug-ins/InjectionPlugin.xcplugin/Contents/Resources/injectSource.pl line 460
** Bundle build failed ***


johnno1962 commented 8 years ago

Doesn’t look too healthy. I don’t know where all the -F’s are coming from or why their path is wrong. I suggest you start with a small example project in the simulator to get familiar with injection before jumping to a project as complex as this. In general though you need to locate IJKMediaFramework and add this to the framework search paths of the bundle project (Project/Injection Plugin/Open Bundle Project.)

jb522185660 commented 8 years ago

I have solved the problem ,but crash when ctrl+=

endif

            if ( strncmp( info.dli_fname, userClass, sizeof userClass-1 ) == 0 &&
                strstr( info.dli_fname, "/InjectionBundle" ) == 0 ) {
                id (_imp)( Class, SEL ) = (id (_)( Class, SEL ))method_getImplementation( m );
                NSLog( @"BundleSweeper: +[%@ sharedInstance] == %p()", classes[i], imp );
                [sharedInstances addObject:imp( classes[i], @selector(sharedInstance))];
            }
        }
    }
    free(classes);
}

auto stop at [sharedInstances addObject:imp( classes[i], @selector(sharedInstance))];

johnno1962 commented 8 years ago

I’m afraid you won’t be able to use the “-injected” feature with this project. You can detect injections using “INJECTION_BUNDLE_NOTIFICATION”.

jb522185660 commented 8 years ago

Is the INJECTION_BUNDLE_NOTIFICATION detect If I have install the injection successfully?

johnno1962 commented 8 years ago

It fires when a bundle has been loaded successfully. If you get that far injection should be installed correctly.