|
From: | Bruce Korb |
Subject: | Re: problems in macros |
Date: | Tue, 27 Dec 2005 09:42:34 -0800 |
User-agent: | Mozilla Thunderbird 1.0.7 (X11/20050923) |
Adnan Shaheen wrote:
Hi there, I want to know how can i define macros in my configure.ac file. If i can do it how i will define a macro TESTING in the configure.ac For my code as #ifdef TESTING do this #else // if not defined TESTING do that #endif // TESTING
Hi Adnan, You're speaking the wrong language. The configure.ac file is a mixture of m4 + Bourne shell. Your conditionals appear to be C preprocessing conditional code. Anyway, it is cleaner to define two macros and then: [if ${TESTING} ; then] MY_TESTING_M4_MACRO [else] MY_PRODUCTION_M4_MACRO [fi] with all those funny '[' and ']' thingeys making it clear that the "enclosed" text is plain shell scripting and not for the M4 processor to figure out. Cheers - Bruce
[Prev in Thread] | Current Thread | [Next in Thread] |