rules_xcodeproj icon indicating copy to clipboard operation
rules_xcodeproj copied to clipboard

Feature Request: add support for Xcode 16.3+

Open luispadron opened this issue 8 months ago • 6 comments

In Xcode 16.3 the hash algorithm used for index store changed, we will need to update https://github.com/MobileNativeFoundation/index-import to support the new hash algorithm in a backwards compatible way and pull that change into rules_xcodeproj

Issues

  • [x] Builds fail with missing global index store files: https://github.com/MobileNativeFoundation/rules_xcodeproj/pull/3162

     /private/var/tmp/_bazel_lpadron/9ae9416857eb79bb978de35a53d54970/rules_xcodeproj.noindex/build_output_base/execroot/_main/bazel-out/_global_index_store/v5/units/UnsafeMutableBufferPointer+SE-0370.swift.o-1AIWS878QEG6M -- Failed opening
     '/private/var/tmp/_bazel_lpadron/9ae9416857eb79bb978de35a53d54970/rules_xcodeproj.noindex/build_output_base/execroot/_main/bazel-out/_global_index_store/v5/units/UnsafeMutableBufferPointer+SE-0370.swift.o-1AIWS878QEG6M': No such file or directory
    
  • [ ] lldb API changes in Xcode 16.3:

    File "<DerivedDataDir>/Build/Intermediates.noindex/Debug/swift_debug_settings.py", line 16757, in handle_stop
     module_name = module.file.GetDirectory() + "/" + module.file.GetFilename()
    TypeError: can only concatenate str (not "NoneType") to str
    Python error occurred handling stop-hook.
    

luispadron avatar Apr 01 '25 15:04 luispadron

Related Issues / PRs

https://github.com/MobileNativeFoundation/index-import/issues/120 https://github.com/MobileNativeFoundation/index-import/pull/122

mlequeux avatar Apr 01 '25 15:04 mlequeux

Even with index-import updates in #3162 im seeing the issue with global index store, workaround for now is: --features=-swift.use_global_index_store

luispadron avatar Apr 01 '25 17:04 luispadron

Did you update rules_swift with the same?

brentleyjones avatar Apr 01 '25 18:04 brentleyjones

oh no i didnt 🤦🏼

luispadron avatar Apr 01 '25 18:04 luispadron

Tested (correctly this time) end-to-end and this is working now in Xcode 16.3 & macOS 15.4 👍🏼

Will require:

  • https://github.com/bazelbuild/rules_swift/pull/1504
  • https://github.com/MobileNativeFoundation/rules_xcodeproj/pull/3162

And will need a proper release of index-import which is backwards compatible

luispadron avatar Apr 01 '25 18:04 luispadron

Related: https://github.com/MobileNativeFoundation/rules_xcodeproj/issues/3171

marcelofabri avatar Apr 20 '25 06:04 marcelofabri

@luispadron any idea when Xcode 16.3+ will be supported? And Xcode 26? Thanks

rpcase avatar Sep 22 '25 11:09 rpcase

@luispadron any idea when Xcode 16.3+ will be supported? And Xcode 26? Thanks

They already are afaik. Have you tried them?

luispadron avatar Sep 22 '25 14:09 luispadron

@luispadron any idea when Xcode 16.3+ will be supported? And Xcode 26? Thanks

They already are afaik. Have you tried them?

Amazing, it's working! It required pulling in the latest rules_apple (4.2.0) and overriding its rules_swift to 3.1.2.

jiawen avatar Sep 22 '25 21:09 jiawen