XcodeBenchmark icon indicating copy to clipboard operation
XcodeBenchmark copied to clipboard

Build Failure with BoringSSL-RPC

Open polanfong opened this issue 1 year ago • 1 comments

System Version: 14.4 Xcode 15.4 Hardware Overview Model Name: MacBook Pro Model Identifier: Mac15,7 Total Number of Cores: 12 (6 performance and 6 efficiency) Memory: 36 GB

Build results in a few of these error messages:

error: unsupported option '-G' for target 'arm64-apple-ios14.5' (in target 'BoringSSL-GRPC' from project 'Pods')

Summary of build failures:

The following build commands failed:
ScanDependencies /XcodeBenchmark-master/DerivedData/Build/Intermediates.noindex/Pods.build/Debug-iphoneos/BoringSSL-GRPC.build/Objects-normal/arm64/x_val.o /Users/polanfong/Downloads/XcodeBenchmark-master/Pods/BoringSSL-GRPC/src/crypto/x509/x_val.c normal arm64 c com.apple.compilers.llvm.clang.1_0.compiler (in target 'BoringSSL-GRPC' from project 'Pods')

ScanDependencies /XcodeBenchmark-master/DerivedData/Build/Intermediates.noindex/Pods.build/Debug-iphoneos/BoringSSL-GRPC.build/Objects-normal/arm64/x_x509a.o /Users/polanfong/Downloads/XcodeBenchmark-master/Pods/BoringSSL-GRPC/src/crypto/x509/x_x509a.c normal arm64 c com.apple.compilers.llvm.clang.1_0.compiler (in target 'BoringSSL-GRPC' from project 'Pods')

ScanDependencies /XcodeBenchmark-master/DerivedData/Build/Intermediates.noindex/Pods.build/Debug-iphoneos/BoringSSL-GRPC.build/Objects-normal/arm64/x_x509.o /Users/polanfong/Downloads/XcodeBenchmark-master/Pods/BoringSSL-GRPC/src/crypto/x509/x_x509.c normal arm64 c com.apple.compilers.llvm.clang.1_0.compiler (in target 'BoringSSL-GRPC' from project 'Pods')

CompileC /XcodeBenchmark-master/DerivedData/Build/Intermediates.noindex/Pods.build/Debug-iphoneos/BoringSSL-GRPC.build/Objects-normal/arm64/tls_record.o /Users/polanfong/Downloads/XcodeBenchmark-master/Pods/BoringSSL-GRPC/src/ssl/tls_record.cc normal arm64 c++ com.apple.compilers.llvm.clang.1_0.compiler (in target 'BoringSSL-GRPC' from project 'Pods')

CompileC /XcodeBenchmark-master/DerivedData/Build/Intermediates.noindex/Pods.build/Debug-iphoneos/BoringSSL-GRPC.build/Objects-normal/arm64/tls_method.o /Users/polanfong/Downloads/XcodeBenchmark-master/Pods/BoringSSL-GRPC/src/ssl/tls_method.cc normal arm64 c++ com.apple.compilers.llvm.clang.1_0.compiler (in target 'BoringSSL-GRPC' from project 'Pods')

I've tried the solution from https://stackoverflow.com/questions/78608693/boringssl-grpc-unsupported-option-g-for-target-arm64-apple-ios15-0 but that didn't resolve the issue.

polanfong avatar Sep 26 '24 07:09 polanfong

I've had the same issues with Xcode 16.0 and found the solution here

Change the bottom of the pod file to: Podfile_copy.txt

Run pod install --no-repo-update and run the benchmark script again:

Screenshot 2024-10-11 at 23 57 27

ilsinszkibal avatar Oct 11 '24 21:10 ilsinszkibal

@ilsinszkibal, thank you, I've updated the project

devMEremenko avatar Oct 27 '24 10:10 devMEremenko

Thank you!

I added BoringSSL-GRPC part into post_install, then build is succeeded in react native

   installer.pods_project.targets.each do |t|
      if t.name == 'BoringSSL-GRPC'
          t.source_build_phase.files.each do |file|
              if file.settings && file.settings['COMPILER_FLAGS']
                  flags = file.settings['COMPILER_FLAGS'].split
                  flags.reject! { |flag| flag == '-GCC_WARN_INHIBIT_ALL_WARNINGS' }
                  file.settings['COMPILER_FLAGS'] = flags.join(' ')
              end
          end
      end
    end

SevkiBekir avatar Nov 03 '24 17:11 SevkiBekir