Skip to content

Reset cflags and swiftflags on each cocoapods integration#197

Merged
polac24 merged 2 commits intospotify:masterfrom
polac24:fix-exclude-sdk
Apr 12, 2023
Merged

Reset cflags and swiftflags on each cocoapods integration#197
polac24 merged 2 commits intospotify:masterfrom
polac24:fix-exclude-sdk

Conversation

@polac24
Copy link
Copy Markdown
Collaborator

@polac24 polac24 commented Apr 11, 2023

This is a follow-up to #196, reported here. I made a silly mistake and introduced reset_build_setting method never used is, while the intention was to call it instead that method instead of add_build_setting.

Rationale

add_build_setting is a method that 1) adds the "main" build setting to all configurations (e.g. MY_VALIE=12 and 2) overrides that with an empty value for all sdks that should be excluded (e.g. MY_VALUE[sdk=iphone*]=).
Later, if you enable back previously excluded sdk (by deleting it from a list in a Podfile), the plugin doesn't remove the previously added override from step 2.

The updated flow:

  1. deletes all already defined build settings: both the "main" one (e.g. MY_VALUE=123) and "overrides" (e.g. MY_VALUE[sdk=iphonesimulator*]=44)
  2. Sets new value + optional overrides from scratch.

@polac24 polac24 merged commit f432917 into spotify:master Apr 12, 2023
@polac24 polac24 deleted the fix-exclude-sdk branch April 12, 2023 01:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants