• 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
Re: Passing PREPROCESSOR_MACROS as input to XCode build
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Passing PREPROCESSOR_MACROS as input to XCode build


  • Subject: Re: Passing PREPROCESSOR_MACROS as input to XCode build
  • From: Chris Espinosa <email@hidden>
  • Date: Fri, 15 May 2009 17:25:38 -0700


On May 15, 2009, at 4:36 PM, Yuichi Kuroda wrote:

I’m currently running an xcode build via an Automator job. I’d like to set a PREPROCESSOR_MACROS (ie. BUILT_BY_AUTOMATOR=1) only when the build is performed through the Automator. I was wondering if this is possible, some sort of way to pass an envrironment variable as input to the xcode build.
 
An alternative method I’m using right now is by creating a new build configuration, a duplicate of the Debug configuration (say, Debug2). But the only difference between the two is that I’m setting that one extra environment variable in the new configuration, which seems too inefficient.

You can pass any build setting via xcodebuild executed in a shell script:

cd myProjectDirectory
xcodebuild -configuration Release -target All PREPROCESSOR_MACROS="BUILT_BY_AUTOMATOR=1"

Chris
 _______________________________________________
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

References: 
 >Passing PREPROCESSOR_MACROS as input to XCode build (From: Yuichi Kuroda <email@hidden>)

  • Prev by Date: Passing PREPROCESSOR_MACROS as input to XCode build
  • Next by Date: Preprocess Info.plist for Single-File Tool
  • Previous by thread: Passing PREPROCESSOR_MACROS as input to XCode build
  • Next by thread: Preprocess Info.plist for Single-File Tool
  • Index(es):
    • Date
    • Thread