Skip to content

Commit

Permalink
Fix DWARF binary not copied for AppleDsymBundleInfo
Browse files Browse the repository at this point in the history
  • Loading branch information
luispadron committed Feb 8, 2024
1 parent 4ae9fff commit 1fb68e3
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion apple/internal/partials/debug_symbols.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -310,6 +310,13 @@ def _bundle_dsym_files(
found_binaries_by_arch = found_binaries_by_arch,
platform_prerequisites = platform_prerequisites,
)
dsyms_command = (" && ".join([
"cp \"{dsym_path}\" \"${{OUTPUT_DIR}}/Contents/Resources/DWARF/{dsym_bundle_name}\"".format(
dsym_path = dsym.path,
dsym_bundle_name = dsym_output_filename,
)
for dsym in output_files
]))

# If we found any binaries, create the Info.plist for the bundle as well.
dsym_plist = _generate_dsym_info_plist(
Expand All @@ -336,7 +343,7 @@ def _bundle_dsym_files(
apple_fragment = platform_prerequisites.apple_fragment,
inputs = [dsym_plist] + found_binaries_by_arch.values(),
outputs = [dsym_bundle_dir],
command = ("mkdir -p \"${OUTPUT_DIR}/Contents/Resources/DWARF\" && " + plist_command),
command = ("mkdir -p \"${OUTPUT_DIR}/Contents/Resources/DWARF\" && " + dsyms_command + " && " + plist_command),
env = {
"OUTPUT_DIR": dsym_bundle_dir.path,
},
Expand Down

0 comments on commit 1fb68e3

Please sign in to comment.