fix building SDL_audiotypecvt.c with gcc < 4.0
authorsezero <sezero@users.sourceforge.net>
Mon, 12 Feb 2018 10:47:00 +0300
changeset 1187396157e099383
parent 11872 e917e911dab6
child 11874 b0e4f5085af4
fix building SDL_audiotypecvt.c with gcc < 4.0
src/audio/SDL_audiotypecvt.c
     1.1 --- a/src/audio/SDL_audiotypecvt.c	Mon Feb 12 17:00:00 2018 +0300
     1.2 +++ b/src/audio/SDL_audiotypecvt.c	Mon Feb 12 10:47:00 2018 +0300
     1.3 @@ -509,6 +509,16 @@
     1.4      }
     1.5  }
     1.6  
     1.7 +#if defined(__GNUC__) && (__GNUC__ < 4)
     1.8 +/* these were added as of gcc-4.0: http://gcc.gnu.org/bugzilla/show_bug.cgi?id=19418 */
     1.9 +static inline __m128 _mm_castsi128_ps(__m128i __A) {
    1.10 +  return (__m128) __A;
    1.11 +}
    1.12 +static inline __m128i _mm_castps_si128(__m128 __A) {
    1.13 +  return (__m128i) __A;
    1.14 +}
    1.15 +#endif
    1.16 +
    1.17  static void SDLCALL
    1.18  SDL_Convert_S32_to_F32_SSE2(SDL_AudioCVT *cvt, SDL_AudioFormat format)
    1.19  {