Commit 023e22d4 authored by Marin Usalj's avatar Marin Usalj

Merge pull request #934 from mneorr/inhibit_warnings

added inhibit warnings per pod. fixes #674
parents c2a192f0 976f8ee8
......@@ -15,6 +15,13 @@
has been renamed to `--no-repo-update`.
[#913](https://github.com/CocoaPods/CocoaPods/issues/913)
###### Enhancements
* Added the ability to inhibit warnings per pod.
Just pass `:inhibit_warnings => true` inline.
[#10](https://github.com/CocoaPods/Core/pull/10)
[#934](https://github.com/CocoaPods/CocoaPods/pull/934)
###### Bug fixes
* Improved handling for Xcode projects containing non ASCII characters.
......
......@@ -362,7 +362,10 @@ module Pod
flags << '-DOS_OBJECT_USE_OBJC=0'
end
end
flags = flags * " "
if target_definition.inhibits_warnings_for_pod?(consumer.spec.root.name)
flags << '-w'
end
flags * " "
end
#-----------------------------------------------------------------------#
......
......@@ -254,6 +254,18 @@ module Pod
ios_flags.should.include '-DOS_OBJECT_USE_OBJC'
osx_flags.should.include '-DOS_OBJECT_USE_OBJC'
end
it "adds -w per pod if target definition inhibits warnings for that pod" do
@installer.library.target_definition.stubs(:inhibits_warnings_for_pod?).returns(true)
flags = @installer.send(:compiler_flags_for_consumer, @spec.consumer(:ios))
flags.should.include?('-w')
end
it "doesn't inhibit warnings by default" do
flags = @installer.send(:compiler_flags_for_consumer, @spec.consumer(:ios))
flags.should.not.include?('-w')
end
end
end
end
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment