[lttng-dev] Bug#751337: [PATCH] tests: test_ctf_writer: replace HOST_NAME_MAX

Sebastian Andrzej Siewior sebastian at breakpoint.cc
Wed Aug 6 03:03:24 EDT 2014


On 2014-08-05 16:14:12 [-0400], Jon Bernard wrote:
> This may also work as well:
> 
>     diff --git a/configure.ac b/configure.ac
>     index 80eba33..248044e 100644
>     --- a/configure.ac
>     +++ b/configure.ac
>     @@ -50,6 +50,17 @@ AC_C_INLINE
>      AC_TYPE_PID_T
>      AC_TYPE_SIZE_T
> 
>     +# FreeBSD does not define HOST_NAME_MAX
>     +AC_CHECK_DECL(HOST_NAME_MAX,,
>     +       [
>     +        AC_CHECK_DECL(_POSIX_HOST_NAME_MAX,
>     +                      AC_DEFINE(HOST_NAME_MAX, _POSIX_HOST_NAME_MAX, []),
>     +                      AC_DEFINE(HOST_NAME_MAX, 256, [Define to 256 if neither have HOST_NAME_MAX nor _POSIX_HOST_NAME_MAX]),
>     +                      [[#include <limits.h>]])
>     +       ],
>     +       [[#include <limits.h>]]
>     +)

Sure it will. I have no strong opinion on how it gets fixed :)

>     +
>      # Checks for library functions.
>      AC_FUNC_MALLOC
>      AC_FUNC_MMAP
> 

Sebastian



More information about the lttng-dev mailing list