⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 configure.in

📁 MPEG-4编解码的实现(包括MPEG4视音频编解码)
💻 IN
📖 第 1 页 / 共 5 页
字号:
dnl Process this file with autoconf to produce a configure script.
AC_INIT(README)

dnl Set various version strings - taken gratefully from the GTk sources
#
# Making releases:
# Edit include/SDL/SDL_version.h and change the version, then:
#   SDL_MICRO_VERSION += 1;
#   SDL_INTERFACE_AGE += 1;
#   SDL_BINARY_AGE += 1;
# if any functions have been added, set SDL_INTERFACE_AGE to 0.
# if backwards compatibility has been broken,
# set SDL_BINARY_AGE and SDL_INTERFACE_AGE to 0.
#
SDL_MAJOR_VERSION=1
SDL_MINOR_VERSION=2
SDL_MICRO_VERSION=4
SDL_INTERFACE_AGE=4
SDL_BINARY_AGE=4
SDL_VERSION=$SDL_MAJOR_VERSION.$SDL_MINOR_VERSION.$SDL_MICRO_VERSION

AC_SUBST(SDL_MAJOR_VERSION)
AC_SUBST(SDL_MINOR_VERSION)
AC_SUBST(SDL_MICRO_VERSION)
AC_SUBST(SDL_INTERFACE_AGE)
AC_SUBST(SDL_BINARY_AGE)
AC_SUBST(SDL_VERSION)

# libtool versioning
LT_RELEASE=$SDL_MAJOR_VERSION.$SDL_MINOR_VERSION
LT_CURRENT=`expr $SDL_MICRO_VERSION - $SDL_INTERFACE_AGE`
LT_REVISION=$SDL_INTERFACE_AGE
LT_AGE=`expr $SDL_BINARY_AGE - $SDL_INTERFACE_AGE`

AC_SUBST(LT_RELEASE)
AC_SUBST(LT_CURRENT)
AC_SUBST(LT_REVISION)
AC_SUBST(LT_AGE)

dnl Detect the canonical host and target build environment
AC_CANONICAL_HOST
AC_CANONICAL_TARGET

dnl Setup for automake
AM_INIT_AUTOMAKE(SDL, $SDL_VERSION)

dnl Check for tools

AC_LIBTOOL_WIN32_DLL
AM_PROG_LIBTOOL
AC_PROG_MAKE_SET
AC_PROG_CC
AC_C_INLINE
AC_C_CONST
OBJC="???"
AC_SUBST(OBJC)
AC_PROG_CXX
AC_PROG_INSTALL
AC_FUNC_ALLOCA
ASFLAGS=""
AC_SUBST(ASFLAGS)
CCAS=gcc
AC_SUBST(CCAS)
CCASFLAGS=""
AC_SUBST(CCASFLAGS)
AM_CONDITIONAL(USE_DIRECTX, false)

dnl The alpha architecture needs special flags for binary portability
case "$target" in
    alpha*-*-linux*)
        if test x$ac_cv_prog_gcc = xyes; then
            CFLAGS="$CFLAGS -mcpu=ev4 -Wa,-mall"
        fi
        ;;
esac

dnl Add compiler-specific optimization flags

dnl See if the user wants aggressive optimizations of the code
AC_ARG_ENABLE(debug,
[  --enable-debug          Disable aggressive optimizations [default=yes]],
              , enable_debug=yes)
if test x$enable_debug != xyes; then
    if test x$ac_cv_prog_gcc = xyes; then
        CFLAGS="$CFLAGS -fexpensive-optimizations"
        # Ack! This breaks the MMX YV12 conversion on gcc 2.95.2
        # CFLAGS="$CFLAGS -fomit-frame-pointer"
    fi
    case "$target" in
        i486-*-*)
            if test x$ac_cv_prog_gcc = xyes; then
                CFLAGS="$CFLAGS -march=486"
            fi
            ;;
        i?86-*-*)
            if test x$ac_cv_prog_gcc = xyes; then
                CFLAGS="$CFLAGS -march=pentium -mcpu=pentiumpro"
            fi
            ;;
        *-*-osf*)
            if test x$ac_cv_prog_gcc != xyes; then
                CFLAGS="-g3 -fast -arch host"
            fi
            ;;
    esac
