(Xcode) Disabling warnings when compiling certain files?

I use several third-party libraries in my iOS project that generate some warnings. Is there a way to disable warnings only for these specific files, similar to how you can disable ARC for each file by adding the "-fno-objc-arc" flag to the "compile sources" area in the build phases?

+4
source share
1 answer

Xcode has an option to set compiler flags for each file:

  • In the Project Navigator panel, click on your project
  • Choose the goal you are building for:
  • Select the Phase Assembly tab
  • Scroll down and expand the Compilation Sources phase
  • Find the Compilers column
  • Set the compiler flag to -w for the file you want to suppress for
+2
source

Source: https://habr.com/ru/post/1383129/


All Articles