[Binary specific version])
])
-dnl
-dnl Check for the contrib directory
-dnl
-AC_ARG_WITH(contrib,
- [AS_HELP_STRING([--with-contrib[=DIR]],
- [search for 3rd party libraries in DIR/include and DIR/lib])
-])
-AC_MSG_CHECKING([for 3rd party libraries path])
-AS_IF([test -z "${with_contrib}" || test "${with_contrib}" = "yes"], [
- CONTRIB_DIR="${srcdir}/contrib/${host}"
- AS_IF([test ! -d "${CONTRIB_DIR}"], [
- echo "${CONTRIB_DIR} not found" >&AS_MESSAGE_LOG_FD
- CONTRIB_DIR="${srcdir}/contrib/`$CC -dumpmachine`"
- AS_IF([test ! -d "${CONTRIB_DIR}"], [
- echo "${CONTRIB_DIR} not found" >&AS_MESSAGE_LOG_FD
- CONTRIB_DIR="${srcdir}/extras/contrib/hosts/${host}"
- AS_IF([test ! -d "${CONTRIB_DIR}"], [
- echo "${CONTRIB_DIR} not found" >&AS_MESSAGE_LOG_FD
- CONTRIB_DIR="${srcdir}/extras/contrib/hosts/`$CC -dumpmachine`"
- AS_IF([test ! -d "${CONTRIB_DIR}"], [
- echo "${CONTRIB_DIR} not found" >&AS_MESSAGE_LOG_FD
- CONTRIB_DIR=""
- AC_MSG_RESULT([not found])
- ])
- ])
- ])
- ])
-], [
- AS_IF([test "${with_contrib}" != "no"], [
- CONTRIB_DIR="${with_contrib}"
- ], [
- CONTRIB_DIR=""
- AC_MSG_RESULT([disabled])
- ])
-])
-AS_IF([test -n "${CONTRIB_DIR}"], [
- AS_IF([test -d "${CONTRIB_DIR}/lib"],[
- CONTRIB_DIR=`cd "${CONTRIB_DIR}" && pwd`
- ], [
- echo "${CONTRIB_DIR}/lib not found" >&AS_MESSAGE_LOG_FD
- CONTRIB_DIR=""
- AC_MSG_RESULT([not usable])
- ])
-
-])
-AS_IF([test -n "${CONTRIB_DIR}"], [
- AC_MSG_RESULT([${CONTRIB_DIR}])
- export PATH=${CONTRIB_DIR}/bin:$PATH
- CPPFLAGS="${CPPFLAGS} -I${CONTRIB_DIR}/include"
- CPPFLAGS_save="${CPPFLAGS_save} -I${CONTRIB_DIR}/include"
- CFLAGS="${CFLAGS} -I${CONTRIB_DIR}/include"
- CFLAGS_save="${CFLAGS_save} -I${CONTRIB_DIR}/include"
- CXXFLAGS="${CXXFLAGS} -I${CONTRIB_DIR}/include"
- CXXFLAGS_save="${CXXFLAGS_save} -I${CONTRIB_DIR}/include"
- OBJCFLAGS="${OBJCFLAGS} -I${CONTRIB_DIR}/include"
- OBJCFLAGS_save="${OBJCFLAGS_save} -I${CONTRIB_DIR}/include"
- AS_IF([test "$build" = "$host" -o "$PKG_CONFIG_LIBDIR"], [
- export PKG_CONFIG_PATH="${CONTRIB_DIR}/lib/pkgconfig:$PKG_CONFIG_PATH"
- ], [
- export PKG_CONFIG_LIBDIR="${CONTRIB_DIR}/lib/pkgconfig"
- ])
- LDFLAGS="${LDFLAGS} -L${CONTRIB_DIR}/lib"
- LDFLAGS_save="${LDFLAGS_save} -L${CONTRIB_DIR}/lib"
-
- AS_IF([test "${SYS}" = "darwin"], [
- export LD_LIBRARY_PATH="${CONTRIB_DIR}/lib:$LD_LIBRARY_PATH"
- export DYLD_LIBRARY_PATH="${CONTRIB_DIR}/lib:$DYLD_LIBRARY_PATH"
- ])
-], [
- AS_IF([test -n "${with_contrib}" && test "${with_contrib}" != "no"], [
- AC_MSG_ERROR([Third party libraries not found!])
- ])
-])
-AC_SUBST(CONTRIB_DIR)
-
-dnl
-dnl Set default values
-dnl
-LDFLAGS_vlc="${LDFLAGS}"
-
dnl
dnl Check the operating system
dnl
dnl NSIS Installer prefix and WIN64
dnl
case "${host}" in
- amd64*|i686-w64*|x86_64*)
+ amd64*|x86_64*)
HAVE_WIN64="1"
PROGRAMFILES="PROGRAMFILES64"
;;
AM_CONDITIONAL(HAVE_SYMBIAN, test "${SYS}" = "symbian")
dnl
-dnl Sadly autoconf doesn't think about testing foo.exe when ask to test
+dnl Check for the contrib directory
+dnl
+AC_ARG_WITH(contrib,
+ [AS_HELP_STRING([--with-contrib[=DIR]],
+ [search for 3rd party libraries in DIR/include and DIR/lib])
+])
+AC_MSG_CHECKING([for 3rd party libraries path])
+AS_IF([test -z "${with_contrib}" || test "${with_contrib}" = "yes"], [
+ CONTRIB_DIR="${srcdir}/contrib/${host}"
+ AS_IF([test ! -d "${CONTRIB_DIR}"], [
+ echo "${CONTRIB_DIR} not found" >&AS_MESSAGE_LOG_FD
+ CONTRIB_DIR="${srcdir}/contrib/`$CC -dumpmachine`"
+ AS_IF([test ! -d "${CONTRIB_DIR}"], [
+ echo "${CONTRIB_DIR} not found" >&AS_MESSAGE_LOG_FD
+ CONTRIB_DIR="${srcdir}/extras/contrib/hosts/${host}"
+ AS_IF([test ! -d "${CONTRIB_DIR}"], [
+ echo "${CONTRIB_DIR} not found" >&AS_MESSAGE_LOG_FD
+ CONTRIB_DIR="${srcdir}/extras/contrib/hosts/`$CC -dumpmachine`"
+ AS_IF([test ! -d "${CONTRIB_DIR}"], [
+ echo "${CONTRIB_DIR} not found" >&AS_MESSAGE_LOG_FD
+ CONTRIB_DIR=""
+ AC_MSG_RESULT([not found])
+ ])
+ ])
+ ])
+ ])
+], [
+ AS_IF([test "${with_contrib}" != "no"], [
+ CONTRIB_DIR="${with_contrib}"
+ ], [
+ CONTRIB_DIR=""
+ AC_MSG_RESULT([disabled])
+ ])
+])
+AS_IF([test -n "${CONTRIB_DIR}"], [
+ AS_IF([test -d "${CONTRIB_DIR}/lib"],[
+ CONTRIB_DIR=`cd "${CONTRIB_DIR}" && pwd`
+ ], [
+ echo "${CONTRIB_DIR}/lib not found" >&AS_MESSAGE_LOG_FD
+ CONTRIB_DIR=""
+ AC_MSG_RESULT([not usable])
+ ])
+
+])
+AS_IF([test -n "${CONTRIB_DIR}"], [
+ AC_MSG_RESULT([${CONTRIB_DIR}])
+ export PATH=${CONTRIB_DIR}/bin:$PATH
+ CPPFLAGS="${CPPFLAGS} -I${CONTRIB_DIR}/include"
+ CPPFLAGS_save="${CPPFLAGS_save} -I${CONTRIB_DIR}/include"
+ CFLAGS="${CFLAGS} -I${CONTRIB_DIR}/include"
+ CFLAGS_save="${CFLAGS_save} -I${CONTRIB_DIR}/include"
+ CXXFLAGS="${CXXFLAGS} -I${CONTRIB_DIR}/include"
+ CXXFLAGS_save="${CXXFLAGS_save} -I${CONTRIB_DIR}/include"
+ OBJCFLAGS="${OBJCFLAGS} -I${CONTRIB_DIR}/include"
+ OBJCFLAGS_save="${OBJCFLAGS_save} -I${CONTRIB_DIR}/include"
+ AS_IF([test "$build" = "$host" -o "$PKG_CONFIG_LIBDIR"], [
+ export PKG_CONFIG_PATH="${CONTRIB_DIR}/lib/pkgconfig:$PKG_CONFIG_PATH"
+ ], [
+ export PKG_CONFIG_LIBDIR="${CONTRIB_DIR}/lib/pkgconfig"
+ ])
+ LDFLAGS="${LDFLAGS} -L${CONTRIB_DIR}/lib"
+ LDFLAGS_save="${LDFLAGS_save} -L${CONTRIB_DIR}/lib"
+
+ AS_IF([test "${SYS}" = "darwin"], [
+ export LD_LIBRARY_PATH="${CONTRIB_DIR}/lib:$LD_LIBRARY_PATH"
+ export DYLD_LIBRARY_PATH="${CONTRIB_DIR}/lib:$DYLD_LIBRARY_PATH"
+ ])
+], [
+ AS_IF([test -n "${with_contrib}" && test "${with_contrib}" != "no"], [
+ AC_MSG_ERROR([Third party libraries not found!])
+ ])
+])
+AC_SUBST(CONTRIB_DIR)
+
+dnl
+dnl Sadly autoconf does not think about testing foo.exe when ask to test
dnl for program foo on win32
case "${build_os}" in
[AC_DEFINE(fdatasync, fsync, [Alias fdatasync() to fsync() if missing.])
])
-# Windows CE doesn't have strcoll()
+# Windows CE does not have strcoll()
AC_FUNC_STRCOLL
dnl Check for non-standard system calls
[AS_HELP_STRING([--disable-optimizations],
[disable compiler optimizations (default enabled)])],,
[enable_optimizations="yes"])
-AS_IF([test "${enable_optimizations}" != "no"], [
- enable_optimizations="speed"
-])
dnl Check for various optimization flags
AS_IF([test "${enable_optimizations}" != "no"], [
])
AS_IF([test "${ac_cv_c_omit_frame_pointer}" != "no"], [
VLC_RESTORE_FLAGS
- AS_IF([test "${SYS}" != "darwin"], [
CFLAGS="${CFLAGS} -fomit-frame-pointer"
CXXFLAGS="${CXXFLAGS} -fomit-frame-pointer"
- ], [
- dnl On darwin we explicitely disable it.
- CFLAGS="${CFLAGS} -fno-omit-frame-pointer"
- CXXFLAGS="${CXXFLAGS} -fno-omit-frame-pointer"
- OBJCFLAGS="${OBJCFLAGS} -fno-omit-frame-pointer"
- ])
+ OBJCFLAGS="${OBJCFLAGS} -fomit-frame-pointer"
VLC_SAVE_FLAGS
])
])
AS_IF([test "${enable_mmx}" != "no"], [
ARCH="${ARCH} mmx"
- AC_CACHE_CHECK([if $CC groks MMX intrinsics],
- [ac_cv_c_mmx_intrinsics],
- [CFLAGS="${CFLAGS_save} -O -mmmx"
- AC_TRY_COMPILE([#include <mmintrin.h>
- #include <stdint.h>
- uint64_t frobzor;],
- [__m64 a, b, c;
- a = b = c = (__m64)frobzor;
- a = _mm_slli_pi16(a, 3);
- a = _mm_adds_pi16(a, b);
- c = _mm_srli_pi16(c, 8);
- c = _mm_slli_pi16(c, 3);
- b = _mm_adds_pi16(b, c);
- a = _mm_unpacklo_pi8(a, b);
- frobzor = (uint64_t)a;],
- [ac_cv_c_mmx_intrinsics=yes],
- [ac_cv_c_mmx_intrinsics=no])])
+ AC_CACHE_CHECK([if $CC groks MMX intrinsics], [ac_cv_c_mmx_intrinsics], [
+ CFLAGS="${CFLAGS_save} -O -mmmx"
+ AC_COMPILE_IFELSE([AC_LANG_PROGRAM([
+[#include <mmintrin.h>
+#include <stdint.h>
+uint64_t frobzor;]], [
+[__m64 a, b, c;
+a = b = c = (__m64)frobzor;
+a = _mm_slli_pi16(a, 3);
+a = _mm_adds_pi16(a, b);
+c = _mm_srli_pi16(c, 8);
+c = _mm_slli_pi16(c, 3);
+b = _mm_adds_pi16(b, c);
+a = _mm_unpacklo_pi8(a, b);
+frobzor = (uint64_t)a;]])], [
+ ac_cv_c_mmx_intrinsics=yes
+ ], [
+ ac_cv_c_mmx_intrinsics=no
+ ])
+ CFLAGS="${CFLAGS_save}"
+ ])
AS_IF([test "${ac_cv_c_mmx_intrinsics}" != "no"], [
AC_DEFINE(HAVE_MMX_INTRINSICS, 1,
[Define to 1 if MMX intrinsics are available.])
], [
ac_cv_mmx_inline=no
])
+ CFLAGS="${CFLAGS_save}"
])
AS_IF([test "${ac_cv_mmx_inline}" != "no"], [
AC_DEFINE(CAN_COMPILE_MMX, 1,
], [
ac_cv_mmxext_inline=no
])
+ CFLAGS="${CFLAGS_save}"
])
AS_IF([test "${ac_cv_mmxext_inline}" != "no"], [
AC_DEFINE(CAN_COMPILE_MMXEXT, 1,
AS_IF([test "${enable_sse}" != "no"], [
ARCH="${ARCH} sse sse2"
- AC_CACHE_CHECK([if $CC groks SSE2 intrinsics],
- [ac_cv_c_sse2_intrinsics],
- [CFLAGS="${CFLAGS_save} -O -msse2"
- AC_TRY_COMPILE([#include <emmintrin.h>
- #include <stdint.h>
- uint64_t frobzor;],
- [__m128i a, b, c;
- a = b = c = _mm_set1_epi64((__m64)frobzor);
- a = _mm_slli_epi16(a, 3);
- a = _mm_adds_epi16(a, b);
- c = _mm_srli_epi16(c, 8);
- c = _mm_slli_epi16(c, 3);
- b = _mm_adds_epi16(b, c);
- a = _mm_unpacklo_epi8(a, b);
- frobzor = (uint64_t)_mm_movepi64_pi64(a);],
- [ac_cv_c_sse2_intrinsics=yes],
- [ac_cv_c_sse2_intrinsics=no])])
+ AC_CACHE_CHECK([if $CC groks SSE2 intrinsics], [ac_cv_c_sse2_intrinsics], [
+ CFLAGS="${CFLAGS_save} -O -msse2"
+ AC_COMPILE_IFELSE([AC_LANG_PROGRAM([
+[#include <emmintrin.h>
+#include <stdint.h>
+uint64_t frobzor;]], [
+[__m128i a, b, c;
+a = b = c = _mm_set1_epi64((__m64)frobzor);
+a = _mm_slli_epi16(a, 3);
+a = _mm_adds_epi16(a, b);
+c = _mm_srli_epi16(c, 8);
+c = _mm_slli_epi16(c, 3);
+b = _mm_adds_epi16(b, c);
+a = _mm_unpacklo_epi8(a, b);
+frobzor = (uint64_t)_mm_movepi64_pi64(a);]])], [
+ ac_cv_c_sse2_intrinsics=yes
+ ], [
+ ac_cv_c_sse2_intrinsics=no
+ ])
+ CFLAGS="${CFLAGS_save}"
+])
AS_IF([test "${ac_cv_c_sse2_intrinsics}" != "no"], [
AC_DEFINE(HAVE_SSE2_INTRINSICS, 1,
[Define to 1 if SSE2 intrinsics are available.])
], [
ac_cv_sse_inline=no
])
+ CFLAGS="${CFLAGS_save}"
])
AS_IF([test "${ac_cv_sse_inline}" != "no" -a "${SYS}" != "solaris"], [
AC_DEFINE(CAN_COMPILE_SSE, 1,
], [
ac_cv_sse2_inline=no
])
+ CFLAGS="${CFLAGS_save}"
])
AS_IF([test "${ac_cv_sse2_inline}" != "no" -a "${SYS}" != "solaris"], [
AC_DEFINE(CAN_COMPILE_SSE2, 1,
], [
ac_cv_sse3_inline=no
])
+ CFLAGS="${CFLAGS_save}"
])
AS_IF([test "${ac_cv_sse3_inline}" != "no"], [
AC_DEFINE(CAN_COMPILE_SSE3, 1,
], [
ac_cv_ssse3_inline=no
])
+ CFLAGS="${CFLAGS_save}"
])
AS_IF([test "${ac_cv_ssse3_inline}" != "no"], [
AC_DEFINE(CAN_COMPILE_SSSE3, 1,
], [
ac_cv_sse4_1_inline=no
])
+ CFLAGS="${CFLAGS_save}"
])
AS_IF([test "${ac_cv_sse4_1_inline}" != "no"], [
AC_DEFINE(CAN_COMPILE_SSE4_1, 1,
], [
ac_cv_sse4_2_inline=no
])
+ CFLAGS="${CFLAGS_save}"
])
AS_IF([test "${ac_cv_sse4_2_inline}" != "no"], [
AC_DEFINE(CAN_COMPILE_SSE4_2, 1,
], [
ac_cv_sse4a_inline=no
])
+ CFLAGS="${CFLAGS_save}"
])
AS_IF([test "${ac_cv_sse4a_inline}" != "no"], [
AC_DEFINE(CAN_COMPILE_SSE4A, 1,
], [
ac_cv_3dnow_inline=no
])
+ CFLAGS="${CFLAGS_save}"
])
AS_IF([test "${ac_cv_3dnow_inline}" != "no"], [
AC_DEFINE(CAN_COMPILE_3DNOW, 1,
AC_CACHE_CHECK([if linker needs -framework vecLib],
[ac_cv_ld_altivec],
- [LDFLAGS="${LDFLAGS_vlc} -Wl,-framework,vecLib"
+ [LDFLAGS="${LDFLAGS} -Wl,-framework,vecLib"
AC_TRY_LINK([],,ac_cv_ld_altivec=yes,ac_cv_ld_altivec=no)
LDFLAGS="${LDFLAGS_save}"
])
fi
dnl NOTE: this can't be cached cleanly
-AS_IF([test "${CFLAGS_TUNING}"],
- [CFLAGS_save="${CFLAGS}"
- CFLAGS="${CFLAGS} ${CFLAGS_TUNING}"
-
- AC_MSG_CHECKING([whether $CC accepts ${CFLAGS_TUNING}])
- AC_COMPILE_IFELSE([AC_LANG_SOURCE([])],
- [tuning="yes"],
- [CFLAGS_TUNING=""; tuning="no"
- AS_IF([test "${with_tuning}"],
- [AC_MSG_ERROR([requested tuning not supported])])])
-
- AC_MSG_RESULT([$tuning])
- CFLAGS="${CFLAGS_save}"
+AS_IF([test -n "${CFLAGS_TUNING}"], [
+ AC_MSG_CHECKING([whether $CC accepts ${CFLAGS_TUNING}])
+ CFLAGS="${CFLAGS_save} ${CFLAGS_TUNING}"
+ AC_COMPILE_IFELSE([AC_LANG_SOURCE([])], [
+ tuning="yes"
+ ], [
+ CFLAGS_TUNING=""; tuning="no"
+ AS_IF([test "${with_tuning}"], [
+ AC_MSG_ERROR([requested tuning not supported])
+ ])
+ ])
+ CFLAGS="${CFLAGS_save}"
+ AC_MSG_RESULT([$tuning])
+ VLC_RESTORE_FLAGS
+ CFLAGS="${CFLAGS} ${CFLAGS_TUNING}"
+ VLC_SAVE_FLAGS
])
dnl
then
dnl The given directory can't be found
AC_MSG_RESULT(no)
- AC_MSG_ERROR([${with_mad_tree} directory doesn't exist])
+ AC_MSG_ERROR([${with_mad_tree} directory does not exist])
fi
dnl Use a custom libmad
AC_MSG_CHECKING(for mad.h in ${real_mad_tree})
AC_CHECK_LIB(mad, mad_bit_init, [
VLC_ADD_PLUGIN([mpgatofixed32])
VLC_ADD_LIBS([mpgatofixed32],[-lmad])
- ],[ AC_MSG_ERROR([the specified tree hasn't been compiled ])
+ ],[ AC_MSG_ERROR([the specified tree has not been compiled ])
],[])
LDFLAGS="${LDFLAGS_save}"
else
AC_MSG_RESULT(no)
- AC_MSG_ERROR([the specified tree doesn't have mad.h])
+ AC_MSG_ERROR([the specified tree does not have mad.h])
fi
else
CPPFLAGS="${CPPFLAGS_save} ${CPPFLAGS_mpgatofixed32}"
AC_CACHE_CHECK([if linker supports -Bsymbolic],
[ac_cv_ld_bsymbolic],
- [LDFLAGS="${LDFLAGS_vlc} -Wl,-Bsymbolic"
+ [LDFLAGS="${LDFLAGS} -Wl,-Bsymbolic"
AC_TRY_LINK([],,ac_cv_ld_bsymbolic=yes,ac_cv_ld_bsymbolic=no)
LDFLAGS="${LDFLAGS_save}"
])
then
dnl The given directory can't be found
AC_MSG_RESULT(no)
- AC_MSG_ERROR([${with_a52_tree} directory doesn't exist])
+ AC_MSG_ERROR([${with_a52_tree} directory does not exist])
fi
dnl Use a custom a52dec
AC_MSG_CHECKING(for a52.h in ${real_a52_tree}/include)
then
AC_MSG_ERROR([make sure you have at least a52dec-0.7.3 ($real_a52_tree)])
else
- AC_MSG_ERROR([the specified tree hasn't been compiled])
+ AC_MSG_ERROR([the specified tree has not been compiled])
fi
])
LDFLAGS="${LDFLAGS_save}"
else
AC_MSG_RESULT(no)
- AC_MSG_ERROR([the specified tree doesn't have a52.h])
+ AC_MSG_ERROR([the specified tree does not have a52.h])
fi
else
if test -z "${with_a52}"
then
dnl The given directory can't be found
AC_MSG_RESULT(no)
- AC_MSG_ERROR([${with_x264_tree} directory doesn't exist])
+ AC_MSG_ERROR([${with_x264_tree} directory does not exist])
fi
dnl Use a custom libx264
AC_MSG_CHECKING(for x264.h in ${real_x264_tree})
VLC_ADD_CFLAGS([x264], [-DPTW32_STATIC_LIB])
fi
],[
- AC_MSG_ERROR([the specified tree hasn't been compiled])
+ AC_MSG_ERROR([the specified tree has not been compiled])
])
LDFLAGS="${LDFLAGS_save}"
else
AC_MSG_RESULT(no)
- AC_MSG_ERROR([the specified tree doesn't have x264.h])
+ AC_MSG_ERROR([the specified tree does not have x264.h])
fi
else
PKG_CHECK_MODULES(X264,x264 >= 0.86, [
AS_IF([test "${SYS}" = "mingw32"], [
VLC_ADD_CPPFLAGS([skins2],[-U_OFF_T_ -U_off_t -Imodules/gui/skins2 -DWIN32_SKINS])
VLC_ADD_CXXFLAGS([skins2],[-O2 -fno-rtti])
- VLC_ADD_LIBS([skins2],[-loleaut32 -lwinspool -lwinmm -lshell32 -ladvapi32 -lwsock32 -lgdi32 -lcomdlg32 -lole32 -luuid -lcomctl32 -lmsimg32 -luser32])
+ VLC_ADD_LIBS([skins2],[-lgdi32 -lole32 -luuid -lmsimg32])
], [test "${SYS}" = "darwin"], [
VLC_ADD_CPPFLAGS([skins2],[-Imodules/gui/skins2 -DMACOSX_SKINS])
dnl Simple test for skins2 dependency
dnl
AS_IF([test "${enable_skins2}" != "no" && test "x$enable_qt4" = "xno"], [
- AC_MSG_ERROR([The skins2 module depends on a the Qt4 development package. Without it you won't 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.])
+ AC_MSG_ERROR([The skins2 module depends on a the Qt4 development package. 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.])
])
dnl
echo exit \$ERROR >>compile
chmod a+x compile
-printf "
+echo "
libvlc configuration
--------------------
version : ${VERSION}
system : ${SYS}
architecture : ${ARCH}
-build flavour : "
-test "${enable_optimizations}" != "no" && printf ${enable_optimizations}
-echo ""
+optimizations : ${enable_optimizations}"
if test "${enable_vlc}" != "no"; then
echo "vlc aliases :${ALIASES}"
else