Skip to content
kikogo edited this page Sep 17, 2013 · 2 revisions

Malcom Lib iOS

Integration

  • CocoaPods is the recommended way to add MalcomLib to your project.

Here's an example podfile that installs MalcomLib.

Podfile

platform :ios, '5.0'

pod 'Malcom'

Note the specification of iOS 5.0 as the platform; leaving out the 5.0 will cause CocoaPods to fail with the following message:

[!] Malcom is not compatible with iOS 4.3.

  • If you don't use cocoapods, you can clone this repository or download the zip:

      git://github.com/MyMalcom/malcom-lib-ios.git
    
  • Add one of available versions of library:

    • Static library: Add the folder of static library. If you don't want to use the 'ad module', just delete the 'ads' folder.
    • Source library: Add source in project. In case that you don't want to use any module (Configuration, Ad or Notifications) you can delete the not desired folder.

    We strongly recommend to use the static library.

  • Add this frameworks to project:

    • Security.framework
    • AdSupport.framework
    • MediaPlayer.framework
    • AVFoundation.framework
    • CFNetwork.framework
    • SystemConfiguration.framework
    • MobileCoreServices.framework
    • QuartzCore.framework
    • CoreTelephony.framework
    • CoreLocation.framework
    • AudioToolbox.framework
    • MessageUI.framework
    • CoreGraphics.framework
    • StoreKit.framework
    • libz.1.2.5.dylib
    • iAd.framework (only for ad module) (Optional if app works whith versions minor than 5.0)
    • ImageIO.framework
  • In target, Link Binary With Libraries, set iAd.framework like 'Optional'.

  • Add in "Other C Flags", in production:

      -DDISTRIBUTION=1
    
  • Add in "Other linker Flags"

      -all_load -ObjC 
    

Sample App

In Samples folder there are two projects, each one of them with a integration type different.

Using library

Init:

Firstly, import MalcomLib.h

	#import "MalcomLib.h"

and add the following lines in the AppDelegate in the application:didFinishLaunchingWithOptions: method:

	[MalcomLib initWithUUID:@"UUID" 
               andSecretKey:@"SECRETKEY"];

with the params of your app in Malcom.

If you would like to have more control and watch the Log generated by Malcom, please use the following method:

[MalcomLib showLog:YES];

We can use these modules:

Clone this wiki locally