shu223 / PulsingHalo

iOS Component for creating a pulsing animation.
MIT License
1.77k stars 240 forks source link

PulsingHaloLayer.m:28:1: Cannot synthesize weak property because the current deployment target does not support weak references #42

Closed gregk8288 closed 6 years ago

gregk8288 commented 7 years ago

I receive the following error when trying to compile a debug version of the app.

/Users/gregkockott/www/Mobile-App-iOS/Pods/PulsingHalo/PulsingHalo/PulsingHaloLayer.m:28:1: Cannot synthesize weak property because the current deployment target does not support weak references

@implementation PulsingHaloLayer <-- HERE IS THE ISSUE

0xp3p3 commented 7 years ago

@property (nonatomic, weak) CALayer prevSuperlayer; I fixed as like this @property (nonatomic, strong) CALayer prevSuperlayer;

CavalcanteLeo commented 7 years ago

@TianDaGe submit a pull request, that fixed...

faimin commented 7 years ago

stackoverflow had a solution: http://stackoverflow.com/questions/37160688/set-deployment-target-for-cocoapodss-pod , it works for me.

post_install do |installer|
    installer.pods_project.targets.each do |target|
        target.build_configurations.each do |config|
            if target.name == 'PulsingHalo'
                config.build_settings['IPHONEOS_DEPLOYMENT_TARGET'] = '8.0'
            end
        end
    end
end
lappp9 commented 7 years ago

@TianDaGe If you make that property strong you'll at least have a retain cycle until you remove the halo view from its superView

shu223 commented 7 years ago

Fixed now, I'm so sorry for my late support.

https://github.com/shu223/PulsingHalo/commit/255eacebdf7b4ba2314429649ae076aa104a07cb

The ios.deployment_target didn't work with the wrong order in the podspec.

Please try the 0.2.8 and let me know if there is still problems.