How to include "FILE VERSION" in "C Headers" (not header files)?

168 views
Skip to first unread message

sathish

unread,
Sep 5, 2013, 10:59:00 AM9/5/13
to programmi...@googlegroups.com
Dear All,


I have a file a.c.

/* *File Version 1.0 */

#include <stdio.h>

main()
{
   printf("Hello world\n");

}

When I compile the file I want the file version (ie 1.0 in this case) to be included in the a.out file.   So that the version can be seen by using utilities such as "dump".

Is there anyway to achieve this?

OS - AIX
Compiler - xLC


Thanks
Sathish Kumar

Ashish

unread,
Sep 5, 2013, 11:43:15 AM9/5/13
to programmi...@googlegroups.com
I have a file a.c.

/* *File Version 1.0 */

static char FILE_VERSION[] = "FILE VERSION 1.0";

--
--
Visit http://www.gowrikumar.com for good puzzles in C programming language and programming interview questions.
 
You received this message because you are subscribed to the Google Groups "Programming Puzzles" group. To post to this group, send email to programmi...@googlegroups.com
---
You received this message because you are subscribed to the Google Groups "Programming Puzzles" group.
To unsubscribe from this group and stop receiving emails from it, send an email to programming-puz...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

Reply all
Reply to author
Forward
0 new messages