Skip to content

Add upstream xcframework improvements#1443

Merged
keith merged 11 commits intomasterfrom
ks/refactor-apple_static_xcframework-from-macro-to-rule
May 2, 2022
Merged

Add upstream xcframework improvements#1443
keith merged 11 commits intomasterfrom
ks/refactor-apple_static_xcframework-from-macro-to-rule

Conversation

@keith
Copy link
Copy Markdown
Member

@keith keith commented Apr 25, 2022

See each commit for details. This depends on bazelbuild/bazel@8778455 in bazel, which is not in the 5.x branches

@lyft-lint-bot
Copy link
Copy Markdown

Lyft integration job started: https://buildkite.com/lyft/rules-apple/builds/527 (must be Lyft employee to view)

@keith keith force-pushed the ks/refactor-apple_static_xcframework-from-macro-to-rule branch from 483bafa to e41a071 Compare April 25, 2022 16:54
keith referenced this pull request Apr 25, 2022
This change rewrites the `apple_static_xcframework` macro to a rule using
the experimental static library linking API (`link_multi_arch_static_library`).

- Refactor `apple_static_library` underlying macro targets to use
  `link_multi_arch_static_library` API instead.
- Replace split transition to `xcframework_transition` since we no longer rely
  on `apple_static_library` default `multi_arch_split`.
- Update `apple_static_xcframework` tests to remove the `.apple_static_library`
  "suffix", and file path names (due to the change of underlying transition).

PiperOrigin-RevId: 435666883
@lyft-lint-bot
Copy link
Copy Markdown

Lyft integration job started: https://buildkite.com/lyft/rules-apple/builds/528 (must be Lyft employee to view)

stravinskii and others added 2 commits April 25, 2022 10:07
This change rewrites the `apple_static_xcframework` macro to a rule using
the experimental static library linking API (`link_multi_arch_static_library`).

- Refactor `apple_static_library` underlying macro targets to use
  `link_multi_arch_static_library` API instead.
- Replace split transition to `xcframework_transition` since we no longer rely
  on `apple_static_library` default `multi_arch_split`.
- Update `apple_static_xcframework` tests to remove the `.apple_static_library`
  "suffix", and file path names (due to the change of underlying transition).

PiperOrigin-RevId: 435666883
(cherry picked from commit 0ab315c)
@keith keith force-pushed the ks/refactor-apple_static_xcframework-from-macro-to-rule branch from e41a071 to c9b5523 Compare April 25, 2022 17:11
@lyft-lint-bot
Copy link
Copy Markdown

Lyft integration job started: https://buildkite.com/lyft/rules-apple/builds/529 (must be Lyft employee to view)

This change replaces current bundling managed by xcodebuild,
to use rules_apple partials, and custom XCFrameworks bundling.

PiperOrigin-RevId: 436273478
(cherry picked from commit adf0a39)
keith referenced this pull request Apr 25, 2022
This change replaces current bundling managed by xcodebuild,
to use rules_apple partials, and custom XCFrameworks bundling.

PiperOrigin-RevId: 436273478
@lyft-lint-bot
Copy link
Copy Markdown

Lyft integration job started: https://buildkite.com/lyft/rules-apple/builds/532 (must be Lyft employee to view)

Replaces public_hdrs bundling to use the framework_header_modulemap_partial
to generate modulemaps and umbrella headers for each XCFramework library.

PiperOrigin-RevId: 440923000
(cherry picked from commit de6a519)
keith referenced this pull request Apr 25, 2022
Replaces public_hdrs bundling to use the framework_header_modulemap_partial
to generate modulemaps and umbrella headers for each XCFramework library.

PiperOrigin-RevId: 440923000
@lyft-lint-bot
Copy link
Copy Markdown

Lyft integration job started: https://buildkite.com/lyft/rules-apple/builds/534 (must be Lyft employee to view)

This change adds support for Swift based static XCFrameworks,
in a similar fashion as dynamic XCFrameworks does today using
the `swift_framework_partial`, and custom bundling for `.swiftmodule`
files under a library identifier directory instead of `Modules/` directory.

PiperOrigin-RevId: 441610792
(cherry picked from commit 1b19374)
keith referenced this pull request Apr 25, 2022
This change adds support for Swift based static XCFrameworks,
in a similar fashion as dynamic XCFrameworks does today using
the `swift_framework_partial`, and custom bundling for `.swiftmodule`
files under a library identifier directory instead of `Modules/` directory.

