📜 ⬆️ ⬇️

Manual “offline” adding and updating iOS 3.x & 4.x support in iOS Simulator SDK 5.x

Greetings to all respected habrazhiteli!

This habratopic describes the “mechanism” of manually downloading the Xcode 4.2 package of iOS 4.3 Simulator, its updates and add-ons to support iOS 3.x & 4.x in the iOS 5.x SDK for later installation in offline mode.
If there are several workplaces used for development, and you want to save time and traffic when updating, the proposed technique may be useful.
To start, start our Xcode environment, go to the Xcode menu -> Preferences ... and in the opened settings window go to the Downloads tab. As a result, we see something like the following:

In this case, iOS 4.3 Simulator is already installed, but there is no support for creating, launching and debugging programs on devices with iOS 3.0-3.2.2 and 4.0-4.1. You can, of course, use the Check for and install updtates service automatically offered by Xcode, but this operation will need to be repeated in all workplaces where Xcode is installed. We want to download updates once and then install them on all jobs. How do we achieve this goal? The solution is given below.
  1. Launch Safari. In the address bar, enter the address of iOS Dev Center and log in under our developer account.
  2. Open another tab Safari and in the address bar enter the address devimages.apple.com.edgekey.net/downloads/xcode/simulators/index.dvtdownloadableindex .
    As a result, in the Safari window we should see the XML code:
    <?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> <plist version="1.0"> <dict> ... 
    For iOS and Mac OS developers, it is clear that we have a PropertyList (.plist).
    • The downloadables key with the array type is an array, each element of which, with the dict type, is a description of a downloadable update package.
      Pay attention to the first element:
       <key>fileSize</key> <integer>498838122</integer> <key>identifier</key> <string>Xcode.SDK.iPhoneSimulator.4.3</string> <key>name</key> <string>iOS 4.3 Simulator</string> <key>source</key> <string>http://adcdownload.apple.com/Developer_Tools/ios_simulator/<br/>iphone_4.3_iphonesimulatorsdk4_3.dmg</string> 
      • The fileSize key with the integer type contains information about the packet size.
      • The identifier key with the string type contains the package identifier.
      • The name key with the string type contains the name of the package.
      • The source key with the string type is the URL for downloading the required package from the update server in the format of the DMG installation image.
      • The following userInfo subkey with the dict type contains the information needed to install the package into the Xcode environment (icon, installation location, description, etc.).
  3. Let's try to open the resulting address in a new tab Safari. We will be redirected to the Downloads & ADC Member Assets page with a message stating that our session is overdue and will return to the ADC Member Site page to try again to download the file. We use this offer and get a redirect to the page Downloads for Apple Developers . This multipage list does not contain the package we need! But temporary setbacks won't stop us. Select any package from the list (I personally used the "HTTP Live Streaming Tools", guided by its relatively small size of 1.63 MB) and download the selected package by reference. You must wait for the file to start downloading.
  4. Simultaneously with the start of the download in the new tab Safari open the address that interests us. If everything is done correctly, the download of the file we need begins.
  5. We repeat this operation for all packages of additions and updates we need.
  6. Open one of the images iphone_4_iphonesdk4x.dmg that we downloaded in step 5 . Inside, we see the standard for Mac OS X installation package iPhoneSDK4_x.pkg . To install it, you need to open it in the Installer application and specify the installation location of the iOS 5.0 SDK as the destination folder (with the default installation , this is the / Developer folder in the root of the system disk ).
  7. Packages from iphone_3_iphonesdk3x.dmg and iphone_4.3.5_iphonesimulatorsdk4_3patch1.dmg images are installed in the same way

.

')

Source: https://habr.com/ru/post/136150/


All Articles