Created new XCode Configuration and Scheme - linker is suddenly failing

后端 未结 2 1327
萌比男神i
萌比男神i 2021-02-14 17:16

A new XCode project has Debug and Release Configurations. I\'ve added a new one under \"ProjectName > Info\" called \"development\", which is for now a duplicate of \"debug\".

2条回答
  •  悲哀的现实
    2021-02-14 17:24

    The problem is that Xcode will expect to find the libraries inside a folder named after your custom configuration. You can add the custom configuration to each library you use, or better follow the steps below to make it use the libraries built via the Release configuration.

    Steps:

    • Select your target
    • Open Build Settings tab
    • Search for 'Library Search Paths'
    • You'll see your new configuration name alongside Debug and Release
    • Double-click the space next to your new configuration name
    • Enter "$(BUILD_DIR)/Release$(EFFECTIVE_PLATFORM_NAME)"
    • Set recursive to true.

    • Exit the dialog and you should see:

    (inspired by this post)

提交回复
热议问题