Change product name macro in an iOS Xcode project

I built my iPhone code on top of an Apple sample . He calls the app “LazyTable” when placed on the iPhone’s home screen. I would like to change this name. If I go to info.plist and manually enter the new name in the Bundle display name key, it will work. But I don’t want to hardcode because PRODUCT_NAME used in many places.

Info.plist

info plist

So, I go to Project> Edit Project Settings to change the macro. I close the window, clean and rebuild. The application name is still stuck with "LazyTable"! How to make this macro change take effect?

Project Information

project info

+6
source share
1 answer

The approach you use is correct. However, remember that each goal can have its own settings that override the project settings. Make sure the target does not override PRODUCT_NAME.

To do this, select the project in the Xcode project browser, then select the target. Each target has its own build settings. Change PRODUCT_NAME in the same way as when editing project build settings.

+5
source

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


All Articles