To solve this problem automatically, you can add Build Script Phase . Go to Xcode β Your project β Your goal β Build phases β + β The phase of the new script run
Rename it to Xcode Link Fix and move it above the Compile Sources phase. Insert this into the body of the script:
# Legacy build system dirname "$LD_DEPENDENCY_INFO_FILE" | xargs -I {} find {} -size 0 | while read -d $'\n' file; do rm "$file" done
This script checks for object files with a size of zero and deletes them, so when the compilation is completed in the next step, it will be successful.
You need to add this script for each purpose of the application, if you have a lot of them.
This script takes ~ 0.1 seconds to run and saves you from a complete rebuild of the project.
Anton Plebanovich Nov 21 '18 at 14:25 2018-11-21 14:25
source share