summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTim-Philipp Müller <tim@centricular.com>2018-01-11 12:02:47 +0000
committerTim-Philipp Müller <tim@centricular.com>2018-01-11 12:04:31 +0000
commitc5e1dc4ee60ad988242a93e61daff37c081dfa18 (patch)
tree1589edbe9d7551e87cbb77abe7cbfd1486a7158e
parent361fbc3fdd09f4a1895e93c9e9f25612bcab67a2 (diff)
tests: abi: fix abi test on 64-bit Windows
Add header with structure sizes for 64-bit windows as well. They're almost the same as on Linux, but it looks like things like padding unions get aligned slightly differently so there are a handful of differences: sizeof(GstGhostPad) is 528, expected 536 sizeof(GstPad) is 512, expected 520 sizeof(GstPadProbeInfo) is 64, expected 72 sizeof(GstProxyPad) is 520, expected 528
-rw-r--r--tests/check/Makefile.am2
-rw-r--r--tests/check/gst/gstabi.c4
-rw-r--r--tests/check/gst/struct_x86_64w.h66
3 files changed, 72 insertions, 0 deletions
diff --git a/tests/check/Makefile.am b/tests/check/Makefile.am
index 9d78cc727..13b916da2 100644
--- a/tests/check/Makefile.am
+++ b/tests/check/Makefile.am
@@ -182,11 +182,13 @@ noinst_HEADERS = \
gst/capslist.h \
gst/struct_arm.h \
gst/struct_i386.h \
+ gst/struct_i386w.h \
gst/struct_hppa.h \
gst/struct_ppc32.h \
gst/struct_ppc64.h \
gst/struct_sparc.h \
gst/struct_x86_64.h \
+ gst/struct_x86_64w.h \
libs/struct_arm.h \
libs/struct_i386.h \
libs/struct_hppa.h \
diff --git a/tests/check/gst/gstabi.c b/tests/check/gst/gstabi.c
index 72d1f337b..6f13b1215 100644
--- a/tests/check/gst/gstabi.c
+++ b/tests/check/gst/gstabi.c
@@ -41,7 +41,11 @@
#define HAVE_ABI_SIZES TRUE
#else
#ifdef HAVE_CPU_X86_64
+#ifndef G_OS_WIN32
#include "struct_x86_64.h"
+#else
+#include "struct_x86_64w.h"
+#endif
#define HAVE_ABI_SIZES TRUE
#else
#ifdef HAVE_CPU_HPPA
diff --git a/tests/check/gst/struct_x86_64w.h b/tests/check/gst/struct_x86_64w.h
new file mode 100644
index 000000000..00c640589
--- /dev/null
+++ b/tests/check/gst/struct_x86_64w.h
@@ -0,0 +1,66 @@
+static GstCheckABIStruct list[] = {
+ {"GstAllocationParams", sizeof (GstAllocationParams), 64},
+ {"GstAllocator", sizeof (GstAllocator), 176},
+ {"GstAllocatorClass", sizeof (GstAllocatorClass), 232},
+ {"GstBinClass", sizeof (GstBinClass), 576},
+ {"GstBin", sizeof (GstBin), 376},
+ {"GstBuffer", sizeof (GstBuffer), 112},
+ {"GstBufferPoolAcquireParams", sizeof (GstBufferPoolAcquireParams), 64},
+ {"GstBufferPool", sizeof (GstBufferPool), 136},
+ {"GstBufferPoolClass", sizeof (GstBufferPoolClass), 288},
+ {"GstBusClass", sizeof (GstBusClass), 232},
+ {"GstBus", sizeof (GstBus), 128},
+ {"GstCaps", sizeof (GstCaps), 64},
+ {"GstClockClass", sizeof (GstClockClass), 264},
+ {"GstClockEntry", sizeof (GstClockEntry), 112},
+ {"GstClock", sizeof (GstClock), 128},
+ {"GstControlBinding", sizeof (GstControlBinding), 152},
+ {"GstControlBindingClass", sizeof (GstControlBindingClass), 248},
+ {"GstControlSource", sizeof (GstControlSource), 136},
+ {"GstControlSourceClass", sizeof (GstControlSourceClass), 216},
+ {"GstDebugCategory", sizeof (GstDebugCategory), 24},
+ {"GstElementClass", sizeof (GstElementClass), 488},
+ {"GstElement", sizeof (GstElement), 264},
+ {"GstEvent", sizeof (GstEvent), 88},
+ {"GstFormatDefinition", sizeof (GstFormatDefinition), 32},
+ {"GstGhostPadClass", sizeof (GstGhostPadClass), 272},
+ {"GstGhostPad", sizeof (GstGhostPad), 528},
+ {"GstIterator", sizeof (GstIterator), 120},
+ {"GstMemory", sizeof (GstMemory), 112},
+ {"GstMapInfo", sizeof (GstMapInfo), 104},
+ {"GstMessage", sizeof (GstMessage), 120},
+ {"GstMeta", sizeof (GstMeta), 16},
+ {"GstMetaTransformCopy", sizeof (GstMetaTransformCopy), 24},
+ {"GstMiniObject", sizeof (GstMiniObject), 64},
+ {"GstObjectClass", sizeof (GstObjectClass), 184},
+ {"GstObject", sizeof (GstObject), 88},
+ {"GstPadClass", sizeof (GstPadClass), 232},
+ {"GstPad", sizeof (GstPad), 512},
+ {"GstPadProbeInfo", sizeof (GstPadProbeInfo), 64},
+ {"GstPadTemplateClass", sizeof (GstPadTemplateClass), 224},
+ {"GstPadTemplate", sizeof (GstPadTemplate), 144},
+ {"GstParamSpecFraction", sizeof (GstParamSpecFraction), 96},
+ {"GstPipelineClass", sizeof (GstPipelineClass), 608},
+ {"GstPipeline", sizeof (GstPipeline), 440},
+ {"GstPluginDesc", sizeof (GstPluginDesc), 112},
+ {"GstProxyPadClass", sizeof (GstProxyPadClass), 240},
+ {"GstProxyPad", sizeof (GstProxyPad), 520},
+ {"GstQuery", sizeof (GstQuery), 72},
+ {"GstRegistryClass", sizeof (GstRegistryClass), 184},
+ {"GstRegistry", sizeof (GstRegistry), 96},
+ {"GstSegment", sizeof (GstSegment), 120},
+ {"GstStaticCaps", sizeof (GstStaticCaps), 48},
+ {"GstStaticPadTemplate", sizeof (GstStaticPadTemplate), 64},
+ {"GstStructure", sizeof (GstStructure), 16},
+ {"GstSystemClockClass", sizeof (GstSystemClockClass), 296},
+ {"GstSystemClock", sizeof (GstSystemClock), 168},
+ {"GstTagList", sizeof (GstTagList), 64,},
+ {"GstTaskClass", sizeof (GstTaskClass), 224},
+ {"GstTask", sizeof (GstTask), 200},
+ {"GstTaskPoolClass", sizeof (GstTaskPoolClass), 248},
+ {"GstTaskPool", sizeof (GstTaskPool), 128},
+ {"GstTimedValue", sizeof (GstTimedValue), 16},
+ {"GstTypeFind", sizeof (GstTypeFind), 64},
+ {"GstValueTable", sizeof (GstValueTable), 64},
+ {NULL, 0, 0}
+};