google / webcrypto.dart

Cross-platform implementation of Web Cryptography APIs
https://pub.dev/packages/webcrypto
Apache License 2.0
81 stars 48 forks source link

Not working latest Xcode 16.0 #150

Closed faraz3796 closed 1 month ago

faraz3796 commented 1 month ago

I just upgraded the iMac to MACOS sequoia. Now android is working fine but throwing issue on IOS build.

faraz3796 commented 1 month ago
Screenshot 2024-09-17 at 6 06 39 PM
plusema86 commented 1 month ago

same here, @faraz3796 have you found a temporary solution?

faraz3796 commented 1 month ago

same here, @faraz3796 have you found a temporary solution?

Not yet

punkaze commented 1 month ago

same here

CoreNion commented 1 month ago

This issue is caused by the removed compiler option in xcode 16. I've submitted a pull request (#154) with a fix, but if you're in a hurry, adding the following code to [ios or macos]/Podfile should fix the issue.

post_install do |installer|
  ...
  installer.pods_project.targets.each do |target|
   ... 

   # Add these lines
    if target.name == 'webcrypto'
      target.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 adding lines

  end
end