You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
gentoo-overlay/net-libs/osptoolkit/files/osptoolkit-4.13.0-gcc5.patch

18 lines
768 B

Starting with GCC 5, the __builtin_isnan() fucntion requires proper overloaded types, even in C:
* osptransapi.c:1040:13: error: non-floating-point argument in call to function __builtin_isnan
* OSPM_ISNAN(metrics.mean, tnisnan);
See also:
https://bugs.gentoo.org/show_bug.cgi?id=581058
--- a/src/osptransapi.c
+++ b/src/osptransapi.c
@@ -983,7 +983,7 @@
/* sample mean - have to cast Samples to a float to get some precision on the mean */
mean = ((metrics.mean * currnumber) + (ospvMean * ospvSamples)) / (float)metrics.samples;
- OSPM_ISNAN(metrics.mean, tnisnan);
+ OSPM_ISNAN((double)metrics.mean, tnisnan);
if (tnisnan) {
errcode = OSPC_ERR_TRAN_INVALID_CALC;