Quick Tip about Disabling ARC on Multiple Files at Once 4

I found this comment on stackoverflow, pixelfreak is the author. But, there are multiple places where it is said that you cannot set the -fno-objc-arc flag on multiple files at once in Xcode. Not true. You can read it from the source here.

But, here’s the deal. I, and doubtless many of you, use third party libraries like Sharekit, for example, that aren’t compatible with ARC yet. One solution is to set the -fno-objc-arc flag for the files that you don’t want using ARC. Sharekit has a ton of files so it would be garbage to have to go through one at a time.

The solution is to select multiple files, hit enter (not double-click), put in the -fno-objc-arc flag, hit enter again. You’ll see that all your selected files now have the flag set. I was glad to find this piece of information.

4 thoughts on “Quick Tip about Disabling ARC on Multiple Files at Once

  1. Reply Joseph Collins Feb 16,2012 5:16 pm

    A tutorial on Ray Wenderlich’s site also describes how multiple files can automatically be flagged as -fno-objc-arc! “Find” the Migration Woes header on the page. The paragraph above that describes how the migration tool will automatically flag all other files that are not selectively converted to arc!

  2. Pingback: Multiple -fno-objc-arc ….alleluja! | fabrizio prosperi

  3. Reply Pawan Dec 4,2012 11:32 am

    thanks … It helped

  4. Reply Tom Apr 4,2013 10:39 pm

    This is ARC implementation of ShareKit.
    Link is https://github.com/yetkin/ShareKitARC

Leave a Reply