• 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
exporting env & build settings as preprocessor defines
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

exporting env & build settings as preprocessor defines


  • Subject: exporting env & build settings as preprocessor defines
  • From: Shaun Wexler <email@hidden>
  • Date: Sun, 3 Sep 2006 23:12:29 -0700

I know I'm missing something simple and/or obvious. I'd like to use Xcode build settings as defines in the code. What is the best way of converting between these types, with the least amount of effort? Example:

#if __x86_64__
#  define SKW_BUILD_ARCH "x86_64"
#elif __i386__
#  define SKW_BUILD_ARCH "i386"
#elif __ppc970__
#  define SKW_BUILD_ARCH "ppc970"
#elif __ppc64__
#  define SKW_BUILD_ARCH "ppc64"
#elif __ppc7400__
#  define SKW_BUILD_ARCH "ppc7400"
#elif __ppc__
#  define SKW_BUILD_ARCH "ppc"
#endif

I'd rather be able to import the build settings directly like this:

#define SKW_BUILD_ARCH STRINGIFY(($arch))

--
Shaun Wexler
MacFOH
http://www.macfoh.com


_______________________________________________ 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: exporting env & build settings as preprocessor defines
      • From: Mailing list subscriptions <email@hidden>
    • Re: exporting env & build settings as preprocessor defines
      • From: Chris Espinosa <email@hidden>
  • Prev by Date: Remote Debugging/exec paths
  • Next by Date: Re: exporting env & build settings as preprocessor defines
  • Previous by thread: Re: Remote Debugging/exec paths
  • Next by thread: Re: exporting env & build settings as preprocessor defines
  • Index(es):
    • Date
    • Thread