File not found XCode Specifications iPhoneOSPackageTypes.xcspec

iod-setup sdk -sdk iphoneos报错:

➜  bin sudo ./iod-setup sdk -sdk iphoneos
Password:
Setting up iPhoneOS 15.0 SDK...
Modifying SDK settings...
Symlinking to private frameworks header files...
Adding specifications to platform...
File not found: /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/Library/Xcode/Specifications/iPhoneOSPackageTypes.xcspec

原因:

找不到specifications

解决办法:

下载别人给的:

  • 4个iPhoneOS的spec文件
  • 4个iPhoneSimulator的spec文件

分别放到对应位置,即可。

下载来源:

下载后,可以看到Specifications中有8个spec。

分别新建Specifications目录:

sudo mkdir /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/Library/Xcode/Specifications
sudo mkdir /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/Library/Xcode/Specifications

再去

  • 移动文件
      • 4个iPhoneOS的文件
        • iPhoneOSPackageTypes.xcspec
        • iPhoneOSPackageTypes.xcspec.iOSOpenDev
        • iPhoneOSProductTypes.xcspec
        • iPhoneOSProductTypes.xcspec.iOSOpenDev
      • 放到:
        • /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/Library/Xcode/Specifications
    • 把:
      • 4个iPhoneSimulator的文件
        • iPhone Simulator PackageTypes.xcspec
        • iPhone Simulator PackageTypes.xcspec.iOSOpenDev
        • iPhone Simulator ProductTypes.xcspec
        • iPhone Simulator ProductTypes.xcspec.iOSOpenDev
      • 放到:
        • /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/Library/Xcode/Specifications

放好后是:

➜  Xcode ll /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/Library/Xcode/Specifications
total 48
-rwxr-xr-x@ 1 crifan  wheel   3.2K 12 24  2015 iPhoneOSPackageTypes.xcspec
-rwxr-xr-x@ 1 crifan  wheel   5.4K 12 24  2015 iPhoneOSPackageTypes.xcspec.iOSOpenDev
-rwxr-xr-x@ 1 crifan  wheel   4.0K 12 24  2015 iPhoneOSProductTypes.xcspec
-rwxr-xr-x@ 1 crifan  wheel   6.4K 12 24  2015 iPhoneOSProductTypes.xcspec.iOSOpenDev
➜  Xcode ll /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/Library/Xcode/Specifications
total 48
-rwxr-xr-x@ 1 crifan  wheel   3.4K 12 24  2015 iPhone Simulator PackageTypes.xcspec
-rwxr-xr-x@ 1 crifan  wheel   6.9K 12 24  2015 iPhone Simulator PackageTypes.xcspec.iOSOpenDev
-rwxr-xr-x@ 1 crifan  wheel   3.4K 12 24  2015 iPhone Simulator ProductTypes.xcspec
-rwxr-xr-x@ 1 crifan  wheel   6.1K 12 24  2015 iPhone Simulator ProductTypes.xcspec.iOSOpenDev

另外,新建usr的bin目录:

sudo mkdir /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin

即可。

results matching ""

    No results matching ""