• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
proprocessing info.plist files
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

proprocessing info.plist files


  • Subject: proprocessing info.plist files
  • From: Steve Mills <email@hidden>
  • Date: Thu, 1 Dec 2005 21:46:37 -0600

So has anyone figured out a way to do this in an info.plist file with preprocessing turned on?

#define kMajor 1
#define kMinor 2
#define kBugFix 3
#define kBuild 987

#define kAppVersion(aa,bb,cc,dd) aa.bb.cc

<key>CFBundleVersion</key>
<string>kAppVersion(kMajor,kMinor,kBugFix,kBuild)</string>

That ends up "1 . 2 . 3". I tried:

#define kAppVersion(aa,bb,cc,dd) #aa.#bb.#cc

And that generated '"kMajor"."kMinor"."kBugFix"'. I then tried:

#define kAppVersion(aa,bb,cc,dd) #aa##.#bb##.#cc

That generated the error "error: pasting ""kMajor"" and "." does not give a valid preprocessing token". I guess I don't know enough about how # and ## work.

Apple took a nice first step in offering preprocessing of info.plist files, but it still has a long way to go. At one point I #included a file at the top of my Info.plist, but the file couldn't be found, even though the dir it's in is in my "Header Search Paths" and "Rez Search Paths".

Steve Mills
Drummer, Mac geek
http://sjmills5.home.mchsi.com/

Attachment: smime.p7s
Description: S/MIME cryptographic signature

 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Follow-Ups:
    • Re: proprocessing info.plist files
      • From: David Ewing <email@hidden>
    • Re: proprocessing info.plist files
      • From: Steve Mills <email@hidden>
  • Prev by Date: Re: Can gcc 4 built binaries be used on 10.2 to 10.3.8? (undefined reference to _fprintf$LDBL128 expected to be defined in /usr/lib/libSystem.B.dylib)
  • Next by Date: Re: proprocessing info.plist files
  • Previous by thread: Re: Can gcc 4 built binaries be used on 10.2 to 10.3.8? (undefined reference to _fprintf$LDBL128 expected to be defined in /usr/lib/libSystem.B.dylib)
  • Next by thread: Re: proprocessing info.plist files
  • Index(es):
    • Date
    • Thread