Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
VideoLAN
libmpeg2
Commits
4d0f1807
Commit
4d0f1807
authored
Dec 03, 2001
by
Michel Lespinasse
Browse files
"make distcheck" now tries to compile with several compilers
parent
e7b742ee
Changes
7
Hide whitespace changes
Inline
Side-by-side
mpeg2dec/acinclude.m4
View file @
4d0f1807
...
...
@@ -34,14 +34,19 @@ dnl AC_CHECK_GENERATE_INTTYPES_H (INCLUDE-DIRECTORY)
dnl generate a default inttypes.h if the header file does not exist already
AC_DEFUN([AC_CHECK_GENERATE_INTTYPES],
[AC_CHECK_HEADER([inttypes.h],[],
[AC_COMPILE_CHECK_SIZEOF([char],[1])
AC_COMPILE_CHECK_SIZEOF([short],[2])
AC_COMPILE_CHECK_SIZEOF([int],[4])
AC_COMPILE_CHECK_SIZEOF([long long],[8])
[AC_CHECK_SIZEOF([char])
AC_CHECK_SIZEOF([short])
AC_CHECK_SIZEOF([int])
if test x"$ac_cv_sizeof_char" != x"1" -o \
x"$ac_cv_sizeof_short" != x"2" -o \
x"$ac_cv_sizeof_int" != x"4"; then
AC_MSG_ERROR([can not build a default inttypes.h])
fi
cat >$1/inttypes.h << EOF
/* default inttypes.h for people who do not have it on their system */
#ifndef _INTTYPES_H
#define _INTTYPES_H
/* default inttypes.h for people who do not have it on their system */
#if (!defined __int8_t_defined) && (!defined __BIT_TYPES_DEFINED__)
#define __int8_t_defined
typedef signed char int8_t;
...
...
@@ -62,12 +67,3 @@ typedef unsigned long long uint64_t;
#endif
EOF
])])
dnl AC_COMPILE_CHECK_SIZEOF (TYPE SUPPOSED-SIZE)
dnl abort if the given type does not have the supposed size
AC_DEFUN([AC_COMPILE_CHECK_SIZEOF],
[AC_MSG_CHECKING(that size of $1 is $2)
AC_TRY_COMPILE([],[switch (0) case 0: case (sizeof ($1) == $2):;],[],
[AC_MSG_ERROR([can not build a default inttypes.h])])
AC_MSG_RESULT([yes])])
mpeg2dec/configure.in
View file @
4d0f1807
...
...
@@ -57,7 +57,7 @@ if test x"$GCC" = x"yes"; then
elif test x"$CC" = x"tcc" -a x"`$CC -version 2>&1 | grep TenDRA`" != x""; then
dnl TenDRA portability checking compiler
TENDRA=yes
CFLAGS="-Xp -Yansi -f`pwd`/include/tendra.h"
CFLAGS="-Xp -Yansi -f`pwd`/include/tendra.h
-DELIDE_CODE
"
enable_mlib=no
no_x=yes
enable_sdl=no
...
...
@@ -83,7 +83,7 @@ dnl Checks for libraries.
dnl Checks for header files.
INCLUDES='-I$(top_srcdir)/include -I$(top_builddir)/include'
AC_SUBST([INCLUDES])
AC_CHECK_HEADERS([
string.h
sys/time.h])
AC_CHECK_HEADERS([sys/time.h])
AC_CHECK_GENERATE_INTTYPES([include])
dnl Checks for typedefs, structures, and compiler characteristics.
...
...
mpeg2dec/include/Makefile.am
View file @
4d0f1807
pkginclude_HEADERS
=
mpeg2.h video_out.h mm_accel.h mmx.h attributes.h
EXTRA_DIST
=
tendra.h
mpeg2dec/libvo/yuv2rgb_mmx.c
View file @
4d0f1807
...
...
@@ -50,14 +50,14 @@ do { \
static
inline
void
mmx_yuv2rgb
(
uint8_t
*
py
,
uint8_t
*
pu
,
uint8_t
*
pv
)
{
static
mmx_t
mmx_80w
=
{
0x0080008000800080
};
static
mmx_t
mmx_U_green
=
{
0xf37df37df37df37d
};
static
mmx_t
mmx_U_blue
=
{
0x4093409340934093
};
static
mmx_t
mmx_V_red
=
{
0x3312331233123312
};
static
mmx_t
mmx_V_green
=
{
0xe5fce5fce5fce5fc
};
static
mmx_t
mmx_10w
=
{
0x1010101010101010
};
static
mmx_t
mmx_00ffw
=
{
0x00ff00ff00ff00ff
};
static
mmx_t
mmx_Y_coeff
=
{
0x253f253f253f253f
};
static
mmx_t
mmx_80w
=
{
0x0080008000800080
LL
};
static
mmx_t
mmx_U_green
=
{
0xf37df37df37df37d
LL
};
static
mmx_t
mmx_U_blue
=
{
0x4093409340934093
LL
};
static
mmx_t
mmx_V_red
=
{
0x3312331233123312
LL
};
static
mmx_t
mmx_V_green
=
{
0xe5fce5fce5fce5fc
LL
};
static
mmx_t
mmx_10w
=
{
0x1010101010101010
LL
};
static
mmx_t
mmx_00ffw
=
{
0x00ff00ff00ff00ff
LL
};
static
mmx_t
mmx_Y_coeff
=
{
0x253f253f253f253f
LL
};
movd_m2r
(
*
pu
,
mm0
);
// mm0 = 00 00 00 00 u3 u2 u1 u0
movd_m2r
(
*
pv
,
mm1
);
// mm1 = 00 00 00 00 v3 v2 v1 v0
...
...
@@ -126,9 +126,9 @@ static inline void mmx_yuv2rgb (uint8_t * py, uint8_t * pu, uint8_t * pv)
static
inline
void
mmx_unpack_16rgb
(
uint8_t
*
image
,
int
cpu
)
{
static
mmx_t
mmx_bluemask
=
{
0xf8f8f8f8f8f8f8f8
};
static
mmx_t
mmx_greenmask
=
{
0xfcfcfcfcfcfcfcfc
};
static
mmx_t
mmx_redmask
=
{
0xf8f8f8f8f8f8f8f8
};
static
mmx_t
mmx_bluemask
=
{
0xf8f8f8f8f8f8f8f8
LL
};
static
mmx_t
mmx_greenmask
=
{
0xfcfcfcfcfcfcfcfc
LL
};
static
mmx_t
mmx_redmask
=
{
0xf8f8f8f8f8f8f8f8
LL
};
/*
* convert RGB plane to RGB 16 bits
...
...
mpeg2dec/test/Makefile.am
View file @
4d0f1807
EXTRA_DIST
=
regression tests tek-525 tek-625
TESTS
=
regression
EXTRA_DIST
=
regression tests tek-525 tek-625
compile
TESTS
=
regression
compile
mpeg2dec/test/compile
0 → 100755
View file @
4d0f1807
#!/bin/sh
if
test
x
"
$srcdir
"
!=
x
""
;
then
builddir
=
"."
# running from make check, but it does not define that
else
srcdir
=
`
echo
"
$0
"
|
sed
s,[^/]
*
$,
,
`
test
"
$srcdir
"
=
"
$0
"
&&
srcdir
=
.
test
-z
"
$srcdir
"
&&
srcdir
=
.
builddir
=
"
$srcdir
"
# running manually, have to assume
fi
srcdir
=
`
cd
$srcdir
;
pwd
`
builddir
=
`
cd
$builddir
;
pwd
`
basedir
=
".."
cd
$srcdir
;
if
[
!
-d
$basedir
-o
!
-f
$basedir
/src/mpeg2dec.c
-o
\
!
-f
$basedir
/mpeg2dec-
*
.tar.gz
]
;
then
cd
..
;
if
[
!
-d
$basedir
-o
!
-f
$basedir
/src/mpeg2dec.c
-o
\
!
-f
$basedir
/mpeg2dec-
*
.tar.gz
]
;
then
exit
77
;
fi
fi
basedir
=
`
cd
$basedir
;
pwd
`
cd
$builddir
rm
-fr
compile_test
for
compiler
in
gcc gcc272 gcc-3.0 cc tcc
;
do
compiler_path
=
`
which
$compiler
`
;
if
test
x
"
$compiler_path
"
=
x
""
;
then continue
;
fi
compiler_inode
=
`
ls
-Li
$compiler_path
|awk
'{print $1}'
`
duplicate
=
0
;
for
inode
in
$inodes
;
do
if
test
x
"
$compiler_inode
"
=
x
"
$inode
"
;
then
duplicate
=
1
;
fi
done
;
if
test
x
"
$duplicate
"
=
x
"1"
;
then continue
;
fi
inodes
=
"
$inodes
$compiler_inode
"
mkdir
compile_test
cd
compile_test
;
tar
xzpf
$basedir
/mpeg2dec-
*
.tar.gz
;
cd
mpeg2dec-
*
error
=
1
CC
=
$compiler
./configure
&&
make
&&
error
=
0
if
test
x
"
$error
"
!=
x
"0"
;
then
exit
1
;
fi
cd
../..
rm
-fr
compile_test
done
exit
0
mpeg2dec/vc++/config.h
View file @
4d0f1807
...
...
@@ -72,6 +72,15 @@
/* Define as the return type of signal handlers (`int' or `void'). */
/* #undef RETSIGTYPE */
/* The size of a `char', as computed by sizeof. */
#define SIZEOF_CHAR 1
/* The size of a `int', as computed by sizeof. */
#define SIZEOF_INT 4
/* The size of a `short', as computed by sizeof. */
#define SIZEOF_SHORT 2
/* Define if you have the ANSI C header files. */
#define STDC_HEADERS 1
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment