Closed nilrezaee88 closed 7 months ago
Hello friends, migrating from react-native 0.61 to 0.69 and regenerated the ios and android folder again run-ios failed and an error generated The following build commands failed: CompileC /Users/abhiranjanchaurasiya/Library/Developer/Xcode/DerivedData/ParentConnect-frlclatfwjdajdgegkwduwpnhqcl/Build/Intermediates.noindex/Pods.build/Debug-iphonesimulator/react-native-image-editor.build/Objects-normal/x86_64/RNCImageEditor.o /Users/abhiranjanchaurasiya/Desktop/workspace/react-native/footprints/ParentReact/node_modules/@react-native-community/image-editor/ios/RNCImageEditor.m normal x86_64 objective-c com.apple.compilers.llvm.clang.1_0.compiler (in target 'react-native-image-editor' from project 'Pods')
@nilrezaee88 Could you please provide more information:
react-native
version did you use?npx react-native info
output?@retyui Hi, I'm unable to run the iOS version after installing this package. would you please help me ?
@Abdulhaque4241 what exactly block you to run the iOS version ?
@retyui thanks for the reply :)
It works perfectly on Android but not on iOS. I'm attaching the screenshot of the error and the Podfile.
require Pod::Executable.execute_command('node', ['-p',
'require.resolve(
"react-native/scripts/react_native_pods.rb",
{paths: [process.argv[1]]},
)', __dir__]).strip
platform :ios, min_ios_version_supported
prepare_react_native_project!
pod 'GoogleUtilities', :modular_headers => true
pod 'FirebaseCore', :modular_headers => true
pod 'FirebaseCoreExtension', :modular_headers => true
pod 'FirebaseInstallations', :modular_headers => true
pod 'GoogleDataTransport', :modular_headers => true
pod 'nanopb', :modular_headers => true
$RNFirebaseAsStaticFramework = true
use_frameworks! :linkage => :static
$static_framework = ['FlipperKit', 'Flipper', 'Flipper-Folly',
'CocoaAsyncSocket', 'ComponentKit', 'Flipper-DoubleConversion',
'Flipper-Glog', 'Flipper-PeerTalk', 'Flipper-RSocket', 'Yoga', 'YogaKit',
'CocoaLibEvent', 'OpenSSL-Universal', 'boost-for-react-native']
flipper_config = ENV['NO_FLIPPER'] == "1" ? FlipperConfiguration.disabled : FlipperConfiguration.enabled
linkage = ENV['USE_FRAMEWORKS']
if linkage != nil
Pod::UI.puts "Configuring Pod with #{linkage}ally linked Frameworks".green
use_frameworks! :linkage => linkage.to_sym
end
target 'Inspection' do
config = use_native_modules!
use_react_native!(
:path => config[:reactNativePath],
:flipper_configuration => FlipperConfiguration.disabled,
:app_path => "#{Pod::Config.instance.installation_root}/.."
)
permissions_path = '../node_modules/react-native-permissions/ios'
pod 'Permission-Camera', :path => "#{permissions_path}/Camera"
pod 'RNImageEditor', :path => '../node_modules/@thienmd/react-native-image-editor/ios'
pod 'iOSPhotoEditor', :git => "https://github.com/ThienMD/photo-editor", :branch => "master"
target 'InspectionTests' do
inherit! :complete
end
pre_install do |installer|
Pod::Installer::Xcode::TargetValidator.send(:define_method, :verify_no_static_framework_transitive_dependencies) {}
installer.pod_targets.each do |pod|
if $static_framework.include?(pod.name)
def pod.build_type;
Pod::BuildType.static_library
end
end
end
end
post_install do |installer|
react_native_post_install(
installer,
config[:reactNativePath],
:mac_catalyst_enabled => false
)
installer.pods_project.targets.each do |target|
if target.name&.eql?('FBReactNativeSpec')
target.build_phases.each do |build_phase|
if build_phase.respond_to?(:name) && build_phase.name.eql?('[CP-User] Generate Specs')
target.build_phases.move(build_phase, 0)
end
end
end
end
installer.pods_project.targets.each do |target|
if target.name.include?('iOSPhotoEditor')
target.build_configurations.each do |config|
config.build_settings['SWIFT_VERSION'] = '5'
end
end
end
installer.aggregate_targets.each do |aggregate_target|
aggregate_target.user_project.native_targets.each do |target|
target.build_phases.each do |build_phase|
if build_phase.respond_to?(:name) && build_phase.name.eql?('[CP] Copy Pods Resources')
target.build_phases.move(build_phase, 0)
end
end
end
end
end
end
Your problem is not related to this package, Please check a react-native-permissions
install guide
@retyui I'm getting this error only after installing the package. and version of "react-native-permissions": "^3.8.4"
@Abdulhaque4241 well, you can create an appropriate issue in the permissions repo
@retyui I made changes on Podfile, now able to run the project. However after selecting the image, the editor is not visible in iOS(and there are no error messages displayed). This is what i'm facing now. Here's the code:
filePath: 'file:///Users/qubicle/Library/Developer/CoreSimulator/Devices/1D2A339A-4A5A-4A73-BD80-2D921BACF99C/data/Containers/Data/Application/C0909DCF-7DEC-40C4-A65F-92CC7009CB87/Library/Caches/A45A9755-2F86-444A-97CA-E29409A4280F.png'
ImageEditor.Edit({ path: filePath, hiddenControls: ['save'], onDone: res => { console.log('on Done', res); }, onCancel: res => { console.log('on cancel', res); }, });
hi my friends run-ios failed and an error generated please help me
The following build commands failed: CompileC /Users/a1/projects/ahub-photo/ios/DerivedData/ahub/Build/Intermediates.noindex/Pods.build/Debug-iphonesimulator/react-native-image-editor.build/Objects-normal/x86_64/RNCImageEditor.o /Users/a1/projects/ahub-photo/node_modules/@react-native-community/image-editor/ios/RNCImageEditor.m normal x86_64 objective-c com.apple.compilers.llvm.clang.1_0.compiler (in target 'react-native-image-editor' from project 'Pods') (1 failures)