Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: SOLVED: The date at compile time?



The following macros:

__DATE__
__TIME__
__FILE__
__LINE__

are all defined by the C standard. They will be supported by any C
compiler. (C99 adds several more, but those listed above are the ones
most likely to be useful to you).

On 2/28/07, Alexander v. Below <email@hidden> wrote:
It is __DATE__

What is weird is that this does not show up with gcc -dM -E -x c - <<<''

Is there a way I can list these obscure preprocessor definitions?

Alex

Am 28.02.2007 um 16:15 schrieb Alexander v. Below:

> Hello List,
>
> is it possible to create a define which expands to the current date
> at compile time? Something like NSLog ("This source was compiled on
> %s", $COMPILEDATE). I am happy to convert from any format (seconds,
> strings, whatever)
>
> Thanks a lot
>
> Alex

-- Clark S. Cox III email@hidden _______________________________________________ Do not post admin requests to the list. They will be ignored. Xcode-users mailing list (email@hidden) Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/xcode-users/email@hidden

This email sent to email@hidden
References: 
 >The date at compile time? (From: "Alexander v. Below" <email@hidden>)
 >SOLVED: The date at compile time? (From: "Alexander v. Below" <email@hidden>)



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.