libsabi: Special struct size values for W32
authorРуслан Ижбулатов <lrn1986@gmail.com>
Mon, 8 Apr 2013 10:42:15 +0000 (14:42 +0400)
committerSebastian Dröge <sebastian.droege@collabora.co.uk>
Tue, 9 Apr 2013 18:10:46 +0000 (20:10 +0200)
These account for both possible type size mismatch AND -mms-bitfields
packing. Sizes are taken from an i686-w64-mingw32-built GStreamer,
gcc 4.8.0, mingw-w64 svn-r5685.

Fixes #697551

tests/check/gst/gstabi.c
tests/check/gst/struct_i386w.h [new file with mode: 0644]

index a9e2fd6..2356cb1 100644 (file)
 #include <gst/check/gstcheck.h>
 
 #ifdef HAVE_CPU_I386
+#ifndef G_OS_WIN32
 #include "struct_i386.h"
+#else
+#include "struct_i386w.h"
+#endif
 #define HAVE_ABI_SIZES TRUE
 #else
 #ifdef __powerpc64__
diff --git a/tests/check/gst/struct_i386w.h b/tests/check/gst/struct_i386w.h
new file mode 100644 (file)
index 0000000..fc7a571
--- /dev/null
@@ -0,0 +1,72 @@
+static GstCheckABIStruct list[] = {
+  {"GstAllocationParams", sizeof (GstAllocationParams), 32},
+  {"GstAllocator", sizeof (GstAllocator), 112},
+  {"GstAllocatorClass", sizeof (GstAllocatorClass), 116},
+  {"GstBinClass", sizeof (GstBinClass), 292},
+  {"GstBin", sizeof (GstBin), 248},
+  {"GstBuffer", sizeof (GstBuffer), 80},
+  {"GstBufferPoolAcquireParams", sizeof (GstBufferPoolAcquireParams), 48},
+  {"GstBufferPool", sizeof (GstBufferPool), 88},
+  {"GstBufferPoolClass", sizeof (GstBufferPoolClass), 144},
+  {"GstBusClass", sizeof (GstBusClass), 116},
+  {"GstBus", sizeof (GstBus), 88},
+  {"GstCaps", sizeof (GstCaps), 36},
+  {"GstChildProxyInterface", sizeof (GstChildProxyInterface), 44},
+  {"GstClockClass", sizeof (GstClockClass), 132},
+  {"GstClockEntry", sizeof (GstClockEntry), 72},
+  {"GstClock", sizeof (GstClock), 88},
+  {"GstControlBinding", sizeof (GstControlBinding), 96},
+  {"GstControlBindingClass", sizeof (GstControlBindingClass), 124},
+  {"GstControlSource", sizeof (GstControlSource), 88},
+  {"GstControlSourceClass", sizeof (GstControlSourceClass), 108},
+  {"GstDebugCategory", sizeof (GstDebugCategory), 16},
+  {"GstElementClass", sizeof (GstElementClass), 248},
+  {"GstElement", sizeof (GstElement), 184},
+  {"GstEvent", sizeof (GstEvent), 56},
+  {"GstFormatDefinition", sizeof (GstFormatDefinition), 16},
+  {"GstGhostPadClass", sizeof (GstGhostPadClass), 136},
+  {"GstGhostPad", sizeof (GstGhostPad), 320},
+  {"GstIterator", sizeof (GstIterator), 60},
+  {"GstMemory", sizeof (GstMemory), 60},
+  {"GstMapInfo", sizeof (GstMapInfo), 52},
+  {"GstMessage", sizeof (GstMessage), 80},
+  {"GstMeta", sizeof (GstMeta), 8},
+  {"GstMetaTransformCopy", sizeof (GstMetaTransformCopy), 12},
+  {"GstMetaInfo", sizeof (GstMetaInfo), 40},
+  {"GstMiniObject", sizeof (GstMiniObject), 36},
+  {"GstObjectClass", sizeof (GstObjectClass), 92},
+  {"GstObject", sizeof (GstObject), 64},
+  {"GstPadClass", sizeof (GstPadClass), 116},
+  {"GstPad", sizeof (GstPad), 304},
+  {"GstPadProbeInfo", sizeof (GstPadProbeInfo), 48},
+  {"GstPadTemplateClass", sizeof (GstPadTemplateClass), 112},
+  {"GstPadTemplate", sizeof (GstPadTemplate), 96},
+  {"GstParamSpecFraction", sizeof (GstParamSpecFraction), 64},
+  {"GstPipelineClass", sizeof (GstPipelineClass), 308},
+  {"GstPipeline", sizeof (GstPipeline), 296},
+  {"GstPluginDesc", sizeof (GstPluginDesc), 60},
+  {"GstPresetInterface", sizeof (GstPresetInterface), 56},
+  {"GstProxyPadClass", sizeof (GstProxyPadClass), 120},
+  {"GstProxyPad", sizeof (GstProxyPad), 312},
+  {"GstQuery", sizeof (GstQuery), 40},
+  {"GstRegistryClass", sizeof (GstRegistryClass), 92},
+  {"GstRegistry", sizeof (GstRegistry), 72},
+  {"GstSegment", sizeof (GstSegment), 104},
+  {"GstStaticCaps", sizeof (GstStaticCaps), 24},
+  {"GstStaticPadTemplate", sizeof (GstStaticPadTemplate), 36},
+  {"GstStructure", sizeof (GstStructure), 8},
+  {"GstSystemClockClass", sizeof (GstSystemClockClass), 148},
+  {"GstSystemClock", sizeof (GstSystemClock), 112},
+  {"GstTagList", sizeof (GstTagList), 36},
+  {"GstTagSetterInterface", sizeof (GstTagSetterInterface), 8},
+  {"GstTaskClass", sizeof (GstTaskClass), 112},
+  {"GstTask", sizeof (GstTask), 128},
+  {"GstTaskPoolClass", sizeof (GstTaskPoolClass), 124},
+  {"GstTaskPool", sizeof (GstTaskPool), 88},
+  {"GstTimedValue", sizeof (GstTimedValue), 16},
+  {"GstTocSetterInterface", sizeof (GstTocSetterInterface), 8},
+  {"GstTypeFind", sizeof (GstTypeFind), 32},
+  {"GstURIHandlerInterface", sizeof (GstURIHandlerInterface), 24},
+  {"GstValueTable", sizeof (GstValueTable), 32},
+  {NULL, 0, 0}
+};