Fixed compiling with gcc 4, patch applied from Gentoo Bugzilla:
authorSam Lantinga <slouken@libsdl.org>
Thu, 08 Dec 2005 14:41:49 +0000
changeset 1197bb5ace455586
parent 1196 b81f54c3963f
child 1198 b616ac4f39d1
Fixed compiling with gcc 4, patch applied from Gentoo Bugzilla:
http://bugs.gentoo.org/show_bug.cgi?id=87809
src/hermes/HeadMMX.h
src/hermes/HeadX86.h
     1.1 --- a/src/hermes/HeadMMX.h	Thu Dec 08 14:21:17 2005 +0000
     1.2 +++ b/src/hermes/HeadMMX.h	Thu Dec 08 14:41:49 2005 +0000
     1.3 @@ -50,21 +50,19 @@
     1.4    extern "C" {   
     1.5    #endif
     1.6  
     1.7 -  void ConvertMMX(HermesConverterInterface *) __attribute__ ((alias ("_ConvertMMX")));
     1.8 -#if 0
     1.9 -  void ClearMMX_32(HermesClearInterface *) __attribute__ ((alias ("_ClearMMX_32")));
    1.10 -  void ClearMMX_24(HermesClearInterface *)  __attribute__ ((alias ("_ClearMMX_24")));
    1.11 -  void ClearMMX_16(HermesClearInterface *)  __attribute__ ((alias ("_ClearMMX_16")));
    1.12 -  void ClearMMX_8(HermesClearInterface *)  __attribute__ ((alias ("_ClearMMX_8")));
    1.13 +  extern void _ConvertMMX(HermesConverterInterface *);
    1.14 +  extern void _ConvertMMXpII32_24RGB888();
    1.15 +  extern void _ConvertMMXpII32_16RGB565();
    1.16 +  extern void _ConvertMMXpII32_16BGR565();
    1.17 +  extern void _ConvertMMXpII32_16RGB555();
    1.18 +  extern void _ConvertMMXpII32_16BGR555();
    1.19  
    1.20 -  void ConvertMMXp32_16RGB555() __attribute__ ((alias ("_ConvertMMXp32_16RGB555")));
    1.21 -#endif
    1.22 -
    1.23 -  void ConvertMMXpII32_24RGB888() __attribute__ ((alias ("_ConvertMMXpII32_24RGB888")));
    1.24 -  void ConvertMMXpII32_16RGB565() __attribute__ ((alias ("_ConvertMMXpII32_16RGB565")));
    1.25 -  void ConvertMMXpII32_16BGR565() __attribute__ ((alias ("_ConvertMMXpII32_16BGR565")));
    1.26 -  void ConvertMMXpII32_16RGB555() __attribute__ ((alias ("_ConvertMMXpII32_16RGB555")));
    1.27 -  void ConvertMMXpII32_16BGR555() __attribute__ ((alias ("_ConvertMMXpII32_16BGR555")));
    1.28 +  #define ConvertMMX _ConvertMMX
    1.29 +  #define ConvertMMXpII32_24RGB888 _ConvertMMXpII32_24RGB888
    1.30 +  #define ConvertMMXpII32_16RGB565 _ConvertMMXpII32_16RGB565
    1.31 +  #define ConvertMMXpII32_16BGR565 _ConvertMMXpII32_16BGR565
    1.32 +  #define ConvertMMXpII32_16RGB555 _ConvertMMXpII32_16RGB555
    1.33 +  #define ConvertMMXpII32_16BGR555 _ConvertMMXpII32_16BGR555
    1.34  
    1.35    #ifdef __cplusplus
    1.36    }
     2.1 --- a/src/hermes/HeadX86.h	Thu Dec 08 14:21:17 2005 +0000
     2.2 +++ b/src/hermes/HeadX86.h	Thu Dec 08 14:41:49 2005 +0000
     2.3 @@ -79,56 +79,47 @@
     2.4    extern "C" {
     2.5    #endif
     2.6  
     2.7 -  int Hermes_X86_CPU() __attribute__ ((alias ("_Hermes_X86_CPU")));
     2.8 +  extern int _Hermes_X86_CPU();
     2.9  
    2.10 -  void ConvertX86(HermesConverterInterface *) __attribute__ ((alias ("_ConvertX86")));
    2.11 +  extern void _ConvertX86(HermesConverterInterface *);
    2.12  
    2.13 -#if 0
    2.14 -  void ClearX86_32(HermesClearInterface *) __attribute__ ((alias ("_ClearX86_32")));
    2.15 -  void ClearX86_24(HermesClearInterface *)  __attribute__ ((alias ("_ClearX86_24")));
    2.16 -  void ClearX86_16(HermesClearInterface *)  __attribute__ ((alias ("_ClearX86_16")));
    2.17 -  void ClearX86_8(HermesClearInterface *)  __attribute__ ((alias ("_ClearX86_8")));
    2.18 -#endif
    2.19 +  extern void _ConvertX86p32_32BGR888();
    2.20 +  extern void _ConvertX86p32_32RGBA888();
    2.21 +  extern void _ConvertX86p32_32BGRA888();
    2.22 +  extern void _ConvertX86p32_24RGB888();
    2.23 +  extern void _ConvertX86p32_24BGR888();
    2.24 +  extern void _ConvertX86p32_16RGB565();
    2.25 +  extern void _ConvertX86p32_16BGR565();
    2.26 +  extern void _ConvertX86p32_16RGB555();
    2.27 +  extern void _ConvertX86p32_16BGR555();
    2.28 +  extern void _ConvertX86p32_8RGB332();
    2.29  
    2.30 -  void ConvertX86p32_32BGR888() __attribute__ ((alias ("_ConvertX86p32_32BGR888")));
    2.31 -  void ConvertX86p32_32RGBA888() __attribute__ ((alias ("_ConvertX86p32_32RGBA888")));
    2.32 -  void ConvertX86p32_32BGRA888() __attribute__ ((alias ("_ConvertX86p32_32BGRA888")));
    2.33 -  void ConvertX86p32_24RGB888() __attribute__ ((alias ("_ConvertX86p32_24RGB888")));
    2.34 -  void ConvertX86p32_24BGR888() __attribute__ ((alias ("_ConvertX86p32_24BGR888")));
    2.35 -  void ConvertX86p32_16RGB565() __attribute__ ((alias ("_ConvertX86p32_16RGB565")));
    2.36 -  void ConvertX86p32_16BGR565() __attribute__ ((alias ("_ConvertX86p32_16BGR565")));
    2.37 -  void ConvertX86p32_16RGB555() __attribute__ ((alias ("_ConvertX86p32_16RGB555")));
    2.38 -  void ConvertX86p32_16BGR555() __attribute__ ((alias ("_ConvertX86p32_16BGR555")));
    2.39 -  void ConvertX86p32_8RGB332() __attribute__ ((alias ("_ConvertX86p32_8RGB332")));
    2.40 +  extern void _ConvertX86p16_16BGR565();
    2.41 +  extern void _ConvertX86p16_16RGB555();
    2.42 +  extern void _ConvertX86p16_16BGR555();
    2.43 +  extern void _ConvertX86p16_8RGB332();
    2.44  
    2.45 -#if 0
    2.46 -  void ConvertX86p16_32RGB888() __attribute__ ((alias ("_ConvertX86p16_32RGB888")));
    2.47 -  void ConvertX86p16_32BGR888() __attribute__ ((alias ("_ConvertX86p16_32BGR888")));
    2.48 -  void ConvertX86p16_32RGBA888() __attribute__ ((alias ("_ConvertX86p16_32RGBA888")));
    2.49 -  void ConvertX86p16_32BGRA888() __attribute__ ((alias ("_ConvertX86p16_32BGRA888")));
    2.50 -  void ConvertX86p16_24RGB888() __attribute__ ((alias ("_ConvertX86p16_24RGB888")));
    2.51 -  void ConvertX86p16_24BGR888() __attribute__ ((alias ("_ConvertX86p16_24BGR888")));
    2.52 -#endif
    2.53 -  void ConvertX86p16_16BGR565() __attribute__ ((alias ("_ConvertX86p16_16BGR565")));
    2.54 -  void ConvertX86p16_16RGB555() __attribute__ ((alias ("_ConvertX86p16_16RGB555")));
    2.55 -  void ConvertX86p16_16BGR555() __attribute__ ((alias ("_ConvertX86p16_16BGR555")));
    2.56 -  void ConvertX86p16_8RGB332() __attribute__ ((alias ("_ConvertX86p16_8RGB332")));
    2.57  
    2.58 -#if 0
    2.59 -  void CopyX86p_4byte() __attribute__ ((alias ("_CopyX86p_4byte")));
    2.60 -  void CopyX86p_3byte() __attribute__ ((alias ("_CopyX86p_3byte")));
    2.61 -  void CopyX86p_2byte() __attribute__ ((alias ("_CopyX86p_2byte")));
    2.62 -  void CopyX86p_1byte() __attribute__ ((alias ("_CopyX86p_1byte")));
    2.63 +  #define Hermes_X86_CPU _Hermes_X86_CPU
    2.64  
    2.65 -  void ConvertX86pI8_32() __attribute__ ((alias ("_ConvertX86pI8_32")));
    2.66 -  void ConvertX86pI8_24() __attribute__ ((alias ("_ConvertX86pI8_24")));
    2.67 -  void ConvertX86pI8_16() __attribute__ ((alias ("_ConvertX86pI8_16")));
    2.68 +  #define ConvertX86 _ConvertX86
    2.69  
    2.70 -  extern int ConvertX86p16_32RGB888_LUT_X86[512] __attribute__ ((alias ("_ConvertX86p16_32RGB888_LUT_X86")));
    2.71 -  extern int ConvertX86p16_32BGR888_LUT_X86[512] __attribute__ ((alias ("_ConvertX86p16_32BGR888_LUT_X86")));
    2.72 -  extern int ConvertX86p16_32RGBA888_LUT_X86[512] __attribute__ ((alias ("_ConvertX86p16_32RGBA888_LUT_X86")));
    2.73 -  extern int ConvertX86p16_32BGRA888_LUT_X86[512] __attribute__ ((alias ("_ConvertX86p16_32BGRA888_LUT_X86")));
    2.74 -#endif
    2.75 +  #define ConvertX86p32_32BGR888 _ConvertX86p32_32BGR888
    2.76 +  #define ConvertX86p32_32RGBA888 _ConvertX86p32_32RGBA888
    2.77 +  #define ConvertX86p32_32BGRA888 _ConvertX86p32_32BGRA888
    2.78 +  #define ConvertX86p32_24RGB888 _ConvertX86p32_24RGB888
    2.79 +  #define ConvertX86p32_24BGR888 _ConvertX86p32_24BGR888
    2.80 +  #define ConvertX86p32_16RGB565 _ConvertX86p32_16RGB565
    2.81 +  #define ConvertX86p32_16BGR565 _ConvertX86p32_16BGR565
    2.82 +  #define ConvertX86p32_16RGB555 _ConvertX86p32_16RGB555
    2.83 +  #define ConvertX86p32_16BGR555 _ConvertX86p32_16BGR555
    2.84 +  #define ConvertX86p32_8RGB332 _ConvertX86p32_8RGB332
    2.85 +
    2.86 +  #define ConvertX86p16_16BGR565 _ConvertX86p16_16BGR565
    2.87 +  #define ConvertX86p16_16RGB555 _ConvertX86p16_16RGB555
    2.88 +  #define ConvertX86p16_16BGR555 _ConvertX86p16_16BGR555
    2.89 +  #define ConvertX86p16_8RGB332 _ConvertX86p16_8RGB332
    2.90 +
    2.91  
    2.92    #ifdef __cplusplus
    2.93    }