Fix autotools on FreeBSD.
Endianness fun is not provided by the same header file on GNU/Linux (endian.h) and FreeBSD (sys/endian.h). Add some magic for the autotools to detect the correct header file. While here, add AC_C_INLINE: it's reported as missing by autoscan(1).
This commit is contained in:
parent
58d83ae20a
commit
4bf33cc707
4 changed files with 22 additions and 2 deletions
|
|
@ -29,8 +29,16 @@
|
|||
* October 6, 2008
|
||||
*/
|
||||
|
||||
#define _BSD_SOURCE
|
||||
#include <endian.h>
|
||||
#include "config.h"
|
||||
|
||||
#if defined(HAVE_SYS_ENDIAN_H)
|
||||
# include <sys/endian.h>
|
||||
#endif
|
||||
|
||||
#if defined(HAVE_ENDIAN_H)
|
||||
# define _BSD_SOURCE
|
||||
# include <endian.h>
|
||||
#endif
|
||||
#include <errno.h>
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue