Newer
Older
[ --enable-xcb X11 support with XCB (default enabled)],, [
AS_IF([test "${SYS}" != "mingw32" -a "${SYS}" != "darwin"], [
enable_xcb="yes"
], [
enable_xcb="no"
])
])
AC_ARG_ENABLE(xvideo,
[ --enable-xvideo XVideo support (default enabled)],, [
enable_xvideo="$enable_xcb"
])
have_xcb_randr="no"
AS_IF([test "${enable_xcb}" != "no"], [
dnl libxcb
PKG_CHECK_MODULES(XCB, [xcb >= 1.6])
PKG_CHECK_MODULES(XCB_COMPOSITE, [xcb-composite])
AS_IF([test "${enable_xvideo}" != "no"], [
PKG_CHECK_MODULES(XCB_XV, [xcb-xv >= 1.1.90.1], [have_xcb_xvideo="yes"])
PKG_CHECK_MODULES(XCB_RANDR, [xcb-randr >= 1.3], [have_xcb_randr="yes"])
dnl xcb-utils
PKG_CHECK_MODULES(XCB_KEYSYMS, [xcb-keysyms >= 0.3.4], [have_xcb_keysyms="yes"], [
AC_MSG_WARN([${XCB_KEYSYMS_PKG_ERRORS}. Hotkeys will not work.])
AM_CONDITIONAL([HAVE_XCB], [test "${have_xcb}" = "yes"])
AM_CONDITIONAL([HAVE_XCB_KEYSYMS], [test "${have_xcb_keysyms}" = "yes"])
AM_CONDITIONAL([HAVE_XCB_RANDR], [test "${have_xcb_randr}" = "yes"])
AM_CONDITIONAL([HAVE_XCB_XVIDEO], [test "${have_xcb_xvideo}" = "yes"])
dnl VDPAU needs X11
dnl
AC_ARG_ENABLE(vdpau,
[AS_HELP_STRING([--enable-vdpau], [VDPAU hardware support (default auto)])])
AS_IF([test "${enable_vdpau}" != "no"], [
PKG_CHECK_MODULES([VDPAU], [vdpau >= 0.6], [
AS_IF([test "${no_x}" = "yes"], [
AC_MSG_ERROR([VDPAU requires Xlib (X11).])
])
], [
AS_IF([test -n "${enable_vdpau}"], [
AC_MSG_ERROR([${VDPAU_PKG_ERRORS}.])
])
])
])
AM_CONDITIONAL([HAVE_VDPAU], [test "${have_vdpau}" = "yes"])
have_avcodec_vdpau="no"
AS_IF([test "${have_vdpau}" = "yes" -a "${have_avcodec}" = "yes"], [
case "${avfork}" in
libav) av_vdpau_ver="55.26.0" ;;
ffmpeg) av_vdpau_ver="55.42.100" ;;
esac
PKG_CHECK_EXISTS([libavutil >= 52.4.0 libavcodec >= ${av_vdpau_ver}], [
have_avcodec_vdpau="yes"
AC_MSG_NOTICE([VDPAU decoding acceleration activated])
], [
AS_IF([test -n "${enable_vdpau}"], [
AC_MSG_ERROR([libav libavutil >= 52.4.0 and libavcodec >= 55.26.0 are required for VDPAU decoding.])
AC_MSG_WARN([libav libavutil >= 52.4.0 and libavcodec >= 55.26.0 are required for VDPAU decoding.])
])
])
])
AM_CONDITIONAL([HAVE_AVCODEC_VDPAU], [test "${have_avcodec_vdpau}" = "yes"])
dnl
dnl Wayland
dnl
AC_ARG_ENABLE(wayland,
[AS_HELP_STRING([--enable-wayland], [Wayland support (default auto)])])
have_wayland="no"
AC_ARG_VAR([WAYLAND_SCANNER], [Wayland scanner utility])
AS_IF([test "${enable_wayland}" != "no"], [
AC_MSG_CHECKING([for the Wayland scanner])
AS_IF([test -z "$WAYLAND_SCANNER"], [
PKG_CHECK_EXISTS([wayland-scanner], [
WAYLAND_SCANNER="$(${PKG_CONFIG} wayland-scanner --variable wayland_scanner)"
], [
WAYLAND_SCANNER="wayland-scanner"
])
])
AC_MSG_RESULT([$WAYLAND_SCANNER])
PKG_CHECK_MODULES([WAYLAND_CLIENT], [wayland-client >= 1.5.91], [
have_wayland="yes"
], [
AS_IF([test -n "${enable_wayland}"], [
AC_MSG_ERROR([${WAYLAND_CLIENT_PKG_ERRORS}.])
])
])
AS_IF([test "${have_egl}" = "yes"], [
PKG_CHECK_MODULES([WAYLAND_EGL], [wayland-egl], [
have_wayland_egl="yes"
], [
AS_IF([test -n "${enable_wayland}"], [
AC_MSG_ERROR([${WAYLAND_EGL_PKG_ERRORS}.])
])
])
])
])
AM_CONDITIONAL([HAVE_WAYLAND], [test "${have_wayland}" = "yes"])
AM_CONDITIONAL([HAVE_WAYLAND_EGL], [test "${have_wayland_egl}" = "yes"])
Christophe Mutricy
committed
AC_ARG_ENABLE(sdl-image,
[ --enable-sdl-image SDL image support (default enabled)])
PKG_CHECK_MODULES(SDL, [sdl >= 1.2.10], [
# SDL on Darwin is heavily patched and can only run SDL_image
if test "${SYS}" != "darwin"; then
# SDL_image
AS_IF([ test "${enable_sdl_image}" != "no"],[
PKG_CHECK_MODULES(SDL_IMAGE, [SDL_image >= 1.2.10], [
[ AC_MSG_WARN([${SDL_IMAGE_PKG_ERRORS}. You should install it alongside your SDL package.])
AC_MSG_WARN([${SDL_PKG_ERRORS}.])
dnl
dnl freetype module
dnl
AC_ARG_ENABLE(freetype,
[ --enable-freetype freetype support (default auto)])
[ --enable-fribidi fribidi support (default auto)])
AC_ARG_ENABLE(harfbuzz,
[ --enable-harfbuzz harfbuzz support (default auto)])
[ --enable-fontconfig fontconfig support (default auto)])
3162
3163
3164
3165
3166
3167
3168
3169
3170
3171
3172
3173
3174
3175
3176
3177
3178
3179
3180
3181
3182
3183
AC_ARG_WITH([default-font],
AS_HELP_STRING([--with-default-font=PATH],
[Path to the default font]),
[AC_DEFINE_UNQUOTED([DEFAULT_FONT_FILE],
"$withval", [Default font])])
AC_ARG_WITH([default-monospace-font],
AS_HELP_STRING([--with-default-monospace-font=PATH],
[Path to the default font]),
[AC_DEFINE_UNQUOTED([DEFAULT_MONOSPACE_FONT_FILE],
"$withval", [Default monospace font])])
AC_ARG_WITH([default-font-family],
AS_HELP_STRING([--with-default-font-family=NAME],
[Path to the default font family]),
[AC_DEFINE_UNQUOTED([DEFAULT_FAMILY],
"$withval", [Default font family])])
AC_ARG_WITH([default-monospace-font-family],
AS_HELP_STRING([--with-default-monospace-font-family=NAME],
[Path to the default font family]),
[AC_DEFINE_UNQUOTED([DEFAULT_MONOSPACE_FAMILY],
"$withval", [Default monospace font family])])
have_freetype="no"
have_fontconfig="no"
have_fribidi="no"
if test "${enable_freetype}" != "no"; then
PKG_CHECK_MODULES(FREETYPE, freetype2, [
have_freetype="yes"
VLC_ADD_CPPFLAGS([skins2],[${FREETYPE_CFLAGS}])
VLC_ADD_LIBS([skins2],[${FREETYPE_LIBS}])
dnl fontconfig support
if test "${SYS}" != "mingw32"; then
if test "${enable_fontconfig}" != "no"; then
AC_CHECK_HEADERS(fontconfig/fontconfig.h, [
],[AC_MSG_WARN([library fontconfig not found. Styles will be disabled in freetype])])
dnl fribidi support
if test "${enable_fribidi}" != "no"; then
PKG_CHECK_MODULES(FRIBIDI, fribidi, [
have_fribidi="yes"
VLC_ADD_CPPFLAGS([skins2], [${FRIBIDI_CFLAGS} -DHAVE_FRIBIDI])
VLC_ADD_LIBS([skins2], [${FRIBIDI_LIBS}])
],[AC_MSG_WARN([${FRIBIDI_PKG_ERRORS}. Bidirectional text and complex scripts (Arabic, Farsi, Thai...) will be disabled in FreeType.])])
fi
dnl harfbuzz support
if test "${have_fribidi}" != "no"; then
if test "${enable_harfbuzz}" != "no"; then
PKG_CHECK_MODULES(HARFBUZZ, harfbuzz, [
have_harfbuzz="yes"
VLC_ADD_CPPFLAGS([skins2], [${HARFBUZZ_CFLAGS} -DHAVE_HARFBUZZ])
VLC_ADD_LIBS([skins2], [${HARFBUZZ_LIBS}])
],[AC_MSG_WARN([${HARFBUZZ_PKG_ERRORS}. Support for complex scripts (Arabic, Farsi, Thai...) will be disabled in FreeType.])])
fi
Christophe Mutricy
committed
],[
AS_IF([test -n "${enable_freetype}"],[
AC_MSG_ERROR([${FREETYPE_PKG_ERRORS}. Install FreeType2 development or configure with --disable-freetype.])
Christophe Mutricy
committed
])
fi
AM_CONDITIONAL([HAVE_FREETYPE], [test "${have_freetype}" = "yes"])
AM_CONDITIONAL([HAVE_FONTCONFIG], [test "${have_fontconfig}" = "yes"])
AM_CONDITIONAL([HAVE_FRIBIDI], [test "${have_fribidi}" = "yes"])
AM_CONDITIONAL([HAVE_HARFBUZZ], [test "${have_harfbuzz}" = "yes"])
dnl QuartzText vout module (iOS/Mac OS)
AC_ARG_ENABLE(macosx-quartztext,
[ --enable-macosx-quartztext Mac OS X quartz text module (default enabled on Mac OS X)])
if test "x${enable_macosx_quartztext}" != "xno" &&
(test "${SYS}" = "darwin" || test "${enable_macosx_quartztext}" = "yes")
then
VLC_ADD_PLUGIN([quartztext])
fi
dnl
dnl

Jean-Baptiste Kempf
committed
PKG_ENABLE_MODULES_VLC([SVG], [], [librsvg-2.0 >= 2.9.0], [SVG rendering library],[auto])
PKG_ENABLE_MODULES_VLC([SVGDEC], [], [librsvg-2.0 >= 2.9.0 cairo >= 1.13.1], [SVG image decoder library],[auto])
AC_ARG_ENABLE(directx,
[AS_HELP_STRING([--enable-directx],
[Microsoft DirectX support (default enabled on Windows)])],, [
enable_directx="yes"
], [
enable_directx="no"
])
])
have_directx="no"
AS_IF([test "${enable_directx}" != "no"], [
dnl DirectDraw
AC_CHECK_HEADERS(ddraw.h, [
have_directx="yes"
], [
AC_MSG_ERROR([Cannot find DirectX headers!])
])
dnl OpenGL
AC_CHECK_HEADERS(GL/wglew.h, [
VLC_ADD_PLUGIN([glwin32])
],, [
#include <windows.h>
#include <GL/gl.h>
])
dnl Direct3D11
AC_CHECK_HEADERS(d3d11.h, [
VLC_ADD_PLUGIN([direct3d11])
])
dnl Direct3D9
AC_CHECK_HEADERS(d3d9.h, [
VLC_ADD_PLUGIN([direct3d9])
dnl Direct2D
AC_CHECK_HEADERS(d2d1.h, [
VLC_ADD_PLUGIN([direct2d])
])
])
AM_CONDITIONAL([HAVE_DIRECTX], [test "$have_directx" = "yes"])
AC_CHECK_HEADER([linux/fb.h], [
VLC_ADD_PLUGIN([fb])
])

Jean-Paul Saman
committed
dnl
dnl DirectFB module
dnl try to find using: 1 - given location; 2 - directfb-config; 3 - pkg-config
dnl TODO: support for static linking

Jean-Paul Saman
committed
dnl
AC_ARG_ENABLE(directfb,
[ --enable-directfb DirectFB support (default disabled)])
[ --with-directfb=PATH path to DirectFB headers and libraries])
if test "${enable_directfb}" = "yes"; then
have_directfb="false"
CPPFLAGS_mydirectfb=
if test "${with_directfb}" != "no" -a -n "${with_directfb}"; then
dnl Trying the given location
VLC_SAVE_FLAGS
CPPFLAGS_new="-I${with_directfb}/include -D_REENTRANT -D_GNU_SOURCE"
LIBS_new="-L${with_directfb}/lib/fusion/.libs/ -L${with_directfb}/lib/direct/.libs/ -L${with_directfb}/src/.libs/"
CPPFLAGS="${CPPFLAGS} ${CPPFLAGS_new}"
dnl FIXME: too obscure
AC_CHECK_HEADER([directfb.h], [
AC_CHECK_LIB([direct],[direct_initialize], [
AC_CHECK_LIB([fusion], [fusion_enter], [
AC_CHECK_LIB([directfb], [DirectFBInit], have_directfb="true", have_directfb="false")
], have_directfb="false")
], have_directfb="false")
], have_directfb="false")
VLC_RESTORE_FLAGS
if test "${have_directfb}" = "true"; then
LIBS_mydirectfb="${LIBS_new} -lz $LIBDL -ldirectfb -lfusion -ldirect -lpthread"
CPPFLAGS_mydirectfb="${CPPFLAGS_new}"
fi
dnl Look for directfb-config
AC_PATH_PROG(DIRECTFB_CONFIG, directfb-config, no, ${PATH})
if test "${DIRECTFB_CONFIG}" != "no"; then
CPPFLAGS_mydirectfb="`${DIRECTFB_CONFIG} --cflags`"
LIBS_mydirectfb="`${DIRECTFB_CONFIG} --libs`"
dnl Trying with pkg-config
PKG_CHECK_MODULES(DIRECTFB, directfb, [
CPPFLAGS_mydirectfb="${DIRECTFB_CFLAGS}"
have_directfb="true"
], [have_directfb="false"])
fi
fi
if test "${have_directfb}" = "true"; then
VLC_ADD_CPPFLAGS([directfb],[${CPPFLAGS_mydirectfb}])
VLC_ADD_LIBS([directfb],[${LIBS_mydirectfb}])
AC_MSG_ERROR([${DIRECTFB_PKG_ERRORS}.])

Jean-Paul Saman
committed
fi
dnl
dnl AA plugin
dnl
AC_ARG_ENABLE(aa,
[ --enable-aa aalib output (default disabled)])
Ramiro Polla
committed
PKG_ENABLE_MODULES_VLC([CACA], [], [caca >= 0.99.beta14], [libcaca output],[auto])
3391
3392
3393
3394
3395
3396
3397
3398
3399
3400
3401
3402
3403
3404
3405
3406
3407
3408
3409
3410
3411
3412
3413
dnl
dnl OS/2 KVA plugin
dnl
AC_ARG_ENABLE(kva,
[AS_HELP_STRING([--enable-kva],
[support the K Video Accelerator KVA (default enabled on OS/2)])],, [
AS_IF([test "$SYS" = "os2"], [
enable_kva="yes"
])
])
have_kva="no"
KVA_LIBS=""
AS_IF([test "$enable_kva" != "no"], [
AC_CHECK_HEADERS([kva.h], [
have_kva="yes"
AC_CHECK_LIB(kva, main, [
KVA_LIBS="-lkva"
])
])
])
AC_SUBST(KVA_LIBS)
AM_CONDITIONAL([HAVE_KVA], [test "${have_kva}" = "yes"])
AC_ARG_ENABLE(mmal,
AS_HELP_STRING([--enable-mmal],
[Multi-Media Abstraction Layer (MMAL) hardware plugin (default enable)]))
if test "${enable_mmal}" != "no"; then
CPPFLAGS="${CPPFLAGS} -I/opt/vc/include -I/opt/vc/include/interface/vcos/pthreads -I/opt/vc/include/interface/vmcs_host/linux"
AC_CHECK_HEADERS(interface/mmal/mmal.h,
[ AC_CHECK_LIB(bcm_host, vc_tv_unregister_callback_full, [
have_mmal="yes"
VLC_ADD_PLUGIN([mmal])
VLC_ADD_LDFLAGS([mmal],[ -L/opt/vc/lib ])
VLC_ADD_CFLAGS([mmal],[ -I/opt/vc/include -I/opt/vc/include/interface/vcos/pthreads -I/opt/vc/include/interface/vmcs_host/linux ])
VLC_ADD_LIBS([mmal],[ -lbcm_host -lmmal -lvchostif ]) ], [
AS_IF([test "${enable_mmal}" = "yes"],
[ AC_MSG_ERROR([Cannot find bcm library...]) ],
[ AC_MSG_WARN([Cannot find bcm library...]) ])
],
[])
] , [ AS_IF([test "${enable_mmal}" = "yes"],
[ AC_MSG_ERROR([Cannot find development headers for mmal...]) ],
[ AC_MSG_WARN([Cannot find development headers for mmal...]) ]) ])
VLC_RESTORE_FLAGS
fi
AM_CONDITIONAL([HAVE_MMAL], [test "${have_mmal}" = "yes"])
dnl
dnl Pulseaudio module
dnl
AC_ARG_ENABLE(pulse,
[AS_HELP_STRING([--enable-pulse],
[use the PulseAudio client library (default auto)])])
have_pulse="no"
AS_IF([test "${enable_pulse}" != "no"], [
PKG_CHECK_MODULES([PULSE], [libpulse >= 1.0], [
AS_IF([test "x${enable_pulse}" != "x"], [
AC_MSG_ERROR([$PULSE_PKG_ERRORS. PulseAudio 1.0 or later required.])
])
])
])
AM_CONDITIONAL([HAVE_PULSE], [test "${have_pulse}" = "yes"])
[AS_HELP_STRING([--enable-alsa],
[support the Advanced Linux Sound Architecture (default auto)])],, [
AS_IF([test "$SYS" = "linux" -a "${have_pulse}" = "no"], [
enable_alsa="yes"
])
])
have_alsa="no"
AS_IF([test "${enable_alsa}" != "no"], [
PKG_CHECK_MODULES([ALSA], [alsa >= 1.0.24], [
have_alsa="yes"
], [
AS_IF([test "x${enable_alsa}" != "x"], [
AC_MSG_ERROR([$ALSA_PKG_ERRORS. alsa-lib 1.0.24 or later required.])
])
])
])
AM_CONDITIONAL([HAVE_ALSA], [test "${have_alsa}" = "yes"])
dnl
dnl Open Sound System module
dnl
AC_ARG_ENABLE(oss,
[AS_HELP_STRING([--enable-oss],
[support the Open Sound System OSS (default enabled on FreeBSD/NetBSD/DragonFlyBSD)])],, [
AS_IF([test "$SYS" = "mingw32" -o "$SYS" = "linux" -o "$SYS" = "openbsd"], [
enable_oss="no"
])
])
have_oss="no"
OSS_LIBS=""
AS_IF([test "$enable_oss" != "no"], [
AC_CHECK_HEADERS([soundcard.h sys/soundcard.h], [
have_oss="yes"
AC_CHECK_LIB(ossaudio, main, [
OSS_LIBS="-lossaudio"
])
])
])
AC_SUBST(OSS_LIBS)
AM_CONDITIONAL([HAVE_OSS], [test "${have_oss}" = "yes"])
dnl
dnl OpenBSD sndio module
dnl
AC_ARG_ENABLE([sndio],
[AS_HELP_STRING([--disable-sndio],
[support the OpenBSD sndio (default auto)])],, [
enable_sndio="yes"
])
])
have_sndio="no"
AS_IF([test "$enable_sndio" != "no"], [
AC_CHECK_HEADER([sndio.h], [
have_sndio="yes"
])
])
AM_CONDITIONAL([HAVE_SNDIO], [test "${have_sndio}" = "yes"])
dnl
dnl Windows Audio Session plugin
dnl
AC_ARG_ENABLE([wasapi],
[AS_HELP_STRING([--enable-wasapi],
[use the Windows Audio Session API (default auto)])
])
have_wasapi="no"
AS_IF([test "$enable_wasapi" != "no"], [
AC_CHECK_HEADER([audioclient.h], [
have_wasapi="yes"
], [
AS_IF([test "x${enable_wasapi}" != "x"], [
AC_MSG_ERROR([Windows Audio Session API not found.])
])
])
])
AM_CONDITIONAL([HAVE_WASAPI], [test "${have_wasapi}" = "yes"])
dnl
dnl AudioQueue plugin
dnl
AC_ARG_ENABLE(audioqueue,
[ --enable-audioqueue AudioQueue audio module (default disabled)])
if test "${enable_audioqueue}" = "yes"
then
VLC_ADD_PLUGIN([audioqueue])
fi
dnl JACK modules
AC_ARG_ENABLE(jack,
[AS_HELP_STRING([--disable-jack],
[do not use jack (default auto)])])
have_jack="no"
AS_IF([test "${enable_jack}" != "no"], [
PKG_CHECK_MODULES(JACK, jack >= 1.9.7,
[ have_jack=yes ],
[
AC_MSG_WARN([${JACK_PKG_ERRORS}, trying jack1 instead])
PKG_CHECK_MODULES(JACK, jack >= 0.120.1 jack < 1.0,
[ have_jack=yes ],
[
AS_IF([test -n "${enable_jack}"],
[AC_MSG_ERROR([${JACK_PKG_ERRORS}.])],
[AC_MSG_WARN([${JACK_PKG_ERRORS}.])])
])
])
])
AM_CONDITIONAL([HAVE_JACK], [test "${have_jack}" != "no"])
dnl
dnl OpenSLES Android
dnl
AC_ARG_ENABLE(opensles,
[ --enable-opensles Android OpenSL ES audio module (default disabled)])
if test "${HAVE_ANDROID}" = "1"; then
if test "${enable_opensles}" = "yes"; then
AC_CHECK_HEADERS(SLES/OpenSLES.h,
[ VLC_ADD_PLUGIN([opensles_android]) ],
[ AC_MSG_ERROR([cannot find OpenSLES headers])] )
fi
fi
dnl libsamplerate plugin
PKG_ENABLE_MODULES_VLC([SAMPLERATE], [], [samplerate], [Resampler with libsamplerate], [auto])
3601
3602
3603
3604
3605
3606
3607
3608
3609
3610
3611
3612
3613
3614
3615
3616
3617
3618
3619
3620
3621
3622
3623
dnl
dnl OS/2 KAI plugin
dnl
AC_ARG_ENABLE(kai,
[AS_HELP_STRING([--enable-kai],
[support the K Audio Interface KAI (default enabled on OS/2)])],, [
AS_IF([test "$SYS" = "os2"], [
enable_kai="yes"
])
])
have_kai="no"
KAI_LIBS=""
AS_IF([test "$enable_kai" != "no"], [
AC_CHECK_HEADERS([kai.h], [
have_kai="yes"
AC_CHECK_LIB(kai, main, [
KAI_LIBS="-lkai"
])
])
])
AC_SUBST(KAI_LIBS)
AM_CONDITIONAL([HAVE_KAI], [test "${have_kai}" = "yes"])
dnl
dnl chromaprint audio track fingerprinter
dnl
m4_pushdef([libchromaprint_version], 0.6.0)
PKG_WITH_MODULES([CHROMAPRINT],[libchromaprint >= libchromaprint_version],
VLC_ADD_PLUGIN([stream_out_chromaprint]),
AS_IF([test "${enable_chromaprint}" = "yes"],
[AC_MSG_ERROR(Library [libchromaprint >= libchromaprint_version] needed for [chromaprint] was not found)],
[AC_MSG_WARN(Library [libchromaprint >= libchromaprint_version] needed for [chromaprint] was not found)]
),
[(Chromaprint based audio fingerprinter)],[auto])
m4_popdef([libchromaprint_version])
dnl
dnl Chromecast streaming support
dnl
m4_pushdef([protobuf_lite_version], 2.5.0)
AC_ARG_VAR(PROTOC, [protobuf compiler])
AC_CHECK_PROGS(PROTOC, protoc, no)
PKG_WITH_MODULES([CHROMECAST],[protobuf-lite >= protobuf_lite_version], [
AS_IF([test "x${PROTOC}" != "xno"], [
build_chromecast="yes"
], [
AC_MSG_ERROR(protoc compiler needed for [chromecast] was not found)
])
], [
AS_IF([test "${enable_chromecast}" = "yes"],
AC_MSG_ERROR(Library [protobuf-lite >= protobuf_lite_version] needed for [chromecast] was not found),
AC_MSG_WARN(Library [protobuf-lite >= protobuf_lite_version] needed for [chromecast] was not found)
)
enable_chromecast="no"
], [(Chromecast streaming support)], [auto])
AM_CONDITIONAL([BUILD_CHROMECAST], [test "${build_chromecast}" = "yes"])
m4_popdef([protobuf_lite_version])
AC_ARG_ENABLE(qt, [
AS_HELP_STRING([--disable-qt], [Qt UI support (default enabled)])],, [
AS_IF([test "${SYS}" = "darwin"], [
enable_qt="no"
])
])
AS_IF([test "${enable_qt}" != "no"], [
PKG_CHECK_MODULES([QT], [Qt5Core >= 5.1.0 Qt5Widgets Qt5Gui], [
PKG_CHECK_MODULES([QTX11], [Qt5X11Extras], [
VLC_ADD_LIBS([qt4],[${QTX11_LIBS}])
VLC_ADD_CXXFLAGS([qt4],[${QTX11_CFLAGS} -DQT5_HAS_X11])
],[
AC_MSG_WARN([Not building Qt Interface with X11 helpers.])
QT_PATH="$(eval $PKG_CONFIG --variable=exec_prefix Qt5Core)"
QT_HOST_PATH="$(eval $PKG_CONFIG --variable=host_bins Qt5Core)"
AC_PATH_PROGS(MOC, [moc-qt5 moc], moc, ["${QT_HOST_PATH}" "${QT_PATH}/bin" "${CONTRIB_DIR}/bin"])
AC_PATH_PROGS(RCC, [rcc-qt5 rcc], rcc, ["${QT_HOST_PATH}" "${QT_PATH}/bin" "${CONTRIB_DIR}/bin"])
AC_PATH_PROGS(UIC, [uic-qt5 uic], uic, ["${QT_HOST_PATH}" "${QT_PATH}/bin" "${CONTRIB_DIR}/bin"])
], [
PKG_CHECK_MODULES([QT], [QtCore QtGui >= 4.6.0],, [
AS_IF([test -n "${enable_qt}"],[
AC_MSG_ERROR([${QT_PKG_ERRORS}.])
],[
AC_MSG_WARN([${QT_PKG_ERRORS}.])
])
enable_qt="no"
QT_PATH="$(eval $PKG_CONFIG --variable=exec_prefix QtCore)"
AC_PATH_PROGS(MOC, [moc-qt4 moc], moc, ["${QT_PATH}/bin" "${CONTRIB_DIR}/bin"])
AC_PATH_PROG(RCC, rcc, rcc, [${QT_PATH}/bin ${CONTRIB_DIR}/bin])
AC_PATH_PROGS(UIC, [uic-qt4 uic], uic, ["${QT_PATH}/bin" "${CONTRIB_DIR}/bin"])
AS_IF([test "${enable_qt}" != "no"], [
VLC_ADD_PLUGIN([qt4])
ALIASES="${ALIASES} qvlc"
AM_CONDITIONAL(ENABLE_QT4, [test "$enable_qt" != "no"])

Jean-Paul Saman
committed
dnl
dnl Simple test for skins2 dependency
dnl
AS_IF([test "$enable_qt" = "no"], [
AS_IF([test "${enable_skins2}" = "yes"], [
AC_MSG_ERROR([The skins2 module depends on the Qt4 interface. Without it you will not be able to open any dialog box from the interface, which makes the skins2 interface rather useless. Install the Qt4 development package or alternatively you can also configure with: --disable-qt4 --disable-skins2.])
], [
enable_skins2="no"
AC_MSG_WARN([The skins2 module depends on the Qt4 interface, Qt4 is not built so skins2 is disabled.])
])

Jean-Paul Saman
committed
dnl
dnl Skins2 module
dnl
AC_ARG_ENABLE(skins2,
[AS_HELP_STRING([--enable-skins2], [skins interface module (default auto)])])
AS_IF([test "${enable_skins2}" != "no"], [
have_skins_deps="yes"
dnl Win32
AS_IF([test "${SYS}" = "mingw32"], [
VLC_ADD_CPPFLAGS([skins2],[-U_OFF_T_ -U_off_t -DWIN32_SKINS])
VLC_ADD_LIBS([skins2],[-lgdi32 -lole32 -luuid -lmsimg32])
dnl MacOS
], [test "${SYS}" = "darwin"], [
VLC_ADD_CPPFLAGS([skins2],[ -DMACOSX_SKINS])
VLC_ADD_LIBS([skins2],[-Wl,-framework,Carbon])
dnl OS/2
], [test "${SYS}" = "os2"], [
VLC_ADD_CPPFLAGS([skins2],[ -DOS2_SKINS])
dnl Linux/Unix
], [
PKG_CHECK_MODULES([XPM], [xpm],, [have_skins_deps="no"])
PKG_CHECK_MODULES([XINERAMA], [xinerama],, [have_skins_deps="no"])
PKG_CHECK_MODULES([XEXT], [xext],, [have_skins_deps="no"])
VLC_ADD_CPPFLAGS([skins2],[${X_CFLAGS} ${XEXT_CFLAGS} ${XPM_CFLAGS} -DX11_SKINS])
VLC_ADD_LIBS([skins2],[${X_LIBS} ${X_PRE_LIBS} ${XEXT_LIBS} ${XPM_LIBS} ${XINERAMA_LIBS} -lX11])
])
dnl for All OSes
VLC_ADD_CXXFLAGS([skins2],[-O2 -fno-rtti])
3751
3752
3753
3754
3755
3756
3757
3758
3759
3760
3761
3762
3763
3764
3765
3766
3767
3768
3769
3770
3771
3772
3773
3774
3775
3776
3777
3778
dnl we need freetype
AS_IF([test "${have_freetype}" != "yes"], [
have_skins_deps="no"
])
AS_IF([test "${have_skins_deps}" = "no"], [
AS_IF([test "x${enable_skins2}" = "x"], [
AC_MSG_WARN([Skins2 interface disabled due to missing dependencies.])
], [
AC_MSG_ERROR([Skins2 interface requires FreeType, libxpm, libxext and libxinerama])
])
enable_skins2="no"
], [
VLC_ADD_PLUGIN([skins2])
ALIASES="${ALIASES} svlc"
enable_skins2="yes"
])
])
AM_CONDITIONAL(BUILD_SKINS, [test "${enable_skins2}" = "yes"])
AC_ARG_ENABLE(libtar,
[ --enable-libtar libtar support for skins2 (default auto)])
AS_IF([test "${enable_skins2}" = "yes" && test "${enable_libtar}" != "no"], [
AC_CHECK_HEADERS(libtar.h, [
VLC_ADD_LIBS([skins2],[-ltar])
])
])
dnl MacOS X gui module
AC_ARG_ENABLE(macosx,
[ --enable-macosx Mac OS X gui support (default enabled on Mac OS X)])
if test "x${enable_macosx}" != "xno" -a "${SYS}" = "darwin"

Felix Paul Kühne
committed
VLC_ADD_PLUGIN([macosx])
if test ! -d ${CONTRIB_DIR}/BGHUDAppKit.framework
AC_MSG_ERROR([BGHUDAppKit framework is required and was not found in ${CONTRIB_DIR}])

Felix Paul Kühne
committed
fi
AM_CONDITIONAL(ENABLE_MACOSX_UI, [test "$enable_macosx" != "no"])
dnl
dnl MacOS X sparkle update support
dnl
AC_ARG_ENABLE(sparkle,
[ --enable-sparkle Sparkle update support for OS X (default enabled on Mac OS X)])
if test "x${enable_sparkle}" != "xno" -a "${HAVE_OSX}" = "1"
then
if test ! -d ${CONTRIB_DIR}/Sparkle.framework
then
AC_MSG_ERROR([Sparkle framework is required and was not found in ${CONTRIB_DIR}])
fi
AC_DEFINE([HAVE_SPARKLE], [1], [Define to 1 if sparkle is enabled.])
fi
AM_CONDITIONAL(HAVE_SPARKLE, [test "$enable_sparkle" != "no"])

Felix Paul Kühne
committed
dnl
dnl Minimal Mac OS X module
dnl
AC_ARG_ENABLE(minimal-macosx,
[ --enable-minimal-macosx Minimal Mac OS X support (default disabled)])
if test "${enable_minimal_macosx}" = "yes" -a "${SYS}" = "darwin"
then
VLC_ADD_PLUGIN([minimal_macosx])
dnl

Felix Paul Kühne
committed
dnl MacOS X dialog provider
dnl
AC_ARG_ENABLE(macosx-dialog-provider,
[ --enable-macosx-dialog-provider Mac OS X dialog module (default enabled on Mac OS X)])
if test "x${enable_macosx_dialog_provider}" != "xno" &&
(test "${SYS}" = "darwin" || test "${enable_macosx_dialog_provider}" = "yes")
then
VLC_ADD_PLUGIN([macosx_dialog_provider])
fi
[AS_HELP_STRING([--disable-ncurses],[ncurses text-based interface (default auto)])])
AS_IF([test "${enable_ncurses}" != "no"] ,[
PKG_CHECK_MODULES([NCURSES], [ncursesw], [
ALIASES="${ALIASES} nvlc"
AS_IF([test -n "${enable_ncurses}"], [
AC_MSG_ERROR([${NCURSES_PKG_ERRORS}.])
])
AM_CONDITIONAL([HAVE_NCURSES], [test "${have_ncurses}" = "yes"])
dnl
dnl Lirc plugin
dnl
AC_ARG_ENABLE(lirc,
[ --enable-lirc lirc support (default disabled)])
have_lirc="no"
AS_IF([test "${enable_lirc}" = "yes"], [
AC_CHECK_HEADER(lirc/lirc_client.h, [
AC_CHECK_LIB(lirc_client, lirc_init, [
have_lirc="true"
])
])
])
AM_CONDITIONAL([HAVE_LIRC], [test "${have_lirc}" = "yes"])
EXTEND_HELP_STRING([Visualisations and Video filter plugins:])
dnl
dnl goom visualization plugin
dnl
PKG_ENABLE_MODULES_VLC([GOOM], [], [libgoom2], [goom visualization plugin], [auto])
dnl
dnl libprojectM visualization plugin
dnl
AC_ARG_ENABLE(projectm,
[ --enable-projectm projectM visualization plugin (default enabled)])
AS_IF([test "${enable_projectm}" != "no"],
[
PKG_CHECK_MODULES(PROJECTM, libprojectM,
[
VLC_ADD_PLUGIN([projectm])
[ AC_DEFINE([HAVE_PROJECTM2], 1, [Define to 1 if using libprojectM 2.x]) ],
[ AC_MSG_WARN( [Using libprojectM version 1] )
])
AC_MSG_WARN([${PROJECTM_PKG_ERRORS}.])
dnl
dnl Vovoid VSXu visualization plugin
dnl
AC_ARG_ENABLE(vsxu,
[ --enable-vsxu Vovoid VSXu visualization plugin (default auto)])
AS_IF([test "${enable_vsxu}" != "no"],
[
PKG_CHECK_MODULES(VSXU, libvsxu,
[
VLC_ADD_PLUGIN([vsxu])
],[
AC_MSG_WARN([${VSXU_PKG_ERRORS}.])
])
])
EXTEND_HELP_STRING([Service Discovery plugins:])
dnl
dnl Bonjour services discovery

Jean-Baptiste Kempf
committed
PKG_ENABLE_MODULES_VLC([BONJOUR], [], [avahi-client >= 0.6], [Bonjour services discovery], [auto])
dnl
dnl libudev services discovery
PKG_ENABLE_MODULES_VLC([UDEV], [], [libudev >= 142], [Linux udev services discovery], [auto])
PKG_ENABLE_MODULES_VLC([MTP], [mtp access_mtp], [libmtp >= 1.0.0], [MTP devices support], [auto])
dnl
dnl UPnP Plugin (Intel SDK)
dnl
PKG_ENABLE_MODULES_VLC([UPNP], [upnp], [libupnp], [Intel UPNP SDK],[auto])
dnl
dnl libxml2 module
dnl
PKG_ENABLE_MODULES_VLC([LIBXML2], [xml], [libxml-2.0 >= 2.5], [libxml2 support],[auto])
dnl
dnl libgcrypt
dnl
AC_ARG_ENABLE(libgcrypt,
[ --disable-libgcrypt gcrypt support (default enabled)])
AS_IF([test "${enable_libgcrypt}" != "no"], [
AC_TRY_COMPILE([
#include <gcrypt.h>
#if GCRYPT_VERSION_NUMBER < 0x010600
#error
#endif],
[], [
have_libgcrypt="yes"
AC_DEFINE([HAVE_GCRYPT], 1, [Defined if having gcrypt])
GCRYPT_CFLAGS="`libgcrypt-config --cflags`"
GCRYPT_LIBS="`libgcrypt-config --libs`"
AS_IF([test "${enable_libgcrypt}" == "yes"], [
AC_MSG_ERROR([libgcrypt version 1.6.0 or higher not found. Install libgcrypt or pass --disable-libgcrypt.])
])
])
AC_SUBST(GCRYPT_CFLAGS)
AC_SUBST(GCRYPT_LIBS)
AM_CONDITIONAL([HAVE_GCRYPT], [test "${have_libgcrypt}" = "yes"])

Rémi Denis-Courmont
committed
dnl
dnl TLS/SSL
dnl
AC_ARG_ENABLE(gnutls,
[ --enable-gnutls GNU TLS TLS/SSL support (default enabled)])

Rémi Denis-Courmont
committed
AS_IF([test "${enable_gnutls}" != "no"], [
PKG_CHECK_MODULES(GNUTLS, [gnutls >= 3.2.0], [

Rémi Denis-Courmont
committed
], [
AS_IF([test -n "${enable_gnutls}"], [
AC_MSG_ERROR([${GNUTLS_PKG_ERRORS}.)])

Rémi Denis-Courmont
committed
])
])
])
dnl
dnl Taglib plugin
dnl
AC_ARG_ENABLE(taglib,
[AS_HELP_STRING([--disable-taglib],
[do not use TagLib (default enabled)])])
AS_IF([test "${enable_taglib}" != "no"], [
PKG_CHECK_MODULES(TAGLIB, taglib >= 1.9, [
VLC_ADD_PLUGIN([taglib])
], [
AC_MSG_WARN([${TAGLIB_PKG_ERRORS}.])])
dnl
dnl Developers helper modules (should be hidden from configure help)
dnl
AC_ARG_ENABLE(devtools, [], [], [enable_devtools="no"])
AS_IF([test "${enable_devtools}" != "no"], [
VLC_ADD_PLUGIN([accesstweaks])
])
dnl
dnl update checking system
dnl
AC_ARG_ENABLE(update-check,