Use dynamic by default.

FFmpeg and Python does not require explicit --enable.
This commit is contained in:
Themaister 2011-11-02 16:50:34 +01:00
parent 34b5994842
commit 90febc4ecf
2 changed files with 22 additions and 10 deletions

View File

@ -12,18 +12,25 @@ if [ -d /opt/local/lib ]; then
add_library_dirs /opt/local/lib
fi
if [ "$OS" = BSD ]; then
if [ $OS = BSD ]; then
DYLIB=-lc
else
DYLIB=-ldl
fi
if [ "$HAVE_DYNAMIC" = "yes" ] && [ "$HAVE_CONFIGFILE" = "no" ]; then
if [ $HAVE_DYNAMIC = yes ] && [ $HAVE_CONFIGFILE = no ]; then
echo "Cannot have dynamic loading of libsnes and no configfile support."
echo "Dynamic loading requires config file support."
exit 1
fi
if [ -z "$LIBSNES" ]; then
LIBSNES="-lsnes"
else
echo "Explicit libsnes used, disabling dynamic libsnes loading ..."
HAVE_DYNAMIC=no
fi
if [ $HAVE_DYNAMIC != yes ]; then
check_lib_cxx SNES $LIBSNES snes_init $DYLIB
check_critical SNES "Cannot find libsnes."
@ -33,18 +40,23 @@ fi
check_lib DYLIB $DYLIB dlopen
check_lib NETPLAY -lc socket
if [ $HAVE_DYLIB = no ] && [ $HAVE_DYNAMIC = yes ]; then
echo "Dynamic loading of libsnes is enabled, but your platform does not appear to have dlopen(), use --disable-dynamic or --with-libsnes=\"-lsnes\"".
exit 1
fi
check_pkgconf ALSA alsa
check_header OSS sys/soundcard.h
check_header OSS_BSD soundcard.h
check_lib OSS_LIB -lossaudio
if [ "$OS" = "Darwin" ]; then
if [ $OS = Darwin ]; then
check_lib AL "-framework OpenAL" alcOpenDevice
else
check_lib AL -lopenal alcOpenDevice
fi
if [ "$OS" = "Darwin" ]; then
if [ $OS = Darwin ]; then
check_lib FBO "-framework OpenGL" glFramebufferTexture2D
else
check_lib FBO -lGL glFramebufferTexture2D
@ -64,7 +76,7 @@ check_critical SDL "Cannot find SDL library."
if [ $HAVE_OPENGL != no ]; then
check_lib_cxx CG -lCg cgCreateContext
else
echo "Ignoring Cg, as OpenGL is not compiled in ..."
echo "Ignoring Cg. OpenGL is not enabled."
HAVE_CG=no
fi
@ -93,7 +105,7 @@ check_lib DYNAMIC $DYLIB dlopen
check_pkgconf FREETYPE freetype2
check_pkgconf X11 x11
check_pkgconf XEXT xext
if [ "$HAVE_X11" = "yes" ] && [ "$HAVE_XEXT" = "yes" ]; then
if [ $HAVE_X11 = yes ] && [ $HAVE_XEXT = yes ]; then
check_pkgconf XVIDEO xv
else
echo "X11 or Xext not present. Skipping XVideo."

View File

@ -7,9 +7,9 @@ PACKAGE_VERSION=0.9.1
# $1: Variable (HAVE_ALSA, HAVE_OSS, etc)
# $2: Comment
# $3: Default arg. auto implies that HAVE_ALSA will be set according to library checks later on.
add_command_line_enable DYNAMIC "Enable dynamic loading of libsnes library" no
add_command_line_string LIBSNES "libsnes library used" "-lsnes"
add_command_line_enable FFMPEG "Enable FFmpeg recording support" no
add_command_line_enable DYNAMIC "Disable dynamic loading of libsnes library" yes
add_command_line_string LIBSNES "libsnes library used" ""
add_command_line_enable FFMPEG "Enable FFmpeg recording support" auto
add_command_line_enable X264RGB "Enable lossless X264 RGB recording" no
add_command_line_enable DYLIB "Enable dynamic loading support" auto
add_command_line_enable NETPLAY "Enable netplay support" auto
@ -29,4 +29,4 @@ add_command_line_enable PULSE "Enable PulseAudio support" auto
add_command_line_enable FREETYPE "Enable FreeType support" auto
add_command_line_enable XVIDEO "Enable XVideo support" auto
add_command_line_enable SDL_IMAGE "Enable SDL_image support" auto
add_command_line_enable PYTHON "Enable Python 3 support for shaders" no
add_command_line_enable PYTHON "Enable Python 3 support for shaders" auto