Commit e12fcb5c authored by Aaron Holtzman's avatar Aaron Holtzman
Browse files

Split libvo and libmpeg2 configure stuff into their respective

sub-directories. This minimizes configure code duplication
between oms/mpeg2dec.

Now for some cvsroot hacking.

aaron
parent 76638780
......@@ -210,7 +210,12 @@ NONE) lt_target="$host" ;;
esac
# Check for any special flags to pass to ltconfig.
libtool_flags="--cache-file=$cache_file"
#
# the following will cause an existing older ltconfig to fail, so
# we ignore this at the expense of the cache file... Checking this
# will just take longer ... bummer!
#libtool_flags="--cache-file=$cache_file"
#
test "$enable_shared" = no && libtool_flags="$libtool_flags --disable-shared"
test "$enable_static" = no && libtool_flags="$libtool_flags --disable-static"
test "$enable_fast_install" = no && libtool_flags="$libtool_flags --disable-fast-install"
......
......@@ -21,102 +21,7 @@ AM_PROG_LIBTOOL
AC_SUBST(GLOBAL_CFLAGS)
AC_SUBST(ROOT_CFLAGS)
AC_SUBST(LIBMPEG2_CFLAGS)
AC_SUBST(LIBMPEG2_CONFIG_OBJS)
AC_SUBST(TOOLS_CFLAGS)
AC_SUBST(LIBVO_CFLAGS)
AC_SUBST(LIBVO_CONFIG_LIBS)
AC_SUBST(LIBVO_CONFIG_OBJS)
dnl
dnl Display driver probing...
dnl
AC_ARG_ENABLE(3dfx,
[ --enable-3dfx make a version using experimental 3dfx driver],
enable_3dfx=yes, enable_3dfx=no)
if test x$enable_3dfx = xyes; then
AC_DEFINE(HAVE_3DFX)
AC_MSG_CHECKING(for /dev/3dfx)
if test -c "/dev/3dfx"; then
AC_MSG_RESULT(found)
X_LIBS="$X_LIBS -lXxf86dga"
else
AC_MSG_RESULT(not found)
fi
fi
AC_ARG_ENABLE(mga,
[ --disable-mga make a version not using MGA],
enable_mga=no, enable_mga=yes)
if test x$enable_mga = xyes; then
AC_DEFINE(HAVE_MGA)
AM_CONDITIONAL(HAVE_MGA,true)
AC_MSG_CHECKING(for /dev/mga_vid)
if test -c "/dev/mga_vid"; then
AC_MSG_RESULT(found)
else
AC_MSG_RESULT(not found)
AC_MSG_WARN("to create /dev/mga_vid - use mknod /dev/mga_vid c 178 0")
fi
else
AM_CONDITIONAL(HAVE_MGA,false)
fi
AC_ARG_ENABLE(gatos,
[ --enable-gatos make a version using GATOS],
enable_gatos=yes, enable_gatos=no)
if test "x$LIBVO_CONFIG_OBJS" = x -a x$enable_gatos = xyes; then
AC_CHECK_LIB(gatos, main, [ LIBVO_CONFIG_OBJS=video_out_gatos.o
LIBS="$LIBS -lgatos" ], , -L/usr/X11R6/lib -L/usr/lib -L/usr/local/lib)
fi
AC_ARG_ENABLE(xil, [ --disable-xil make a version not using XIL],
enable_xil=no, enable_xil=yes)
if test "x$LIBVO_CONFIG_OBJS" = x -a x$enable_xil = xyes; then
AC_CHECK_LIB(xil, main, [ LIBVO_CONFIG_OBJS="video_out_xil.o yuv2rgb.o"
LIBS="$LIBS -lxil" ])
fi
dnl SDL option added by Ryan C. Gordon 04/23/2000
dnl !!! This really needs to check the SDL version.
dnl !!! I think we're using SDL 1.1 features, so 1.0 won't cut it.
AC_ARG_ENABLE(sdl, [ --enable-sdl make a version using SDL],
enable_sdl=yes, enable_sdl=no)
if test "x$enable_sdl" = xyes; then
AC_CHECK_PROG(SDLCONFIG, sdl-config, yes)
if test "x$SDLCONFIG" = xyes; then
AC_DEFINE(HAVE_SDL)
LIBVO_CFLAGS="$LIBVO_CFLAGS `sdl-config --cflags`"
LIBVO_CONFIG_LIBS="$LIBVO_CONFIG_LIBS `sdl-config --libs`"
else
AC_MSG_ERROR(["--enable-sdl" specified, but sdl-config isn't in your path!])
fi
fi
dnl FIXME check for X actually existing
AC_DEFINE(HAVE_X11)
dnl Checks for libraries. (X11)
AC_PATH_XTRA
AC_CHECK_LIB(Xv, XvShmCreateImage,
X_LIBS="$X_LIBS -lXv"
AC_DEFINE(HAVE_XV),,
$X_LIBS $X_PRE_LIBS -lXext -lX11 $X_EXTRA_LIBS)
dnl There must be a better way to check for SMP....
AC_MSG_CHECKING(for SMP)
AC_SUBST(MOD_CFLAGS)
if uname -a | grep SMP >/dev/null; then
AC_MSG_RESULT(yes)
MOD_CFLAGS=-D__SMP__
else
AC_MSG_RESULT(no)
fi
dnl Figure out which OS we're on and what to do about it
case "$host" in
......@@ -129,8 +34,6 @@ dnl Set the appropriate architecture define
case "$host_alias" in
i?86-* | k?-*) dnl catch i386,i486,i586,i686,k6,k7
AC_DEFINE(__i386__)
LIBMPEG2_CONFIG_OBJS="idct_mmx.lo idct_block_mmx.lo motion_comp_mmx.lo"
LIBVO_CONFIG_OBJS="yuv2rgb_mmx.lo"
case "$host_alias" in
i386-*) dnl who are we kidding?
GLOBAL_CFLAGS="$GLOBAL_CFLAGS -march=m386";;
......@@ -162,4 +65,7 @@ AC_ARG_WITH(kernel-headers,
[KERNEL_INCLUDES=/usr/src/linux/include])
AC_SUBST(KERNEL_INCLUDES)
builtin(include,libmpeg2/configure.incl)
builtin(include,libvo/configure.incl)
AC_OUTPUT( libvo/Makefile libmpeg2/Makefile tools/Makefile drivers/Makefile Makefile )
......@@ -14,5 +14,5 @@ libmpeg2_la_SOURCES = getvlc.c slice.c header.c stats.c idct.c motion_comp.c\
EXTRA_libmpeg2_la_SOURCES = idct_mmx.c idct_block_mmx.S idct_mlib.c\
motion_comp_mmx.c motion_comp_mlib.c
noinst_HEADERS = mpeg2.h getvlc.h stats.h header.h slice.h motion_comp.h
noinst_HEADERS = mpeg2.h getvlc.h stats.h header.h slice.h motion_comp.h\
mpeg2_internal.h idct.h debug.h bitstream.h idct_mmx.h idct_mlib.h mmx.h
AC_SUBST(LIBMPEG2_CFLAGS)
AC_SUBST(LIBMPEG2_CONFIG_OBJS)
dnl Do the right thing for architecture specific goodness
case "$host_alias" in
i?86-* | k?-*) dnl catch i386,i486,i586,i686,k6,k7
LIBMPEG2_CONFIG_OBJS="idct_mmx.lo idct_block_mmx.lo motion_comp_mmx.lo";;
alpha*-*) ;;
sparc-*) ;;
ppc-*) ;;
esac
......@@ -6,7 +6,7 @@ CFLAGS = -g -O3 -Wall -Werror @LIBVO_CFLAGS@ @GLOBAL_CFLAGS@ @X_CFLAGS@
lib_LTLIBRARIES = libvo.la
include_HEADER = video_out.h
include_HEADERS = video_out.h
libvo_la_LIBADD = @LIBVO_CONFIG_OBJS@ @LIBVO_CONFIG_LIBS@ @X_PRE_LIBS@ @X_LIBS@ -lXext
libvo_la_DEPENDENCIES = @LIBVO_CONFIG_OBJS@
......
AC_SUBST(LIBVO_CFLAGS)
AC_SUBST(LIBVO_CONFIG_LIBS)
AC_SUBST(LIBVO_CONFIG_OBJS)
dnl
dnl Display driver probing...
dnl
AC_ARG_ENABLE(3dfx,
[ --enable-3dfx make a version using experimental 3dfx driver],
enable_3dfx=yes, enable_3dfx=no)
if test x$enable_3dfx = xyes; then
AC_DEFINE(HAVE_3DFX)
AC_MSG_CHECKING(for /dev/3dfx)
if test -c "/dev/3dfx"; then
AC_MSG_RESULT(found)
X_LIBS="$X_LIBS -lXxf86dga"
else
AC_MSG_RESULT(not found)
fi
fi
AC_ARG_ENABLE(mga,
[ --disable-mga make a version not using MGA],
enable_mga=no, enable_mga=yes)
if test x$enable_mga = xyes; then
AC_DEFINE(HAVE_MGA)
AM_CONDITIONAL(HAVE_MGA,true)
AC_MSG_CHECKING(for /dev/mga_vid)
if test -c "/dev/mga_vid"; then
AC_MSG_RESULT(found)
else
AC_MSG_RESULT(not found)
AC_MSG_WARN("to create /dev/mga_vid - use mknod /dev/mga_vid c 178 0")
fi
else
AM_CONDITIONAL(HAVE_MGA,false)
fi
AC_ARG_ENABLE(gatos,
[ --enable-gatos make a version using GATOS],
enable_gatos=yes, enable_gatos=no)
if test "x$LIBVO_CONFIG_OBJS" = x -a x$enable_gatos = xyes; then
AC_CHECK_LIB(gatos, main, [ LIBVO_CONFIG_OBJS=video_out_gatos.o
LIBS="$LIBS -lgatos" ], , -L/usr/X11R6/lib -L/usr/lib -L/usr/local/lib)
fi
AC_ARG_ENABLE(xil, [ --disable-xil make a version not using XIL],
enable_xil=no, enable_xil=yes)
if test "x$LIBVO_CONFIG_OBJS" = x -a x$enable_xil = xyes; then
AC_CHECK_LIB(xil, main, [ LIBVO_CONFIG_OBJS="video_out_xil.o yuv2rgb.o"
LIBS="$LIBS -lxil" ])
fi
dnl SDL option added by Ryan C. Gordon 04/23/2000
dnl !!! This really needs to check the SDL version.
dnl !!! I think we're using SDL 1.1 features, so 1.0 won't cut it.
AC_ARG_ENABLE(sdl, [ --enable-sdl make a version using SDL],
enable_sdl=yes, enable_sdl=no)
if test "x$enable_sdl" = xyes; then
AC_CHECK_PROG(SDLCONFIG, sdl-config, yes)
if test "x$SDLCONFIG" = xyes; then
AC_DEFINE(HAVE_SDL)
LIBVO_CFLAGS="$LIBVO_CFLAGS `sdl-config --cflags`"
LIBVO_CONFIG_LIBS="$LIBVO_CONFIG_LIBS `sdl-config --libs`"
else
AC_MSG_ERROR(["--enable-sdl" specified, but sdl-config isn't in your path!])
fi
fi
dnl FIXME check for X actually existing
AC_DEFINE(HAVE_X11)
dnl Checks for libraries. (X11)
AC_PATH_XTRA
AC_CHECK_LIB(Xv, XvShmCreateImage,
X_LIBS="$X_LIBS -lXv"
AC_DEFINE(HAVE_XV),,
$X_LIBS $X_PRE_LIBS -lXext -lX11 $X_EXTRA_LIBS)
dnl There must be a better way to check for SMP....
AC_MSG_CHECKING(for SMP)
AC_SUBST(MOD_CFLAGS)
if uname -a | grep SMP >/dev/null; then
AC_MSG_RESULT(yes)
MOD_CFLAGS=-D__SMP__
else
AC_MSG_RESULT(no)
fi
dnl Do the right thing for architecture specific goodness
case "$host_alias" in
i?86-* | k?-*) dnl catch i386,i486,i586,i686,k6,k7
LIBVO_CONFIG_OBJS="yuv2rgb_mmx.lo" ;;
alpha*-*) ;;
sparc-*) ;;
ppc-*) ;;
esac
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment