Uploaded image for project: 'AeroGear'
  1. AeroGear
  2. AEROGEAR-1341

aerogear-pushplugin-cordova iOS build fails unless SystemConfiguration framework is explicitly added

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Done
    • Icon: Major Major
    • None
    • None
    • cordova
    • None

      The build of a Cordova iOS project which contains the aerogear-pushplugin-cordova fails unless the SystemConfiguration library is added through XCode.

      Errors which appear during build:
      Undefined symbols for architecture i386:
      "_SCNetworkReachabilityCreateWithName", referenced from:
      -[AFHTTPClient startMonitoringNetworkReachability] in libPods.a(AFHTTPClient.o)
      "_SCNetworkReachabilityGetFlags", referenced from:
      -[AFHTTPClient startMonitoringNetworkReachability] in libPods.a(AFHTTPClient.o)
      "_SCNetworkReachabilityScheduleWithRunLoop", referenced from:
      -[AFHTTPClient startMonitoringNetworkReachability] in libPods.a(AFHTTPClient.o)
      "_SCNetworkReachabilitySetCallback", referenced from:
      -[AFHTTPClient startMonitoringNetworkReachability] in libPods.a(AFHTTPClient.o)
      "_SCNetworkReachabilityUnscheduleFromRunLoop", referenced from:
      -[AFHTTPClient stopMonitoringNetworkReachability] in libPods.a(AFHTTPClient.o)
      ld: symbol(s) not found for architecture i386
      clang: error: linker command failed with exit code 1 (use -v to see invocation)

      This issue seems similar to the one mentioned by mwessend@redhat.com https://github.com/AFNetworking/AFNetworking/issues/670

      The workaround is:
      1. Open workspace in Xcode
      2. Build Phases --> Link Binaries With Libraries
      3. Click +
      4. Add the SystemConfiguration framework

      I'm wondering whether the above procedure could be somehow automatized.

              mwessend@redhat.com Matthias Wessendorf
              aemmanou Tolis Emmanouilidis (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Created:
                Updated:
                Resolved: