1 Include <fpu_control.h> only on glibc systems
3 The <fpu_control.h> header provides _FPU_*() macros, which the
4 Init_FPU() function uses only on i386, and only when they are
5 defined. Since <fpu_control.h> is not available, this causes a build
6 failure with C libraries such as musl. By simply including
7 <fpu_control.h> explicitly on glibc systems, we avoid the build
8 failure, since mpcenc.c already conditionally uses the <fpu_control.h>
9 macros only if they are defined.
11 Signed-off-by: Bernd Kuhls <bernd.kuhls@t-online.de>
12 [Thomas: better commit log.]
13 Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
15 diff -uNr musepack_src_r475.org/mpcenc/mpcenc.h musepack_src_r475/mpcenc/mpcenc.h
16 --- musepack_src_r475.org/mpcenc/mpcenc.h 2009-02-23 19:15:46.000000000 +0100
17 +++ musepack_src_r475/mpcenc/mpcenc.h 2016-01-30 09:29:08.000000000 +0100
22 -#if defined __linux__
23 +#if defined __GLIBC__
24 # include <fpu_control.h>
25 #elif defined __FreeBSD__
26 # include <machine/floatingpoint.h>