2

i usually use ShareKit to add share featuring into my apps, but since with iOS 5 SDK and ARC ShareKit doesn't compile anything, even i set the -fno-objc-arc flag. I need essentially the share on Facebook, how can i do without ShareKit?

I found FacebookAgent, but if you open the dialog and then want to close it, it's impossible because there isn't a close button! Help me with some Facebook library, advise on ShareKit with ARC or a little tutorial on how share with Facebook SDK. Thanks

Srikar Appalaraju
  • 71,928
  • 54
  • 216
  • 264
Andrea Mario Lufino
  • 7,921
  • 12
  • 47
  • 78

4 Answers4

1

It's working on my iOS 5 project and ARC.

You need to use the compile flag

-fno-objc-arc

in all files of ShareKit in Project -> Target -> Build Phases -> Compile Sources

Matteo Alessani
  • 10,264
  • 4
  • 40
  • 57
1

If you can't get it working, you can try addthis:

http://www.addthis.com/help/ios-quickstart#.TtNb5XOzVt4

It seems to be updated more often than ShareKit, but it's still not ARCified. So you'll need to add the flags and whatnot. If you have trouble, check the forum, there is a solution there if you have trouble.

TigerCoding
  • 8,710
  • 10
  • 47
  • 72
1

You know what, even though you've gotten ShareKit to work, Facebook's implementation is way better because they'll update it accordingly when they change the way their backend works.

https://github.com/facebook/facebook-ios-sdk

  • On a side note, ShareKit seems to be an abandoned child anyway due to the fact that there has been very few updates to their code lately.
Alex Nguyen
  • 2,820
  • 1
  • 19
  • 14
0

go to class facebook.m and change the authorization to NO as mention below:

(void)authorize:(NSArray *)permissions { self.permissions = permissions;

[self authorizeWithFBAppAuth:NO safariAuth:NO]; }
Stewbob
  • 16,759
  • 9
  • 63
  • 107