fi

dnl Add verbose warnings by default, and allow ANSI compliance checking
AC_ARG_ENABLE(strict-ansi,
[  --enable-strict-ansi    Enable strict ANSI compliance build [default=no]],
              , enable_strict_ansi=no)
if test x$ac_cv_prog_gcc = xyes; then
    CFLAGS="$CFLAGS -Wall"
    if test x$enable_strict_ansi = xyes; then
        CFLAGS="$CFLAGS -ansi -pedantic -D_XOPEN_SOURCE"
    fi
fi

dnl Initialize the compiler and linker flags for SDL applications

SDL_CFLAGS=""
SDL_LIBS="-lSDL"

dnl Add the math library for the new gamma correction support

case "$target" in
    *-*-cygwin* | *-*-mingw32*)
        MATHLIB=""
        ;;
    *-*-beos*)
        MATHLIB=""
        ;;
    *-*-darwin*)
        MATHLIB=""
        ;;
    *)
        MATHLIB="-lm"
        ;;
esac
SYSTEM_LIBS="$SYSTEM_LIBS $MATHLIB"

dnl Enable/disable various subsystems of the SDL library

AC_ARG_ENABLE(audio,
[  --enable-audio          Enable the audio subsystem [default=yes]],
              , enable_audio=yes)
if test x$enable_audio = xyes; then
    SDL_EXTRADIRS="$SDL_EXTRADIRS audio"
    SDL_EXTRALIBS="$SDL_EXTRALIBS audio/libaudio.la"
else
    CFLAGS="$CFLAGS -DDISABLE_AUDIO"
fi
AC_ARG_ENABLE(video,
[  --enable-video          Enable the video subsystem [default=yes]],
              , enable_video=yes)
if test x$enable_video = xyes; then
    SDL_EXTRADIRS="$SDL_EXTRADIRS video"
    SDL_EXTRALIBS="$SDL_EXTRALIBS video/libvideo.la"
else
    CFLAGS="$CFLAGS -DDISABLE_VIDEO"
fi
AC_ARG_ENABLE(events,
[  --enable-events         Enable the events subsystem [default=yes]],
              , enable_events=yes)
if test x$enable_video = xyes -a x$enable_events = xyes; then
    SDL_EXTRADIRS="$SDL_EXTRADIRS events"
    SDL_EXTRALIBS="$SDL_EXTRALIBS events/libevents.la"
else
    CFLAGS="$CFLAGS -DDISABLE_EVENTS"
fi
AC_ARG_ENABLE(joystick,
[  --enable-joystick       Enable the joystick subsystem [default=yes]],
              , enable_joystick=yes)
if test x$enable_joystick = xyes; then
    SDL_EXTRADIRS="$SDL_EXTRADIRS joystick"
    SDL_EXTRALIBS="$SDL_EXTRALIBS joystick/libjoystick.la"
else
    CFLAGS="$CFLAGS -DDISABLE_JOYSTICK"
fi
AC_ARG_ENABLE(cdrom,
[  --enable-cdrom          Enable the cdrom subsystem [default=yes]],
              , enable_cdrom=yes)
if test x$enable_cdrom = xyes; then
    SDL_EXTRADIRS="$SDL_EXTRADIRS cdrom"
    SDL_EXTRALIBS="$SDL_EXTRALIBS cdrom/libcdrom.la"
else
    CFLAGS="$CFLAGS -DDISABLE_CDROM"
fi
AC_ARG_ENABLE(threads,
[  --enable-threads        Enable the threading subsystem [default=yes]],
              , enable_threads=yes)
