I'm trying to create a POD spec for an existing library project.
In the Xcode project, the build settings define different Preprocessor macros for different Build Configurations (e.g.: "Debug" and "Release")
For example:
For the "Debug" Configuration:
GCC_PREPROCESSOR_DEFINITIONS = DEBUG=1
For the "Release" Configuration:
GCC_PREPROCESSOR_DEFINITIONS = NDEBUG NS_BLOCK_ASSERTIONS
How do I map these settings to the corresponding POD spec?
For example:
spec.compiler_flags = '-DDEBUG=1'
and
spec.compiler_flags = '-DNDEBUG -DNS_BLOCK_ASSERTIONS'
Unfortunately, the official documentation in general is mostly more confusing and unclear, than really helpful:
Build settings
In this group are listed the attributes related to the configuration of the build environment that should be used to build the library.
If not defined in a subspec the attributes of this group inherit the value of the parent.
Examples:
spec.compiler_flags = '-DOS_OBJECT_USE_OBJC=0', '-Wno-format'
Intuitively, I would do something like this:
configuration :Debug do
spec.compiler_flags = '-DDEBUG=1'
end
configuration :Release do
spec.compiler_flags = '-DNDEBUG -DNS_BLOCK_ASSERTIONS'
end
However, that's guessing.