--- /dev/null
+#! /bin/sh /usr/share/dpatch/dpatch-run
+## Paul Brossier <piem@debian.org>
+## DP: fix avi.h packed attribute for gcc-4.0
+
+@DPATCH@
+--- kino-0.8.0/src/avi.h 2005-10-20 07:28:39.000000000 +0100
++++ kino-0.80/src/avi.h 2005-11-28 18:57:02.782807000 +0000
+@@ -31,7 +31,7 @@
+ #include "riff.h"
+ #include "frame.h"
+
+-#define PACKED(x) __attribute__((packed)) x
++#define PACKED(x) x __attribute__((packed))
+
+ #define AVI_SMALL_INDEX (0x01)
+ #define AVI_LARGE_INDEX (0x02)
+@@ -48,35 +48,35 @@
+ typedef struct
+ {
+ /// frame display rate (or 0L)
+- DWORD dwMicroSecPerFrame;
++ DWORD PACKED(dwMicroSecPerFrame);
+
+ /// max. transfer rate
+- DWORD dwMaxBytesPerSec;
++ DWORD PACKED(dwMaxBytesPerSec);
+
+ /// pad to multiples of this size, normally 2K
+- DWORD dwPaddingGranularity;
++ DWORD PACKED(dwPaddingGranularity);
+
+ /// the ever-present flags
+- DWORD dwFlags;
++ DWORD PACKED(dwFlags);
+
+ /// # frames in file
+- DWORD dwTotalFrames;
+- DWORD dwInitialFrames;
+- DWORD dwStreams;
+- DWORD dwSuggestedBufferSize;
++ DWORD PACKED(dwTotalFrames);
++ DWORD PACKED(dwInitialFrames);
++ DWORD PACKED(dwStreams);
++ DWORD PACKED(dwSuggestedBufferSize);
+
+- DWORD dwWidth;
+- DWORD dwHeight;
++ DWORD PACKED(dwWidth);
++ DWORD PACKED(dwHeight);
+
+- DWORD dwReserved[ 4 ];
++ DWORD PACKED(dwReserved[ 4 ]);
+ }
+-PACKED(MainAVIHeader);
++MainAVIHeader;
+
+ typedef struct
+ {
+- WORD top, bottom, left, right;
++ WORD PACKED(top), PACKED(bottom), PACKED(left), PACKED(right);
+ }
+-PACKED(RECT);
++RECT;
+
+ /** Declaration of a stream header
+
+@@ -84,113 +84,113 @@
+
+ typedef struct
+ {
+- FOURCC fccType;
+- FOURCC fccHandler;
+- DWORD dwFlags; /* Contains AVITF_* flags */
+- WORD wPriority;
+- WORD wLanguage;
+- DWORD dwInitialFrames;
+- DWORD dwScale;
+- DWORD dwRate; /* dwRate / dwScale == samples/second */
+- DWORD dwStart;
+- DWORD dwLength; /* In units above... */
+- DWORD dwSuggestedBufferSize;
+- DWORD dwQuality;
+- DWORD dwSampleSize;
+- RECT rcFrame;
++ FOURCC PACKED(fccType);
++ FOURCC PACKED(fccHandler);
++ DWORD PACKED(dwFlags); /* Contains AVITF_* flags */
++ WORD PACKED(wPriority);
++ WORD PACKED(wLanguage);
++ DWORD PACKED(dwInitialFrames);
++ DWORD PACKED(dwScale);
++ DWORD PACKED(dwRate); /* dwRate / dwScale == samples/second */
++ DWORD PACKED(dwStart);
++ DWORD PACKED(dwLength); /* In units above... */
++ DWORD PACKED(dwSuggestedBufferSize);
++ DWORD PACKED(dwQuality);
++ DWORD PACKED(dwSampleSize);
++ RECT PACKED(rcFrame);
+ }
+-PACKED(AVIStreamHeader);
++AVIStreamHeader;
+
+ typedef struct
+ {
+- DWORD dwDVAAuxSrc;
+- DWORD dwDVAAuxCtl;
+- DWORD dwDVAAuxSrc1;
+- DWORD dwDVAAuxCtl1;
+- DWORD dwDVVAuxSrc;
+- DWORD dwDVVAuxCtl;
+- DWORD dwDVReserved[ 2 ];
++ DWORD PACKED(dwDVAAuxSrc);
++ DWORD PACKED(dwDVAAuxCtl);
++ DWORD PACKED(dwDVAAuxSrc1);
++ DWORD PACKED(dwDVAAuxCtl1);
++ DWORD PACKED(dwDVVAuxSrc);
++ DWORD PACKED(dwDVVAuxCtl);
++ DWORD PACKED(dwDVReserved[ 2 ]);
+ }
+-PACKED(DVINFO);
++DVINFO;
+
+ typedef struct
+ {
+- DWORD biSize;
+- LONG biWidth;
+- LONG biHeight;
+- WORD biPlanes;
+- WORD biBitCount;
+- DWORD biCompression;
+- DWORD biSizeImage;
+- LONG biXPelsPerMeter;
+- LONG biYPelsPerMeter;
+- DWORD biClrUsed;
+- DWORD biClrImportant;
++ DWORD PACKED(biSize);
++ LONG PACKED(biWidth);
++ LONG PACKED(biHeight);
++ WORD PACKED(biPlanes);
++ WORD PACKED(biBitCount);
++ DWORD PACKED(biCompression);
++ DWORD PACKED(biSizeImage);
++ LONG PACKED(biXPelsPerMeter);
++ LONG PACKED(biYPelsPerMeter);
++ DWORD PACKED(biClrUsed);
++ DWORD PACKED(biClrImportant);
+ }
+-PACKED(BITMAPINFOHEADER);
++BITMAPINFOHEADER;
+
+ typedef struct
+ {
+- WORD wFormatTag;
+- WORD nChannels;
+- DWORD nSamplesPerSec;
+- DWORD nAvgBytesPerSec;
+- WORD nBlockAlign;
+- WORD wBitsPerSample;
+- WORD cbSize;
+- WORD dummy;
++ WORD PACKED(wFormatTag);
++ WORD PACKED(nChannels);
++ DWORD PACKED(nSamplesPerSec);
++ DWORD PACKED(nAvgBytesPerSec);
++ WORD PACKED(nBlockAlign);
++ WORD PACKED(wBitsPerSample);
++ WORD PACKED(cbSize);
++ WORD PACKED(dummy);
+ }
+-PACKED(WAVEFORMATEX);
++WAVEFORMATEX;
+
+ typedef struct
+ {
+- WORD wLongsPerEntry;
+- BYTE bIndexSubType;
+- BYTE bIndexType;
+- DWORD nEntriesInUse;
+- FOURCC dwChunkId;
+- DWORD dwReserved[ 3 ];
++ WORD PACKED(wLongsPerEntry);
++ BYTE PACKED(bIndexSubType);
++ BYTE PACKED(bIndexType);
++ DWORD PACKED(nEntriesInUse);
++ FOURCC PACKED(dwChunkId);
++ DWORD PACKED(dwReserved[ 3 ]);
+ struct avisuperindex_entry
+ {
+- QUADWORD qwOffset;
+- DWORD dwSize;
+- DWORD dwDuration;
++ QUADWORD PACKED(qwOffset);
++ DWORD PACKED(dwSize);
++ DWORD PACKED(dwDuration);
+ }
+ aIndex[ 2014 ];
+ }
+-PACKED(AVISuperIndex);
++AVISuperIndex;
+
+ typedef struct
+ {
+- WORD wLongsPerEntry;
+- BYTE bIndexSubType;
+- BYTE bIndexType;
+- DWORD nEntriesInUse;
+- FOURCC dwChunkId;
+- QUADWORD qwBaseOffset;
+- DWORD dwReserved;
++ WORD PACKED(wLongsPerEntry);
++ BYTE PACKED(bIndexSubType);
++ BYTE PACKED(bIndexType);
++ DWORD PACKED(nEntriesInUse);
++ FOURCC PACKED(dwChunkId);
++ QUADWORD PACKED(qwBaseOffset);
++ DWORD PACKED(dwReserved);
+ struct avifieldindex_entry
+ {
+- DWORD dwOffset;
+- DWORD dwSize;
++ DWORD PACKED(dwOffset);
++ DWORD PACKED(dwSize);
+ }
+- aIndex[ 17895 ];
++ aIndex[ 4028 ];
+ }
+-PACKED(AVIStdIndex);
++AVIStdIndex;
+
+ typedef struct
+ {
+ struct avisimpleindex_entry
+ {
+- FOURCC dwChunkId;
+- DWORD dwFlags;
+- DWORD dwOffset;
+- DWORD dwSize;
++ FOURCC PACKED(dwChunkId);
++ DWORD PACKED(dwFlags);
++ DWORD PACKED(dwOffset);
++ DWORD PACKED(dwSize);
+ }
+ aIndex[ 20000 ];
+- DWORD nEntriesInUse;
++ DWORD PACKED(nEntriesInUse);
+ }
+-PACKED(AVISimpleIndex);
++AVISimpleIndex;
+
+ typedef struct
+ {