I'm trying to add an item
<key>UIStatusBarHidden</key><true/>
for my plist, which is automatically generated by CMake. For certain keys, there appear to be predefined ways to add an element; eg:
set(MACOSX_BUNDLE_ICON_FILE ${ICON})
But I can not find a way to add an arbitrary property.
I tried to use the MACOSX_BUNDLE_INFO_PLIST target property as follows: I would like the resulting plist to be identical to the old one, except for the new property that I want, so I just copied the automatically generated plist and set that as my template. But plist uses some Xcode variables that also look like ${foo} , and CMake grumbles about it:
Syntax error in cmake code when parsing line
<string>com.bedaire.${PRODUCT_NAME:identifier}</string>
syntax error, unexpected cal_SYMBOL, Waiting} (47)
CMP0010 policy is not installed: Poor variable reference syntax is an error. Run "cmake --help-policy CMP0010" for policy details. Use the cmake_policy command to set the policy and suppress this warning. This warning is for project developers. Use -Wno-dev to suppress it.
In any case, I'm not even sure if this is correct. I cannot find a good example or good documentation about this. Ideally, I would just let CMake generate everything as before, and just add one extra line. What can I do?
iphone cmake plist macos
Jesse beder
source share