How to write a conditional test in configure.ac

2012-01-12 Thread Svante Signell
Hello. Consider the code snippet below. How to modify it to get the GNU version of baseline if defined (in my case GNU/Hurd). The macro AC_USE_SYSTEM_EXTENSIONS is stated earlier in configure.ac. Something like: >>>if defined _GNU_SOURCE<<< ... [AC_TRY_RUN([ #include #include #ifdef HAVE_

Re: How to write a conditional test in configure.ac

2012-01-12 Thread Eric Blake
On 01/12/2012 03:58 PM, Svante Signell wrote: > Hello. > > Consider the code snippet below. How to modify it to get the GNU version > of baseline if defined (in my case GNU/Hurd). The macro > AC_USE_SYSTEM_EXTENSIONS is stated earlier in configure.ac. First, I'd suggest that you _don't_ use base

Re: How to write a conditional test in configure.ac

2012-01-12 Thread Mike Frysinger
On Thursday 12 January 2012 18:32:15 Eric Blake wrote: > First, I'd suggest that you _don't_ use basename(); it has severe > portability problems (POSIX allows, but does not require, it to modify > its incoming argument and some systems (like some *BSDs) do modify it :( -mike signature.asc Descr

Re: How to write a conditional test in configure.ac

2012-01-12 Thread Svante Signell
Thank you for your (and Mikes) prompt replies. On Thu, 2012-01-12 at 16:32 -0700, Eric Blake wrote: > On 01/12/2012 03:58 PM, Svante Signell wrote: > > Hello. > > > > Consider the code snippet below. How to modify it to get the GNU version > > of baseline if defined (in my case GNU/Hurd). The macr