7.4.4 swift sdk configure

原文链接: https://docs.swift.org/latest/documentation/packagemanagerdocs/sdkconfigure/

7.4.4 swift sdk configure

管理已安装 Swift SDK 的配置选项。

sdk configure [--package-path=<package-path>]
  [--cache-path=<cache-path>] [--config-path=<config-path>]
  [--security-path=<security-path>]
  [--scratch-path=<scratch-path>]
  [--swift-sdks-path=<swift-sdks-path>]
  [--toolset=<toolset>...]
  [--pkg-config-path=<pkg-config-path>...]
  [--sdk-root-path=<sdk-root-path>]
  [--swift-resources-path=<swift-resources-path>]
  [--swift-static-resources-path=<swift-static-resources-path>]
  [--include-search-path=<include-search-path>...]
  [--library-search-path=<library-search-path>...]
  [--toolset-path=<toolset-path>...] [--reset]
  [--show-configuration] <sdk-id> [target-triple...] [--version]
  [--help]
  • –package-path=<package-path>:

指定要操作的包路径(默认为当前目录)。这会先切换工作目录,然后再执行其他任何操作。

  • –cache-path=<cache-path>:

指定共享缓存目录的路径。

  • –config-path=<config-path>:

指定共享配置目录的路径。

  • –security-path=<security-path>:

指定共享安全目录的路径。

  • –scratch-path=<scratch-path>:

指定自定义的临时构建目录路径。(默认 .build)

  • –swift-sdks-path=<swift-sdks-path>:

包含已安装 Swift SDK 的目录路径。

  • –toolset=<toolset>:

指定为目标平台构建时使用的工具集 JSON 文件。可以多次使用该选项来指定多个工具集。各个工具集会按指定顺序合并为当前构建的单个最终工具集。

  • –pkg-config-path=<pkg-config-path>:

指定搜索 pkg-config .pc 文件的替代路径。可以多次使用该选项来指定多个路径。

  • –sdk-root-path=<sdk-root-path>:

包含 SDK 根目录的目录路径。

  • –swift-resources-path=<swift-resources-path>:

包含用于动态链接的 Swift 资源的目录路径。

  • –swift-static-resources-path=<swift-static-resources-path>:

包含用于静态链接的 Swift 资源的目录路径。

  • –include-search-path=<include-search-path>:

包含头文件的目录路径。可以通过多次向命令提供该选项来指定多个路径。

  • –library-search-path=<library-search-path>:

包含库的目录路径。可以通过多次向命令提供该选项来指定多个路径。

  • –toolset-path=<toolset-path>:

工具集文件的路径。可以通过多次向命令提供该选项来指定多个路径。

  • –reset:

重置当前应用到某个 Swift SDK 和目标三元组的配置属性。如果没有指定具体属性,则重置该 Swift SDK 的所有属性。

  • –show-configuration:

打印当前应用到某个 Swift SDK 和目标三元组的所有配置属性。

  • sdk-id:

已安装 Swift SDK 的标识符。使用 list 子命令查看所有可用的标识符。

  • target-triple:

要配置的 Swift SDK 的目标三元组。

  • –version:

显示版本。

  • –help:

显示帮助信息。