scripts: set GI_TYPELIB_PATH in gst-uninstalled
[platform/upstream/gstreamer.git] / tests / check / libs / libsabi.c
1 /* GStreamer
2  * Copyright (C) 2005 Wim Taymans <wim@fluendo.com>
3  *
4  * libsabi.c: Unit test for ABI compatibility
5  *
6  * This library is free software; you can redistribute it and/or
7  * modify it under the terms of the GNU Library General Public
8  * License as published by the Free Software Foundation; either
9  * version 2 of the License, or (at your option) any later version.
10  *
11  * This library is distributed in the hope that it will be useful,
12  * but WITHOUT ANY WARRANTY; without even the implied warranty of
13  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
14  * Library General Public License for more details.
15  *
16  * You should have received a copy of the GNU Library General Public
17  * License along with this library; if not, write to the
18  * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
19  * Boston, MA 02111-1307, USA.
20  */
21
22 #include <config.h>
23 #include <gst/check/gstcheck.h>
24
25 #include <gst/base/gstadapter.h>
26 #include <gst/base/gstbasesink.h>
27 #include <gst/base/gstbasesrc.h>
28 #include <gst/base/gstbasetransform.h>
29 #include <gst/base/gstbitreader.h>
30 #include <gst/base/gstbytereader.h>
31 #include <gst/base/gstbytewriter.h>
32 #include <gst/base/gstcollectpads.h>
33 #include <gst/base/gstdataqueue.h>
34 #include <gst/base/gstpushsrc.h>
35 #include <gst/base/gsttypefindhelper.h>
36 #include <gst/controller/gstcontroller.h>
37 #include <gst/controller/gstcontrolsource.h>
38 #include <gst/controller/gstinterpolationcontrolsource.h>
39 #include <gst/controller/gstlfocontrolsource.h>
40 #include <gst/dataprotocol/dataprotocol.h>
41 #include <gst/net/gstnet.h>
42 #include <gst/net/gstnetclientclock.h>
43 #include <gst/net/gstnettimepacket.h>
44 #include <gst/net/gstnettimeprovider.h>
45
46 #ifdef HAVE_CPU_I386
47 #include "struct_i386.h"
48 #define HAVE_ABI_SIZES TRUE
49 #else
50 #ifdef __powerpc64__
51 #include "struct_ppc64.h"
52 #define HAVE_ABI_SIZES TRUE
53 #else
54 #ifdef __powerpc__
55 #include "struct_ppc32.h"
56 #define HAVE_ABI_SIZES TRUE
57 #else
58 #ifdef HAVE_CPU_X86_64
59 #include "struct_x86_64.h"
60 #define HAVE_ABI_SIZES TRUE
61 #else
62 #ifdef HAVE_CPU_HPPA
63 #include "struct_hppa.h"
64 #define HAVE_ABI_SIZES TRUE
65 #else
66 #ifdef HAVE_CPU_SPARC
67 #include "struct_sparc.h"
68 #define HAVE_ABI_SIZES TRUE
69 #else
70 #ifdef HAVE_CPU_ARM
71 #include "struct_arm.h"
72 #define HAVE_ABI_SIZES TRUE
73 #else
74 /* in case someone wants to generate a new arch */
75 #include "struct_i386.h"
76 #define HAVE_ABI_SIZES FALSE
77 #endif
78 #endif
79 #endif
80 #endif
81 #endif
82 #endif
83 #endif
84
85 GST_START_TEST (test_ABI)
86 {
87   gst_check_abi_list (list, HAVE_ABI_SIZES);
88 }
89
90 GST_END_TEST;
91
92 static Suite *
93 libsabi_suite (void)
94 {
95   Suite *s = suite_create ("LibsABI");
96   TCase *tc_chain = tcase_create ("size check");
97
98   tcase_set_timeout (tc_chain, 0);
99
100   suite_add_tcase (s, tc_chain);
101   tcase_add_test (tc_chain, test_ABI);
102   return s;
103 }
104
105 GST_CHECK_MAIN (libsabi);