jpeg-turbo: fix legal info
[buildroot-gz.git] / package / lftp / 0002-fix-gcc-6-conflicts-signbit.patch
blobe906c7ac804fe0827bde179277ff3634e5560bf7
1 Use <cmath> instead of <math.h> to fix gcc 6.x build
3 This patch fixes the following build issue:
5 ../lib/math.h:2577:1: error: ‘int signbit(float)’ conflicts with a previous declaration
7 that occurs with gcc 6.x.
9 Patch taken from
10 https://raw.githubusercontent.com/openembedded/meta-openembedded/master/meta-networking/recipes-connectivity/lftp/files/fix-gcc-6-conflicts-signbit.patch
12 Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
14 --- lftp-4.6.3a/src/NetAccess.cc.orig 2016-06-18 10:25:51.063358981 -0400
15 +++ lftp-4.6.3a/src/NetAccess.cc 2016-06-18 10:26:04.143359209 -0400
16 @@ -21,7 +21,7 @@
18 #include <errno.h>
19 #include <assert.h>
20 -#include <math.h>
21 +#include <cmath>
22 #include <sys/types.h>
24 #include "NetAccess.h"
25 --- lftp-4.6.3a/src/Speedometer.cc.orig 2016-06-18 10:24:58.895358073 -0400
26 +++ lftp-4.6.3a/src/Speedometer.cc 2016-06-18 10:25:10.879358281 -0400
27 @@ -18,7 +18,7 @@
30 #include <config.h>
31 -#include <math.h>
32 +#include <cmath>
33 #include <stdlib.h>
34 #include "Speedometer.h"
35 #include "misc.h"
36 --- lftp-4.6.3a/src/FileCopy.cc.orig 2016-06-18 10:24:15.939357325 -0400
37 +++ lftp-4.6.3a/src/FileCopy.cc 2016-06-18 10:24:24.583357475 -0400
38 @@ -36,7 +36,7 @@
39 #include <sys/types.h>
40 #include <sys/stat.h>
41 #include <fcntl.h>
42 -#include <math.h>
43 +#include <cmath>
44 #include <stddef.h>
45 #include "FileCopy.h"
46 #include "url.h"
47 --- lftp-4.6.3a/src/ResMgr.cc.orig 2016-06-18 10:23:31.387356549 -0400
48 +++ lftp-4.6.3a/src/ResMgr.cc 2016-06-18 10:23:41.771356729 -0400
49 @@ -23,7 +23,7 @@
50 #include <ctype.h>
51 #include <unistd.h>
52 #include <stdlib.h>
53 -#include <math.h>
54 +#include <cmath>
55 #include <sys/types.h>
56 #include <sys/stat.h>
57 #include <errno.h>