/*
**    Name: config.h
**
**    RISC OS configuration for libsndfile 1.2.2 (replaces the
**    autoconf/CMake generated config.h).
*/

#ifndef CONFIG_H
#define CONFIG_H

#include <math.h>

/*
** Newer Norcroft math.h headers map these functions to __d_xxx/__r_xxx
** variants. Call the plain CLib functions instead, which are already in the
** SampleEd Rink symbol map, so the map does not need regenerating.
*/
#ifdef acos
#undef acos
#endif
#ifdef acosf
#undef acosf
#endif
#ifdef asin
#undef asin
#endif
#ifdef asinf
#undef asinf
#endif
#ifdef atan
#undef atan
#endif
#ifdef atanf
#undef atanf
#endif
#ifdef ceil
#undef ceil
#endif
#ifdef ceilf
#undef ceilf
#endif
#ifdef cos
#undef cos
#endif
#ifdef cosf
#undef cosf
#endif
#ifdef exp
#undef exp
#endif
#ifdef expf
#undef expf
#endif
#ifdef fabs
#undef fabs
#endif
#ifdef floor
#undef floor
#endif
#ifdef floorf
#undef floorf
#endif
#ifdef log
#undef log
#endif
#ifdef log10
#undef log10
#endif
#ifdef log10f
#undef log10f
#endif
#ifdef logf
#undef logf
#endif
#ifdef lrint
#undef lrint
#endif
#ifdef lrintf
#undef lrintf
#endif
#ifdef rint
#undef rint
#endif
#ifdef rintf
#undef rintf
#endif
#ifdef sin
#undef sin
#endif
#ifdef sinf
#undef sinf
#endif
#ifdef sqrt
#undef sqrt
#endif
#ifdef sqrtf
#undef sqrtf
#endif
#ifdef tan
#undef tan
#endif
#ifdef tanf
#undef tanf
#endif
#ifdef trunc
#undef trunc
#endif
#ifdef truncf
#undef truncf
#endif

/* Processor */
#define CPU_IS_BIG_ENDIAN 0
#define CPU_IS_LITTLE_ENDIAN 1
#define CPU_CLIPS_NEGATIVE 0
#define CPU_CLIPS_POSITIVE 0
#define COMPILER_IS_GCC 0

/* Sizes */
#define SIZEOF_DOUBLE 8
#define SIZEOF_FLOAT 4
#define SIZEOF_INT 4
#define SIZEOF_INT64_T 8
#define SIZEOF_LONG 4
#define SIZEOF_LONG_LONG 8
#define SIZEOF_OFF_T 4
#define SIZEOF_SHORT 2
#define SIZEOF_SIZE_T 4
#define SIZEOF_SSIZE_T 4
#define SIZEOF_VOIDP 4
#define SIZEOF_WCHAR_T 4

/* External codec libraries are not ported: FLAC, Ogg/Vorbis/Opus/Speex, MPEG */
#define HAVE_EXTERNAL_XIPH_LIBS 0
#define HAVE_MPEG 0
#define HAVE_SQLITE3 0
#define HAVE_ALSA 0
#define HAVE_ALSA_ASOUNDLIB_H 0
#define HAVE_SNDIO_H 0

/* Headers */
#define STDC_HEADERS 1
#define HAVE_STDINT_H 1
#define HAVE_INTTYPES_H 1
#define HAVE_STDBOOL_H 1
#define HAVE_STDIO_H 1
#define HAVE_STDLIB_H 1
#define HAVE_STRING_H 1
#define HAVE_STRINGS_H 0
#define HAVE_LOCALE_H 1
#define HAVE_WCHAR_H 0
#define HAVE_BYTESWAP_H 0
#define HAVE_ENDIAN_H 0
#define HAVE_DLFCN_H 0
#define HAVE_IMMINTRIN_H 0
#define HAVE_MINIX_CONFIG_H 0
#define HAVE_SYS_STAT_H 0
#define HAVE_SYS_TIME_H 0
#define HAVE_SYS_TYPES_H 0
#define HAVE_SYS_WAIT_H 0
#define HAVE_UNISTD_H 0
#define HAVE_DECL_S_IRGRP 1

/* Functions */
#define HAVE_CALLOC 1
#define HAVE_CEIL 1
#define HAVE_FLOOR 1
#define HAVE_FMOD 1
#define HAVE_FREE 1
#define HAVE_MALLOC 1
#define HAVE_REALLOC 1
#define HAVE_SNPRINTF 1
#define HAVE_VSNPRINTF 1
#define HAVE_GMTIME 1
/* HAVE_GMTIME_R and HAVE_LOCALTIME_R are tested with defined (), so leave them undefined */
#define HAVE_LOCALTIME 1
#define HAVE_SETLOCALE 1
#define HAVE_LRINT 1
#define HAVE_LRINTF 1
#define HAVE_FSTAT 0
#define HAVE_FSTAT64 0
#define HAVE_FSYNC 0
#define HAVE_FTRUNCATE 0
#define HAVE_GETPAGESIZE 0
#define HAVE_GETTIMEOFDAY 0
#define HAVE_LSEEK 0
#define HAVE_LSEEK64 0
#define HAVE_MMAP 0
#define HAVE_OPEN 0
#define HAVE_PIPE 0
#define HAVE_READ 0
#define HAVE_WAITPID 0
#define HAVE_WRITE 0

/* Platform */
#define ENABLE_EXPERIMENTAL_CODE 0
#define OS_IS_OPENBSD 0
#define OS_IS_WIN32 0
#define USE_WINDOWS_API 0
#define WIN32_TARGET_DLL 0

/* Package */
#define PACKAGE "libsndfile"
#define PACKAGE_BUGREPORT "sndfile@mega-nerd.com"
#define PACKAGE_NAME "libsndfile"
#define PACKAGE_STRING "libsndfile 1.2.2"
#define PACKAGE_TARNAME "libsndfile"
#define PACKAGE_URL "http://libsndfile.github.io/libsndfile/"
#define PACKAGE_VERSION "1.2.2"
#define VERSION "1.2.2"
#define HOST_TRIPLET "arm-acorn-riscos"

#endif
