ios - Info.plist value as C++ #define -


in c++ ios project (or other mac os), there simple way of making value available both info.plist settings, , code in form of preprocessor macro?

ideally, have this

c++ code:

#define my_version_string "1.0" 

info.plist

cfbundleversion: ${my_version_string} 

or alternatively, there way of getting values .plist in c++? (without manually parsing .plist xml.)

probably not best solution, use /usr/libexec/plistbuddy utility in build script generate .h file containing define value extracted plist.

to output value plist:

/usr/libexec/plistbuddy -c 'print :path:to:key' filename.plist 

Comments

Popular posts from this blog

linux - Mailx and Gmail nss config dir -

c# - Is it possible to remove an existing registration from Autofac container builder? -

php - Mysql PK and FK char(36) vs int(10) -