• 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: date-time info at compile time
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: date-time info at compile time


  • Subject: Re: date-time info at compile time
  • From: Chris Espinosa <email@hidden>
  • Date: Tue, 19 May 2009 14:50:48 -0700

On May 18, 2009, at 10:32 PM, Paul M wrote:

Thanks Jeff, you're is right, this is exactly the problem I'm solving, so it's the build date I need, not the compile time of one of the sources.

It seems the 2 step proceedure outlined earlier could be simplified/ streamlined for my needs - the key is probably the 'run script phase'. I dont know xcode very well either, but this gives me something I can look up in the docs.

I'd want it to be a fully automated one step process to avoid potential errors (if there is potential for error, you can never rely on the result after the fact). Once I've figured out the way to run an arbtrary command as part of the build, the rest should be easy enough.

When you set the install name of a dylib, ld automatically adds an LC_ID_DYLIB load command that includes a timestamp of when the library was built. You can access this with otool:


$ otool -Dv /System/Library/Frameworks/CoreServices.framework/Versions/ A/CoreServices
/System/Library/Frameworks/CoreServices.framework/Versions/A/ CoreServices:
/System/Library/Frameworks/CoreServices.framework/Versions/A/ CoreServices
time stamp 1192163023 Thu Oct 11 21:23:43 2007


If what you want is a single time stamp of when your product was built, it's automatic, and free.

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: 
 >Re: date-time info at compile time (From: "Ray, Jeffrey R. {Jeff}(DFRC-ME)" <email@hidden>)
 >Re: date-time info at compile time (From: Paul M <email@hidden>)

  • Prev by Date: Re: gcc poison, how to catch use of strcpy()?
  • Next by Date: Re: Xcode, SCM and External Editors - Not picking up changes?
  • Previous by thread: Re: date-time info at compile time
  • Next by thread: date-time info at compile time
  • Index(es):
    • Date
    • Thread