From: Mathieu Malaterre Date: Tue, 25 Feb 2014 14:03:30 +0000 (+0000) Subject: [trunk] Import commit 87b08a096bb8ad61f9dbe4811e208d9c9d7fe63b from ghostpdl X-Git-Tag: version.2.0.1~4^2~240 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=e260ec6e9d85a81d950956227c343a1c38815b42;p=openjpeg [trunk] Import commit 87b08a096bb8ad61f9dbe4811e208d9c9d7fe63b from ghostpdl don't define lrintf for MSVC 2013 (fix compilation breakage) Update issue 225 --- diff --git a/src/lib/openjp2/opj_includes.h b/src/lib/openjp2/opj_includes.h index 9d74e470..bdbb7c6c 100644 --- a/src/lib/openjp2/opj_includes.h +++ b/src/lib/openjp2/opj_includes.h @@ -129,8 +129,8 @@ Most compilers implement their own version of this keyword ... #endif #endif -/* MSVC and Borland C do not have lrintf */ -#if defined(_MSC_VER) || defined(__BORLANDC__) +/* MSVC before 2013 and Borland C do not have lrintf */ +#if defined(_MSC_VER) && (_MSC_VER < 1800) || defined(__BORLANDC__) static INLINE long lrintf(float f){ #ifdef _M_X64 return (long)((f>0.0f) ? (f + 0.5f):(f -0.5f));