Skip to content

Commit

Permalink
Pass the -f option when resolving the path to the symlinked source.
Browse files Browse the repository at this point in the history
Fixes the issue where archives fail when using Xcode 14.3.

Xcode 14.3 is now using a relative path in its symlink for frameworks. Without the -f flag, this relative path would be evaluated relative to the working directory of the script being executed, instead of relative to the framework symlink itself. With the -f flag, it resolves that relative path and returns the full path to the source.
  • Loading branch information
chrisvasselli committed Mar 23, 2023
1 parent df6cd9e commit 9a9e712
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/cocoapods/generator/embed_frameworks_script.rb
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ def script
if [ -L "${source}" ]; then
echo "Symlinked..."
source="$(readlink "${source}")"
source="$(readlink -f "${source}")"
fi
if [ -d "${source}/${BCSYMBOLMAP_DIR}" ]; then
Expand Down

2 comments on commit 9a9e712

@yaalaa
Copy link

@yaalaa yaalaa commented on 9a9e712 Apr 2, 2023

Choose a reason for hiding this comment

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

+1

@FusioniTechnologies
Copy link

Choose a reason for hiding this comment

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

Thanks for the solution it's working fine, but what if in One project if we have more than 20 targets so i have to replace every Target do you have any other solutions for this,please let me know.

Please sign in to comment.