Closed TimMumsnet closed 7 years ago
embedding the framework makes it being copied within the folder "YourApp.app/Framework", and so uploaded to ITC A solution can be to rm -R it in a script build phase after the "embed framework" one, removing it only when:
if [ "$ACTION" == "install" ] ; then
rm ....
fi
@kenji21 's solution worked for me, here's the complete command:
rm -R ${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/SimulatorStatusMagic.framework
Instead of using the if clause you can also check the box 'Run script only when installing'.
Edit: The submission worked, but the app crashes at launch (Library not loaded).
I've managed to solve the issue in my CocoaPods configuration:
pod 'SimulatorStatusMagic', :configurations => ['Debug']
This way the framework isn't included when I archive the app with 'Release' configuration.
The framework calls and import statements can be toggled with a Swift compiler flag. For example, I've defined a compiler flag -D CONFIGURATION_$(CONFIGURATION)
for my project, which I can use in code like this:
#if CONFIGURATION_Debug
import SimulatorStatusMagic
#endif
...
#if CONFIGURATION_Debug
SDStatusBarManager.sharedInstance().enableOverrides()
#endif
@FelixII - this is perfect, it's submitting without errors now. Thanks!
When attempting to upload my app to ITC, I received an email informing me:
I've imported the SimulatorStatusMagic project, added
SimulatorStatusMagiciOS.framework
as an embedded binary. To ensure I don't include the framework in the submission, I only import the framework on the debug config, but I think I'm missing something...