Xcode 26.1.1 React Native build fails: “Could not delete ios/build” & “Operation not permitted”
03:35 24 Nov 2025

I’m building a React Native 0.72.10 iOS app and hitting build errors.

Environment:

  • macOS: Apple M4, Sequoia 15.7.2

  • Xcode: 26.1.1

  • React Native: 0.72.10

Errors:

  1. Could not delete /Users/.../ios/build because it was not created by the build system

  2. Unable to write file '/Users/.../ios/build/Pods.build/Debug-iphonesimulator/...': Operation not permitted
    (Multiple Pods / React Native framework headers affected)

What I’ve tried:

rm -rf ios/build
rm -rf ~/Library/Developer/Xcode/DerivedData
xattr -w com.apple.xcode.CreatedByBuildSystem true ios/build
pod deintegrate && pod install
sudo chown -R $(whoami) ios/build

Observations:

  • ios/build is recreated automatically.

  • Some files have com.apple.xcode.CreatedByBuildSystem: true.

  1. Why does Xcode fail to delete / write to ios/build even though it’s recreated automatically by the build system?

  2. Is this caused by Xcode itself, macOS permissions, or a React Native / Pod issue?

  3. Any recommended fix or workaround for these “Operation not permitted” errors?

ios xcode react-native macos permissions