PiperOrigin-RevId: 441610792
@keith keith changed the title Refactor apple_static_xcframework from macro to rule Add upstream xcframework improvements Apr 25, 2022
@lyft-lint-bot
Copy link
Copy Markdown

Lyft integration job started: https://buildkite.com/lyft/rules-apple/builds/537 (must be Lyft employee to view)

PiperOrigin-RevId: 441872601
(cherry picked from commit d873646)
keith referenced this pull request Apr 25, 2022
This change adds additional tests to `apple_static_xcframework` rule,\
to verify static libraries builds for simulator/device using Mach-O load\
commands.

Currently Mach-O files include either `LC_BUILD_VERSION` or\
`LC_VERSION_MIN_IPHONEOS` depending on the target environment and target\
minimum iOS version.

PiperOrigin-RevId: 443200094
(cherry picked from commit 702370f)
keith referenced this pull request Apr 25, 2022
This change adds additional tests to `apple_static_xcframework` rule,\
to verify static libraries builds for simulator/device using Mach-O load\
commands.

Currently Mach-O files include either `LC_BUILD_VERSION` or\
`LC_VERSION_MIN_IPHONEOS` depending on the target environment and target\
minimum iOS version.

PiperOrigin-RevId: 443200094
@lyft-lint-bot
Copy link
Copy Markdown

Lyft integration job started: https://buildkite.com/lyft/rules-apple/builds/541 (must be Lyft employee to view)

@lyft-lint-bot
Copy link
Copy Markdown

Lyft integration job started: https://buildkite.com/lyft/rules-apple/builds/542 (must be Lyft employee to view)

jpsim added a commit to envoyproxy/envoy-mobile that referenced this pull request Apr 27, 2022
Update rules_apple to have xcframework improvements

bazelbuild/rules_apple#1443

Signed-off-by: JP Simard <jp@jpsim.com>
@keith keith force-pushed the ks/refactor-apple_static_xcframework-from-macro-to-rule branch 2 times, most recently from 46c38ae to 71b5b66 Compare April 27, 2022 20:27
@lyft-lint-bot
Copy link
Copy Markdown

Lyft integration job started: https://buildkite.com/lyft/rules-apple/builds/549 (must be Lyft employee to view)

@keith keith force-pushed the ks/refactor-apple_static_xcframework-from-macro-to-rule branch from 71b5b66 to 7bbd037 Compare April 27, 2022 20:36
@lyft-lint-bot
Copy link
Copy Markdown

Lyft integration job started: https://buildkite.com/lyft/rules-apple/builds/550 (must be Lyft employee to view)

@keith keith force-pushed the ks/refactor-apple_static_xcframework-from-macro-to-rule branch from 7bbd037 to 694d879 Compare April 27, 2022 21:13
@lyft-lint-bot
Copy link
Copy Markdown

Lyft integration job started: https://buildkite.com/lyft/rules-apple/builds/551 (must be Lyft employee to view)

Copy link
Copy Markdown
Contributor

@jpsim jpsim left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

apple_static_xcframework appears to be working well in my tests here: envoyproxy/envoy-mobile#2217

@lyft-lint-bot
Copy link
Copy Markdown

Lyft integration job started: https://buildkite.com/lyft/rules-apple/builds/556 (must be Lyft employee to view)

@keith keith force-pushed the ks/refactor-apple_static_xcframework-from-macro-to-rule branch from 416cef7 to bbad80c Compare April 28, 2022 19:50
@lyft-lint-bot
Copy link
Copy Markdown

Lyft integration job started: https://buildkite.com/lyft/rules-apple/builds/557 (must be Lyft employee to view)

@keith keith force-pushed the ks/refactor-apple_static_xcframework-from-macro-to-rule branch from bbad80c to 0f66ee3 Compare April 28, 2022 19:55
@lyft-lint-bot
Copy link
Copy Markdown

Lyft integration job started: https://buildkite.com/lyft/rules-apple/builds/558 (must be Lyft employee to view)

@keith keith marked this pull request as ready for review April 28, 2022 20:21
@keith keith merged commit 2d1fa9e into master May 2, 2022
@keith keith deleted the ks/refactor-apple_static_xcframework-from-macro-to-rule branch May 2, 2022 18:02
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

Successfully merging this pull request may close these issues.

6 participants