Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can't play music #9

Closed
bangjier opened this issue Feb 25, 2019 · 5 comments
Closed

Can't play music #9

bangjier opened this issue Feb 25, 2019 · 5 comments
Assignees
Labels
known issue Still finding a way to fix it

Comments

@bangjier
Copy link

Music cannot be played after the project is packaged, so it can be played through direct debugging with the mobile phone

@CodeEagle
Copy link
Owner

Are you using Cocoapods? Project can only run through Debug Mode.

@CodeEagle CodeEagle added the known issue Still finding a way to fix it label Feb 25, 2019
@CodeEagle CodeEagle self-assigned this Feb 25, 2019
@CodeEagle CodeEagle pinned this issue Feb 25, 2019
@bangjier
Copy link
Author

Installation with cocoapods, Can't you pack AppStore?

@CodeEagle
Copy link
Owner

CodeEagle commented Feb 25, 2019

Under Xcode10.2, workaround is using carthage to build a debug framework to integrate.

Or

post_install do |installer|
 installer.pods_project.targets.each do |target|
        target.build_configurations.each do |config|
            swiftPods = ['APlay']
            if swiftPods.include?(target.name)
                config.build_settings['SWIFT_OPTIMIZATION_LEVEL'] =  '-Onone'
            end
        end
    end
end

@bangjier
Copy link
Author

When you add this code, the following error is reported:

An error occurred while processing the pre-install hook of the Podfile.
undefined method `targets' for nil:NilClass

@CodeEagle
Copy link
Owner

Sorry, mybad, change pre_install to post_install

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
known issue Still finding a way to fix it
Projects
None yet
Development

No branches or pull requests

2 participants