diff options
author | Diego 'Flameeyes' Pettenò <flameeyes@gmail.com> | 2008-05-09 15:16:17 +0200 |
---|---|---|
committer | Diego 'Flameeyes' Pettenò <flameeyes@gmail.com> | 2008-05-09 15:16:17 +0200 |
commit | c99cd9519a56b2d7c60fa30e9fecd02f08336671 (patch) | |
tree | d897b2e3e31a2386a16dc6b5f4c3500ac66f601f /src/xine-engine/alphablend.h | |
parent | ed72565137c93ab0385a10036d234f5f4dd1b960 (diff) | |
download | xine-lib-c99cd9519a56b2d7c60fa30e9fecd02f08336671.tar.gz xine-lib-c99cd9519a56b2d7c60fa30e9fecd02f08336671.tar.bz2 |
Cleanup handling of packed attribute.
- Add a configure test for the attribute, during xine build process.
- Define the attribute as supported when using GCC 2.95 or later
outside xine build process.
- Use the new XINE_PACKED define instead of the attribute directly.
- Check for SUPPORT_ATTRIBUTE_PACKED rather than doing strange
subdefines.
Diffstat (limited to 'src/xine-engine/alphablend.h')
-rw-r--r-- | src/xine-engine/alphablend.h | 21 |
1 files changed, 3 insertions, 18 deletions
diff --git a/src/xine-engine/alphablend.h b/src/xine-engine/alphablend.h index 3c9a693d9..7aa63b306 100644 --- a/src/xine-engine/alphablend.h +++ b/src/xine-engine/alphablend.h @@ -39,22 +39,7 @@ typedef struct { void _x_alphablend_init(alphablend_t *extra_data, xine_t *xine) XINE_PROTECTED; void _x_alphablend_free(alphablend_t *extra_data) XINE_PROTECTED; -/* _MSC_VER port changes */ -#undef ATTRIBUTE_PACKED -#undef PRAGMA_PACK_BEGIN -#undef PRAGMA_PACK_END - -#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 95) || defined(__ICC) -#define ATTRIBUTE_PACKED __attribute__ ((packed)) -#define PRAGMA_PACK 0 -#endif - -#if !defined(ATTRIBUTE_PACKED) -#define ATTRIBUTE_PACKED -#define PRAGMA_PACK 1 -#endif - -#if PRAGMA_PACK +#if !SUPPORT_ATTRIBUTE_PACKED #pragma pack(8) #endif @@ -63,10 +48,10 @@ typedef struct { /* CLUT == Color LookUp Table */ uint8_t cr; uint8_t y; uint8_t foo; -} ATTRIBUTE_PACKED clut_t; +} XINE_PACKED clut_t; -#if PRAGMA_PACK +#if !SUPPORT_ATTRIBUTE_PACKED #pragma pack() #endif |