Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Crash after installing on xcode simulator or on ios Device #302

Closed
amitbravo opened this issue Apr 14, 2017 · 8 comments
Closed

Crash after installing on xcode simulator or on ios Device #302

amitbravo opened this issue Apr 14, 2017 · 8 comments

Comments

@amitbravo
Copy link

there is no error to build , it launches for a fraction of second and crash at once, same on device(iphone5s ios 10.3) xcode throws following log :
dyld: Library not loaded: @rpath/QBImagePicker.framework/QBImagePicker
Referenced from: /var/containers/Bundle/Application/A9C4A1F8-6299-493E-B56C-E1A629561451/CropPicker.app/CropPicker
Reason: image not found

@ivpusic
Copy link
Owner

ivpusic commented Apr 15, 2017

check post installation steps in readme file. my suggestion is to use cocoapods

@ivpusic ivpusic closed this as completed Apr 15, 2017
@amitbravo
Copy link
Author

amitbravo commented Apr 16, 2017

I am using podfile already. My steps were:
react-native init uptest4
cd uptest4
npm i react-native-image-crop-picker --save
react-native link react-native-image-crop-picker
cd ios
pod init
and then changes in podfile as below :

# Uncomment the next line to define a global platform for your project
platform :ios, '8.0'

target 'uptest4' do
  # Uncomment the next line if you're using Swift or would like to use dynamic frameworks
  # use_frameworks!


  pod 'RSKImageCropper'
  pod 'QBImagePickerController'

  #pod "RSKImageCropper"
  #pod "QBImagePickerController", :path => "../node_modules/react-native-image-crop-picker/ios/QBImagePicker"

  # Pods for uptest4

  target 'uptest4-tvOSTests' do
    inherit! :search_paths
    # Pods for testing
  end

  target 'uptest4Tests' do
    inherit! :search_paths
    # Pods for testing
  end

end

target 'uptest4-tvOS' do
  # Uncomment the next line if you're using Swift or would like to use dynamic frameworks
  # use_frameworks!

  # Pods for uptest4-tvOS

  target 'uptest4-tvOSTests' do
    inherit! :search_paths
    # Pods for testing
  end

end

then info.plist file

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>

	<key>NSPhotoLibraryUsageDescription</key>
		<string>This app requires to access photo albums</string>

		<key>NSCameraUsageDescription</key>
			<string>This app requires to access camera</string>

			<key>NSMicrophoneUsageDescription</key>
				<string>This app requires to access microphone</string>

	<key>CFBundleDevelopmentRegion</key>
	<string>en</string>
	<key>CFBundleDisplayName</key>
	<string>uptest4</string>
	<key>CFBundleExecutable</key>
	<string>$(EXECUTABLE_NAME)</string>
	<key>CFBundleIdentifier</key>
	<string>org.reactjs.native.example.$(PRODUCT_NAME:rfc1034identifier)</string>
	<key>CFBundleInfoDictionaryVersion</key>
	<string>6.0</string>
	<key>CFBundleName</key>
	<string>$(PRODUCT_NAME)</string>
	<key>CFBundlePackageType</key>
	<string>APPL</string>
	<key>CFBundleShortVersionString</key>
	<string>1.0</string>
	<key>CFBundleSignature</key>
	<string>????</string>
	<key>CFBundleVersion</key>
	<string>1</string>
	<key>LSRequiresIPhoneOS</key>
	<true/>
	<key>UILaunchStoryboardName</key>
	<string>LaunchScreen</string>
	<key>UIRequiredDeviceCapabilities</key>
	<array>
		<string>armv7</string>
	</array>
	<key>UISupportedInterfaceOrientations</key>
	<array>
		<string>UIInterfaceOrientationPortrait</string>
		<string>UIInterfaceOrientationLandscapeLeft</string>
		<string>UIInterfaceOrientationLandscapeRight</string>
	</array>
	<key>UIViewControllerBasedStatusBarAppearance</key>
	<false/>
	<key>NSLocationWhenInUseUsageDescription</key>
	<string></string>
	<key>NSAppTransportSecurity</key>
	<!--See http://ste.vn/2015/06/10/configuring-app-transport-security-ios-9-osx-10-11/ -->
	<dict>
		<key>NSExceptionDomains</key>
		<dict>
			<key>localhost</key>
			<dict>
				<key>NSExceptionAllowsInsecureHTTPLoads</key>
				<true/>
			</dict>
		</dict>
	</dict>
</dict>
</plist>

and when I build project and got this error .

@amitbravo
Copy link
Author

However, I forget to mention that when I hit pod install , I got this error:
pod install
Analyzing dependencies
[!] The target uptest4-tvOSTests is declared twice.

is this causing trouble ?

@amitbravo
Copy link
Author

screen shot 2017-04-17 at 2 00 52 am

@amitbravo
Copy link
Author

Ok, pod installation failed was the reason and it was happening because of
[!] The target uptest4-tvOSTests is declared twice. issue,
I used this auth0/react-native-lock#123 to delete tvOS etc. deleted podfile and pod folder, reinstall using pod init and pod install and it did work.

@loseway
Copy link

loseway commented Aug 9, 2017

@amitbravo ,
i have the same problem,but now i fix it ,that you can do this:
open yourproject->General->Embedded Binaries->add RSKImageCropper.framework/QBImagePicker.framework
thats all

@prasad456
Copy link

Unable make ipa file for development

@haripermadi
Copy link

where can I found RSKImageCropper.framework/QBImagePicker.framework for Embedded binaries??
when I click + sign I cannot found the framework.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants