From 023aa3209a1edcb68c5cacaa5c041d744a5bc2bd Mon Sep 17 00:00:00 2001 From: Paul Brossier Date: Fri, 13 May 2016 14:25:59 +0200 Subject: [PATCH] src/aubio_priv.h: if compiling with -std=c99, use defines for strnlen and floorf --- src/aubio_priv.h | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/aubio_priv.h b/src/aubio_priv.h index 90853b99..982b5fc0 100644 --- a/src/aubio_priv.h +++ b/src/aubio_priv.h @@ -289,4 +289,12 @@ typedef enum { #define UNUSED #endif +/* are we using gcc -std=c99 ? */ +#if defined(__STRICT_ANSI__) +#define strnlen(a,b) MIN(strlen(a),b) +#if !HAVE_AUBIO_DOUBLE +#define floorf floor +#endif +#endif /* __STRICT_ANSI__ */ + #endif /* AUBIO_PRIV_H */ -- 2.11.0