mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-12-24 01:00:37 +00:00
configure: Add configure option to pack OpenMAX structures
This is required to set to 4 for the Raspberry Pi for example.
This commit is contained in:
parent
b8498d6dbc
commit
7c53535026
2 changed files with 32 additions and 0 deletions
10
configure.ac
10
configure.ac
|
@ -167,6 +167,16 @@ AC_ARG_ENABLE(Bsymbolic,
|
|||
enable_Bsymbolic=no)
|
||||
LDFLAGS="${SAVED_LDFLAGS}"])
|
||||
|
||||
|
||||
AC_ARG_WITH([omx-struct-packing],
|
||||
AS_HELP_STRING([--with-omx-struct-packing],[Force OpenMAX struct packing, (default is none)]),
|
||||
[ac_cv_omx_struct_packing="$withval"], [ac_cv_omx_struct_packing="none"])
|
||||
|
||||
if test x"$ac_cv_omx_struct_packing" != x"none"; then
|
||||
AC_MSG_NOTICE([Using $ac_cv_omx_struct_packing as OpenMAX struct packing])
|
||||
AC_DEFINE_UNQUOTED(GST_OMX_STRUCT_PACKING, $ac_cv_omx_struct_packing, [The struct packing used for OpenMAX structures])
|
||||
fi
|
||||
|
||||
dnl *** set variables based on configure arguments ***
|
||||
|
||||
dnl set license and copyright notice
|
||||
|
|
22
omx/gstomx.h
22
omx/gstomx.h
|
@ -27,9 +27,31 @@
|
|||
#include <gst/video/video.h>
|
||||
#include <string.h>
|
||||
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include "config.h"
|
||||
#endif
|
||||
|
||||
#ifdef GST_OMX_STRUCT_PACKING
|
||||
# if GST_OMX_STRUCT_PACKING == 1
|
||||
# pragma pack(1)
|
||||
# elif GST_OMX_STRUCT_PACKING == 2
|
||||
# pragma pack(2)
|
||||
# elif GST_OMX_STRUCT_PACKING == 4
|
||||
# pragma pack(4)
|
||||
# elif GST_OMX_STRUCT_PACKING == 8
|
||||
# pragma pack(8)
|
||||
# else
|
||||
# error "Unsupported struct packing value"
|
||||
# endif
|
||||
#endif
|
||||
|
||||
#include <OMX_Core.h>
|
||||
#include <OMX_Component.h>
|
||||
|
||||
#ifdef GST_OMX_STRUCT_PACKING
|
||||
#pragma pack()
|
||||
#endif
|
||||
|
||||
#include "gstomxrecmutex.h"
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
|
Loading…
Reference in a new issue