SDL_EXTRADIRS="$SDL_EXTRADIRS thread"
SDL_EXTRALIBS="$SDL_EXTRALIBS thread/libthread.la"
if test x$enable_threads != xyes; then
    CFLAGS="$CFLAGS -DDISABLE_THREADS"
    COPY_ARCH_SRC(src/thread, generic, SDL_systhread.c)
    COPY_ARCH_SRC(src/thread, generic, SDL_systhread_c.h)
    COPY_ARCH_SRC(src/thread, generic, SDL_sysmutex.c)
    COPY_ARCH_SRC(src/thread, generic, SDL_sysmutex_c.h)
    COPY_ARCH_SRC(src/thread, generic, SDL_syssem.c)
    COPY_ARCH_SRC(src/thread, generic, SDL_syssem_c.h)
    COPY_ARCH_SRC(src/thread, generic, SDL_syscond.c)
    COPY_ARCH_SRC(src/thread, generic, SDL_syscond_c.h)
fi
AC_ARG_ENABLE(timers,
[  --enable-timers         Enable the timer subsystem [default=yes]],
              , enable_timers=yes)
if test x$enable_timers = xyes; then
    SDL_EXTRADIRS="$SDL_EXTRADIRS timer"
    SDL_EXTRALIBS="$SDL_EXTRALIBS timer/libtimer.la"
else
    CFLAGS="$CFLAGS -DDISABLE_TIMERS"
fi
AC_ARG_ENABLE(endian,
[  --enable-endian         Enable the endian subsystem [default=yes]],
              , enable_endian=yes)
if test x$enable_endian = xyes; then
    SDL_EXTRADIRS="$SDL_EXTRADIRS endian"
    SDL_EXTRALIBS="$SDL_EXTRALIBS endian/libendian.la"
else
    CFLAGS="$CFLAGS -DDISABLE_ENDIAN"
fi
AC_ARG_ENABLE(file,
[  --enable-file           Enable the file subsystem [default=yes]],
              , enable_file=yes)
if test x$enable_file = xyes; then
    SDL_EXTRADIRS="$SDL_EXTRADIRS file"
    SDL_EXTRALIBS="$SDL_EXTRALIBS file/libfile.la"
else
    CFLAGS="$CFLAGS -DDISABLE_FILE"
fi

dnl See if the OSS audio interface is supported
CheckOSS()
{
    AC_ARG_ENABLE(oss,
[  --enable-oss            support the OSS audio API [default=yes]],
                  , enable_oss=yes)
    if test x$enable_audio = xyes -a x$enable_oss = xyes; then
        AC_MSG_CHECKING(for OSS audio support)
        have_oss=no
        if test x$have_oss != xyes; then
            AC_TRY_COMPILE([
              #include <sys/soundcard.h>
            ],[
              int arg = SNDCTL_DSP_SETFRAGMENT;
            ],[
            have_oss=yes
            ])
        fi
        if test x$have_oss != xyes; then
            AC_TRY_COMPILE([
              #include <soundcard.h>
            ],[
              int arg = SNDCTL_DSP_SETFRAGMENT;
            ],[
            have_oss=yes
            CFLAGS="$CFLAGS -DOSS_USE_SOUNDCARD_H"
            ])
        fi
        AC_MSG_RESULT($have_oss)
        if test x$have_oss = xyes; then
            CFLAGS="$CFLAGS -DOSS_SUPPORT"
            AUDIO_SUBDIRS="$AUDIO_SUBDIRS dsp"
            AUDIO_DRIVERS="$AUDIO_DRIVERS dsp/libaudio_dsp.la"
            AUDIO_SUBDIRS="$AUDIO_SUBDIRS dma"
            AUDIO_DRIVERS="$AUDIO_DRIVERS dma/libaudio_dma.la"
        fi
    fi
}

dnl See if the ALSA audio interface is supported
CheckALSA()
{
    AC_ARG_ENABLE(alsa,
[  --enable-alsa           support the ALSA audio API [default=yes]],
                  , enable_alsa=yes)
    if test x$enable_audio = xyes -a x$enable_alsa = xyes; then
        have_alsa=no
        AC_CHECK_HEADER(sys/asoundlib.h, have_alsa_hdr=yes)
        AC_CHECK_LIB(asound, snd_pcm_open, have_alsa_lib=yes)
        if test x$have_alsa_hdr = xyes -a x$have_alsa_lib = xyes; then
            CFLAGS="$CFLAGS -DALSA_SUPPORT"
            SYSTEM_LIBS="$SYSTEM_LIBS -lasound"
            AUDIO_SUBDIRS="$AUDIO_SUBDIRS alsa"
            AUDIO_DRIVERS="$AUDIO_DRIVERS alsa/libaudio_alsa.la"
        fi
    fi
}

dnl Check whether we want to use OpenBSD native audio or not
CheckOPENBSDAUDIO()
{
    AC_ARG_ENABLE(openbsdaudio,
[  --enable-openbsdaudio   OpenBSD native audio support [default=yes]],
                  , enable_openbsdaudio=yes)
    if test x$enable_audio = xyes -a x$enable_openbsdaudio = xyes; then
        CFLAGS="$CFLAGS -DOPENBSD_AUDIO_SUPPORT"
        AUDIO_SUBDIRS="$AUDIO_SUBDIRS openbsd"
        AUDIO_DRIVERS="$AUDIO_DRIVERS openbsd/libaudio_openbsd.la"
    fi
}

dnl Check whether we want to use IRIX 6.5+ native audio or not
CheckDMEDIA()
{
    if test x$enable_audio = xyes; then
        AC_MSG_CHECKING(for dmedia audio support)
        have_dmedia=no
        AC_TRY_COMPILE([
          #include <dmedia/audio.h>
        ],[
          ALport audio_port;
        ],[
        have_dmedia=yes
        ])
        # Set up files for the audio library
        if test x$have_dmedia = xyes; then
            CFLAGS="$CFLAGS -DDMEDIA_SUPPORT"
            AUDIO_SUBDIRS="$AUDIO_SUBDIRS dmedia"
            AUDIO_DRIVERS="$AUDIO_DRIVERS dmedia/libaudio_dmedia.la"
            SYSTEM_LIBS="$SYSTEM_LIBS -laudio"
        fi
    fi
}

dnl Find the ESD includes and libraries
CheckESD()
{
    AC_ARG_ENABLE(esd,
[  --enable-esd            support the Enlightened Sound Daemon [default=yes]],
                  , enable_esd=yes)
    if test x$enable_audio = xyes -a x$enable_esd = xyes; then
	use_esd=no
        AM_PATH_ESD(0.2.8, use_esd=yes)
	if test x$use_esd = xyes; then
            AC_ARG_ENABLE(esd-shared,
[  --enable-esd-shared     dynamically load ESD audio support [default=no]],
                          , enable_esd_shared=no)
            esd_lib_spec=`echo $ESD_LIBS | sed 's/.*-L\([[^ ]]*\).*/\1\/libesd.so.*/'`
	    esd_lib=`ls $esd_lib_spec | head -1 | sed 's/.*\/\(.*\)/\1/'`
	    echo "-- $esd_lib_spec -> $esd_lib"
            if test x$enable_dlopen != xyes && \
               test x$enable_esd_shared = xyes; then
                AC_MSG_ERROR([You must have dlopen() support and use the --enable-dlopen option])
            fi
            if test x$enable_dlopen = xyes && \
               test x$enable_esd_shared = xyes && test x$esd_lib != x; then
                CFLAGS="$CFLAGS -DESD_SUPPORT -DESD_DYNAMIC=\$(esd_lib) $ESD_CFLAGS"
		AC_SUBST(esd_lib)
            else
                CFLAGS="$CFLAGS -DESD_SUPPORT $ESD_CFLAGS"
                SYSTEM_LIBS="$SYSTEM_LIBS $ESD_LIBS"
            fi
            AUDIO_SUBDIRS="$AUDIO_SUBDIRS esd"
            AUDIO_DRIVERS="$AUDIO_DRIVERS esd/libaudio_esd.la"
        fi
    fi
}

CheckARTSC()
{
    AC_ARG_ENABLE(arts,
[  --enable-arts           support the Analog Real Time Synthesizer [default=yes]],
                  , enable_arts=yes)
    if test x$enable_audio = xyes -a x$enable_arts = xyes; then
        AC_PATH_PROG(ARTSCCONFIG, artsc-config)
        if test x$ARTSCCONFIG = x -o x$ARTSCCONFIG = x'"$ARTSCCONFIG"'; then
            : # arts isn't installed
        else

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -