diff options
101 files changed, 2250 insertions, 8508 deletions
diff --git a/Makefile.am b/Makefile.am index f41b34b2c..2b82d1bdc 100644 --- a/Makefile.am +++ b/Makefile.am @@ -48,22 +48,8 @@ pass2: @$(MAKE) MULTIPASS_CFLAGS='$(PASS2_CFLAGS)' -debug: - @list='$(SUBDIRS)'; for subdir in $$list; do \ - (cd $$subdir && $(MAKE) $@) || exit;\ - done; - -debug-install: install-debug - -install-debug: debug - @list='$(SUBDIRS)'; for subdir in $$list; do \ - (cd $$subdir && $(MAKE) $@) || exit; \ - done; - $(MAKE) $(AM_MAKEFLAGS) install-data-hook - - prune-cache: - -rm -f config.cache + -rm -rf config.cache autom4te.cache release-check: diff --git a/autogen.sh b/autogen.sh index e228f051b..95bce9774 100755 --- a/autogen.sh +++ b/autogen.sh @@ -27,11 +27,11 @@ PROG=xine-lib # Minimum value required to build -WANT_AUTOMAKE_1_8=1 export WANT_AUTOMAKE_1_8 -WANT_AUTOMAKE=1.8 export WANT_AUTOMAKE -AUTOMAKE_MIN=1.8.0 +export WANT_AUTOMAKE_1_9=1 +export WANT_AUTOMAKE=1.9 +AUTOMAKE_MIN=1.9.0 AUTOCONF_MIN=2.59 -LIBTOOL_MIN=1.4.0 +LIBTOOL_MIN=1.5.20 # Check how echo works in this /bin/sh case `echo -n` in @@ -192,7 +192,7 @@ run_automake () { echo $_echo_n " + Running automake: $_echo_c"; - automake --gnu --add-missing --copy; + automake --gnu --add-missing --copy -Wno-portability; echo "done." } @@ -231,7 +231,7 @@ run_aclocal () { echo $_echo_n " + Running aclocal: $_echo_c" - aclocal -I m4 + aclocal -I m4 -I m4/gettext echo "done." } diff --git a/configure.ac b/configure.ac index 9389c792e..433387eb1 100644 --- a/configure.ac +++ b/configure.ac @@ -1,223 +1,219 @@ -dnl -dnl Configure.ac for xine -dnl +AC_PREREQ(2.59) -AC_INIT +dnl Note that autoconf/autoheader/automake cache using autom4te, so version.sh +dnl will only be run if configure.ac has changed. This must be done before +dnl AC_INIT so that XINE_VERSION_SPEC, which is an m4 macro, is available. +m4_esyscmd([./version.sh]) + +dnl Initialize autoconf, autoheader, and automake +AC_INIT([xine-lib], XINE_VERSION_SPEC, [xine-bugs@lists.sourceforge.net]) +AM_INIT_AUTOMAKE AC_CONFIG_SRCDIR([src/xine-engine/xine.c]) AC_CONFIG_LIBOBJ_DIR([lib]) +AC_CONFIG_HEADERS([config.h]) +AM_MAINTAINER_MODE -dnl -dnl Require autoconf version 2.60 -dnl -AC_PREREQ(2.59) +AH_TOP([#ifndef __XINE_LIB_CONFIG_H__ +#define __XINE_LIB_CONFIG_H__ 1 +]) +AH_BOTTOM([#ifdef ASMALIGN_1SLN +# define ASMALIGN(ZEROBITS) ".align " #ZEROBITS "\n\t" +#else +# define ASMALIGN(ZEROBITS) ".align 1<<" #ZEROBITS "\n\t" +#endif -dnl Making releases: -dnl XINE_SUB += 1; continue with XINE_LT_* values below -dnl -XINE_MAJOR=1 -XINE_MINOR=1 -XINE_SUB=90 +/* include internal system specific header */ +#include "os_internal.h" -#if test $XINE_SUB -eq 0 ; then -# XINE_SUBPART=""; -#else - XINE_SUBPART=".$XINE_SUB" -#fi - -dnl The libtool version numbers (XINE_LT_*); Don't even think about faking this! -dnl -dnl immediately before every release do: -dnl =================================== -dnl if (the interface is totally unchanged from previous release) -dnl XINE_LT_REVISION ++; -dnl else { /* interfaces have been added, removed or changed */ -dnl XINE_LT_REVISION = 0; -dnl XINE_LT_CURRENT ++; -dnl if (any interfaces have been _added_ since last release) -dnl XINE_LT_AGE ++; -dnl if (any interfaces have been _removed_ or _incompatibly changed_) -dnl XINE_LT_AGE = 0; -dnl } -dnl -dnl If you want to know more about what you are doing, here are some details: -dnl * XINE_LT_CURRENT is the current API version -dnl * XINE_LT_REVISION is an internal revision number which is increased when the API -dnl itself did not change -dnl * XINE_LT_AGE is the number of previous API versions still supported by this library -dnl * libtool has its own numbering scheme, because local library numbering schemes -dnl are platform dependent -dnl * in Linux, the library will be named -dnl libname.so.(XINE_LT_CURRENT - XINE_LT_AGE).XINE_LT_AGE.XINE_LT_REVISION - -XINE_LT_CURRENT=19 -XINE_LT_REVISION=0 -XINE_LT_AGE=17 - -dnl for a release tarball do "rm .cvsversion" before "make dist" -if test -f "${srcdir-.}/.cvsversion"; then - XINE_PRE="hg" -else - XINE_PRE="" +#endif /* __XINE_LIB_CONFIG_H__ */ +]) + +test x"$prefix" = x"NONE" && prefix="${ac_default_prefix}" +test x"$exec_prefix" = x"NONE" && exec_prefix='${prefix}' + +dnl Use features of autoconf 2.61, but stay compatible with older versions. +if test x"$datarootdir" = x""; then + datarootdir='${datadir}' + AC_SUBST(datarootdir) +fi + +if test x"$docdir" = x""; then + docdir='${datarootdir}/doc/${PACKAGE}' + AC_SUBST(docdir) +fi + +if test x"$htmldir" = x""; then + htmldir='${docdir}' + AC_SUBST(htmldir) fi + +dnl ------------------------- +dnl Setup version information +dnl ------------------------- + +dnl Do not change these manually; they come from running ./version.sh when +dnl autoconf runs. This must all be done after AC_INIT is done, but running +dnl the version.sh script must be done before AC_INIT. +XINE_MAJOR=XINE_VERSION_MAJOR AC_SUBST(XINE_MAJOR) +AC_DEFINE_UNQUOTED([XINE_MAJOR], [$XINE_MAJOR], [xine major version number]) +XINE_MINOR=XINE_VERSION_MINOR AC_SUBST(XINE_MINOR) +AC_DEFINE_UNQUOTED([XINE_MINOR], [$XINE_MINOR], [xine minor version number]) +XINE_SUB=XINE_VERSION_SUB AC_SUBST(XINE_SUB) -AC_SUBST(XINE_IFACE_AGE) -AC_SUBST(XINE_BIN_AGE) - -AC_DEFINE_UNQUOTED(XINE_MAJOR, $XINE_MAJOR,[xine major version number]) -AC_DEFINE_UNQUOTED(XINE_MINOR, $XINE_MINOR,[xine minor version number]) -AC_DEFINE_UNQUOTED(XINE_SUB, $XINE_SUB, [xine sub version number]) +AC_DEFINE_UNQUOTED([XINE_SUB], [$XINE_SUB], [xine sub version number]) +XINE_LT_CURRENT=__XINE_LT_CURRENT AC_SUBST(XINE_LT_CURRENT) +XINE_LT_REVISION=__XINE_LT_REVISION AC_SUBST(XINE_LT_REVISION) +XINE_LT_AGE=__XINE_LT_AGE AC_SUBST(XINE_LT_AGE) -SPEC_VERSION=$XINE_MAJOR.$XINE_MINOR${XINE_SUBPART}$XINE_PRE -TAR_NAME="xine-lib-"$SPEC_VERSION -dnl TAR_NAME="xine-lib-"$XINE_MAJOR-$XINE_PRE -dnl SPEC_VERSION=${XINE_MAJOR}_$XINE_PRE +LIBNAME="libxine${XINE_MAJOR}" +AC_SUBST(LIBNAME) +AC_DEFINE_UNQUOTED([XINE_TEXTDOMAIN], "$LIBNAME", [catalog message text domain]) + +dnl Always set flags to begin with -g so that debug information will be +dnl included. In release bulids, this can be stripped out later if desired. +dnl More importantly, it prevents autoconf from initializing the defaults to +dnl include -O2, which is not desirable in a debug build, and it messes with +dnl other optimizations that we'll want to be setting ourselves later. +ASFLAGS="-g $ASFLAGS" +CFLAGS="-g $CFLAGS" +CPPFLAGS="-D_REENTRANT -DXINE_COMPILE $CPPFLAGS" +LDFLAGS="-g $LDFLAGS" +OBJCFLAGS="-g $OBJCFLAGS" -AC_SUBST(TAR_NAME) -AC_SUBST(SPEC_VERSION) +AC_SUBST(ASFLAGS) -LIBNAME=libxine$XINE_MAJOR -AC_SUBST(LIBNAME) -AC_DEFINE_UNQUOTED(XINE_TEXTDOMAIN, "$LIBNAME", [catalog message text domain]) +dnl ------------------------------ +dnl Build modes: debug and profile +dnl ------------------------------ -dnl -AM_INIT_AUTOMAKE("xine-lib", $SPEC_VERSION) -dnl AM_INIT_AUTOMAKE("xine-lib", $XINE_MAJOR-$XINE_PRE) +AC_ARG_ENABLE([debug], + [AS_HELP_STRING([--enable-debug], [build with debugging code enabled])], + [], [enable_debug="no"]) +if test x"$enable_debug" != x"no"; then + CPPFLAGS="-DDEBUG $CPPFLAGS" +else + CPPFLAGS="-DNDEBUG $CPPFLAGS" +fi +AM_CONDITIONAL([DEBUG_BUILD], [test x"$enable_debug" != x"no"]) -dnl --------------------------------------------- -dnl Made possible to build for another arch. -dnl --------------------------------------------- +AC_ARG_ENABLE([profiling], + [AS_HELP_STRING([--enable-profiling], [build with profiling code enabled])], + [], [enable_profiling="no"]) +if test x"$enable_profiling" != x"no"; then + CFLAGS="-pg $CFLAGS" + OBJCFLAGS="-pg $OBJCFLAGS" + LDFLAGS="-pg $LDFLAGS" +fi +AM_CONDITIONAL([PROFILING_BUILD], [test x"$enable_profiling" != x"no"]) -AC_CANONICAL_HOST -AC_CANONICAL_BUILD -test "$host" == "$build" && check_athlon=yes +dnl -------------- +dnl Build features +dnl -------------- -AC_CONFIG_HEADERS([config.h]) +AC_ARG_ENABLE([altivec], + [AS_HELP_STRING([--disable-altivec], [do not use assembly codes for Motorola 74xx CPUs])], + [], [enable_altivec="yes"]) -AC_ARG_ENABLE([macosx-universal], - AS_HELP_STRING([--enable-macosx-universal], [build a Mac OS X univeral binary (ppc and x86)]), - [], [enable_macosx_universal="no"]) -if test x"$enable_macosx_universal" != x"no" ; then - case "$host_os" in - *darwin*) - dnl x64_64 and ppc64 binaries could also be built, but there is no - dnl version of Mac OS X currently shipping that can run them, so - dnl do not enable them by default for now. - if test x"$enable_macosx_universal" = x"yes" ; then - UNIVERSAL_ARCHES="i386 ppc" - else - UNIVERSAL_ARCHES=`echo "$enable_macosx_universal" | sed -e 's/,/ /g'` - fi - ;; - *) - AC_MSG_ERROR([Universal binaries can only be built on Darwin]) - ;; - esac +AC_ARG_ENABLE([vis], + [AS_HELP_STRING([--disable-vis], [do not use assembly codes for Sun UltraSPARC CPUs])], + [], [enable_vis="yes"]) - UNIVERSAL_CFLAGS="$UNIVERSAL_CFLAGS -isysroot /Developer/SDKs/MacOSX10.4u.sdk" - UNIVERSAL_LDFLAGS="$UNIVERSAL_LDFLAGS -Wl,-syslibroot,/Developer/SDKs/MacOSX10.4u.sdk" - if test x"$UNIVERSAL_ARCHES" != x"" ; then - # Forcibly disable dependency tracking for Universal builds, because -M - # does not work with multiple -arch arguments on the gcc command-line. - ac_tool_warned=yes - cross_compiling=yes - enable_dependency_tracking=no - host="`echo $host | sed -e s/$host_cpu/universal/g`" - host_cpu=universal - - CFLAGS="$CFLAGS $UNIVERSAL_CFLAGS" - OBJCFLAGS="$OBJCFLAGS $UNIVERSAL_CFLAGS" - LDFLAGS="$LDFLAGS $UNIVERSAL_LDFLAGS" - AC_DEFINE(XINE_MACOSX_UNIVERSAL_BINARY, 1, [Define this if a universal binary is being built for Mac OS X]) - for arch in $UNIVERSAL_ARCHES ; do - UNIVERSAL_CFLAGS="$UNIVERSAL_CFLAGS -arch $arch" - UNIVERSAL_LDFLAGS="$UNIVERSAL_LDFLAGS -arch $arch" - CFLAGS="$CFLAGS -arch $arch" - OBJCFLAGS="$OBJCFLAGS -arch $arch" - LDFLAGS="$LDFLAGS -arch $arch" - done - fi -fi -AM_CONDITIONAL([MACOSX_UNIVERSAL_BINARY], [test x"$enable_macosx_universal" = x"yes"]) -AC_SUBST(UNIVERSAL_ARCHES) -AC_SUBST(UNIVERSAL_CFLAGS) -AC_SUBST(UNIVERSAL_LDFLAGS) +AC_ARG_ENABLE([ipv6], + [AS_HELP_STRING([--enable-ipv6], [enable use of IPv6])], + [if test x"$enableval" != x"no"; then + AC_DEFINE([ENABLE_IPV6], 1, [Enable this when IPv6 is requested]) + fi]) +AC_ARG_ENABLE([antialiasing], + [AS_HELP_STRING([--enable-antialiasing], [enable font antialiasing])], + [if test x"$enableval" != x"no"; then + AC_DEFINE([ENABLE_ANTIALIASING], 1, [Define this to 1 to enable font antialising.]) + fi]) -dnl --------------------------------------------- -dnl Check for programs. -dnl --------------------------------------------- -AC_PROG_CC -AM_PROG_AS +dnl ---------------------------------------------- +dnl Cross compilation, Mac OS X Universal Binaries +dnl ---------------------------------------------- -case "$host_os" in - *darwin*) - m4_ifdef([AC_PROG_OBJC], - [AC_PROG_OBJC], - [AC_CHECK_TOOL([OBJC], [gcc]) - AC_SUBST([OBJC]) - AC_SUBST([OBJCFLAGS]) - ]) - CPPFLAGS="$CPPFLAGS -DCONFIG_DARWIN" - ;; -esac +AC_CANONICAL_BUILD +AC_CANONICAL_HOST -AC_GNU_SOURCE -dnl Save CFLAGS, AC_ISC_POSIX set some unwanted default CFLAGS -saved_CFLAGS="$CFLAGS" -AC_ISC_POSIX -AC_PATH_MAGIC -CFLAGS="$saved_CFLAGS" -AC_HEADER_STDC +dnl check for Mac OS X universal binary support early, because certain flags +dnl must be set prior to looking for cc/libtool, etc. +MACOSX_UNIVERSAL_BINARIES + +dnl Check to see if $host is empty. If it is, try $host_alias instead. +dnl If $host is empty, it's because the user has run ./configure with a host +dnl parameter unknown to config.sub. This used to be set in xv handling, but +dnl it's also used in a bunch of other places unrelated to Xwindows support, +dnl so if X is disabled, other things could go badly. +host_or_hostalias="$host" +test x"$host_or_hostalias" = x"" && host_or_hostalias="$host_alias" + + +dnl ------------------- +dnl checks for programs +dnl ------------------- + +AC_PROG_CC +AC_PROG_OBJC +AM_PROG_AS AC_PROG_MAKE_SET AC_PROG_EGREP AC_PROG_INSTALL AC_PROG_LN_S AC_PROG_AWK -AC_C_INLINE AC_CHECK_TOOL([STRINGS], [strings], [false]) -dnl --------------------------------------------- -dnl Libtool -dnl --------------------------------------------- +AC_GNU_SOURCE +AC_ISC_POSIX +PKG_PROG_PKG_CONFIG + +dnl Check for documentation formatting tools +AC_CHECK_PROG([SGMLTOOLS], [sgmltools], [sgmltools], [no]) +AM_CONDITIONAL([HAVE_SGMLTOOLS], [test x"$SGMLTOOLS" != x"no"]) + +AC_CHECK_PROG([FIG2DEV], [fig2dev], [fig2dev], [no]) +AM_CONDITIONAL([HAVE_FIG2DEV], [test x"$FIG2DEV" != x"no"]) + + +dnl libtool m4_undefine([AC_PROG_F77]) m4_defun([AC_PROG_F77],[]) -AC_LIBTOOL_DLOPEN AC_DISABLE_STATIC +AC_LIBTOOL_DLOPEN AC_LIBTOOL_WIN32_DLL +AC_PATH_MAGIC AC_PROG_LIBTOOL AC_PROG_LIBTOOL_SANITYCHECK + +dnl REVISIT: +dnl Nothing seems to use LIBTOOL_DEPS +dnl src/video_out/libdha and src/video_out/vidix both use STATIC -- why? AC_SUBST(LIBTOOL_DEPS) if ${CONFIG_SHELL} ./libtool --features | grep "enable static" >/dev/null; then - STATIC="-static" + STATIC="-static" else - STATIC= + STATIC= fi AC_SUBST(STATIC) dnl --------------------------------------------- -dnl Requirements for macros whose first invocations are conditional -dnl --------------------------------------------- - -PKG_PROG_PKG_CONFIG -CC_CHECK_WERROR - -dnl --------------------------------------------- -dnl NLS Support +dnl REVISIT: NLS Support dnl --------------------------------------------- dnl ALL_LINGUAS="cs da de el en@quot en@boldquot es et fr gl id it ja ko nl nn no pl pt pt_BR ru sl sv tr zh" @@ -246,93 +242,543 @@ AC_PROG_GMSGFMT_PLURAL AC_CHECK_FUNCS([nl_langinfo]) -dnl --------------------------------------------- -dnl Checks for typedefs, structures, and compiler characteristics. -dnl --------------------------------------------- +dnl -------------------- +dnl checks for libraries +dnl -------------------- + +AM_DL() + +dnl Test for socket and network support library +AC_CHECK_LIB([socket], [socket], [NET_LIBS="-lsocket $NET_LIBS"]) +AC_CHECK_LIB([nsl], [gethostbyname], [NET_LIBS="-lnsl $NET_LIBS"]) +AC_CHECK_LIB([resolv], [hstrerror], [NET_LIBS="-lresolv $NET_LIBS"]) +AC_SUBST(NET_LIBS) + +AC_CHECK_LIB([rt], [clock_getres], + [RT_LIBS="-lrt" + AC_DEFINE(HAVE_POSIX_TIMERS, 1, [Define this if you have POSIX timers.])], + [AC_MSG_RESULT([*** no POSIX timers available.])]) +AC_SUBST(RT_LIBS) + +AC_CHECK_LIB([posix4], [sched_get_priority_min]) + +dnl ----------------------- +dnl checks for header files +dnl ----------------------- + +AC_HEADER_STDC + +dnl REVISIT: should we not be using AC_FUNC_ALLOCA for this? +AC_CHECK_HEADERS([alloca.h]) + +AC_CHECK_HEADERS([assert.h byteswap.h dirent.h execinfo.h libgen.h malloc.h netdb.h ucontext.h]) +AC_CHECK_HEADERS([sys/ioctl.h sys/mixer.h sys/mman.h sys/param.h sys/times.h]) + + +dnl ---------------- +dnl checks for types +dnl ---------------- -AC_C_BIGENDIAN -AC_C_CONST -dnl AC_C_ALWAYS_INLINE removal allows ffmpeg to be more widely buildable AC_TYPE_OFF_T AC_TYPE_SIZE_T AC_CHECK_SIZEOF(long) dnl AC_CHECK_TYPES([ptrdiff_t]) dnl For systems without inttypes.h would be needed extend generated replacement. AC_CHECK_GENERATE_INTTYPES([include]) -AM_CONDITIONAL(GENERATED_INTTYPES_H, test "x$ac_cv_header_inttypes_h" != x"yes") +AM_CONDITIONAL([GENERATED_INTTYPES_H], [test "x$ac_cv_header_inttypes_h" != x"yes"]) AC_CHECK_TYPE(ssize_t, :, AC_DEFINE(ssize_t, __int64, [define ssize_t to __int64 if it's missing in default includes])) -dnl --------------------------------------------- -dnl threads and OS specific stuff -dnl --------------------------------------------- +AC_CHECK_SOCKLEN_T -CC_PTHREAD_FLAGS(, [AC_MSG_ERROR([Pthread support is needed])]) +dnl --------------------- +dnl checks for structures +dnl --------------------- -dnl -AC_MSG_CHECKING(for recursive mutex support in pthread) -ac_save_LIBS="$LIBS" -LIBS="$LIBS $PTHREAD_LIBS" +AC_CHECK_IP_MREQN -have_recursive_mutex=no -AC_COMPILE_IFELSE(AC_LANG_SOURCE([#include <pthread.h> -int main() { - pthread_mutexattr_t attr; - pthread_mutexattr_settype(&attr, PTHREAD_MUTEX_RECURSIVE); - return 0; -} - ]),[ - have_recursive_mutex=yes - ],[ - AC_MSG_ERROR(recursive mutex support is needed - please report) - ]) -LIBS="$ac_save_LIBS" +dnl ----------------------------------- +dnl checks for compiler characteristics +dnl ----------------------------------- -AC_MSG_RESULT($have_recursive_mutex) +if test x"$GCC" = x"yes"; then + GCC_VERSION="`"$CC" -dumpversion`" + GCC_VERSION_MAJOR="`echo "$GCC_VERSION" | cut -d '.' -f1`" + GCC_VERSION_MINOR="`echo "$GCC_VERSION" | cut -d '.' -f2`" + GCC_VERSION_PATCHLEVEL="`echo "$GCC_VERSION" | cut -d '.' -f3`" +fi +AC_SUBST(GCC_VERSION) +AC_SUBST(GCC_VERSION_MAJOR) +AC_SUBST(GCC_VERSION_MINOR) +AC_SUBST(GCC_VERSION_PATCHLEVEL) -AC_CHECK_DECL(sysi86,[ - AC_DEFINE(HAVE_SYSI86,1,[Define this if the 'sysi86' function is declared in sys/sysi86.h]) - ],,[ -#include <sys/sysi86.h> -]) +CC_CHECK_WERROR + +CC_PTHREAD_FLAGS([], [AC_MSG_ERROR([Pthread support is needed])]) +CC_PTHREAD_RECURSIVE_MUTEX([], [AC_MSG_ERROR([recursive mutex support is needed - please report])]) + +dnl REVISIT: AC_C_ALWAYS_INLINE removal allows ffmpeg to be more widely buildable +AC_C_BIGENDIAN +AC_C_CONST +AC_C_INLINE +AC_C_RESTRICT + +dnl ASM ALIGN is power of two ? +dnl src/post/planar +AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[]], [[asm(".align 3");]])], + [AC_DEFINE([ASMALIGN_1SLN], [1], + [define if '.align n' means alignment to (1 << n) - byte boundaries])]) + +CC_ATTRIBUTE_ALIGNED + +CC_ATTRIBUTE_PACKED([XINE_PACKED='__attribute__((packed))'], + [AC_MSG_WARN([Your compiler doesn't support __attribute__((packed)); xine might not work as expected.])]) +AC_DEFINE_UNQUOTED([XINE_PACKED], [$XINE_PACKED], [Mark a structure as being packed]) + +CC_ATTRIBUTE_MALLOC + +CC_ATTRIBUTE_VISIBILITY([protected], + [visibility_export="protected"], + [CC_ATTRIBUTE_VISIBILITY([default], [visibility_export="default"])]) + +if test x"$visibility_export" != x""; then + CC_FLAG_VISIBILITY([VISIBILITY_FLAG="-fvisibility=hidden" + EXPORTED='__attribute__((visibility("default")))']) +fi +AC_DEFINE_UNQUOTED([EXPORTED], [$EXPORTED], [Mark a symbol as being exported if visibility is changed]) +AC_SUBST([VISIBILITY_FLAG]) + +CC_ATTRIBUTE_SENTINEL +CC_ATTRIBUTE_FORMAT +CC_ATTRIBUTE_FORMAT_ARG + +CC_CHECK_CFLAGS([-pipe], [miscflags="$miscflags -pipe"]) + +dnl Set warning flags for warnings that we do not want to skip. In all cases, +dnl these warnings should be enabled. Set these into CFLAGS and OBJCFLAGS +dnl later after all testing is done. + +CC_CHECK_CFLAGS([-Wall], [warnflags="$warnflags -Wall"]) + +CC_CHECK_CFLAGS([-Wformat=2], [wformat="-Wformat=2"], + [CC_CHECK_CFLAGS([-Wformat], [wformat="-Wformat"])]) +if test x"$wformat" != x""; then + CC_CHECK_CFLAGS([-Wno-format-zero-length], [wformat="$wformat -Wno-format-zero-length"]) +fi +CC_CHECK_CFLAGS([-Wmissing-format-attribute], [wformat="$wformat -Wmissing-format-attribute"]) +warnflags="$warnflags $wformat" + +dnl WARNING: This warning flag, if set into CFLAGS now, can break some autoconf tests. +CC_CHECK_CFLAGS([-Werror-implicit-function-declaration], [warnflags="$warnflags -Werror-implicit-function-declaration"]) + +CC_CHECK_CFLAGS([-Wstrict-aliasing=2], [warnflags="$warnflags -Wstrict-aliasing=2"], + [CC_CHECK_CFLAGS([-Wstrict-aliasing], [warnflags="$warnflags -Wstrict-aliasing"])]) + +CC_CHECK_CFLAGS([-Wchar-subscripts], [warnflags="$warnflags -Wchar-subscripts"]) +CC_CHECK_CFLAGS([-Wmissing-declarations], [warnflags="$warnflags -Wmissing-declarations"]) +CC_CHECK_CFLAGS([-Wmissing-prototypes], [warnflags="$warnflags -Wmissing-prototypes"]) + +dnl Some combinations of gcc and glibc produce useless warnings on memset when +dnl compiling with -Wpointer-arith, so check for this first. +AC_MSG_CHECKING([for sane -Wpointer-arith]) +AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include <string.h>]], [[int a; memset(&a, 0, sizeof(int))]])], + [warnflags="$warnflags -Wpointer-arith" + AC_MSG_RESULT([yes])], [AC_MSG_RESULT([no])]) + +dnl FreeBSD (et al.) does not complete linking for shared objects when pthreads +dnl are requested, as different implementations are present; to avoid problems +dnl use -Wl,-z,defs only for those platforms not behaving this way. +case "$host_or_hostalias" in + *-freebsd*) ;; -dnl --------------------------------------------- -dnl Windows ports checks -dnl --------------------------------------------- -case "$host" in - *-*-mingw* | *-*-cygwin*) dnl check if we are using the cygwin, mingw or cygwin with mno-cygwin mode dnl in which case we are actually dealing with a mingw32 compiler - case "$host" in - *-*-mingw32*) - SYS=mingw32 + dnl This cannot be done until AC_PROG_EGREP and AC_PROG_CC are both done. + *-*-mingw* | *-*-cygwin*) + case "$host_or_hostalias" in + *-*-mingw32*) + WIN32_SYS=mingw32 + ;; + *-*-cygwin*) + AC_EGREP_CPP([yes], + [#ifdef WIN32 + yes + #endif], + [WIN32_SYS=mingw32], [WIN32_SYS=cygwin]) + ;; + esac + + if test "$WIN32_SYS" = "mingw32"; then + WIN32_CPPFLAGS='-I$(top_srcdir)/win32/include' + LIBS="-lwinmm -lwsock32 $LIBS" + GOOM_LIBS="-liberty" + AC_SUBST(GOOM_LIBS) + AC_SUBST(WIN32_CPPFLAGS) + fi + LDFLAGS="-no-undefined $LDFLAGS" ;; - *-*-cygwin*) - AC_EGREP_CPP(pattern, - [#ifdef WIN32 - yes - #endif], - SYS=mingw32, SYS=cygwin) + + *) + CC_CHECK_LDFLAGS([-Wl,-z,defs], [NOUNDEF="-Wl,-z,defs"]) + AC_SUBST([NOUNDEF]) ;; - esac +esac - if test "$SYS" = "mingw32"; then - WIN32_CPPFLAGS='-I$(top_srcdir)/win32/include' - LIBS="-lwinmm -lwsock32 $LIBS" - GOOM_LIBS="-liberty" +AM_CONDITIONAL([WIN32], [test x"$WIN32_SYS" = x"mingw32"]) + +dnl No optimization at all. For gcc, this is the optimization level. +O0_CFLAGS="-O0" + +dnl Lowest level of optimization. For gcc, this enables: +dnl -fdefer-pop -fdelayed-branch -fguess-branch-probability -fcprop-registers +dnl -floop-optimize -fif-conversion -fif-conversion2 -ftree-ccp -ftree-dce +dnl -ftree-dce -ftree-dominator-opts -ftree-dse -ftree-ter -ftree-lrs +dnl -ftree-sra -ftree-copyrename -ftree-fre -ftree-ch -fmerge-constants +dnl On platforms where -fomit-frame-pointer does not interfere with debugging, +dnl it is also enabled by -O1. +O1_CFLAGS="-O1" + +dnl Middle level of optimization. For gcc, this enables -O1 and: +dnl -fthread-jumps -fcrossjumping -foptimize-sibling-calls -fcse-follow-jumps +dnl -fcse-skip-blocks -fgcse -fgcse-lm -fexpensive-optimizations +dnl -fstrength-reduce -frerun-cse-after-loop -frerun-loop-opt -fcaller-saves +dnl -fforce-mem -fpeephole2 -fschedule-insns -fschedule-insns2 +dnl -fsched-interblock -fsched-spec -fregmove -fstrict-aliasing +dnl -fdelete-null-pointer-checks -freorder-blocks -freorder-functions +dnl -funit-at-a-time -falign-functions -falign-jumps -falign-loops +dnl -falign-labels -ftree-pre +dnl Note that Apple's version of gcc differs slightly, because it does not enable +dnl -fstrict-aliasing -freorder-blocks -fsched-interblock +O2_CFLAGS="-O2" + +dnl Highest level of optimization. For gcc, this enables -O2 and: +dnl -finline-functions -funswitch-loops -fgcse-after-reload +O3_CFLAGS="-O3" + +dnl gcc 3.3.5 (at least) is known to be buggy wrt optimization with +dnl -finline-functions, so use -fno-inline-functions for gcc < 3.4.0 +if test x"$GCC" = x"yes"; then + if test "$GCC_VERSION_MAJOR" -lt 3; then + O3_CFLAGS="$O3_CFLAGS -fno-inline-functions" + else + if test "$GCC_VERSION_MAJOR" -eq 3 -a "$GCC_VERSION_MINOR" -lt 4; then + O3_CFLAGS="$O3_CFLAGS -fno-inline-functions" + fi fi - LDFLAGS="-no-undefined $LDFLAGS" - ;; +fi + +CC_CHECK_CFLAGS([-ffast-math], [optflags="$optflags -ffast-math"]) +CC_CHECK_CFLAGS([-fexpensive-optimizations], [optflags="$optflags -fexpensive-optimizations"]) + +case "$host_or_hostalias" in + alphaev56-*) cpuflags="-mcpu=ev56 -mieee $cpuflags" ;; + alpha*) cpuflags="-mieee $cpuflags" ;; + + armv4l-*-linux*) + cpuflags="-mcpu=strongarm1100 -ffast-math -fsigned-char $cpuflags" + DEFAULT_OCFLAGS='$(O2_CFLAGS)' + ;; + + sparc*-*-linux*) + case "`uname -m`" in + sparc) cpuflags="-mcpu=supersparc -mtune=supersparc" ;; + sparc64) cpuflags="-mcpu=ultrasparc -mtune=ultrasparc" ;; + esac + test x"$enable_vis" != x"no" && has_vis=yes + AC_DEFINE([ARCH_SPARC], [], [Define this if you're running SPARC architecture]) + ;; + + sparc-*-solaris*) + if test x"$GCC" = x"yes"; then + case "`uname -m`" in + sun4c) cpuflags="-mcpu=v7 -mtune=supersparc" ;; + sun4m) cpuflags="-mcpu=v8 -mtune=supersparc" ;; + sun4u) + if test x"$GCC_VERSION_MAJOR" -lt 3; then + # -mcpu=ultrasparc triggers a GCC 2.95.x compiler bug + # when compiling video_out.c: + # gcc: Internal compiler error: program cc1 got fatal signal 11 + # avoid -mcpu=ultrasparc with gcc 2.* + cpuflags="-mcpu=v8 -mtune=ultrasparc" + else + cpuflags="-mcpu=ultrasparc -mtune=ultrasparc" + fi + ;; + esac + if test "$GCC_VERSION_MAJOR" -ge 3; then + test x$"enable_vis" != x"no" && has_vis=yes + fi + else + case "`uname -m`" in + sun4c) cpuflags="-xarch=v7" ;; + sun4m) cpuflags="-xarch=v8" ;; + sun4u) cpuflags="-xarch=v8plusa" ;; + esac + O1_CFLAGS="-fast -xCC" + O2_CFLAGS="$O1_CFLAGS" + O3_CFLAGS="$O1_CFLAGS" + fi + AC_DEFINE([ARCH_SPARC], [], [Define this if you're running SPARC architecture]) + ;; + + x86_64-*) + arch_x86=yes + AC_DEFINE([ARCH_X86_64], [], [Define this if you're running x86 architecture 64 bits]) + ;; + + *-*-darwin*) + case "$host_or_hostalias" in + i386-* | universal-* | x86_64-*) + arch_x86=yes + ;; + ppc* | powerpc*) + dnl avoid ppc compilation crash + AS="$CC" + + AC_CHECK_HEADER([altivec.h], [], [enable_altivec=no]) + if test x"$enable_altivec" != x"no"; then + AC_DEFINE([ENABLE_ALTIVEC], [], [Define this if you want to use altivec on PowerPC CPUs]) + cpuflags="$cpuflags -faltivec -maltivec" + LIBMPEG2_CFLAGS="$LIBMPEG2_CFLAGS -force_cpusubtype_ALL" + fi + ;; + esac + + enable_impure_text=yes + HOST_OS_DARWIN=1 + dnl HOST_OS_DARWIN is used by a bunch of difference stuff, including + dnl libdvdnav, libmpeg2, and xine itself (xine-engine, xine-utils) + AC_DEFINE([HOST_OS_DARWIN], 1, [Define this if built on Mac OS X/Darwin]) + dnl CONFIG_DARWIN is used by ffmpeg, so anything that pulls ffmpeg + dnl headers needs to have this set. + AC_DEFINE([CONFIG_DARWIN], 1, [Define this if built on Mac OS X/Darwin]) + CPPFLAGS="-D_INTL_REDIRECT_MACROS $CPPFLAGS" + ;; + + ppc-*-linux* | powerpc-*) + dnl avoid ppc compilation crash + AS="$CC" + AC_DEFINE([ARCH_PPC], [], [Define this if you're running PowerPC architecture]) + + AC_CHECK_HEADER([altivec.h], [], [enable_altivec=no]) + + if test x"$enable_altivec" != x"no"; then + AC_DEFINE([ENABLE_ALTIVEC], [], [Define this if you want to use altivec on PowerPC CPUs]) + cpuflags="$cpuflags -maltivec" + fi + ;; + + i?86-* | k?-* | athlon-* | pentium*) + arch_x86=yes + enable_impure_text=yes + + case "$host_or_hostalias" in + *-*-cygwin* | *-*-mingw32*) + CC_CHECK_CFLAGS([-fno-omit-frame-pointer], [W32_NO_OPTIMIZE="$W32_NO_OPTIMIZE -fno-omit-frame-pointer"]) + CC_CHECK_CFLAGS([-fno-inline-functions], [W32_NO_OPTIMIZE="$W32_NO_OPTIMIZE -fno-inline-functions"]) + CC_CHECK_CFLAGS([-fno-rename-registers], [W32_NO_OPTIMIZE="$W32_NO_OPTIMIZE -fno-rename-registers"]) + AC_SUBST(W32_NO_OPTIMIZE) + case "$host_or_hostalias" in + *-*-cygwin*) LIBS="$LIBS @INTLLIBS@ -lkernel32" ;; + esac + ;; + esac + + AC_DEFINE([ARCH_X86_32], [], [Define this if you're running x86 architecture 32 bits]) + + if test x"$GCC" = x"yes" -o x"${CC##*/}" = x"icc"; then + if test x"$GCC" = x"yes"; then + # GCC optimizations + CC_CHECK_CFLAGS([-mtune=i386], [sarchopt="-mtune"], + [CC_CHECK_CFLAGS([-mcpu=i386], [sarchopt="-mcpu"], + [CC_CHECK_CFLAGS([-march=i386], [sarchopt="-march"], [sarchopt="no"])])]) + if test "$sarchopt" != "no"; then + case "$host_or_hostalias" in + i386-*) archopt_val="i386" ;; + i486-*) archopt_val="i486" ;; + i586-*) archopt_val="pentium" ;; + pentium-mmx-*) archopt_val="pentium-mmx" ;; + k6-2* | k6-3-*) archopt_val="k6-2" ;; + k6-*) archopt_val="k6" ;; + pentium3-*) archopt_val="pentium3" ;; + pentium4-*) archopt_val="pentium4" ;; + + athlon-4-* | athlon-xp-* | althon-mp-*) archopt_val="athlon-4" ;; + k7-* | athlon-tbird-* | athlon-*) archopt_val="athlon" ;; + + pentiumpro-* | pentium2-* | i686-*) + archopt_val="pentiumpro" + if test x"$cross_compiling" != x"yes"; then + if test -f /proc/cpuinfo; then + modelname=`cat /proc/cpuinfo | grep "model\ name\ :" | sed -e 's/ //g' | cut -d ':' -f2` + case "$modelname" in + *Athlon* | *Duron* | *K7*) + dnl Special check for k7 cpu CC support + CC_CHECK_CFLAGS([$sarchopt=athlon], + [archopt_val="athlon"], [archopt_val="i686"]) + ;; + VIAEzra) + archopt_val="c3" + ;; + esac + fi + fi + ;; + esac + test x$"archopt_val" != x"" && cpuflags="$cpuflags $sarchopt=$archopt_val" + fi + else + # Intel optimizations + O3_CFLAGS="$O3_CFLAGS -unroll -ipo -ipo_obj" + fi + fi + ;; esac -AC_SUBST(GOOM_LIBS) -AC_SUBST(WIN32_CPPFLAGS) -AM_CONDITIONAL(WIN32, test "x$SYS" = "xmingw32") + +if test "x$has_vis" = "xyes"; then + AC_DEFINE([ENABLE_VIS], [], [Define this if you have Sun UltraSPARC CPU]) + case "$cpuflags" in + *-mcpu=*) ;; + *) cpuflags="$cpuflags -mcpu=v9" ;; + esac +fi +AM_CONDITIONAL([ENABLE_VIS], test x"$has_vis" = x"yes") + +dnl Allow turning off/on of optimizations. By default, optimizations are +dnl enabled if --enable-debug is not specified. Even with --enable-debug, +dnl optimizations can be enabled by explicitly specifying --enable-optimizations +AC_ARG_ENABLE([optimizations], + [AS_HELP_STRING([--disable-optimizations], [Don't try to guess what optimization to enable])], + [], [test x"$enable_debug" != x"no" && enable_optimizations="no"]) +if test x"$enable_optimizations" = x"no"; then + O1_CFLAGS="$O0_CLFAGS" + O2_CFLAGS="$O0_CFLAGS" + O3_CFLAGS="$O0_CFLAGS" +else + O1_CFLAGS="$O1_CFLAGS $optflags $cpuflags" + O2_CFLAGS="$O2_CFLAGS $optflags $cpuflags" + O3_CFLAGS="$O3_CFLAGS $optflags $cpuflags" + + dnl For multi-pass compilation: never when cross-compiling + if test x"$cross_compiling" != x"yes"; then + if test x"$GCC" = x"yes"; then + CC_CHECK_CFLAGS([-fprofile-arcs], [CC_CHECK_CFLAGS([-fbranch-probabilities], + [PASS1_CFLAGS="-fprofile-arcs $PASS1_CFLAGS" + PASS2_CFLAGS="-fbranch-probabilities $PASS2_CFLAGS"])]) + else + pass1flags="-prof_dir \$(PWD)/\$(top_builddir)/ -prof_genx" + pass2flags="-prof_dir \$(PWD)/\$(top_builddir)/ -prof_use" + CC_CHECK_CFLAGS(["$pass1flags"], [CC_CHECK_CFLAGS(["$pass2flags"], + [PASS1_CFLAGS="$pass1flags $PASS1_CFLAGS" + PASS2_CFLAGS="$pass2flags $PASS2_CFLAGS"])]) + fi + fi +fi +AC_SUBST(O0_CFLAGS) +AC_SUBST(O1_CFLAGS) +AC_SUBST(O2_CFLAGS) +AC_SUBST(O3_CFLAGS) + +AC_SUBST(PASS1_CFLAGS) +AC_SUBST(PASS2_CFLAGS) + +test x"$DEFAULT_OCFLAGS" = x"" && DEFAULT_OCFLAGS='$(O3_CFLAGS)' +AC_SUBST(DEFAULT_OCFLAGS) + +if test x"$arch_x86" = x"yes"; then + AC_DEFINE([ARCH_X86], [], [Define this if you're running x86 architecture]) + AC_DEFINE([HAVE_MMX], [], [Define this if you can compile MMX asm instructions]) +fi +AM_CONDITIONAL([ARCH_X86], test x"$arch_x86" = x"yes") +AM_CONDITIONAL([HAVE_MMX], test x"$arch_x86" = x"yes") +AM_CONDITIONAL([HOST_OS_DARWIN], test x"$HOST_OS_DARWIN" = x"1") + +if test x"$enable_impure_text" = x"yes"; then + case "$host_or_hostalias" in + *solaris*) + if test "$GCC" = yes; then + IMPURE_TEXT_LDFLAGS="-mimpure-text" + else + IMPURE_TEXT_LDFLAGS="-z textoff" + fi + ;; + *darwin*) + IMPURE_TEXT_LDFLAGS="-Wl,-read_only_relocs,warning" + ;; + esac +fi +AC_SUBST(IMPURE_TEXT_LDFLAGS) + + +dnl ---------------------------- +dnl checks for library functions +dnl ---------------------------- + +dnl src/libfaad +AC_CHECK_DECL(lrintf,[ + AC_DEFINE([HAVE_LRINTF], [1], [Define this if the 'lrintf' function is declared in math.h]) + AC_DEFINE([_ISOC9X_SOURCE], [1], [Define this if you are ISO C9X compliant]) + ],,[ +#define _ISOC9X_SOURCE +#include <math.h> +]) + +dnl contrib/libdca, src/video_out/vidix/drivers/mach64_vid.c +AC_CHECK_FUNCS([memalign]) + +dnl src/input/input_file.c +AC_ARG_ENABLE([mmap], + AS_HELP_STRING([--enable-mmap], [Enable mmap() file loading (default: no)])) +if test x"$enable_mmap" = x"yes"; then + AC_CHECK_FUNCS([mmap]) +fi + +AC_CHECK_FUNCS([vsscanf sigaction sigset getpwuid_r nanosleep lstat memset readlink strchr va_copy]) + +AC_CHECK_FUNCS([snprintf _snprintf], [have_required_function="yes"]) + test x"$have_required_function" != x"yes" && AC_MSG_ERROR([required function not found]) +AC_CHECK_FUNCS([vsnprintf _vsnprintf], [have_required_function="yes"]) + test x"$have_required_function" != x"yes" && AC_MSG_ERROR([required function not found]) +AC_CHECK_FUNCS([strcasecmp _stricmp], [have_required_function="yes"]) + test x"$have_required_function" != x"yes" && AC_MSG_ERROR([required function not found]) +AC_CHECK_FUNCS([strncasecmp _strnicmp], [have_required_function="yes"]) + test x"$have_required_function" != x"yes" && AC_MSG_ERROR([required function not found]) + +AC_FUNC_FSEEKO + +AC_REPLACE_FUNCS([asprintf basename gettimeofday setenv strndup strpbrk strsep strtok_r timegm unsetenv]) + +AC_LIBSOURCE([hstrerror.c]) +AC_LINK_IFELSE([AC_LANG_PROGRAM([[#include <netdb.h>]], [[hstrerror(0)]])], + [AC_DEFINE([HAVE_HSTRERROR], 1, [Define to 1 if you have 'hstrerror' in <netdb.h>])], + [AC_LIBOBJ([hstrerror])]) + +AC_LIBSOURCE([dirent_msvc.c]) +AC_CHECK_FUNC([opendir], + [AC_DEFINE([HAVE_OPENDIR], 1, [Define to 1 if you have 'opendir' function])], + [if test x"$WIN32_SYS" = x"mingw32"; then + AC_LIBOBJ([dirent_msvc]) + else + AC_MSG_ERROR([dirent is needed (opendir, readdir, ...)]) + fi]) + + +dnl -------------------------- +dnl checks for system services +dnl -------------------------- + +AC_SYS_LARGEFILE + + + + + + + + + -dnl --------------------------------------------- -dnl dynamic linker -dnl --------------------------------------------- -AM_DL() dnl --------------------------------------------- @@ -340,7 +786,7 @@ dnl determine libdir name dnl --------------------------------------------- AC_MSG_CHECKING([libdir name]) -case $host in +case $host_or_hostalias in *-*-linux*) # Test if the compiler is 64bit echo 'int i;' > conftest.$ac_ext @@ -437,27 +883,6 @@ AM_CONDITIONAL([FFMPEG_DISABLE_POPULAR_CODECS], [test "x$enable_ffmpeg_popular_c LIBMPEG2_CFLAGS="" -AC_CHECK_DECL(lrintf,[ - AC_DEFINE(HAVE_LRINTF,1,[Define this if the 'lrintf' function is declared in math.h]) - AC_DEFINE(_ISOC9X_SOURCE,1,[Define this if you are ISO C9X compliant]) - ],,[ -#define _ISOC9X_SOURCE -#include <math.h> -]) -AC_CHECK_DECL(rintf,[ - AC_DEFINE(HAVE_RINTF,1,[Define this if the 'rintf' function is declared in math.h]) - ],,[ -#include <math.h> -]) - -AC_CHECK_FUNCS(memalign) - -AC_ARG_ENABLE([altivec], - AS_HELP_STRING([--disable-altivec], [do not use assembly codes for Motorola 74xx CPUs])) - -AC_ARG_ENABLE([vis], - AS_HELP_STRING([--disable-vis], [do not use assembly codes for Sun UltraSPARC CPUs])) - AC_ARG_ENABLE([mlib], AS_HELP_STRING([--disable-mlib], [do not build Sun mediaLib support])) @@ -499,87 +924,9 @@ AM_CONDITIONAL(HAVE_MLIB, test "x$ac_have_mlib" = "xyes") AC_SUBST(MLIB_LIBS) AC_SUBST(MLIB_CFLAGS) -dnl --------------------------------------------- -dnl Checks for X11 -dnl --------------------------------------------- - -if test "x$with_x" != "xno"; then - PKG_CHECK_MODULES([X], [x11 xext], , [ - AC_PATH_XTRA - - dnl Set xv_path if its not done already - dnl we do it here before rewriting X_LIBS - if test x$xv_path = x; then - xv_path=`echo $X_LIBS | sed -e 's/\-L\(.*\)/\1/'` - fi - - dnl ---------------------------------------------- - dnl Check for XShm support (required with X) - dnl ---------------------------------------------- - - if test "x$no_x" != "xyes"; then - ac_save_CPPFLAGS="$CPPFLAGS" - CPPFLAGS="$CPPFLAGS $X_CFLAGS" - AC_CHECK_HEADERS([X11/extensions/XShm.h], [true], - [AC_MSG_ERROR([XShm extension is required])]) - AC_CHECK_LIB([Xext], [main], [true], - [AC_MSG_ERROR([libXext is required])], [$X_LIBS]) - CPPFLAGS="$ac_save_CPPFLAGS" - X_LIBS="$X_LIBS $X_PRE_LIBS -lX11 -lXext" - fi - ]) -else - no_x="yes" -fi - -if test "x$no_x" != "xyes"; then - AC_DEFINE(HAVE_X11,1,[Define this if you have X11R6 installed]) -fi -AM_CONDITIONAL(HAVE_X11, [test "x$no_x" != "xyes"]) - - -dnl --------------------------------------------- -dnl Locate libraries needed for X health check -dnl --------------------------------------------- - -soname_script="/[[0-9]]$/! d; s%^.*/%% -t q -b -:q -q" -x_lib_location="`ls -1 "${x_libraries:-/usr/local/lib}/libX11.so"* "${x_libraries:-/usr/lib}/libX11.so"* 2>/dev/null | sed -e \"${soname_script}\"`" -AC_DEFINE_UNQUOTED([LIBX11_SO], "${x_lib_location:-libX11.so}", [The soname of libX11, needed for dlopen()]) -x_lib_location="`ls -1 "${x_libraries:-/usr/local/lib}/libXv.so"* "${x_libraries:-/usr/lib}/libXv.so"* 2>/dev/null | sed -e \"${soname_script}\"`" -AC_DEFINE_UNQUOTED([LIBXV_SO], "${x_lib_location:-libXv.so}", [The soname of libXv, needed for dlopen()]) - - -dnl --------------------------------------------- -dnl socket library -dnl --------------------------------------------- - -dnl Test for socket and network support library -NET_LIBS="" -AC_CHECK_LIB(socket, socket, NET_LIBS="-lsocket $NET_LIBS",) -AC_CHECK_LIB(nsl, gethostbyname, NET_LIBS="-lnsl $NET_LIBS",) -AC_SUBST(NET_LIBS) - - -dnl --------------------------------------------- -dnl socklen_t -dnl --------------------------------------------- -AC_CHECK_SOCKLEN_T - - -dnl --------------------------------------------- -dnl IPv6 -dnl --------------------------------------------- -AC_ARG_ENABLE([ipv6], - AS_HELP_STRING([--enable-ipv6], [enable use of IPv6])) +XINE_X11_SUPPORT -if test "x$enable_ipv6" = "xyes"; then - AC_DEFINE([ENABLE_IPV6], [1], [Enable this when IPv6 is requested]) -fi dnl --------------------------------------------- dnl zlib @@ -619,17 +966,6 @@ AC_SUBST(ZLIB_LIBS) dnl --------------------------------------------- -dnl check posix timers -dnl --------------------------------------------- - -AC_CHECK_LIB(rt, clock_getres, - [RT_LIBS="-lrt" - AC_DEFINE(HAVE_POSIX_TIMERS,1, - [Define this if you have POSIX timers.])], - AC_MSG_RESULT([*** no POSIX timers available.])) -AC_SUBST(RT_LIBS) - -dnl --------------------------------------------- dnl Check for OpenGL & [GLut | GLU] dnl --------------------------------------------- @@ -671,206 +1007,7 @@ fi AM_CONDITIONAL(HAVE_V4L, [test "x$have_v4l" = "xyes"]) -dnl ---------------------------------------------- -dnl Check for Xv and XvMC support -dnl ---------------------------------------------- - -dnl With recent XFree86 or Xorg, dynamic linking is preferred! -dnl Only dynamic linking is possible when using libtool < 1.4.0 - -AC_ARG_WITH(xv-path, AS_HELP_STRING([--with-xv-path=path], [where libXv is installed]), - xv_path="$withval",) - -AC_ARG_ENABLE([static-xv], - AS_HELP_STRING([--enable-static-xv],[Enable this to force linking against libXv.a])) - -if test "x$enable_static_xv" = "xyes"; then - xv_prefer_shared="no" -else - xv_prefer_shared="yes" -fi - -if test "x$no_x" != "xyes"; then - PKG_CHECK_MODULES([XV], [xv], [ - ac_have_xv="yes" - AC_DEFINE([HAVE_XV], [1], [Define this if you have libXv installed]) - ], [AC_FIND_LIBXV]) -fi -AM_CONDITIONAL(HAVE_XV, test "x$ac_have_xv" = "xyes") - - -host_or_hostalias="$host" -if test "$host_or_hostalias" = ""; then - dnl user has called ./configure with a host parameter unknown to - dnl config.sub; the canonical "$host" is empty - dnl - dnl Try the following switch with user's original host_alias - dnl input instead. - dnl - host_or_hostalias="$host_alias" -fi - -case "$host_or_hostalias" in - hppa*) - if test "x$ac_have_xv_static" = "xyes"; then - echo "warning: hppa linker - disabling static libXv" - XV_LIBS="libXv.so" - fi - ;; - - ppc-*-linux* | powerpc-*) - ppc_arch="yes" - ;; - - *) - ;; -esac -AM_CONDITIONAL(PPC_ARCH, test "x$ppc_arch" = "xyes") - -dnl -dnl Check if we can enable the xxmc plugin. -dnl - -AC_ARG_ENABLE([xvmc], - AS_HELP_STRING([--disable-xvmc], [Disable XxMC and XvMC outplut plugins]) ) - -if test "x$no_x" = "x" && test "x$enable_xvmc" != "xno"; then - -AC_ARG_WITH(xxmc-path, AS_HELP_STRING([--with-xxmc-path=path], [where libXvMC libraries for the - xxmc plugin are installed. Defalts to the default X library path.]), - xxmc_path="$withval", xxmc_path="$x_libraries") -AC_ARG_WITH(xxmc-lib, AS_HELP_STRING([--with-xxmc-lib=XXXX], [The name of the XvMC library - libXXXX.so for the xxmc plugin.]),xxmc_stub="$withval", - xxmc_stub="XvMCW") - -saved_libs="$LIBS" -saved_CPPFLAGS="$CPPFLAGS" -if test "x$x_includes" != "x"; then - CPPFLAGS="$CPPFLAGS -I$x_includes" -fi - -XXMC_LIBS="-L$xxmc_path -l$xxmc_stub" -AC_MSG_CHECKING(whether to enable the xxmc plugin with vld extensions) -AC_MSG_RESULT() -dnl Check if vld "extended" XvMC is available -if test "x$xxmc_stub" == "xXvMCW" && test "x$ac_have_xv" == "xyes"; then - AC_CHECK_LIB($xxmc_stub, XvMCPutSlice, - ac_have_xxmc="yes", - [ac_have_xxmc="no" - AC_MSG_RESULT([*** Could not link with -l$xxmc_stub for vld extensions.])], - [-L$xxmc_path $X_LIBS $X_PRE_LIBS $XV_LIBS -lXext $X_EXTRA_LIBS]) -else - if test "x$ac_have_xv" = "xyes"; then - AC_CHECK_LIB($xxmc_stub, XvMCPutSlice, - [ac_have_xxmc="yes" - XXMC_LIBS="$XXMC_LIBS -lXvMC"], - [ac_have_xxmc="no" - AC_MSG_RESULT([*** Could not link with -l$xxmc_stub -lXvMC for vld extensions.])], - [-L$xxmc_path -lXvMC $X_LIBS $X_PRE_LIBS $XV_LIBS -lXext $X_EXTRA_LIBS]) - else - ac_have_xxmc="no", - fi -fi - -if test "x$ac_have_xxmc" = "xyes"; then - AC_CHECK_HEADERS(X11/extensions/vldXvMC.h, - [ac_have_vldxvmc_h="yes"], - ac_have_vldxvmc="no",) - if test "x$ac_have_vldxvmc_h" = "xyes"; then - AC_DEFINE([HAVE_VLDXVMC], [1], - [Define 1 if you have vldXvMC.h]) - fi -fi -dnl Try fallback to standard XvMC if vld failed -if test "x$ac_have_xxmc" = "xno"; then - if test "x$xxmc_stub" == "xXvMCW"; then - AC_CHECK_LIB($xxmc_stub, XvMCCreateContext, - ac_have_xxmc="yes", - [ac_have_xxmc="no" - AC_MSG_RESULT([*** Could not link with -l$xxmc_stub for standard XvMC.])], - [-L$xxmc_path $X_LIBS $X_PRE_LIBS $XV_LIBS -lXext $X_EXTRA_LIBS]) - else - if test "x$ac_have_xv" = "xyes"; then - AC_CHECK_LIB($xxmc_stub, XvMCCreateContext, - [ac_have_xxmc="yes" - XXMC_LIBS="$XXMC_LIBS -lXvMC"], - [ac_have_xxmc="no" - AC_MSG_RESULT([*** Could not link with -lXvMC for standard XvMC.])], - [-L$xxmc_path -lXvMC $X_LIBS $X_PRE_LIBS $XV_LIBS -lXext $X_EXTRA_LIBS]) - else - ac_have_xxmc="no", - fi - fi -fi -if test "x$ac_have_xxmc" = "xyes"; then - AC_CHECK_HEADERS(X11/extensions/XvMC.h,, - ac_have_xxmc="no",) -fi -if test "x$ac_have_xxmc" = "xyes"; then - AC_DEFINE(HAVE_XXMC,1,[Define this to compile the xxmc plugin.]) - if test "x$ac_have_vldxvmc_h" = "xyes"; then - AC_MSG_RESULT([*** Enabling xxmc plugin with vld extensions.]) - else - AC_MSG_RESULT([*** Enabling xxmc plugin for standard XvMC *only*.]) - fi -else - AC_MSG_RESULT([*** Disabling xxmc plugin due to above errors.]) -fi -LIBS="$saved_libs" -fi -AM_CONDITIONAL(HAVE_VLDXVMC, test "x$ac_have_vldxvmc_h" = "xyes") -AM_CONDITIONAL(HAVE_XXMC, test "x$ac_have_xxmc" = "xyes") -AC_SUBST(XXMC_LIBS) - -dnl -dnl Check if we can enable the xvmc plugin. -dnl -if test "x$no_x" = "x" && test "x$enable_xvmc" != "xno"; then - -AC_ARG_WITH(xvmc-path, AS_HELP_STRING([--with-xvmc-path=path], [where libXvMC libraries for the - xvmc plugin are installed. Defalts to the default X library path.]), - xvmc_path="$withval", xvmc_path="$x_libraries") -AC_ARG_WITH(xvmc-lib, AS_HELP_STRING([--with-xvmc-lib=XXXX], [The name of the XvMC library - libXXXX.so for the xvmc plugin.]),xvmc_stub="$withval", - xvmc_stub="XvMCW") -saved_libs="$LIBS" -XVMC_LIBS="-L$xvmc_path -l$xvmc_stub" -AC_MSG_CHECKING(whether to enable the xvmc plugin) -AC_MSG_RESULT() -if test "x$xvmc_stub" == "xXvMCW"; then - AC_CHECK_LIB($xvmc_stub, XvMCCreateContext, - ac_have_xvmc="yes", - [ac_have_xvmc="no" - AC_MSG_RESULT([*** Could not link with -l$xvmc_stub.])], - [-L$xvmc_path $X_LIBS $X_PRE_LIBS $XV_LIBS -lXext $X_EXTRA_LIBS]) -else - if test "x$ac_have_xv" = "xyes"; then - AC_CHECK_LIB($xvmc_stub, XvMCCreateContext, - [ac_have_xvmc="yes" - XVMC_LIBS="$XVMC_LIBS -lXvMC"], - [ac_have_xvmc="no" - AC_MSG_RESULT([*** Could not link with -lXvMC.])], - [-L$xvmc_path -lXvMC $X_LIBS $X_PRE_LIBS $XV_LIBS -lXext $X_EXTRA_LIBS]) - else - ac_have_xvmc="no", - fi -fi -if test "x$ac_have_xvmc" = "xyes"; then - AC_CHECK_HEADERS(X11/extensions/XvMC.h,, - ac_have_xvmc="no",) -fi -if test "x$ac_have_xvmc" = "xyes"; then - AC_DEFINE(HAVE_XVMC,1,[Define this if you have an XvMC library and XvMC.h installed.]) - AC_MSG_RESULT([*** Enabling old xvmc plugin.]) -else - AC_MSG_RESULT([*** Disabling old xvmc plugin due to above errors.]) -fi -CPPFLAGS="$saved_CPPFLAGS" -LIBS="$saved_libs" -fi -AM_CONDITIONAL(HAVE_XVMC, test "x$ac_have_xvmc" = "xyes") -AC_SUBST(XVMC_LIBS) - +XINE_XV_SUPPORT dnl --------------------------------------------- dnl Check for xcb @@ -1014,18 +1151,14 @@ dnl --------------------------------------------- dnl Check whether to build Mac OS X video output driver dnl --------------------------------------------- -AC_ARG_ENABLE(macosx_video, AS_HELP_STRING([--enable-macosx-video], [enable support for Mac OS X OpenGL video output]), - have_macosx_video=$enableval) -AM_CONDITIONAL(HAVE_MACOSX_VIDEO, [test "x$have_macosx_video" = "xyes"]) +MACOSX_VIDEO_SUPPORT dnl --------------------------------------------- dnl Check whether to build Mac OS X audio output driver dnl --------------------------------------------- -AC_ARG_ENABLE(coreaudio, AS_HELP_STRING([--enable-coreaudio], [enable support for Mac OS X Coreaudio output]), - have_coreaudio=$enableval) -AM_CONDITIONAL(HAVE_COREAUDIO, [test "x$have_coreaudio" = "xyes"]) +MACOSX_AUDIO_SUPPORT dnl --------------------------------------------- @@ -1731,248 +1864,7 @@ dnl --------------------------------------------- dnl Video CD dnl --------------------------------------------- -AC_ARG_ENABLE(vcd, AS_HELP_STRING([--disable-vcd], [do not compile VCD plugin]), - enable_vcd=$enableval, enable_vcd=yes) - -dnl Force build of both vcd plugins, for now. -dnl AC_ARG_ENABLE(vcdo, AS_HELP_STRING([--disable-vcdo], [do not compile old VCD plugin]), -dnl enable_vcdo=$enableval, enable_vcdo=yes) -dnl -enable_vcdo="yes" - -AC_ARG_WITH(internal-vcdlibs, AS_HELP_STRING([--with-internal-vcdlibs], [force using internal libcdio/libvcd/libvcdinfo]), - [internal_vcdnav="$withval"], [internal_vcdnav="no"]) - -if test "x$enable_vcd" = "xyes"; then - dnl empty_array_size - AC_MSG_CHECKING([how to create empty arrays]) - - empty_array_size="xxx" - AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[]], [[struct { int foo; int bar[]; } doo;]])],[empty_array_size=""],[]) - - if test "x$empty_array_size" = "xxxx";then - AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[]], [[struct { int foo; int bar[0]; } doo;]])],[empty_array_size="0"],[]) - fi - - if test "x$empty_array_size" = "xxxx" - then - AC_MSG_ERROR([compiler is unable to creaty empty arrays]) - else - AC_DEFINE_UNQUOTED(EMPTY_ARRAY_SIZE, $empty_array_size, - [what to put between the brackets for empty arrays]) - changequote(`,') - msg="[${empty_array_size}]" - changequote([,]) - AC_MSG_RESULT($msg) - fi - dnl empty_array_size - - if test "x$internal_vcdnav" = "xno" ; then - PKG_CHECK_MODULES([LIBCDIO], [libcdio >= 0.71], [], [internal_vcdnav=yes]) - PKG_CHECK_MODULES([LIBVCDINFO], [libvcdinfo >= 0.7.23], [], [internal_vcdnav=yes]) - if test "x$internal_vcdnav" = "xyes"; then - AC_MSG_RESULT([Use included libcdio/libvcdinfo support]) - fi - fi - - dnl check twice, fallback is internal copy - if test "x$internal_vcdnav" = "xno"; then - AC_DEFINE([HAVE_VCDNAV], [1], [Define this if you use external libcdio/libvcdinfo]) - else - AC_DEFINE_UNQUOTED(HOST_ARCH, "$host_os/$host_cpu", [host os/cpu identifier]) - - AC_DEFINE(_DEVELOPMENT_, [], enable warnings about being development release) - AC_HEADER_STDC - AC_CHECK_HEADERS(sys/stat.h stdint.h glob.h inttypes.h stdbool.h) - - if test "x$ac_cv_header_stdint_h" != "xyes" - then - AC_CHECK_SIZEOF(int, 4) - AC_CHECK_SIZEOF(long, 4) - AC_CHECK_SIZEOF(long long, 8) - fi - - dnl ISOC99_PRAGMA - AC_MSG_CHECKING([whether $CC supports ISOC99 _Pragma()]) - AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[]], [[_Pragma("pack(1)")]])],[ - ISOC99_PRAGMA=yes - AC_DEFINE(HAVE_ISOC99_PRAGMA, [], [Supports ISO _Pragma() macro]) - ],[ISOC99_PRAGMA=no]) - AC_MSG_RESULT($ISOC99_PRAGMA) - - dnl - dnl bitfield order - dnl - AC_MSG_CHECKING([bitfield ordering in structs]) - - dnl basic compile test for all platforms - AC_COMPILE_IFELSE([ -int main() { - struct { char bit_0:1, bit_12:2, bit_345:3, bit_67:2; } -#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ > 4) - __attribute__((packed)) -#endif - bf = { 1,1,1,1 }; - switch (0) case 0: case sizeof(bf) == 1:; - return 0; -} -], [], AC_MSG_ERROR([compiler doesn't support bitfield structs])) - - - dnl run test - AC_RUN_IFELSE([ -int main() { - struct { char bit_0:1, bit_12:2, bit_345:3, bit_67:2; } -#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ > 4) - __attribute__((packed)) -#endif - bf = { 1,1,1,1 }; - if (sizeof (bf) != 1) return 1; - return *((unsigned char*) &bf) != 0x4b; } -], bf_lsbf=1, [ - AC_RUN_IFELSE([ -int main() { - struct { char bit_0:1, bit_12:2, bit_345:3, bit_67:2; } -#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ > 4) - __attribute__((packed)) -#endif - bf = { 1,1,1,1 }; - if (sizeof (bf) != 1) return 1; - return *((unsigned char*) &bf) != 0xa5; } -], bf_lsbf=0, AC_MSG_ERROR([unsupported bitfield ordering])) - ], - [case "$host" in - *-*-mingw32* | *-*-cygwin*) - bf_lsbf=1 - ;; - universal-*-darwin*) - bf_lsbf=0 - ;; - *) - AC_MSG_RESULT([unknown]) - AC_MSG_ERROR([value of bitfield test isn't known for $host -********************************************************************* -Value of bitfield test can't be found out for cross-compiling and we -don't know its value for host "$host". - -Because it's needed for VCD plugin, disable VCD by configure option ---disable-vcd or use external VCD library. -*********************************************************************]) - esac] -) - - if test "x$cross_compiling" = "xyes"; then - TEXT=" (guessed)" - else - TEXT="" - fi - if test "x$bf_lsbf" = "x1"; then - AC_MSG_RESULT(LSBF${TEXT}) - AC_DEFINE(BITFIELD_LSBF, [], [compiler does lsbf in struct bitfields]) - else - AC_MSG_RESULT(MSBF${TEXT}) - fi - - AC_CHECK_HEADERS([errno.h fcntl.h \ - stdbool.h stdlib.h stdint.h stdio.h string.h \ - strings.h linux/version.h sys/cdio.h sys/stat.h \ - sys/types.h ]) - - LIBCDIO_CFLAGS='-I$(top_srcdir)/src/input/vcd/libcdio' - LIBCDIO_LIBS='$(top_builddir)/src/input/vcd/libcdio/libcdio.la' - LIBISO9660_LIBS='$(top_builddir)/src/input/vcd/libcdio/libiso9660.la' - LIBVCD_CFLAGS='-I$(top_srcdir)/src/input/vcd/libvcd' - LIBVCD_LIBS='$(top_builddir)/src/input/vcd/libvcd/libvcd.la' - LIBVCDINFO_LIBS='$(top_builddir)/src/input/vcd/libvcd/libvcdinfo.la' - - case $host_os in - darwin*) - AC_CHECK_HEADERS(IOKit/IOKitLib.h CoreFoundation/CFBase.h, - [have_iokit_h="yes"]) - if test "x$have_iokit_h" = "xyes" ; then - AC_DEFINE([HAVE_DARWIN_CDROM], [1], - [Define 1 if you have Darwin OS X-type CD-ROM support]) - fi - ;; - linux*) - AC_CHECK_HEADERS(linux/version.h) - AC_CHECK_HEADERS(linux/cdrom.h, [have_linux_cdrom_h="yes"]) - if test "x$have_linux_cdrom_h" = "xyes" ; then - AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[]], [[ -#include <linux/cdrom.h> -struct cdrom_generic_command test; -int has_timeout=sizeof(test.timeout);]])], - [AC_DEFINE([HAVE_LINUX_CDROM_TIMEOUT], [1], - [Define 1 if timeout is in cdrom_generic_command struct])],[]) - AC_DEFINE([HAVE_LINUX_CDROM], [1], - [Define 1 if you have Linux-type CD-ROM support]) - fi - ;; - bsdi*) - AC_CHECK_HEADERS(dvd.h, [have_bsdi_dvd_h="yes"]) - if test "x$have_bsdi_dvd_h" = "xyes" ; then - AC_DEFINE([HAVE_BSDI_CDROM], [1], - [Define 1 if you have BSDI-type CD-ROM support]) - fi - ;; - sunos*|sun*|solaris*) - AC_CHECK_HEADERS(sys/cdio.h) - AC_DEFINE([HAVE_SOLARIS_CDROM], [1], - [Define 1 if you have Solaris CD-ROM support]) - ;; - cygwin*) - AC_DEFINE([CYGWIN], [1], - [Define 1 if you are compiling using cygwin]) - AC_DEFINE([HAVE_WIN32_CDROM], [1], - [Define 1 if you have MinGW CD-ROM support]) - LIBCDIO_LIBS="$LIBCDIO_LIBS -lwinmm" - LIBVCD_LIBS="$LIBVCD_LIBS -lwinmm" - ;; - mingw*) - AC_DEFINE([MINGW32], [1], - [Define 1 if you are compiling using MinGW]) - AC_DEFINE([HAVE_WIN32_CDROM], [1], - [Define 1 if you have MinGW CD-ROM support]) - ;; - freebsd4.*) - AC_DEFINE([HAVE_FREEBSD_CDROM], [1], - [Define 1 if you have FreeBSD CD-ROM support]) - ;; - *) - AC_MSG_WARN(Don't have OS CD-reading support for ${host_os}...) - AC_MSG_WARN(Will use generic support.) - ;; - esac - AC_SUBST(LINUX_CDROM_TIMEOUT) - AC_SUBST(HAVE_BSDI_CDROM) - AC_SUBST(HAVE_DARWIN_CDROM) - AC_SUBST(HAVE_FREEBSD_CDROM) - AC_SUBST(HAVE_LINUX_CDROM) - AC_SUBST(HAVE_SOLARIS_CDROM) - AC_SUBST(HAVE_WIN32_CDROM) - AC_SUBST(LINUX_CDROM_TIMEOUT) - AC_SUBST(LIBVCD_SYSDEP) - - AC_CHECK_FUNCS( bzero memcpy ) - - AC_CHECK_MEMBER([struct tm.tm_gmtoff], - [AC_DEFINE(HAVE_TM_GMTOFF, 1, - [Define if struct tm has the tm_gmtoff member.])], - , - [#include <time.h>]) - fi -fi - -AC_DEFINE([LIBCDIO_CONFIG_H], 1, [Get of rid system libcdio build configuration]) -AC_DEFINE([EXTERNAL_LIBCDIO_CONFIG_H], 1, [Get of rid system libcdio build configuration]) -AC_SUBST(LIBCDIO_CFLAGS) -AC_SUBST(LIBCDIO_LIBS) -AC_SUBST(LIBISO9660_LIBS) -AC_SUBST(LIBVCD_CFLAGS) -AC_SUBST(LIBVCD_LIBS) -AC_SUBST(LIBVCDINFO_LIBS) -AM_CONDITIONAL(HAVE_VCDNAV, [test "x$internal_vcdnav" = "xno"]) -AM_CONDITIONAL(ENABLE_VCD, [test "x$enable_vcd" = "xyes"]) +VCD_SUPPORT dnl --------------------------------------------- @@ -2064,7 +1956,7 @@ AC_ARG_WITH([real-codecs-path], dnl On some systems, we cannot enable Real codecs support to begin with. dnl This includes Darwin, that uses Mach-O rather than ELF. -case $host in +case $host_or_hostalias in *-darwin*) enable_real_codecs="no" ;; esac @@ -2083,338 +1975,47 @@ fi AM_CONDITIONAL([ENABLE_REAL], [test "x$enable_real_codecs" != "xno"]) -dnl -------------------------------------------- -dnl mmap() support -dnl -------------------------------------------- - -AC_ARG_ENABLE([mmap], - AS_HELP_STRING([--enable-mmap], [Enable mmap() file loading (default: no)])) - -if test "x$enable_mmap" = "xyes"; then - AC_CHECK_FUNCS([mmap]) -fi - -dnl --------------------------------------------- -dnl antialising support -dnl --------------------------------------------- - -AC_ARG_ENABLE([antialiasing], - AS_HELP_STRING([--enable-antialiasing], [enable font antialiasing])) - -if test "x$enable_antialiasing" = "xyes"; then - AC_DEFINE(ENABLE_ANTIALIASING,1,[Define this to 1 to enable font antialising.]) -fi - -dnl --------------------------------------------- -dnl ip_mreqn -dnl --------------------------------------------- - -AC_CHECK_IP_MREQN -if test "x$have_ip_mreqn" = "xyes"; then - AC_DEFINE(HAVE_IP_MREQN,1,[Define this if you have ip_mreqn in netinet/in.h]) -fi - -dnl --------------------------------------------- -dnl restrict keyword finding (from gstreamer) -dnl --------------------------------------------- -restrict="" -for restrict_keyword in restrict __restrict__ __restrict; do - AC_MSG_CHECKING(for restrict keyword $restrict_keyword) - AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[]], [[ void foo(char * $restrict_keyword p); ]])],[ - KEYWORD_FOUND=yes && AC_MSG_RESULT(yes) ],[ - KEYWORD_FOUND=no && AC_MSG_RESULT(no) ]) - if test "x$KEYWORD_FOUND" = xyes; then - restrict="$restrict_keyword" - break - fi -done -if test "x$restrict" = x; then - AC_MSG_ERROR(No restrict keyword found) -fi -AC_DEFINE_UNQUOTED(restrict, $restrict, [restrict keyword]) - -dnl --------------------------------------------- -dnl ASM ALIGN is power of two ? -dnl Used by internal FFmpeg and Planar postprocess dnl --------------------------------------------- -AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[]], [[ asm (".align 3"); ]])], - AC_DEFINE([ASMALIGN_1SLN], [1], [define if '.align n' means alignment to (1<<n)-byte boundaries]), - :) -AH_TOP([#ifndef __XINE_CONFIG_H__ -#define __XINE_CONFIG_H__ 1 -]) -AH_BOTTOM([#ifdef ASMALIGN_1SLN -# define ASMALIGN(ZEROBITS) ".align " #ZEROBITS "\n\t" -#else -# define ASMALIGN(ZEROBITS) ".align 1<<" #ZEROBITS "\n\t" -#endif -#endif /* __XINE_CONFIG_H__ */ -]) - -dnl --------------------------------------------- -dnl Some extra checks. -dnl --------------------------------------------- - -AC_SYS_LARGEFILE -AC_CHECK_LIB(posix4, sched_get_priority_min) -AC_CHECK_FUNCS([vsscanf sigaction sigset getpwuid_r nanosleep lstat memset readlink strchr va_copy]) -AC_CHECK_FUNCS([snprintf _snprintf], [some_snprintf="yes"; break]) -AC_CHECK_FUNCS([vsnprintf _vsnprintf], [some_vsnprintf="yes"; break]) -AC_CHECK_FUNCS([strcasecmp _stricmp], [some_strcasecmp="yes"; break]) -AC_CHECK_FUNCS([strncasecmp _strnicmp], [some_strncasecmp="yes"; break]) -if test "x$some_snprintf" != "xyes" -o \ - "x$some_vsnprintf" != "xyes" -o \ - "x$some_strcasecmp" != "xyes" -o \ - "x$some_strncasecmp" != "xyes"; then - AC_MSG_ERROR([required function not found]) -fi -AC_FUNC_FSEEKO -AC_CHECK_HEADERS(assert.h byteswap.h malloc.h execinfo.h ucontext.h sys/mman.h sys/mixer.h libgen.h netdb.h dirent.h sys/times.h sys/ioctl.h sys/param.h alloca.h) -AC_REPLACE_FUNCS(asprintf basename gettimeofday setenv strndup strpbrk strsep strtok_r timegm unsetenv) - -AC_LIBSOURCE(hstrerror.c) -AC_LINK_IFELSE([#include <netdb.h> -int main(void) { - hstrerror(0); -}], ac_cv_function_system_hstrerror="yes") -AC_CHECK_LIB([resolv], [hstrerror], [ - ac_cv_function_system_hstrerror="yes" - NET_LIBS="-lresolv $NET_LIBS" -]) -AC_SUBST(NET_LIBS) -if test "x$ac_cv_function_system_hstrerror" = "xyes"; then - AC_DEFINE(HAVE_HSTRERROR, 1, [Define to 1 if you have 'hstrerror' in <netdb.h>]) - -else - AC_LIBOBJ(hstrerror) -fi - -AC_LIBSOURCE(dirent_msvc.c) -AC_CHECK_FUNC(opendir, - [AC_DEFINE(HAVE_OPENDIR, 1, [Define to 1 if you have 'opendir' function])], - [if test "x$SYS" = "xmingw32"; then - AC_LIBOBJ(dirent_msvc) - else - AC_MSG_ERROR([dirent is needed (opendir, readdir, ...)]) - fi]) - -AH_BOTTOM([/* include internal system specific header */ -#include "os_internal.h"]) - - -dnl --------------------------------------------- -dnl cflags and debug cflags -dnl --------------------------------------------- - -AC_SUBST(DEBUG_CFLAGS) -DEBUG_CFLAGS="-g -DDEBUG $CFLAGS" - -dnl dummy -ASFLAGS="$ASFLAGS" -AC_SUBST(ASFLAGS) - -dnl --------------------------------------------- -dnl Check for some __attribute__ support needed +dnl For win32 libraries location, needed by libw32dll. dnl --------------------------------------------- -CC_ATTRIBUTE_ALIGNED - -CC_ATTRIBUTE_PACKED( - [AC_DEFINE([XINE_PACKED], [__attribute__((packed))], [Mark a structure as being packed])], - [AC_MSG_WARN([Your compiler doesn't support __attribute__((packed)); xine might not work as expected.]) - AC_DEFINE([XINE_PACKED], [], [Dummy mark a structure as being packed])] -) - -CC_ATTRIBUTE_MALLOC - -CC_ATTRIBUTE_VISIBILITY([protected], [visibility_export="protected"], - [CC_ATTRIBUTE_VISIBILITY([default], [visibility_export="default"])] -) - -if test "x$visibility_export" != "x"; then - CC_FLAG_VISIBILITY([ - AC_DEFINE([EXPORTED], [__attribute__((visibility("default")))], - [Mark a symbol as being exported if visibility is changed]) - VISIBILITY_FLAG="-fvisibility=hidden" - ], [AC_DEFINE([EXPORTED], [], [Dummy mark as being exported]) - ]) -else - AC_DEFINE([EXPORTED], [], [Dummy mark as being exported]) -fi - -AC_SUBST([VISIBILITY_FLAG]) - -CC_ATTRIBUTE_SENTINEL -CC_ATTRIBUTE_FORMAT -CC_ATTRIBUTE_FORMAT_ARG - -AC_OPTIMIZATIONS - -arch_x86="no" -enable_armv4l="no" - -case "$host_or_hostalias" in - i?86-* | k?-* | athlon-* | pentium*-) - dnl enable x86 specific parts of the code - dnl - dnl all of this stuff needs gcc/gas; it uses gnu c compiler extensions - dnl like the extended asm() or __attribute(__cdecl__), or other direct - dnl mmx/sse/3dnow assembler instructions. - dnl - AC_DEFINE_UNQUOTED(ARCH_X86_32,,[Define this if you're running x86 architecture 32 bits]) - arch_x86="yes" - enable_impure_text="yes" - - case "$host_or_hostalias" in - *-*-cygwin) - LIBS="$LIBS @INTLLIBS@ -lkernel32" - ;; - esac - ;; - x86_64-*) - AC_DEFINE_UNQUOTED(ARCH_X86_64,,[Define this if you're running x86 architecture 64 bits]) - arch_x86="yes" - ;; - universal-*-darwin*) - enable_impure_text="yes" - ;; - powerpc-*-darwin*) - dnl avoid ppc compilation crash - AS="$CC" - AC_DEFINE_UNQUOTED(ARCH_PPC,,[Define this if you're running PowerPC architecture]) - - AC_CHECK_HEADER([altivec.h], , enable_altivec=no) - - if test "x$enable_altivec" != xno; then - AC_DEFINE_UNQUOTED(ENABLE_ALTIVEC,,[Define this if you want to use altivec on PowerPC CPUs]) - CFLAGS="$CFLAGS -faltivec -maltivec" - LIBMPEG2_CFLAGS="$LIBMPEG2_CFLAGS -force_cpusubtype_ALL -faltivec -maltivec" - fi - ;; - ppc-*-linux* | powerpc-*) - dnl avoid ppc compilation crash - AS="$CC" - AC_DEFINE_UNQUOTED(ARCH_PPC,,[Define this if you're running PowerPC architecture]) - - AC_CHECK_HEADER([altivec.h], , enable_altivec=no) - - if test "x$enable_altivec" != xno; then - AC_DEFINE_UNQUOTED(ENABLE_ALTIVEC,,[Define this if you have a Motorola 74xx CPU]) - CFLAGS="$CFLAGS -maltivec" - LIBMPEG2_CFLAGS="$LIBMPEG2_CFLAGS -maltivec" - fi - ;; - sparc*-*-linux*) - if test "x$enable_vis" != xno; then - has_vis=yes - fi - - AC_DEFINE_UNQUOTED(ARCH_SPARC,,[Define this if you're running SPARC architecture]) - ;; - sparc-*-solaris*) - if test "$GCC" = yes; then - case `$CC --version 2>/dev/null` in - 1.*|2.*) ;; - *) - if test "x$enable_vis" != xno; then - has_vis=yes - fi - ;; - esac - - AC_DEFINE_UNQUOTED(ARCH_SPARC,,[Define this if you're running SPARC architecture]) - fi - ;; - armv4l-*-linux*) - enable_armv4l="yes" - ;; -esac +AC_ARG_WITH([w32-path], + AS_HELP_STRING([--with-w32-path=path], [location of Win32 binary codecs]), + [w32_path="$withval"], [w32_path="/usr/lib/codecs"]) +AC_SUBST(w32_path) -if test "x$has_vis" = "xyes"; then - AC_DEFINE_UNQUOTED(ENABLE_VIS,,[Define this if you have Sun UltraSPARC CPU]) - case "$CFLAGS" in - *-mcpu=*) ;; - *) CFLAGS="$CFLAGS -mcpu=v9" ;; - esac -fi -AM_CONDITIONAL(ENABLE_VIS, test "x$has_vis" = "xyes") +AC_ARG_ENABLE([w32dll], + AS_HELP_STRING([--disable-w32dll], [Disable Win32 DLL support]), + , [enable_w32dll=$with_gnu_as]) -if test "x$arch_x86" = "xyes"; then - AC_DEFINE_UNQUOTED(ARCH_X86,,[Define this if you're running x86 architecture]) - AC_DEFINE_UNQUOTED(HAVE_MMX,,[Define this if you can compile MMX asm instructions]) -fi -AM_CONDITIONAL(ARCH_X86, test "x$arch_x86" = "xyes") -AM_CONDITIONAL(HAVE_MMX, test "x$arch_x86" = "xyes") - -case $host_os in - darwin*) - HOST_OS_DARWIN=1 - AC_DEFINE_UNQUOTED(HOST_OS_DARWIN, 1, [Define this if built on Mac OS X/Darwin]) - OBJCFLAGS="-D_INTL_REDIRECT_MACROS $OBJCFLAGS" - ;; +case $host_or_hostalias in + *-mingw* | *-cygwin) + enable_w32dll="no" ;; + i?86-* | k?-* | athlon-* | pentium*-) + if test "x$enable_w32dll" != "xno"; then + CC_PROG_AS + fi + test "x$enable_w32dll" = "x" && \ + enable_w32dll="$with_gnu_as" + ;; + *) + enable_w32dll="no" ;; esac -AM_CONDITIONAL(HOST_OS_DARWIN, test "x$HOST_OS_DARWIN" = "x1") - -dnl --------------------------------------------- -dnl Set IMPURE_TEXT_LDFLAGS -dnl --------------------------------------------- -IMPURE_TEXT_LDFLAGS="" -if test "x$enable_impure_text" = xyes; then - case "$host_or_hostalias" in - *solaris*) - if test "$GCC" = yes; then - IMPURE_TEXT_LDFLAGS="-mimpure-text" - else - IMPURE_TEXT_LDFLAGS="-z textoff" - fi - ;; - *-darwin*) - IMPURE_TEXT_LDFLAGS="-Wl,-read_only_relocs,warning" - ;; - esac -fi -AC_SUBST(IMPURE_TEXT_LDFLAGS) - -dnl --------------------------------------------- -dnl HAVE_ARMV4L is currently used in libavcodec makefile.am -dnl --------------------------------------------- - -AM_CONDITIONAL(HAVE_ARMV4L, test "x$enable_armv4l" = "xyes") - - -dnl --------------------------------------------- -dnl Use features of autoconf 2.61, but stay compatible -dnl with older versions. -dnl --------------------------------------------- +if test "x$enable_w32dll" = "xyes" && \ + test "x$with_gnu_as" = "xno"; then -if test "x$datarootdir" = "x"; then - datarootdir='${datadir}' - AC_SUBST(datarootdir) + AC_MSG_ERROR([You need GNU as to enable Win32 codecs support]) fi -if test "x$docdir" = "x"; then - docdir='${datarootdir}/doc/${PACKAGE}' - AC_SUBST(docdir) -fi +AM_CONDITIONAL(HAVE_W32DLL, test "x$enable_w32dll" != "xno") -if test "x$htmldir" = "x"; then - htmldir='${docdir}' - AC_SUBST(htmldir) -fi dnl --------------------------------------------- dnl XINE_ROOTDIR does not work if architecture independent files are dnl installed to another place than architecture dependent files !!! dnl --------------------------------------------- -if test "x$prefix" = xNONE; then - prefix="${ac_default_prefix}" -fi -if test "x$exec_prefix" = xNONE; then - exec_prefix='${prefix}' -fi - dnl dnl installation directories and directories relative to prefix dnl @@ -2438,7 +2039,7 @@ XINE_REL_PLUGINDIR="`makeexpand "$XINE_PLUGINDIR"`" XINE_REL_PLUGINDIR="`makeexpand "$XINE_REL_PLUGINDIR" | sed -e "s,^${prefix}/,,"`" XINE_REL_FONTDIR="`makeexpand "$XINE_FONTDIR" | sed -e "s,^${prefix}/,,"`" XINE_REL_LOCALEDIR="`makeexpand "$XINE_LOCALEDIR" | sed -e "s,^${prefix}/,,"`" -if test "x$SYS" = "xmingw32" -o "x$SYS" = "xcygwin"; then +if test "x$WIN32_SYS" = "xmingw32" -o "x$WIN32_SYS" = "xcygwin"; then dnl polish paths (MinGW runtime accepts both \ and / anyway) XINE_REL_PLUGINDIR="`echo "$XINE_REL_PLUGINDIR" | sed -e 's/\\//\\\\\\\\/g'`" XINE_REL_FONTDIR="`echo "$XINE_REL_FONTDIR" | sed -e 's/\\//\\\\\\\\/g'`" @@ -2491,62 +2092,6 @@ AC_SUBST(XINE_SCRIPTPATH) dnl --------------------------------------------- -dnl Some informations about xine-lib compilation -dnl --------------------------------------------- - -XINE_BUILD_CC="`$CC -v 2>&1 | tail -1 2>/dev/null`" -XINE_BUILD_OS="`uname -s -r -m`" -XINE_BUILD_DATE="`date \"+%a %d %b %Y %T\"`" -AC_SUBST(XINE_BUILD_CC) -AC_SUBST(XINE_BUILD_OS) -AC_SUBST(XINE_BUILD_DATE) - - -dnl --------------------------------------------- -dnl For win32 libraries location, needed by libw32dll. -dnl --------------------------------------------- - -AC_ARG_WITH([w32-path], - AS_HELP_STRING([--with-w32-path=path], [location of Win32 binary codecs]), - [w32_path="$withval"], [w32_path="/usr/lib/codecs"]) -AC_SUBST(w32_path) - -AC_ARG_ENABLE([w32dll], - AS_HELP_STRING([--disable-w32dll], [Disable Win32 DLL support]), - , [enable_w32dll=$with_gnu_as]) - -case $host in - *-mingw* | *-cygwin) - enable_w32dll="no" ;; - i?86-* | k?-* | athlon-* | pentium*-) - if test "x$enable_w32dll" != "xno"; then - CC_PROG_AS - fi - test "x$enable_w32dll" = "x" && \ - enable_w32dll="$with_gnu_as" - ;; - *) - enable_w32dll="no" ;; -esac - -if test "x$enable_w32dll" = "xyes" && \ - test "x$with_gnu_as" = "xno"; then - - AC_MSG_ERROR([You need GNU as to enable Win32 codecs support]) -fi - -AM_CONDITIONAL(HAVE_W32DLL, test "x$enable_w32dll" != "xno") - - -dnl --------------------------------------------- -dnl some include paths ( !!! DO NOT REMOVE !!! ) -dnl --------------------------------------------- - -INCLUDES='-I$(top_srcdir) -I$(top_builddir)/include -I$(top_srcdir)/include -I$(top_srcdir)/src -I$(top_builddir)/src/xine-engine -I$(top_srcdir)/src/xine-engine -I$(top_srcdir)/src/xine-utils $(INTLDIR) -I$(top_builddir)/src/input -I$(top_srcdir)/src/input $(WIN32_CPPFLAGS) -I$(top_builddir)/lib -I$(top_srcdir)/lib' -AC_SUBST(INCLUDES) - - -dnl --------------------------------------------- dnl Get where .m4 should be installed. dnl --------------------------------------------- @@ -2570,41 +2115,6 @@ AC_SUBST(ACLOCAL_DIR) AM_CONDITIONAL([INSTALL_M4],[test "x$ACLOCAL_DIR" != "x"]) -dnl --------------------------------------------- -dnl It seems automake 1.5 don't take care about this script -dnl --------------------------------------------- - -if test ! -z "$am_depcomp"; then - DEPCOMP="depcomp" -fi -AC_SUBST(DEPCOMP) - - -dnl --------------------------------------------- -dnl Check for documentation formatting tool -dnl --------------------------------------------- - -AC_CHECK_PROG(SGMLTOOLS, sgmltools, sgmltools, no) -AM_CONDITIONAL([HAVE_SGMLTOOLS], [test "$SGMLTOOLS" != "no"]) - -AC_CHECK_PROG(FIG2DEV, fig2dev, fig2dev, no) -AM_CONDITIONAL([HAVE_FIG2DEV], [test "$FIG2DEV" != "no"]) - -dnl --------------------------------------------- -dnl Newest automake workaround -dnl --------------------------------------------- - -AC_SUBST(mkdir_p) -if test -n "$ac_aux_dir"; then - case "$ac_aux_dir" in - /*) MKINSTALLDIRS="$ac_aux_dir/install-sh -d" ;; - *) MKINSTALLDIRS="\$(top_builddir)/$ac_aux_dir/install-sh -d" ;; - esac -else - MKINSTALLDIRS="\$(top_srcdir)/install-sh -d" -fi -AC_SUBST(MKINSTALLDIRS) - dnl this is an internal function we should not use, but dnl as long as neither autoconf nor automake offer an A[CM]_PROG_OBJC dnl check we will have to call it @@ -2612,45 +2122,28 @@ _AM_DEPENDENCIES([OBJC]) AM_CONDITIONAL([BUILD_DMX_IMAGE], [test "x$have_imagemagick" = "xyes" -o "x$no_gdkpixbuf" != "xyes"]) -dnl Important warnings we _don't_ want to skip -dnl Don't put these under conditional for optimisations, because these -dnl need always to be enabled. -CC_CHECK_CFLAGS([-Wformat=2], [wformat="-Wformat=2"], - [CC_CHECK_CFLAGS([-Wformat], [wformat="-Wformat"])]) +dnl --------------------------------------------- +dnl some include paths ( !!! DO NOT REMOVE !!! ) +dnl --------------------------------------------- -test "x$wformat" != "x" && \ - CC_CHECK_CFLAGS([-Wno-format-zero-length], [wformat="$wformat -Wno-format-zero-length"]) +INCLUDES='-I$(top_srcdir) -I$(top_builddir)/include -I$(top_srcdir)/include -I$(top_srcdir)/src -I$(top_builddir)/src/xine-engine -I$(top_srcdir)/src/xine-engine -I$(top_srcdir)/src/xine-utils $(INTLDIR) -I$(top_builddir)/src/input -I$(top_srcdir)/src/input $(WIN32_CPPFLAGS) -I$(top_builddir)/lib -I$(top_srcdir)/lib' +AC_SUBST(INCLUDES) -CC_CHECK_CFLAGS([-Wmissing-format-attribute], [wformat="$wformat -Wmissing-format-attribute"]) -warnflags="$warnflags $wformat" -dnl This *has* to stay at the end as it can break some autoconf tests. -CC_CHECK_CFLAGS([-Werror-implicit-function-declaration], [warnflags="$warnflags -Werror-implicit-function-declaration"]) +dnl Common cflags for all platforms +CFLAGS="$UNIVERSAL_CFLAGS \$(MULTIPASS_CFLAGS) $miscflags $warnflags $CFLAGS" +LDFLAGS="$UNIVERSAL_LDFLAGS $LDFLAGS" +OBJCFLAGS="$UNIVERSAL_CFLAGS $miscflags $warnflags $OBJCFLAGS" -CC_CHECK_CFLAGS([-Wstrict-aliasing=2], [warnflags="$warnflags -Wstrict-aliasing=2"], - [CC_CHECK_CFLAGS([-Wstrict-aliasing], [warnflags="$warnflags -Wstrict-aliasing"])]) - -case $host in - dnl FreeBSD (et al.) does not complete linking for shared objects when pthreads - dnl are requested, as different implementations are present; to avoid problems - dnl use -Wl,-z,defs only for those platform not behaving this way. - *-freebsd*) ;; - *) - AC_TRY_LDFLAGS([-Wl,-z,defs], [NOUNDEF="-Wl,-z,defs"]) - ;; -esac -AC_SUBST([NOUNDEF]) -dnl Common cflags for all platforms -CPPFLAGS="-D_REENTRANT -D_FILE_OFFSET_BITS=64 -DXINE_COMPILE $CPPFLAGS" -CFLAGS="\$(MULTIPASS_CFLAGS) $warnflags $CFLAGS" -DEBUG_CFLAGS="$warnflags $DEBUG_CFLAGS" +dnl Some informations about xine-lib compilation for xine-config +XINE_BUILD_CC="`$CC -v 2>&1 | tail -1 2>/dev/null`" +XINE_BUILD_OS="`uname -s -r -m`" +XINE_BUILD_DATE="`date \"+%a %d %b %Y %T\"`" +AC_SUBST(XINE_BUILD_CC) +AC_SUBST(XINE_BUILD_OS) +AC_SUBST(XINE_BUILD_DATE) -if test "x$enable_debug" = "xyes"; then - CPPFLAGS="$CPPFLAGS -DDEBUG" -else - CPPFLAGS="$CPPFLAGS -DNDEBUG" -fi dnl --------------------------------------------- dnl Output configuration files @@ -2672,6 +2165,7 @@ include/Makefile include/xine.h lib/Makefile m4/Makefile +m4/gettext/Makefile misc/Makefile misc/SlackBuild misc/build_rpms.sh @@ -2761,438 +2255,4 @@ cat libtool | sed -e '/sys_lib_search_path_spec=/s/\/\([[ "]]\)/\1/g' > libtool. mv -f libtool.tmp libtool chmod +x libtool -dnl --------------------------------------------- -dnl Some infos: -dnl --------------------------------------------- - -echo "xine-lib summary:" -echo "----------------" - -dnl Input -echo " * input plugins:" -echo " - file - net" -echo " - stdin_fifo - rtp" -echo " - http - mms" -echo " - pnm - rtsp" -echo " - dvb" -if test "x$external_dvdnav" = "xyes"; then - echo " - dvd (external libs)" -else - echo " - dvd (internal libs)" -fi -if test "x$have_cdrom_ioctls" = "xyes"; then - if test "x$enable_vcd" = "xyes"; then - if test "x$internal_vcdnav" = "xno"; then - echo " - vcd (external libs)" - else - echo " - vcd (internal libs)" - fi - fi - echo " - vcdo" - echo " - cdda" -fi -if test "x$no_gnome_vfs" = "xno"; then - echo " - gnome-vfs" -fi -if test "x$have_v4l" = "xyes"; then - echo " - v4l" -fi -if test "x$have_libsmbclient" = "xyes"; then - echo " - smbclient" -fi -echo "" - -dnl Demuxers -echo " * demultiplexer plugins:" -echo " - avi - mpeg" -echo " - mpeg_block - mpeg_audio" -echo " - mpeg_elem - mpeg_pes" -echo " - mpeg_ts - qt/mpeg-4" -echo " - film - roq" -echo " - fli - smjpeg" -echo " - idcin - wav" -echo " - wc3 mve - voc" -echo " - vqa - aiff" -echo " - cdda - snd/au" -echo " - yuv4mpeg2 - real/realaudio" -echo " - ea wve - raw dv" -echo " - interplay mve - psx str" -echo " - ws aud - pva" -echo " - vox - nsf" -echo " - nsv - 4xm" -echo " - FLAC - aac" -echo " - iff - matroska" -echo " - vmd - flv" -if test "x$enable_asf" = "xyes"; then - echo " - asf" -fi -if test "x$have_vorbis" = "xyes"; then - echo " - ogg" -fi -if test "x$have_libmng" = "xyes"; then - echo " - mng" -fi -if test "x$enable_modplug" != x"no"; then - echo " - mod" -fi -if test "x$have_libflac" = "xyes"; then - echo " - FLAC (with libFLAC)" -fi -if test "x$have_wavpack" = "xyes"; then - echo " - WavPack" -fi -if test "x$enable_a52dec" = "xyes"; then - if test "x$have_a52" = "xyes"; then - echo " - ac3 (external library)" - else - echo " - ac3 (internal library)" - fi -fi -echo "" - -dnl video decoders -echo " * video decoder plugins:" -echo " - MPEG 1,2 - Amiga Bitplane" -echo " - Raw RGB - Raw YUV" -if test "x$with_external_ffmpeg" = "xyes"; then - echo " - ffmpeg (external library):" -else - echo " - ffmpeg (internal library):" -fi -echo " - MPEG-4 (ISO, Microsoft, DivX*, XviD)" -echo " - Creative YUV - Motion JPEG" -echo " - Cinepak - MS Video-1" -echo " - FLI/FLC - MS RLE" -echo " - Id RoQ - Id Cin" -echo " - Apple Graphics - Apple Video" -echo " - Apple Animation - Interplay Video" -echo " - Westwood VQA - Origin Xan" -echo " - H.263 - Intel Indeo 3" -echo " - SVQ1 - SVQ3" -echo " - Real Video 1.0 - Real Video 2.0" -echo " - 4X Video - Sierra Video" -echo " - Asus v1/v2 - HuffYUV" -echo " - On2 VP3 - DV" -echo " - 8BPS - Duck TrueMotion v1" -echo " - ATI VCR1 - Flash Video" -echo " - ZLIB - MSZH" -if test "x$have_dxr3" = "xyes"; then - echo " - dxr3_video" -fi -if test "x$enable_w32dll" = "xyes"; then - echo " - w32dll" -fi -if test "x$have_imagemagick" = "xyes"; then - echo " - image" -fi -if test x"no_gdkpixbuf" != "xyes"; then - echo " - gdk-pixbuf" -fi -if test "x$have_theora" = "xyes"; then - echo " - theora" -fi -echo "" - -dnl audio decoders -echo " * audio decoder plugins:" -echo " - GSM 06.10" -echo " - linear PCM - Nosefart (NSF)" -if test "x$with_external_ffmpeg" = "xyes"; then - echo " - ffmpeg (external library):" -else - echo " - ffmpeg (internal library):" -fi -echo " - Windows Media Audio v1/v2" -echo " - DV - logarithmic PCM" -echo " - 14k4 - 28k8" -echo " - MS ADPCM - IMA ADPCM" -echo " - XA ADPCM - Game DPCM/ADPCM" -echo " - Mace 3:13 - Mace 6:1" -echo " - FLAC" -if test "x$have_libflac" = "xyes"; then - echo " - FLAC (with libFLAC)" -fi -if test "x$have_vorbis" = "xyes"; then - echo " - vorbis" -fi -if test "x$have_speex" = "xyes"; then - echo " - speex" -fi -if test "x$enable_w32dll" = "xyes"; then - echo " - w32dll" -fi -if test "x$enable_faad" = "xyes"; then - echo " - faad" -fi -if test "x$enable_libmad" = "xyes"; then - if test "x$have_mad" = "xyes"; then - echo " - MAD (MPG 1/2/3) (external library)" - else - echo " - MAD (MPG 1/2/3) (internal library)" - fi -fi -if test "x$enable_libdts" = "xyes"; then - if test "x$have_dts" = "xyes"; then - echo " - DTS (external library)" - else - echo " - DTS (internal library)" - fi -fi -if test "x$enable_a52dec" = "xyes"; then - if test "x$have_a52" = "xyes"; then - echo " - A52/ra-dnet (external library)" - else - echo " - A52/ra-dnet (internal library)" - fi -fi -if test "x$enable_musepack" != "xno"; then - if test "x$have_mpcdec" = "xyes"; then - echo " - MusePack (external library)" - else - echo " - MusePack (internal library)" - fi -fi -if test "x$have_wavpack" = "xyes"; then - echo " - WavPack" -fi -echo "" - -dnl spu decoders -echo " * subtitle decoder plugins:" -echo " - spu - spucc" -echo " - spucmml - sputext" -echo " - spudvb" -if test "x$have_dxr3" = "xyes"; then - echo " - dxr3_spu" -fi -echo "" - -dnl post plugins -echo " * post effect plugins:" -echo " * planar video effects:" -echo " - invert - expand" -echo " - eq - eq2" -echo " - boxblur - denoise3d" -echo " - unsharp - tvtime" -echo " * SFX:" -echo " - goom - oscope" -echo " - fftscope - mosaico" -echo "" - -dnl Video plugins -echo " * video driver plugins:" -if test "x$no_x" != "xyes"; then - echo " - XShm (X11 shared memory)" - dnl synfb - if test "x$enable_syncfb" != "xno"; then - echo " - SyncFB (for Matrox G200/G400 cards)" - fi - dnl Xv - if test "x$ac_have_xv" = "xyes"; then - if test "x$ac_have_xv_static" = "xyes"; then - echo " - Xv (XVideo *static*)" - else - echo " - Xv (XVideo *shared*)" - fi - fi - dnl XxMC - if test "x$ac_have_xxmc" = "xyes"; then - if test "x$ac_have_vldxvmc_h" = "xyes"; then - echo " - XxMC (XVideo extended motion compensation)" - else - echo " - XxMC (XVideo motion compensation - vld extensions DISABLED)" - fi - fi - dnl XvMC - if test "x$ac_have_xvmc" = "xyes"; then - echo " - XvMC (XVideo motion compensation)" - fi - if test "x$ac_have_opengl" = "xyes" -a "x$ac_have_glut" = "xyes" -o \ - x$"ac_have_opengl" = "xyes" -a "x$ac_have_glu" = "xyes"; then - echo " - OpenGL" - fi - if test "x$ac_have_sunfb" = "xyes"; then - if test "x$ac_have_sundga" = "xyes"; then - echo " - PGX64 (for Sun XVR100/PGX64/PGX24 cards)" - echo " - PGX32 (for Sun PGX32 cards)" - fi - fi -fi -if test "x$have_xcb" = "xyes"; then - dnl xcb-shm - if test "x$have_xcbshm" = "xyes"; then - echo " - xcb-shm (X shared memory using XCB)" - fi - dnl xcb-xv - if test "x$have_xcbxv" = "xyes"; then - echo " - xcb-xv (XVideo using XCB)" - fi -fi -if test "x$no_aalib" != "xyes"; then - echo " - aa (Ascii ART)" -fi -if test "x$have_caca" = "xyes"; then - echo " - caca (Color AsCii Art)" -fi -if test "x$have_fb" = "xyes"; then - echo " - fb (Linux framebuffer device)" -fi -if test "x$have_sdl" = "xyes"; then - echo " - sdl (Simple DirectMedia Layer)" -fi -if test "x$have_libstk" = "xyes"; then - echo " - stk (Libstk Set-top Toolkit)" -fi -if test "x$have_directfb" = "xyes"; then - echo " - directfb (DirectFB driver)" -fi -if test "x$have_dxr3" = "xyes"; then - if test "x$have_encoder" = "xyes"; then - echo " - dxr3 (Hollywood+ and Creative dxr3, both mpeg and non-mpeg video)" - else - echo " - dxr3 (Hollywood+ and Creative dxr3, mpeg video only)" - fi -fi -if test "x$enable_vidix" = "xyes"; then - echo $ECHO_N " - vidix (" - - if test "x$no_x" != "xyes"; then - echo $ECHO_N "X11" - if test "x$have_fb" = "xyes"; then - echo $ECHO_N " and " - fi - fi - - if test "x$have_fb" = "xyes"; then - echo $ECHO_N "framebuffer" - fi - - echo $ECHO_N " support" - - if test "x$enable_dha_kmod" = "xyes"; then - echo " with dhahelper)" - else - echo ")" - fi -fi -if test "x$have_directx" = "xyes"; then - echo " - directx (DirectX video driver)" -fi -if test "x$have_macosx_video" = "xyes"; then - echo " - Mac OS X OpenGL" -fi - -echo "" - -dnl Audio plugins -echo " * audio driver plugins:" -if test "x$have_ossaudio" = "xyes"; then - echo " - oss (Open Sound System)" -fi -if test "x$have_alsa" = "xyes"; then - echo " - alsa" -fi -if test "x$have_esound" = "xyes"; then - echo " - esd (Enlightened Sound Daemon)" -fi -if test "x$no_arts" != "xyes"; then - echo " - arts (aRts - KDE soundserver)" -fi -if test "x$no_fusionsound" != "xyes"; then - echo " - fusionsound (FusionSound driver)" -fi -if test "x$have_sunaudio" = "xyes"; then - echo " - sun ()" -fi -if test "x$am_cv_have_irixal" = xyes; then - echo " - irixal (Irix audio library)" -fi -if test "x$have_directx" = "xyes"; then - echo " - directx (DirectX audio driver)" -fi -if test "x$have_coreaudio" = "xyes"; then - echo " - CoreAudio (Mac OS X audio driver)" -fi -if test "x$have_pulseaudio" = "xyes"; then - echo " - pulseaudio sound server" -fi -if test "x$have_jack" = "xyes"; then - echo " - Jack" -fi -echo "---" - - -dnl --------------------------------------------- -dnl some user warnings -dnl --------------------------------------------- - -dnl some levels of variable expansion to get final install paths -final_libdir="`eval eval eval eval echo $libdir`" -final_bindir="`eval eval eval eval echo $bindir`" - -if test -r /etc/ld.so.conf && ! grep -x "$final_libdir" /etc/ld.so.conf >/dev/null ; then - if test "$final_libdir" != "/lib" -a "$final_libdir" != "/usr/lib" ; then - if ! echo "$LD_LIBRARY_PATH" | egrep "(:|^)$final_libdir(/?:|/?$)" >/dev/null ; then - echo - echo "****************************************************************" - echo "xine-lib will be installed to $final_libdir" - echo - echo "This path is not mentioned among the linker search paths in your" - echo "/etc/ld.so.conf. This means it is possible that xine-lib will" - echo "not be found when you try to compile or run a program using it." - echo "If this happens, you should add $final_libdir to" - echo "the environment variable LD_LIBRARY_PATH like that:" - echo - echo "export LD_LIBRARY_PATH=$final_libdir:\$LD_LIBRARY_PATH" - echo - echo "Alternatively you can add a line \"$final_libdir\"" - echo "to your /etc/ld.so.conf." - echo "****************************************************************" - echo - fi - fi -fi - -if ! echo "$PATH" | egrep "(:|^)$final_bindir(/?:|/?$)" >/dev/null ; then - echo - echo "****************************************************************" - echo "xine-config will be installed to $final_bindir" - echo - echo "This path is not in your search path. This means it is possible" - echo "that xine-config will not be found when you try to compile a" - echo "program using xine-lib. This will result in build failures." - echo "If this happens, you should add $final_bindir to" - echo "the environment variable PATH like that:" - echo - echo "export PATH=$final_bindir:\$PATH" - echo - echo "Note that this is only needed for compilation. It is not needed" - echo "to have xine-config in your search path at runtime. (Although" - echo "it will not cause any harm either.)" - echo "****************************************************************" - echo -fi - -dnl warn if no X11 plugins will be built -if test "x$no_x" = "xyes"; then - case $host in - *mingw*|*-cygwin) ;; - *-darwin*) ;; - *) - echo - echo "****************************************************************" - echo "WARNING! No X11 output plugins will be built." - echo - echo "For some reason, the requirements for building the X11 video" - echo "output plugins are not met. That means, that you will NOT be" - echo "able to use the resulting xine-lib to watch videos in a window" - echo "on any X11-based display (e.g. your desktop)." - echo - echo "If this is not what you want, provide the necessary X11 build" - echo "dependencies (usually done by installing a package called" - echo "XFree86-devel or similar) and run configure again." - echo "****************************************************************" - echo - ;; - esac -fi +XINE_LIB_SUMMARY diff --git a/contrib/libdca/Makefile.am b/contrib/libdca/Makefile.am index 14206a363..a118a9dc9 100644 --- a/contrib/libdca/Makefile.am +++ b/contrib/libdca/Makefile.am @@ -4,12 +4,14 @@ noinst_LTLIBRARIES = libdca.la endif endif +AM_CFLAGS = $(DEFAULT_OCFLAGS) $(VISIBILITY_FLAG) + libdca_la_SOURCES = dca_internal.h tables.h tables_quantization.h \ tables_huffman.h tables_fir.h tables_adpcm.h tables_vq.h \ bitstream.h bitstream.c parse.c downmix.c \ include/dca.h include/dts.h -libdca_la_CFLAGS = -I$(srcdir)/include $(VISIBILITY_FLAG) +libdca_la_CPPFLAGS = -I$(srcdir)/include libdca_la_LIBADD = -lm EXTRA_DIST = COPYING diff --git a/contrib/libmpcdec/Makefile.am b/contrib/libmpcdec/Makefile.am index 16ea80c28..5751239bf 100644 --- a/contrib/libmpcdec/Makefile.am +++ b/contrib/libmpcdec/Makefile.am @@ -4,11 +4,12 @@ noinst_LTLIBRARIES = libmpcdec.la endif endif +AM_CFLAGS = $(DEFAULT_OCFLAGS) $(VISIBILITY_FLAG) + libmpcdec_la_SOURCES = huffsv46.c huffsv7.c idtag.c mpc_decoder.c mpc_reader.c \ requant.c streaminfo.c synth_filter.c \ mpcdec/internal.h mpcdec/mpcdec.h mpcdec/streaminfo.h mpcdec/math.h \ mpcdec/decoder.h mpcdec/config_types.h mpcdec/requant.h mpcdec/huffman.h \ mpcdec/reader.h -libmpcdec_la_CFLAGS = $(VISIBILITY_FLAG) EXTRA_DIST = diff_from_libmpcdec_1.2.5.patch COPYING diff --git a/contrib/libxdg-basedir/Makefile.am b/contrib/libxdg-basedir/Makefile.am index 68f09b0a9..420d85999 100644 --- a/contrib/libxdg-basedir/Makefile.am +++ b/contrib/libxdg-basedir/Makefile.am @@ -2,5 +2,6 @@ if !EXTERNAL_LIBXDG_BASEDIR noinst_LTLIBRARIES = libxdg-basedir.la endif +AM_CFLAGS = $(DEFAULT_OCFLAGS) $(VISIBILITY_FLAG) + libxdg_basedir_la_SOURCES = basedir.c basedir.h -libxdg_basedir_la_CFLAGS = $(VISIBILITY_FLAG) diff --git a/include/Makefile.am b/include/Makefile.am index 97d82e063..621bd423c 100644 --- a/include/Makefile.am +++ b/include/Makefile.am @@ -8,12 +8,6 @@ include_HEADERS = xine.h CONFIG_CLEAN_FILES = xine.h $(inttypes_h) -debug: - @$(MAKE) CFLAGS="$(DEBUG_CFLAGS)" - -install-debug: debug - @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am - mostlyclean-generic: -rm -f *~ \#* .*~ .\#* diff --git a/lib/Makefile.am b/lib/Makefile.am index 36b695bc8..c6462037e 100644 --- a/lib/Makefile.am +++ b/lib/Makefile.am @@ -1,5 +1,7 @@ include $(top_srcdir)/misc/Makefile.common +AM_CFLAGS = $(DEFAULT_OCFLAGS) + EXTRA_DIST = Makefile.common noinst_LTLIBRARIES = libxineposix.la diff --git a/m4/Makefile.am b/m4/Makefile.am index 3a5209dc3..90067a942 100644 --- a/m4/Makefile.am +++ b/m4/Makefile.am @@ -1,5 +1,7 @@ include $(top_srcdir)/misc/Makefile.common +SUBDIRS = gettext + if INSTALL_M4 m4datadir = $(ACLOCAL_DIR) else @@ -8,29 +10,27 @@ endif m4data_DATA = xine.m4 -EXTRA_DIST = glibc2.m4 intdiv0.m4 intmax.m4 inttypes.m4 inttypes_h.m4 inttypes-pri.m4 lib-ld.m4 lib-link.m4 lib-prefix.m4 longdouble.m4 longlong.m4 nls.m4 po.m4 printf-posix.m4 signed.m4 size_max.m4 stdint_h.m4 uintmax_t.m4 ulonglong.m4 wchar_t.m4 wint_t.m4 xsize.m4 \ +EXTRA_DIST = \ aa.m4 \ arts.m4 \ attributes.m4 \ - codeset.m4 \ directx.m4 \ dl.m4 \ dvdnav.m4 \ - gettext.m4 \ - glibc21.m4 \ - iconv.m4 \ + gas.m4 \ + ioctl_request.m4 \ irixal.m4 \ - isc-posix.m4 \ - lcmessage.m4 \ libFLAC.m4 \ libfame.m4 \ - libtool15.m4 \ + macosx.m4 \ + objc.m4 \ opengl.m4 \ - optimizations.m4 \ pkg.m4 \ - progtest.m4 \ + pthreads.m4 \ + symbol.m4 \ + summary.m4 \ xine.m4 \ _xine.m4 \ + x11.m4 \ xv.m4 \ - pthreads.m4 \ - gas.m4 + vcd.m4 diff --git a/m4/_xine.m4 b/m4/_xine.m4 index 930703bbb..005ae3138 100644 --- a/m4/_xine.m4 +++ b/m4/_xine.m4 @@ -44,60 +44,6 @@ AC_DEFUN([AC_C_ALWAYS_INLINE], fi ]) -dnl -dnl Check for minimum version of libtool -dnl AC_PREREQ_LIBTOOL([MINIMUM VERSION],[ACTION-IF-FOUND [, ACTION-IF-NOT-FOUND ]]) -AC_DEFUN([AC_PREREQ_LIBTOOL], - [ - lt_min_full=ifelse([$1], ,1.3.5,$1) - lt_min=`echo $lt_min_full | sed -e 's/\.//g'` - AC_MSG_CHECKING(for libtool >= $lt_min_full) - lt_version="`grep '^VERSION' $srcdir/ltmain.sh | sed -e 's/VERSION\=//g;s/[[-.a-zA-Z]]//g'`" - - if test $lt_version -lt 100 ; then - lt_version=`expr $lt_version \* 10` - fi - - if test $lt_version -lt $lt_min ; then - AC_MSG_RESULT(no) - ifelse([$3], , :, [$3]) - fi - AC_MSG_RESULT(yes) - ifelse([$2], , :, [$2]) - ]) - -dnl -AC_DEFUN([AC_CHECK_LIRC], - [AC_ARG_ENABLE(lirc, - AS_HELP_STRING([--disable-lirc], [turn off LIRC support]), - enable_lirc=$enableval, enable_lirc=yes) - - if test x"$enable_lirc" = xyes; then - have_lirc=yes - AC_REQUIRE_CPP - AC_CHECK_LIB(lirc_client,lirc_init, - AC_CHECK_HEADER(lirc/lirc_client.h, true, have_lirc=no), have_lirc=no) - if test "$have_lirc" = "yes"; then - - if test x"$LIRC_PREFIX" != "x"; then - lirc_libprefix="$LIRC_PREFIX/lib" - LIRC_INCLUDE="-I$LIRC_PREFIX/include" - fi - for llirc in $lirc_libprefix /lib /usr/lib /usr/local/lib; do - AC_CHECK_FILE("$llirc/liblirc_client.a", - LIRC_LIBS="$llirc/liblirc_client.a" - AC_DEFINE(HAVE_LIRC),,) - done - else - AC_MSG_RESULT([*** LIRC client support not available, LIRC support will be disabled ***]); - fi - fi - - AC_SUBST(LIRC_LIBS) - AC_SUBST(LIRC_INCLUDE) -]) - - dnl AC_LINUX_PATH(DEFAULT PATH) AC_DEFUN([AC_LINUX_PATH], [AC_ARG_WITH(linux-path, @@ -142,36 +88,6 @@ AC_DEFUN([AC_CHECK_DXR3], fi ]) -dnl AC_TRY_CFLAGS (CFLAGS, [ACTION-IF-WORKS], [ACTION-IF-FAILS]) -dnl check if $CC supports a given set of cflags -AC_DEFUN([AC_TRY_CFLAGS], - [AC_MSG_CHECKING([if $CC supports $1 flags]) - SAVE_CFLAGS="$CFLAGS" - CFLAGS="$1" - AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[]], [[]])],[ac_cv_try_cflags_ok=yes],[ac_cv_try_cflags_ok=no]) - CFLAGS="$SAVE_CFLAGS" - AC_MSG_RESULT([$ac_cv_try_cflags_ok]) - if test x"$ac_cv_try_cflags_ok" = x"yes"; then - ifelse([$2],[],[:],[$2]) - else - ifelse([$3],[],[:],[$3]) - fi]) - -dnl AC_TRY_LDFLAGS (CFLAGS, [ACTION-IF-WORKS], [ACTION-IF-FAILS]) -dnl check if $CC supports a given set of ldflags -AC_DEFUN([AC_TRY_LDFLAGS], - [AC_MSG_CHECKING([if $CC supports $1 flags]) - SAVE_LDFLAGS="$LDFLAGS" - LDFLAGS="$1" - AC_LINK_IFELSE([AC_LANG_PROGRAM([[]], [[]])],[ac_cv_try_ldflags_ok=yes],[ac_cv_try_ldflags_ok=no]) - LDFLAGS="$SAVE_LDFLAGS" - AC_MSG_RESULT([$ac_cv_try_ldflags_ok]) - if test x"$ac_cv_try_ldflags_ok" = x"yes"; then - ifelse([$2],[],[:],[$2]) - else - ifelse([$3],[],[:],[$3]) - fi]) - dnl AC_CHECK_GENERATE_INTTYPES_H (INCLUDE-DIRECTORY) dnl generate a default inttypes.h if the header file does not exist already AC_DEFUN([AC_CHECK_GENERATE_INTTYPES], diff --git a/m4/attributes.m4 b/m4/attributes.m4 index 23b5f2ee4..f781429f7 100644 --- a/m4/attributes.m4 +++ b/m4/attributes.m4 @@ -50,6 +50,24 @@ AC_DEFUN([CC_CHECK_CFLAGS], [ fi ]) +AC_DEFUN([CC_CHECK_LDFLAGS], [ + AC_CACHE_CHECK([if $CC supports $1 flag], + AS_TR_SH([cc_cv_ldflags_$1]), + [ac_save_LDFLAGS="$LDFLAGS" + LDFLAGS="$LDFLAGS $1" + AC_LINK_IFELSE([int a;], + [eval "AS_TR_SH([cc_cv_ldflags_$1])='yes'"], + [eval "AS_TR_SH([cc_cv_ldflags_$1])="]) + LDFLAGS="$ac_save_LDFLAGS" + ]) + + if eval test [x$]AS_TR_SH([cc_cv_ldflags_$1]) = xyes; then + ifelse([$2], , [:], [$2]) + else + ifelse([$3], , [:], [$3]) + fi +]) + dnl Check for a -Werror flag or equivalent. -Werror is the GCC dnl and ICC flag that tells the compiler to treat all the warnings dnl as fatal. We usually need this option to make sure that some diff --git a/m4/gettext/Makefile.am b/m4/gettext/Makefile.am new file mode 100644 index 000000000..1ea9db48c --- /dev/null +++ b/m4/gettext/Makefile.am @@ -0,0 +1,32 @@ +include $(top_srcdir)/misc/Makefile.common + +EXTRA_DIST = \ + codeset.m4 + gettext.m4 + glibc2.m4 + glibc21.m4 + iconv.m4 + intdiv0.m4 + intmax.m4 + inttypes-pri.m4 + inttypes.m4 + inttypes_h.m4 + isc-posix.m4 + lcmessage.m4 + lib-ld.m4 + lib-link.m4 + lib-prefix.m4 + longdouble.m4 + longlong.m4 + nls.m4 + po.m4 + printf-posix.m4 + progtest.m4 + signed.m4 + size_max.m4 + stdint_h.m4 + uintmax_t.m4 + ulonglong.m4 + wchar_t.m4 + wint_t.m4 + xsize.m4 diff --git a/m4/codeset.m4 b/m4/gettext/codeset.m4 index a6e67ec49..a6e67ec49 100644 --- a/m4/codeset.m4 +++ b/m4/gettext/codeset.m4 diff --git a/m4/gettext.m4 b/m4/gettext/gettext.m4 index 624a80785..624a80785 100644 --- a/m4/gettext.m4 +++ b/m4/gettext/gettext.m4 diff --git a/m4/glibc2.m4 b/m4/gettext/glibc2.m4 index e8f5bfe6e..e8f5bfe6e 100644 --- a/m4/glibc2.m4 +++ b/m4/gettext/glibc2.m4 diff --git a/m4/glibc21.m4 b/m4/gettext/glibc21.m4 index d95fd9861..d95fd9861 100644 --- a/m4/glibc21.m4 +++ b/m4/gettext/glibc21.m4 diff --git a/m4/iconv.m4 b/m4/gettext/iconv.m4 index 5ed7c43ae..654c41589 100644 --- a/m4/iconv.m4 +++ b/m4/gettext/iconv.m4 @@ -15,22 +15,6 @@ AC_DEFUN([AM_ICONV_LINKFLAGS_BODY], dnl Search for libiconv and define LIBICONV, LTLIBICONV and INCICONV dnl accordingly. AC_LIB_LINKFLAGS_BODY([iconv]) - - dnl - dnl xine: added the prefix /usr/local on FreeBSD if none specified - dnl - if test -z "$INCICONV"; then - case "$host" in - *-*-freebsd*) - dir=/usr/local - if test -d $dir/include; then INCICONV="$INCICONV -I$dir/include"; fi - if test -d $dir/lib; then - LIBICONV="$LIBICONV -L$dir/lib" - LTLIBICONV="$LTLIBICONV -L$dir/lib" - fi - ;; - esac - fi ]) AC_DEFUN([AM_ICONV_LINK], diff --git a/m4/intdiv0.m4 b/m4/gettext/intdiv0.m4 index b8d78176a..b8d78176a 100644 --- a/m4/intdiv0.m4 +++ b/m4/gettext/intdiv0.m4 diff --git a/m4/intmax.m4 b/m4/gettext/intmax.m4 index d99c999fd..d99c999fd 100644 --- a/m4/intmax.m4 +++ b/m4/gettext/intmax.m4 diff --git a/m4/inttypes-pri.m4 b/m4/gettext/inttypes-pri.m4 index 4d56a9ad3..4d56a9ad3 100644 --- a/m4/inttypes-pri.m4 +++ b/m4/gettext/inttypes-pri.m4 diff --git a/m4/inttypes.m4 b/m4/gettext/inttypes.m4 index 779bcea05..779bcea05 100644 --- a/m4/inttypes.m4 +++ b/m4/gettext/inttypes.m4 diff --git a/m4/inttypes_h.m4 b/m4/gettext/inttypes_h.m4 index a5d075d96..a5d075d96 100644 --- a/m4/inttypes_h.m4 +++ b/m4/gettext/inttypes_h.m4 diff --git a/m4/isc-posix.m4 b/m4/gettext/isc-posix.m4 index 74dc8f26d..74dc8f26d 100644 --- a/m4/isc-posix.m4 +++ b/m4/gettext/isc-posix.m4 diff --git a/m4/lcmessage.m4 b/m4/gettext/lcmessage.m4 index 19aa77e4f..19aa77e4f 100644 --- a/m4/lcmessage.m4 +++ b/m4/gettext/lcmessage.m4 diff --git a/m4/lib-ld.m4 b/m4/gettext/lib-ld.m4 index 96c4e2c33..96c4e2c33 100644 --- a/m4/lib-ld.m4 +++ b/m4/gettext/lib-ld.m4 diff --git a/m4/lib-link.m4 b/m4/gettext/lib-link.m4 index ea0b0c4ea..ea0b0c4ea 100644 --- a/m4/lib-link.m4 +++ b/m4/gettext/lib-link.m4 diff --git a/m4/lib-prefix.m4 b/m4/gettext/lib-prefix.m4 index e0736ce1c..0d895ca63 100644 --- a/m4/lib-prefix.m4 +++ b/m4/gettext/lib-prefix.m4 @@ -9,7 +9,7 @@ dnl From Bruno Haible. dnl AC_LIB_ARG_WITH is synonymous to AC_ARG_WITH in autoconf-2.13, and dnl similar to AC_ARG_WITH in autoconf 2.52...2.57 except that is doesn't dnl require excessive bracketing. -ifdef([AS_HELP_STRING], +ifdef([AC_HELP_STRING], [AC_DEFUN([AC_LIB_ARG_WITH], [AC_ARG_WITH([$1],[[$2]],[$3],[$4])])], [AC_DEFUN([AC_][LIB_ARG_WITH], [AC_ARG_WITH([$1],[$2],[$3],[$4])])]) diff --git a/m4/longdouble.m4 b/m4/gettext/longdouble.m4 index 40cd7ce02..40cd7ce02 100644 --- a/m4/longdouble.m4 +++ b/m4/gettext/longdouble.m4 diff --git a/m4/longlong.m4 b/m4/gettext/longlong.m4 index 7b399e012..7b399e012 100644 --- a/m4/longlong.m4 +++ b/m4/gettext/longlong.m4 diff --git a/m4/nls.m4 b/m4/gettext/nls.m4 index 2082c3b24..2082c3b24 100644 --- a/m4/nls.m4 +++ b/m4/gettext/nls.m4 diff --git a/m4/po.m4 b/m4/gettext/po.m4 index f2795eea0..f2795eea0 100644 --- a/m4/po.m4 +++ b/m4/gettext/po.m4 diff --git a/m4/printf-posix.m4 b/m4/gettext/printf-posix.m4 index af10170af..af10170af 100644 --- a/m4/printf-posix.m4 +++ b/m4/gettext/printf-posix.m4 diff --git a/m4/progtest.m4 b/m4/gettext/progtest.m4 index a56365cd3..a56365cd3 100644 --- a/m4/progtest.m4 +++ b/m4/gettext/progtest.m4 diff --git a/m4/signed.m4 b/m4/gettext/signed.m4 index 048f59369..048f59369 100644 --- a/m4/signed.m4 +++ b/m4/gettext/signed.m4 diff --git a/m4/size_max.m4 b/m4/gettext/size_max.m4 index 4fe81c7b0..4fe81c7b0 100644 --- a/m4/size_max.m4 +++ b/m4/gettext/size_max.m4 diff --git a/m4/stdint_h.m4 b/m4/gettext/stdint_h.m4 index 3355f35aa..3355f35aa 100644 --- a/m4/stdint_h.m4 +++ b/m4/gettext/stdint_h.m4 diff --git a/m4/uintmax_t.m4 b/m4/gettext/uintmax_t.m4 index bf83ed746..bf83ed746 100644 --- a/m4/uintmax_t.m4 +++ b/m4/gettext/uintmax_t.m4 diff --git a/m4/ulonglong.m4 b/m4/gettext/ulonglong.m4 index dee10ccc3..dee10ccc3 100644 --- a/m4/ulonglong.m4 +++ b/m4/gettext/ulonglong.m4 diff --git a/m4/wchar_t.m4 b/m4/gettext/wchar_t.m4 index cde2129a9..cde2129a9 100644 --- a/m4/wchar_t.m4 +++ b/m4/gettext/wchar_t.m4 diff --git a/m4/wint_t.m4 b/m4/gettext/wint_t.m4 index b8fff9c86..b8fff9c86 100644 --- a/m4/wint_t.m4 +++ b/m4/gettext/wint_t.m4 diff --git a/m4/xsize.m4 b/m4/gettext/xsize.m4 index 85bb721e4..85bb721e4 100644 --- a/m4/xsize.m4 +++ b/m4/gettext/xsize.m4 diff --git a/m4/libtool15.m4 b/m4/libtool15.m4 deleted file mode 100644 index 1f0567787..000000000 --- a/m4/libtool15.m4 +++ /dev/null @@ -1,6168 +0,0 @@ -# libtool.m4 - Configure libtool for the host system. -*-Autoconf-*- -## Copyright 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005 -## Free Software Foundation, Inc. -## Originally by Gordon Matzigkeit <gord@gnu.ai.mit.edu>, 1996 -## -## This file is free software; the Free Software Foundation gives -## unlimited permission to copy and/or distribute it, with or without -## modifications, as long as this notice is preserved. - -# serial 47 AC_PROG_LIBTOOL - - -# AC_PROVIDE_IFELSE(MACRO-NAME, IF-PROVIDED, IF-NOT-PROVIDED) -# ----------------------------------------------------------- -# If this macro is not defined by Autoconf, define it here. -m4_ifdef([AC_PROVIDE_IFELSE], - [], - [m4_define([AC_PROVIDE_IFELSE], - [m4_ifdef([AC_PROVIDE_$1], - [$2], [$3])])]) - - -# AC_PROG_LIBTOOL -# --------------- -AC_DEFUN([AC_PROG_LIBTOOL], -[AC_REQUIRE([_AC_PROG_LIBTOOL])dnl -dnl If AC_PROG_CXX has already been expanded, run AC_LIBTOOL_CXX -dnl immediately, otherwise, hook it in at the end of AC_PROG_CXX. - AC_PROVIDE_IFELSE([AC_PROG_CXX], - [AC_LIBTOOL_CXX], - [define([AC_PROG_CXX], defn([AC_PROG_CXX])[AC_LIBTOOL_CXX - ])]) -dnl And a similar setup for Fortran 77 support - AC_PROVIDE_IFELSE([AC_PROG_F77], - [AC_LIBTOOL_F77], - [define([AC_PROG_F77], defn([AC_PROG_F77])[AC_LIBTOOL_F77 -])]) - -dnl Quote A][M_PROG_GCJ so that aclocal doesn't bring it in needlessly. -dnl If either AC_PROG_GCJ or A][M_PROG_GCJ have already been expanded, run -dnl AC_LIBTOOL_GCJ immediately, otherwise, hook it in at the end of both. - AC_PROVIDE_IFELSE([AC_PROG_GCJ], - [AC_LIBTOOL_GCJ], - [AC_PROVIDE_IFELSE([A][M_PROG_GCJ], - [AC_LIBTOOL_GCJ], - [AC_PROVIDE_IFELSE([LT_AC_PROG_GCJ], - [AC_LIBTOOL_GCJ], - [ifdef([AC_PROG_GCJ], - [define([AC_PROG_GCJ], defn([AC_PROG_GCJ])[AC_LIBTOOL_GCJ])]) - ifdef([A][M_PROG_GCJ], - [define([A][M_PROG_GCJ], defn([A][M_PROG_GCJ])[AC_LIBTOOL_GCJ])]) - ifdef([LT_AC_PROG_GCJ], - [define([LT_AC_PROG_GCJ], - defn([LT_AC_PROG_GCJ])[AC_LIBTOOL_GCJ])])])]) -])])# AC_PROG_LIBTOOL - - -# _AC_PROG_LIBTOOL -# ---------------- -AC_DEFUN([_AC_PROG_LIBTOOL], -[AC_REQUIRE([AC_LIBTOOL_SETUP])dnl -AC_BEFORE([$0],[AC_LIBTOOL_CXX])dnl -AC_BEFORE([$0],[AC_LIBTOOL_F77])dnl -AC_BEFORE([$0],[AC_LIBTOOL_GCJ])dnl - -# This can be used to rebuild libtool when needed -LIBTOOL_DEPS="$ac_aux_dir/ltmain.sh" - -# Always use our own libtool. -LIBTOOL='$(SHELL) $(top_builddir)/libtool' -AC_SUBST(LIBTOOL)dnl - -# Prevent multiple expansion -define([AC_PROG_LIBTOOL], []) -])# _AC_PROG_LIBTOOL - - -# AC_LIBTOOL_SETUP -# ---------------- -AC_DEFUN([AC_LIBTOOL_SETUP], -[AC_PREREQ(2.50)dnl -AC_REQUIRE([AC_ENABLE_SHARED])dnl -AC_REQUIRE([AC_ENABLE_STATIC])dnl -AC_REQUIRE([AC_ENABLE_FAST_INSTALL])dnl -AC_REQUIRE([AC_CANONICAL_HOST])dnl -AC_REQUIRE([AC_CANONICAL_BUILD])dnl -AC_REQUIRE([AC_PROG_CC])dnl -AC_REQUIRE([AC_PROG_LD])dnl -AC_REQUIRE([AC_PROG_LD_RELOAD_FLAG])dnl -AC_REQUIRE([AC_PROG_NM])dnl - -AC_REQUIRE([AC_PROG_LN_S])dnl -AC_REQUIRE([AC_DEPLIBS_CHECK_METHOD])dnl -# Autoconf 2.13's AC_OBJEXT and AC_EXEEXT macros only works for C compilers! -AC_REQUIRE([AC_OBJEXT])dnl -AC_REQUIRE([AC_EXEEXT])dnl -dnl - -AC_LIBTOOL_SYS_MAX_CMD_LEN -AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE -AC_LIBTOOL_OBJDIR - -AC_REQUIRE([_LT_AC_SYS_COMPILER])dnl -_LT_AC_PROG_ECHO_BACKSLASH - -case $host_os in -aix3*) - # AIX sometimes has problems with the GCC collect2 program. For some - # reason, if we set the COLLECT_NAMES environment variable, the problems - # vanish in a puff of smoke. - if test "X${COLLECT_NAMES+set}" != Xset; then - COLLECT_NAMES= - export COLLECT_NAMES - fi - ;; -esac - -# Sed substitution that helps us do robust quoting. It backslashifies -# metacharacters that are still active within double-quoted strings. -Xsed='sed -e 1s/^X//' -[sed_quote_subst='s/\([\\"\\`$\\\\]\)/\\\1/g'] - -# Same as above, but do not quote variable references. -[double_quote_subst='s/\([\\"\\`\\\\]\)/\\\1/g'] - -# Sed substitution to delay expansion of an escaped shell variable in a -# double_quote_subst'ed string. -delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g' - -# Sed substitution to avoid accidental globbing in evaled expressions -no_glob_subst='s/\*/\\\*/g' - -# Constants: -rm="rm -f" - -# Global variables: -default_ofile=libtool -can_build_shared=yes - -# All known linkers require a `.a' archive for static linking (except M$VC, -# which needs '.lib'). -libext=a -ltmain="$ac_aux_dir/ltmain.sh" -ofile="$default_ofile" -with_gnu_ld="$lt_cv_prog_gnu_ld" - -AC_CHECK_TOOL(AR, ar, false) -AC_CHECK_TOOL(RANLIB, ranlib, :) -AC_CHECK_TOOL(STRIP, strip, :) - -old_CC="$CC" -old_CFLAGS="$CFLAGS" - -# Set sane defaults for various variables -test -z "$AR" && AR=ar -test -z "$AR_FLAGS" && AR_FLAGS=cru -test -z "$AS" && AS=as -test -z "$CC" && CC=cc -test -z "$LTCC" && LTCC=$CC -test -z "$DLLTOOL" && DLLTOOL=dlltool -test -z "$LD" && LD=ld -test -z "$LN_S" && LN_S="ln -s" -test -z "$MAGIC_CMD" && MAGIC_CMD=file -test -z "$NM" && NM=nm -test -z "$SED" && SED=sed -test -z "$OBJDUMP" && OBJDUMP=objdump -test -z "$RANLIB" && RANLIB=: -test -z "$STRIP" && STRIP=: -test -z "$ac_objext" && ac_objext=o - -# Determine commands to create old-style static archives. -old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs$old_deplibs' -old_postinstall_cmds='chmod 644 $oldlib' -old_postuninstall_cmds= - -if test -n "$RANLIB"; then - case $host_os in - openbsd*) - old_postinstall_cmds="\$RANLIB -t \$oldlib~$old_postinstall_cmds" - ;; - *) - old_postinstall_cmds="\$RANLIB \$oldlib~$old_postinstall_cmds" - ;; - esac - old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib" -fi - -_LT_CC_BASENAME([$compiler]) - -# Only perform the check for file, if the check method requires it -case $deplibs_check_method in -file_magic*) - if test "$file_magic_cmd" = '$MAGIC_CMD'; then - AC_PATH_MAGIC - fi - ;; -esac - -AC_PROVIDE_IFELSE([AC_LIBTOOL_DLOPEN], enable_dlopen=yes, enable_dlopen=no) -AC_PROVIDE_IFELSE([AC_LIBTOOL_WIN32_DLL], -enable_win32_dll=yes, enable_win32_dll=no) - -AC_ARG_ENABLE([libtool-lock], - [AS_HELP_STRING([--disable-libtool-lock], - [avoid locking (might break parallel builds)])]) -test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes - -AC_ARG_WITH([pic], - [AS_HELP_STRING([--with-pic], - [try to use only PIC/non-PIC objects @<:@default=use both@:>@])], - [pic_mode="$withval"], - [pic_mode=default]) -test -z "$pic_mode" && pic_mode=default - -# Use C for the default configuration in the libtool script -tagname= -AC_LIBTOOL_LANG_C_CONFIG -_LT_AC_TAGCONFIG -])# AC_LIBTOOL_SETUP - - -# _LT_AC_SYS_COMPILER -# ------------------- -AC_DEFUN([_LT_AC_SYS_COMPILER], -[AC_REQUIRE([AC_PROG_CC])dnl - -# If no C compiler was specified, use CC. -LTCC=${LTCC-"$CC"} - -# Allow CC to be a program name with arguments. -compiler=$CC -])# _LT_AC_SYS_COMPILER - - -# _LT_CC_BASENAME(CC) -# ------------------- -# Calculate cc_basename. Skip known compiler wrappers and cross-prefix. -AC_DEFUN([_LT_CC_BASENAME], -[for cc_temp in $1""; do - case $cc_temp in - compile | *[[\\/]]compile | ccache | *[[\\/]]ccache ) ;; - distcc | *[[\\/]]distcc | purify | *[[\\/]]purify ) ;; - \-*) ;; - *) break;; - esac -done -cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"` -]) - - -# _LT_COMPILER_BOILERPLATE -# ------------------------ -# Check for compiler boilerplate output or warnings with -# the simple compiler test code. -AC_DEFUN([_LT_COMPILER_BOILERPLATE], -[ac_outfile=conftest.$ac_objext -printf "$lt_simple_compile_test_code" >conftest.$ac_ext -eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d' >conftest.err -_lt_compiler_boilerplate=`cat conftest.err` -$rm conftest* -])# _LT_COMPILER_BOILERPLATE - - -# _LT_LINKER_BOILERPLATE -# ---------------------- -# Check for linker boilerplate output or warnings with -# the simple link test code. -AC_DEFUN([_LT_LINKER_BOILERPLATE], -[ac_outfile=conftest.$ac_objext -printf "$lt_simple_link_test_code" >conftest.$ac_ext -eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d' >conftest.err -_lt_linker_boilerplate=`cat conftest.err` -$rm conftest* -])# _LT_LINKER_BOILERPLATE - - -# _LT_AC_SYS_LIBPATH_AIX -# ---------------------- -# Links a minimal program and checks the executable -# for the system default hardcoded library path. In most cases, -# this is /usr/lib:/lib, but when the MPI compilers are used -# the location of the communication and MPI libs are included too. -# If we don't find anything, use the default library path according -# to the aix ld manual. -AC_DEFUN([_LT_AC_SYS_LIBPATH_AIX], -[AC_LINK_IFELSE(AC_LANG_PROGRAM,[ -aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; } -}'` -# Check for a 64-bit object if we didn't find anything. -if test -z "$aix_libpath"; then aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/; p; } -}'`; fi],[]) -if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi -])# _LT_AC_SYS_LIBPATH_AIX - - -# _LT_AC_SHELL_INIT(ARG) -# ---------------------- -AC_DEFUN([_LT_AC_SHELL_INIT], -[ifdef([AC_DIVERSION_NOTICE], - [AC_DIVERT_PUSH(AC_DIVERSION_NOTICE)], - [AC_DIVERT_PUSH(NOTICE)]) -$1 -AC_DIVERT_POP -])# _LT_AC_SHELL_INIT - - -# _LT_AC_PROG_ECHO_BACKSLASH -# -------------------------- -# Add some code to the start of the generated configure script which -# will find an echo command which doesn't interpret backslashes. -AC_DEFUN([_LT_AC_PROG_ECHO_BACKSLASH], -[_LT_AC_SHELL_INIT([ -# Check that we are running under the correct shell. -SHELL=${CONFIG_SHELL-/bin/sh} - -case X$ECHO in -X*--fallback-echo) - # Remove one level of quotation (which was required for Make). - ECHO=`echo "$ECHO" | sed 's,\\\\\[$]\\[$]0,'[$]0','` - ;; -esac - -echo=${ECHO-echo} -if test "X[$]1" = X--no-reexec; then - # Discard the --no-reexec flag, and continue. - shift -elif test "X[$]1" = X--fallback-echo; then - # Avoid inline document here, it may be left over - : -elif test "X`($echo '\t') 2>/dev/null`" = 'X\t' ; then - # Yippee, $echo works! - : -else - # Restart under the correct shell. - exec $SHELL "[$]0" --no-reexec ${1+"[$]@"} -fi - -if test "X[$]1" = X--fallback-echo; then - # used as fallback echo - shift - cat <<EOF -[$]* -EOF - exit 0 -fi - -# The HP-UX ksh and POSIX shell print the target directory to stdout -# if CDPATH is set. -(unset CDPATH) >/dev/null 2>&1 && unset CDPATH - -if test -z "$ECHO"; then -if test "X${echo_test_string+set}" != Xset; then -# find a string as large as possible, as long as the shell can cope with it - for cmd in 'sed 50q "[$]0"' 'sed 20q "[$]0"' 'sed 10q "[$]0"' 'sed 2q "[$]0"' 'echo test'; do - # expected sizes: less than 2Kb, 1Kb, 512 bytes, 16 bytes, ... - if (echo_test_string="`eval $cmd`") 2>/dev/null && - echo_test_string="`eval $cmd`" && - (test "X$echo_test_string" = "X$echo_test_string") 2>/dev/null - then - break - fi - done -fi - -if test "X`($echo '\t') 2>/dev/null`" = 'X\t' && - echo_testing_string=`($echo "$echo_test_string") 2>/dev/null` && - test "X$echo_testing_string" = "X$echo_test_string"; then - : -else - # The Solaris, AIX, and Digital Unix default echo programs unquote - # backslashes. This makes it impossible to quote backslashes using - # echo "$something" | sed 's/\\/\\\\/g' - # - # So, first we look for a working echo in the user's PATH. - - lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR - for dir in $PATH /usr/ucb; do - IFS="$lt_save_ifs" - if (test -f $dir/echo || test -f $dir/echo$ac_exeext) && - test "X`($dir/echo '\t') 2>/dev/null`" = 'X\t' && - echo_testing_string=`($dir/echo "$echo_test_string") 2>/dev/null` && - test "X$echo_testing_string" = "X$echo_test_string"; then - echo="$dir/echo" - break - fi - done - IFS="$lt_save_ifs" - - if test "X$echo" = Xecho; then - # We didn't find a better echo, so look for alternatives. - if test "X`(print -r '\t') 2>/dev/null`" = 'X\t' && - echo_testing_string=`(print -r "$echo_test_string") 2>/dev/null` && - test "X$echo_testing_string" = "X$echo_test_string"; then - # This shell has a builtin print -r that does the trick. - echo='print -r' - elif (test -f /bin/ksh || test -f /bin/ksh$ac_exeext) && - test "X$CONFIG_SHELL" != X/bin/ksh; then - # If we have ksh, try running configure again with it. - ORIGINAL_CONFIG_SHELL=${CONFIG_SHELL-/bin/sh} - export ORIGINAL_CONFIG_SHELL - CONFIG_SHELL=/bin/ksh - export CONFIG_SHELL - exec $CONFIG_SHELL "[$]0" --no-reexec ${1+"[$]@"} - else - # Try using printf. - echo='printf %s\n' - if test "X`($echo '\t') 2>/dev/null`" = 'X\t' && - echo_testing_string=`($echo "$echo_test_string") 2>/dev/null` && - test "X$echo_testing_string" = "X$echo_test_string"; then - # Cool, printf works - : - elif echo_testing_string=`($ORIGINAL_CONFIG_SHELL "[$]0" --fallback-echo '\t') 2>/dev/null` && - test "X$echo_testing_string" = 'X\t' && - echo_testing_string=`($ORIGINAL_CONFIG_SHELL "[$]0" --fallback-echo "$echo_test_string") 2>/dev/null` && - test "X$echo_testing_string" = "X$echo_test_string"; then - CONFIG_SHELL=$ORIGINAL_CONFIG_SHELL - export CONFIG_SHELL - SHELL="$CONFIG_SHELL" - export SHELL - echo="$CONFIG_SHELL [$]0 --fallback-echo" - elif echo_testing_string=`($CONFIG_SHELL "[$]0" --fallback-echo '\t') 2>/dev/null` && - test "X$echo_testing_string" = 'X\t' && - echo_testing_string=`($CONFIG_SHELL "[$]0" --fallback-echo "$echo_test_string") 2>/dev/null` && - test "X$echo_testing_string" = "X$echo_test_string"; then - echo="$CONFIG_SHELL [$]0 --fallback-echo" - else - # maybe with a smaller string... - prev=: - - for cmd in 'echo test' 'sed 2q "[$]0"' 'sed 10q "[$]0"' 'sed 20q "[$]0"' 'sed 50q "[$]0"'; do - if (test "X$echo_test_string" = "X`eval $cmd`") 2>/dev/null - then - break - fi - prev="$cmd" - done - - if test "$prev" != 'sed 50q "[$]0"'; then - echo_test_string=`eval $prev` - export echo_test_string - exec ${ORIGINAL_CONFIG_SHELL-${CONFIG_SHELL-/bin/sh}} "[$]0" ${1+"[$]@"} - else - # Oops. We lost completely, so just stick with echo. - echo=echo - fi - fi - fi - fi -fi -fi - -# Copy echo and quote the copy suitably for passing to libtool from -# the Makefile, instead of quoting the original, which is used later. -ECHO=$echo -if test "X$ECHO" = "X$CONFIG_SHELL [$]0 --fallback-echo"; then - ECHO="$CONFIG_SHELL \\\$\[$]0 --fallback-echo" -fi - -AC_SUBST(ECHO) -])])# _LT_AC_PROG_ECHO_BACKSLASH - - -# _LT_AC_LOCK -# ----------- -AC_DEFUN([_LT_AC_LOCK], -[AC_ARG_ENABLE([libtool-lock], - [AS_HELP_STRING([--disable-libtool-lock], - [avoid locking (might break parallel builds)])]) -test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes - -# Some flags need to be propagated to the compiler or linker for good -# libtool support. -case $host in -ia64-*-hpux*) - # Find out which ABI we are using. - echo 'int i;' > conftest.$ac_ext - if AC_TRY_EVAL(ac_compile); then - case `/usr/bin/file conftest.$ac_objext` in - *ELF-32*) - HPUX_IA64_MODE="32" - ;; - *ELF-64*) - HPUX_IA64_MODE="64" - ;; - esac - fi - rm -rf conftest* - ;; -*-*-irix6*) - # Find out which ABI we are using. - echo '[#]line __oline__ "configure"' > conftest.$ac_ext - if AC_TRY_EVAL(ac_compile); then - if test "$lt_cv_prog_gnu_ld" = yes; then - case `/usr/bin/file conftest.$ac_objext` in - *32-bit*) - LD="${LD-ld} -melf32bsmip" - ;; - *N32*) - LD="${LD-ld} -melf32bmipn32" - ;; - *64-bit*) - LD="${LD-ld} -melf64bmip" - ;; - esac - else - case `/usr/bin/file conftest.$ac_objext` in - *32-bit*) - LD="${LD-ld} -32" - ;; - *N32*) - LD="${LD-ld} -n32" - ;; - *64-bit*) - LD="${LD-ld} -64" - ;; - esac - fi - fi - rm -rf conftest* - ;; - -x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*|s390*-*linux*|sparc*-*linux*) - # Find out which ABI we are using. - echo 'int i;' > conftest.$ac_ext - if AC_TRY_EVAL(ac_compile); then - case "`/usr/bin/file conftest.o`" in - *32-bit*) - case $host in - x86_64-*linux*) - LD="${LD-ld} -m elf_i386" - ;; - ppc64-*linux*|powerpc64-*linux*) - LD="${LD-ld} -m elf32ppclinux" - ;; - s390x-*linux*) - LD="${LD-ld} -m elf_s390" - ;; - sparc64-*linux*) - LD="${LD-ld} -m elf32_sparc" - ;; - esac - ;; - *64-bit*) - case $host in - x86_64-*linux*) - LD="${LD-ld} -m elf_x86_64" - ;; - ppc*-*linux*|powerpc*-*linux*) - LD="${LD-ld} -m elf64ppc" - ;; - s390*-*linux*) - LD="${LD-ld} -m elf64_s390" - ;; - sparc*-*linux*) - LD="${LD-ld} -m elf64_sparc" - ;; - esac - ;; - esac - fi - rm -rf conftest* - ;; - -*-*-sco3.2v5*) - # On SCO OpenServer 5, we need -belf to get full-featured binaries. - SAVE_CFLAGS="$CFLAGS" - CFLAGS="$CFLAGS -belf" - AC_CACHE_CHECK([whether the C compiler needs -belf], lt_cv_cc_needs_belf, - [AC_LANG_PUSH(C) - AC_TRY_LINK([],[],[lt_cv_cc_needs_belf=yes],[lt_cv_cc_needs_belf=no]) - AC_LANG_POP]) - if test x"$lt_cv_cc_needs_belf" != x"yes"; then - # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf - CFLAGS="$SAVE_CFLAGS" - fi - ;; -AC_PROVIDE_IFELSE([AC_LIBTOOL_WIN32_DLL], -[*-*-cygwin* | *-*-mingw* | *-*-pw32*) - AC_CHECK_TOOL(DLLTOOL, dlltool, false) - AC_CHECK_TOOL(AS, as, false) - AC_CHECK_TOOL(OBJDUMP, objdump, false) - ;; - ]) -esac - -need_locks="$enable_libtool_lock" - -])# _LT_AC_LOCK - - -# AC_LIBTOOL_COMPILER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS, -# [OUTPUT-FILE], [ACTION-SUCCESS], [ACTION-FAILURE]) -# ---------------------------------------------------------------- -# Check whether the given compiler option works -AC_DEFUN([AC_LIBTOOL_COMPILER_OPTION], -[AC_REQUIRE([LT_AC_PROG_SED]) -AC_CACHE_CHECK([$1], [$2], - [$2=no - ifelse([$4], , [ac_outfile=conftest.$ac_objext], [ac_outfile=$4]) - printf "$lt_simple_compile_test_code" > conftest.$ac_ext - lt_compiler_flag="$3" - # Insert the option either (1) after the last *FLAGS variable, or - # (2) before a word containing "conftest.", or (3) at the end. - # Note that $ac_compile itself does not contain backslashes and begins - # with a dollar sign (not a hyphen), so the echo should work correctly. - # The option is referenced via a variable to avoid confusing sed. - lt_compile=`echo "$ac_compile" | $SED \ - -e 's:.*FLAGS}? :&$lt_compiler_flag :; t' \ - -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \ - -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:__oline__: $lt_compile\"" >&AS_MESSAGE_LOG_FD) - (eval "$lt_compile" 2>conftest.err) - ac_status=$? - cat conftest.err >&AS_MESSAGE_LOG_FD - echo "$as_me:__oline__: \$? = $ac_status" >&AS_MESSAGE_LOG_FD - if (exit $ac_status) && test -s "$ac_outfile"; then - # The compiler can only warn and ignore the option if not recognized - # So say no if there are warnings other than the usual output. - $echo "X$_lt_compiler_boilerplate" | $Xsed >conftest.exp - $SED '/^$/d' conftest.err >conftest.er2 - if test ! -s conftest.err || diff conftest.exp conftest.er2 >/dev/null; then - $2=yes - fi - fi - $rm conftest* -]) - -if test x"[$]$2" = xyes; then - ifelse([$5], , :, [$5]) -else - ifelse([$6], , :, [$6]) -fi -])# AC_LIBTOOL_COMPILER_OPTION - - -# AC_LIBTOOL_LINKER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS, -# [ACTION-SUCCESS], [ACTION-FAILURE]) -# ------------------------------------------------------------ -# Check whether the given compiler option works -AC_DEFUN([AC_LIBTOOL_LINKER_OPTION], -[AC_CACHE_CHECK([$1], [$2], - [$2=no - save_LDFLAGS="$LDFLAGS" - LDFLAGS="$LDFLAGS $3" - printf "$lt_simple_link_test_code" > conftest.$ac_ext - if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then - # The compiler can only warn and ignore the option if not recognized - # So say no if there are warnings - if test -s conftest.err; then - # Append any errors to the config.log. - cat conftest.err 1>&AS_MESSAGE_LOG_FD - $echo "X$_lt_linker_boilerplate" | $Xsed > conftest.exp - $SED '/^$/d' conftest.err >conftest.er2 - if diff conftest.exp conftest.er2 >/dev/null; then - $2=yes - fi - else - $2=yes - fi - fi - $rm conftest* - LDFLAGS="$save_LDFLAGS" -]) - -if test x"[$]$2" = xyes; then - ifelse([$4], , :, [$4]) -else - ifelse([$5], , :, [$5]) -fi -])# AC_LIBTOOL_LINKER_OPTION - - -# AC_LIBTOOL_SYS_MAX_CMD_LEN -# -------------------------- -AC_DEFUN([AC_LIBTOOL_SYS_MAX_CMD_LEN], -[# find the maximum length of command line arguments -AC_MSG_CHECKING([the maximum length of command line arguments]) -AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl - i=0 - teststring="ABCD" - - case $build_os in - msdosdjgpp*) - # On DJGPP, this test can blow up pretty badly due to problems in libc - # (any single argument exceeding 2000 bytes causes a buffer overrun - # during glob expansion). Even if it were fixed, the result of this - # check would be larger than it should be. - lt_cv_sys_max_cmd_len=12288; # 12K is about right - ;; - - gnu*) - # Under GNU Hurd, this test is not required because there is - # no limit to the length of command line arguments. - # Libtool will interpret -1 as no limit whatsoever - lt_cv_sys_max_cmd_len=-1; - ;; - - cygwin* | mingw*) - # On Win9x/ME, this test blows up -- it succeeds, but takes - # about 5 minutes as the teststring grows exponentially. - # Worse, since 9x/ME are not pre-emptively multitasking, - # you end up with a "frozen" computer, even though with patience - # the test eventually succeeds (with a max line length of 256k). - # Instead, let's just punt: use the minimum linelength reported by - # all of the supported platforms: 8192 (on NT/2K/XP). - lt_cv_sys_max_cmd_len=8192; - ;; - - amigaos*) - # On AmigaOS with pdksh, this test takes hours, literally. - # So we just punt and use a minimum line length of 8192. - lt_cv_sys_max_cmd_len=8192; - ;; - - netbsd* | freebsd* | openbsd* | darwin* | dragonfly*) - # This has been around since 386BSD, at least. Likely further. - if test -x /sbin/sysctl; then - lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax` - elif test -x /usr/sbin/sysctl; then - lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax` - else - lt_cv_sys_max_cmd_len=65536 # usable default for *BSD - fi - # And add a safety zone - lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` - lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` - ;; - osf*) - # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure - # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not - # nice to cause kernel panics so lets avoid the loop below. - # First set a reasonable default. - lt_cv_sys_max_cmd_len=16384 - # - if test -x /sbin/sysconfig; then - case `/sbin/sysconfig -q proc exec_disable_arg_limit` in - *1*) lt_cv_sys_max_cmd_len=-1 ;; - esac - fi - ;; - *) - # If test is not a shell built-in, we'll probably end up computing a - # maximum length that is only half of the actual maximum length, but - # we can't tell. - SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}} - while (test "X"`$SHELL [$]0 --fallback-echo "X$teststring" 2>/dev/null` \ - = "XX$teststring") >/dev/null 2>&1 && - new_result=`expr "X$teststring" : ".*" 2>&1` && - lt_cv_sys_max_cmd_len=$new_result && - test $i != 17 # 1/2 MB should be enough - do - i=`expr $i + 1` - teststring=$teststring$teststring - done - teststring= - # Add a significant safety factor because C++ compilers can tack on massive - # amounts of additional arguments before passing them to the linker. - # It appears as though 1/2 is a usable value. - lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2` - ;; - esac -]) -if test -n $lt_cv_sys_max_cmd_len ; then - AC_MSG_RESULT($lt_cv_sys_max_cmd_len) -else - AC_MSG_RESULT(none) -fi -])# AC_LIBTOOL_SYS_MAX_CMD_LEN - - -# _LT_AC_CHECK_DLFCN -# -------------------- -AC_DEFUN([_LT_AC_CHECK_DLFCN], -[AC_CHECK_HEADERS(dlfcn.h)dnl -])# _LT_AC_CHECK_DLFCN - - -# _LT_AC_TRY_DLOPEN_SELF (ACTION-IF-TRUE, ACTION-IF-TRUE-W-USCORE, -# ACTION-IF-FALSE, ACTION-IF-CROSS-COMPILING) -# ------------------------------------------------------------------ -AC_DEFUN([_LT_AC_TRY_DLOPEN_SELF], -[AC_REQUIRE([_LT_AC_CHECK_DLFCN])dnl -if test "$cross_compiling" = yes; then : - [$4] -else - lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 - lt_status=$lt_dlunknown - cat > conftest.$ac_ext <<EOF -[#line __oline__ "configure" -#include "confdefs.h" - -#if HAVE_DLFCN_H -#include <dlfcn.h> -#endif - -#include <stdio.h> - -#ifdef RTLD_GLOBAL -# define LT_DLGLOBAL RTLD_GLOBAL -#else -# ifdef DL_GLOBAL -# define LT_DLGLOBAL DL_GLOBAL -# else -# define LT_DLGLOBAL 0 -# endif -#endif - -/* We may have to define LT_DLLAZY_OR_NOW in the command line if we - find out it does not work in some platform. */ -#ifndef LT_DLLAZY_OR_NOW -# ifdef RTLD_LAZY -# define LT_DLLAZY_OR_NOW RTLD_LAZY -# else -# ifdef DL_LAZY -# define LT_DLLAZY_OR_NOW DL_LAZY -# else -# ifdef RTLD_NOW -# define LT_DLLAZY_OR_NOW RTLD_NOW -# else -# ifdef DL_NOW -# define LT_DLLAZY_OR_NOW DL_NOW -# else -# define LT_DLLAZY_OR_NOW 0 -# endif -# endif -# endif -# endif -#endif - -#ifdef __cplusplus -extern "C" void exit (int); -#endif - -void fnord() { int i=42;} -int main () -{ - void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); - int status = $lt_dlunknown; - - if (self) - { - if (dlsym (self,"fnord")) status = $lt_dlno_uscore; - else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; - /* dlclose (self); */ - } - - exit (status); -}] -EOF - if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext} 2>/dev/null; then - (./conftest; exit; ) 2>/dev/null - lt_status=$? - case x$lt_status in - x$lt_dlno_uscore) $1 ;; - x$lt_dlneed_uscore) $2 ;; - x$lt_unknown|x*) $3 ;; - esac - else : - # compilation failed - $3 - fi -fi -rm -fr conftest* -])# _LT_AC_TRY_DLOPEN_SELF - - -# AC_LIBTOOL_DLOPEN_SELF -# ------------------- -AC_DEFUN([AC_LIBTOOL_DLOPEN_SELF], -[AC_REQUIRE([_LT_AC_CHECK_DLFCN])dnl -if test "x$enable_dlopen" != xyes; then - enable_dlopen=unknown - enable_dlopen_self=unknown - enable_dlopen_self_static=unknown -else - lt_cv_dlopen=no - lt_cv_dlopen_libs= - - case $host_os in - beos*) - lt_cv_dlopen="load_add_on" - lt_cv_dlopen_libs= - lt_cv_dlopen_self=yes - ;; - - mingw* | pw32*) - lt_cv_dlopen="LoadLibrary" - lt_cv_dlopen_libs= - ;; - - cygwin*) - lt_cv_dlopen="dlopen" - lt_cv_dlopen_libs= - ;; - - darwin*) - # if libdl is installed we need to link against it - AC_CHECK_LIB([dl], [dlopen], - [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],[ - lt_cv_dlopen="dyld" - lt_cv_dlopen_libs= - lt_cv_dlopen_self=yes - ]) - ;; - - *) - AC_CHECK_FUNC([shl_load], - [lt_cv_dlopen="shl_load"], - [AC_CHECK_LIB([dld], [shl_load], - [lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-dld"], - [AC_CHECK_FUNC([dlopen], - [lt_cv_dlopen="dlopen"], - [AC_CHECK_LIB([dl], [dlopen], - [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"], - [AC_CHECK_LIB([svld], [dlopen], - [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"], - [AC_CHECK_LIB([dld], [dld_link], - [lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-dld"]) - ]) - ]) - ]) - ]) - ]) - ;; - esac - - if test "x$lt_cv_dlopen" != xno; then - enable_dlopen=yes - else - enable_dlopen=no - fi - - case $lt_cv_dlopen in - dlopen) - save_CPPFLAGS="$CPPFLAGS" - test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H" - - save_LDFLAGS="$LDFLAGS" - eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\" - - save_LIBS="$LIBS" - LIBS="$lt_cv_dlopen_libs $LIBS" - - AC_CACHE_CHECK([whether a program can dlopen itself], - lt_cv_dlopen_self, [dnl - _LT_AC_TRY_DLOPEN_SELF( - lt_cv_dlopen_self=yes, lt_cv_dlopen_self=yes, - lt_cv_dlopen_self=no, lt_cv_dlopen_self=cross) - ]) - - if test "x$lt_cv_dlopen_self" = xyes; then - LDFLAGS="$LDFLAGS $link_static_flag" - AC_CACHE_CHECK([whether a statically linked program can dlopen itself], - lt_cv_dlopen_self_static, [dnl - _LT_AC_TRY_DLOPEN_SELF( - lt_cv_dlopen_self_static=yes, lt_cv_dlopen_self_static=yes, - lt_cv_dlopen_self_static=no, lt_cv_dlopen_self_static=cross) - ]) - fi - - CPPFLAGS="$save_CPPFLAGS" - LDFLAGS="$save_LDFLAGS" - LIBS="$save_LIBS" - ;; - esac - - case $lt_cv_dlopen_self in - yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;; - *) enable_dlopen_self=unknown ;; - esac - - case $lt_cv_dlopen_self_static in - yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;; - *) enable_dlopen_self_static=unknown ;; - esac -fi -])# AC_LIBTOOL_DLOPEN_SELF - - -# AC_LIBTOOL_PROG_CC_C_O([TAGNAME]) -# --------------------------------- -# Check to see if options -c and -o are simultaneously supported by compiler -AC_DEFUN([AC_LIBTOOL_PROG_CC_C_O], -[AC_REQUIRE([_LT_AC_SYS_COMPILER])dnl -AC_CACHE_CHECK([if $compiler supports -c -o file.$ac_objext], - [_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)], - [_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)=no - $rm -r conftest 2>/dev/null - mkdir conftest - cd conftest - mkdir out - printf "$lt_simple_compile_test_code" > conftest.$ac_ext - - lt_compiler_flag="-o out/conftest2.$ac_objext" - # Insert the option either (1) after the last *FLAGS variable, or - # (2) before a word containing "conftest.", or (3) at the end. - # Note that $ac_compile itself does not contain backslashes and begins - # with a dollar sign (not a hyphen), so the echo should work correctly. - lt_compile=`echo "$ac_compile" | $SED \ - -e 's:.*FLAGS}? :&$lt_compiler_flag :; t' \ - -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \ - -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:__oline__: $lt_compile\"" >&AS_MESSAGE_LOG_FD) - (eval "$lt_compile" 2>out/conftest.err) - ac_status=$? - cat out/conftest.err >&AS_MESSAGE_LOG_FD - echo "$as_me:__oline__: \$? = $ac_status" >&AS_MESSAGE_LOG_FD - if (exit $ac_status) && test -s out/conftest2.$ac_objext - then - # The compiler can only warn and ignore the option if not recognized - # So say no if there are warnings - $echo "X$_lt_compiler_boilerplate" | $Xsed > out/conftest.exp - $SED '/^$/d' out/conftest.err >out/conftest.er2 - if test ! -s out/conftest.err || diff out/conftest.exp out/conftest.er2 >/dev/null; then - _LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes - fi - fi - chmod u+w . - $rm conftest* - # SGI C++ compiler will create directory out/ii_files/ for - # template instantiation - test -d out/ii_files && $rm out/ii_files/* && rmdir out/ii_files - $rm out/* && rmdir out - cd .. - rmdir conftest - $rm conftest* -]) -])# AC_LIBTOOL_PROG_CC_C_O - - -# AC_LIBTOOL_SYS_HARD_LINK_LOCKS([TAGNAME]) -# ----------------------------------------- -# Check to see if we can do hard links to lock some files if needed -AC_DEFUN([AC_LIBTOOL_SYS_HARD_LINK_LOCKS], -[AC_REQUIRE([_LT_AC_LOCK])dnl - -hard_links="nottested" -if test "$_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)" = no && test "$need_locks" != no; then - # do not overwrite the value of need_locks provided by the user - AC_MSG_CHECKING([if we can lock with hard links]) - hard_links=yes - $rm conftest* - ln conftest.a conftest.b 2>/dev/null && hard_links=no - touch conftest.a - ln conftest.a conftest.b 2>&5 || hard_links=no - ln conftest.a conftest.b 2>/dev/null && hard_links=no - AC_MSG_RESULT([$hard_links]) - if test "$hard_links" = no; then - AC_MSG_WARN([`$CC' does not support `-c -o', so `make -j' may be unsafe]) - need_locks=warn - fi -else - need_locks=no -fi -])# AC_LIBTOOL_SYS_HARD_LINK_LOCKS - - -# AC_LIBTOOL_OBJDIR -# ----------------- -AC_DEFUN([AC_LIBTOOL_OBJDIR], -[AC_CACHE_CHECK([for objdir], [lt_cv_objdir], -[rm -f .libs 2>/dev/null -mkdir .libs 2>/dev/null -if test -d .libs; then - lt_cv_objdir=.libs -else - # MS-DOS does not allow filenames that begin with a dot. - lt_cv_objdir=_libs -fi -rmdir .libs 2>/dev/null]) -objdir=$lt_cv_objdir -])# AC_LIBTOOL_OBJDIR - - -# AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH([TAGNAME]) -# ---------------------------------------------- -# Check hardcoding attributes. -AC_DEFUN([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH], -[AC_MSG_CHECKING([how to hardcode library paths into programs]) -_LT_AC_TAGVAR(hardcode_action, $1)= -if test -n "$_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)" || \ - test -n "$_LT_AC_TAGVAR(runpath_var, $1)" || \ - test "X$_LT_AC_TAGVAR(hardcode_automatic, $1)" = "Xyes" ; then - - # We can hardcode non-existant directories. - if test "$_LT_AC_TAGVAR(hardcode_direct, $1)" != no && - # If the only mechanism to avoid hardcoding is shlibpath_var, we - # have to relink, otherwise we might link with an installed library - # when we should be linking with a yet-to-be-installed one - ## test "$_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)" != no && - test "$_LT_AC_TAGVAR(hardcode_minus_L, $1)" != no; then - # Linking always hardcodes the temporary library directory. - _LT_AC_TAGVAR(hardcode_action, $1)=relink - else - # We can link without hardcoding, and we can hardcode nonexisting dirs. - _LT_AC_TAGVAR(hardcode_action, $1)=immediate - fi -else - # We cannot hardcode anything, or else we can only hardcode existing - # directories. - _LT_AC_TAGVAR(hardcode_action, $1)=unsupported -fi -AC_MSG_RESULT([$_LT_AC_TAGVAR(hardcode_action, $1)]) - -if test "$_LT_AC_TAGVAR(hardcode_action, $1)" = relink; then - # Fast installation is not supported - enable_fast_install=no -elif test "$shlibpath_overrides_runpath" = yes || - test "$enable_shared" = no; then - # Fast installation is not necessary - enable_fast_install=needless -fi -])# AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH - - -# AC_LIBTOOL_SYS_LIB_STRIP -# ------------------------ -AC_DEFUN([AC_LIBTOOL_SYS_LIB_STRIP], -[striplib= -old_striplib= -AC_MSG_CHECKING([whether stripping libraries is possible]) -if test -n "$STRIP" && $STRIP -V 2>&1 | grep "GNU strip" >/dev/null; then - test -z "$old_striplib" && old_striplib="$STRIP --strip-debug" - test -z "$striplib" && striplib="$STRIP --strip-unneeded" - AC_MSG_RESULT([yes]) -else -# FIXME - insert some real tests, host_os isn't really good enough - case $host_os in - darwin*) - if test -n "$STRIP" ; then - striplib="$STRIP -x" - AC_MSG_RESULT([yes]) - else - AC_MSG_RESULT([no]) -fi - ;; - *) - AC_MSG_RESULT([no]) - ;; - esac -fi -])# AC_LIBTOOL_SYS_LIB_STRIP - - -# AC_LIBTOOL_SYS_DYNAMIC_LINKER -# ----------------------------- -# PORTME Fill in your ld.so characteristics -AC_DEFUN([AC_LIBTOOL_SYS_DYNAMIC_LINKER], -[AC_MSG_CHECKING([dynamic linker characteristics]) -library_names_spec= -libname_spec='lib$name' -soname_spec= -shrext_cmds=".so"; shrext="$shrext_cmds" -postinstall_cmds= -postuninstall_cmds= -finish_cmds= -finish_eval= -shlibpath_var= -shlibpath_overrides_runpath=unknown -version_type=none -dynamic_linker="$host_os ld.so" -sys_lib_dlsearch_path_spec="/lib /usr/lib" -if test "$GCC" = yes; then - sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"` - if echo "$sys_lib_search_path_spec" | grep ';' >/dev/null ; then - # if the path contains ";" then we assume it to be the separator - # otherwise default to the standard path separator (i.e. ":") - it is - # assumed that no part of a normal pathname contains ";" but that should - # okay in the real world where ";" in dirpaths is itself problematic. - sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` - else - sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` - fi -else - sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" -fi -need_lib_prefix=unknown -hardcode_into_libs=no - -# when you set need_version to no, make sure it does not cause -set_version -# flags to be left without arguments -need_version=unknown - -case $host_os in -aix3*) - version_type=linux - library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a' - shlibpath_var=LIBPATH - - # AIX 3 has no versioning support, so we append a major version to the name. - soname_spec='${libname}${release}${shared_ext}$major' - ;; - -aix4* | aix5*) - version_type=linux - need_lib_prefix=no - need_version=no - hardcode_into_libs=yes - if test "$host_cpu" = ia64; then - # AIX 5 supports IA64 - library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}' - shlibpath_var=LD_LIBRARY_PATH - else - # With GCC up to 2.95.x, collect2 would create an import file - # for dependence libraries. The import file would start with - # the line `#! .'. This would cause the generated library to - # depend on `.', always an invalid library. This was fixed in - # development snapshots of GCC prior to 3.0. - case $host_os in - aix4 | aix4.[[01]] | aix4.[[01]].*) - if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' - echo ' yes ' - echo '#endif'; } | ${CC} -E - | grep yes > /dev/null; then - : - else - can_build_shared=no - fi - ;; - esac - # AIX (on Power*) has no versioning support, so currently we can not hardcode correct - # soname into executable. Probably we can add versioning support to - # collect2, so additional links can be useful in future. - if test "$aix_use_runtimelinking" = yes; then - # If using run time linking (on AIX 4.2 or later) use lib<name>.so - # instead of lib<name>.a to let people know that these are not - # typical AIX shared libraries. - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - else - # We preserve .a as extension for shared libraries through AIX4.2 - # and later when we are not doing run time linking. - library_names_spec='${libname}${release}.a $libname.a' - soname_spec='${libname}${release}${shared_ext}$major' - fi - shlibpath_var=LIBPATH - fi - ;; - -amigaos*) - library_names_spec='$libname.ixlibrary $libname.a' - # Create ${libname}_ixlibrary.a entries in /sys/libs. - finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`$echo "X$lib" | $Xsed -e '\''s%^.*/\([[^/]]*\)\.ixlibrary$%\1%'\''`; test $rm /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done' - ;; - -beos*) - library_names_spec='${libname}${shared_ext}' - dynamic_linker="$host_os ld.so" - shlibpath_var=LIBRARY_PATH - ;; - -bsdi[[45]]*) - version_type=linux - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' - shlibpath_var=LD_LIBRARY_PATH - sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" - sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" - # the default ld.so.conf also contains /usr/contrib/lib and - # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow - # libtool to hard-code these into programs - ;; - -cygwin* | mingw* | pw32*) - version_type=windows - shrext_cmds=".dll"; shrext="$shrext_cmds" - need_version=no - need_lib_prefix=no - - case $GCC,$host_os in - yes,cygwin* | yes,mingw* | yes,pw32*) - library_names_spec='$libname.dll.a' - # DLL is installed to $(libdir)/../bin by postinstall_cmds - postinstall_cmds='base_file=`basename \${file}`~ - dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i;echo \$dlname'\''`~ - dldir=$destdir/`dirname \$dlpath`~ - test -d \$dldir || mkdir -p \$dldir~ - $install_prog $dir/$dlname \$dldir/$dlname' - postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ - dlpath=$dir/\$dldll~ - $rm \$dlpath' - shlibpath_overrides_runpath=yes - - case $host_os in - cygwin*) - # Cygwin DLLs use 'cyg' prefix rather than 'lib' - soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' - sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib" - ;; - mingw*) - # MinGW DLLs use traditional 'lib' prefix - soname_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' - sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"` - if echo "$sys_lib_search_path_spec" | [grep ';[c-zC-Z]:/' >/dev/null]; then - # It is most probably a Windows format PATH printed by - # mingw gcc, but we are running on Cygwin. Gcc prints its search - # path with ; separators, and with drive letters. We can handle the - # drive letters (cygwin fileutils understands them), so leave them, - # especially as we might pass files found there to a mingw objdump, - # which wouldn't understand a cygwinified path. Ahh. - sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` - else - sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` - fi - ;; - pw32*) - # pw32 DLLs use 'pw' prefix rather than 'lib' - library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' - ;; - esac - ;; - - *) - library_names_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext} $libname.lib' - ;; - esac - dynamic_linker='Win32 ld.exe' - # FIXME: first we should search . and the directory the executable is in - shlibpath_var=PATH - ;; - -darwin* | rhapsody*) - dynamic_linker="$host_os dyld" - version_type=darwin - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${versuffix}$shared_ext ${libname}${release}${major}$shared_ext ${libname}$shared_ext' - soname_spec='${libname}${release}${major}$shared_ext' - shlibpath_overrides_runpath=yes - shlibpath_var=DYLD_LIBRARY_PATH - shrext_cmds='$(test .$module = .yes && echo .so || echo .dylib)'; shrext="$shrext_cmds" - # Apple's gcc prints 'gcc -print-search-dirs' doesn't operate the same. - if test "$GCC" = yes; then - sys_lib_search_path_spec=`$CC -print-search-dirs | tr "\n" "$PATH_SEPARATOR" | sed -e 's/libraries:/@libraries:/' | tr "@" "\n" | grep "^libraries:" | sed -e "s/^libraries://" -e "s,=/,/,g" -e "s,$PATH_SEPARATOR, ,g" -e "s,.*,& /lib /usr/lib /usr/local/lib,g"` - else - sys_lib_search_path_spec='/lib /usr/lib /usr/local/lib' - fi - sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' - ;; - -dgux*) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - ;; - -freebsd1*) - dynamic_linker=no - ;; - -kfreebsd*-gnu) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - dynamic_linker='GNU ld.so' - ;; - -freebsd* | dragonfly*) - # DragonFly does not have aout. When/if they implement a new - # versioning mechanism, adjust this. - objformat=`test -x /usr/bin/objformat && /usr/bin/objformat || echo aout` - version_type=freebsd-$objformat - case $version_type in - freebsd-elf*) - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' - need_version=no - need_lib_prefix=no - ;; - freebsd-*) - library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix' - need_version=yes - ;; - esac - shlibpath_var=LD_LIBRARY_PATH - case $host_os in - freebsd2*) - shlibpath_overrides_runpath=yes - ;; - freebsd3.[[01]]* | freebsdelf3.[[01]]*) - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - ;; - *) # from 3.2 on - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - ;; - esac - ;; - -gnu*) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - hardcode_into_libs=yes - ;; - -hpux9* | hpux10* | hpux11*) - # Give a soname corresponding to the major version so that dld.sl refuses to - # link against other versions. - version_type=sunos - need_lib_prefix=no - need_version=no - case "$host_cpu" in - ia64*) - shrext_cmds='.so'; shrext="$shrext_cmds" - hardcode_into_libs=yes - dynamic_linker="$host_os dld.so" - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - if test "X$HPUX_IA64_MODE" = X32; then - sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" - else - sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" - fi - sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec - ;; - hppa*64*) - shrext_cmds='.sl'; shrext="$shrext_cmds" - hardcode_into_libs=yes - dynamic_linker="$host_os dld.sl" - shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH - shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" - sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec - ;; - *) - shrext_cmds='.sl'; shrext="$shrext_cmds" - dynamic_linker="$host_os dld.sl" - shlibpath_var=SHLIB_PATH - shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - ;; - esac - # HP-UX runs *really* slowly unless shared libraries are mode 555. - postinstall_cmds='chmod 555 $lib' - ;; - -irix5* | irix6* | nonstopux*) - case $host_os in - nonstopux*) version_type=nonstopux ;; - *) - if test "$lt_cv_prog_gnu_ld" = yes; then - version_type=linux - else - version_type=irix - fi ;; - esac - need_lib_prefix=no - need_version=no - soname_spec='${libname}${release}${shared_ext}$major' - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}' - case $host_os in - irix5* | nonstopux*) - libsuff= shlibsuff= - ;; - *) - case $LD in # libtool.m4 will add one of these switches to LD - *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") - libsuff= shlibsuff= libmagic=32-bit;; - *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") - libsuff=32 shlibsuff=N32 libmagic=N32;; - *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") - libsuff=64 shlibsuff=64 libmagic=64-bit;; - *) libsuff= shlibsuff= libmagic=never-match;; - esac - ;; - esac - shlibpath_var=LD_LIBRARY${shlibsuff}_PATH - shlibpath_overrides_runpath=no - sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}" - sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}" - hardcode_into_libs=yes - ;; - -# No shared lib support for Linux oldld, aout, or coff. -linux*oldld* | linux*aout* | linux*coff*) - dynamic_linker=no - ;; - -# This must be Linux ELF. -linux*) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - # This implies no fast_install, which is unacceptable. - # Some rework will be needed to allow for fast_install - # before this can be enabled. - hardcode_into_libs=yes - - # Append ld.so.conf contents to the search path - if test -f /etc/ld.so.conf; then - lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s", \[$]2)); skip = 1; } { if (!skip) print \[$]0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;/^$/d' | tr '\n' ' '` - sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" - fi - - # We used to test for /lib/ld.so.1 and disable shared libraries on - # powerpc, because MkLinux only supported shared libraries with the - # GNU dynamic linker. Since this was broken with cross compilers, - # most powerpc-linux boxes support dynamic linking these days and - # people can always --disable-shared, the test was removed, and we - # assume the GNU/Linux dynamic linker is in use. - dynamic_linker='GNU/Linux ld.so' - ;; - -knetbsd*-gnu) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - dynamic_linker='GNU ld.so' - ;; - -netbsd*) - version_type=sunos - need_lib_prefix=no - need_version=no - if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' - finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' - dynamic_linker='NetBSD (a.out) ld.so' - else - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - dynamic_linker='NetBSD ld.elf_so' - fi - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - ;; - -newsos6) - version_type=linux - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - ;; - -nto-qnx*) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - ;; - -openbsd*) - version_type=sunos - need_lib_prefix=no - # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs. - case $host_os in - openbsd3.3 | openbsd3.3.*) need_version=yes ;; - *) need_version=no ;; - esac - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' - finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' - shlibpath_var=LD_LIBRARY_PATH - if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then - case $host_os in - openbsd2.[[89]] | openbsd2.[[89]].*) - shlibpath_overrides_runpath=no - ;; - *) - shlibpath_overrides_runpath=yes - ;; - esac - else - shlibpath_overrides_runpath=yes - fi - ;; - -os2*) - libname_spec='$name' - shrext_cmds=".dll"; shrext="$shrext_cmds" - need_lib_prefix=no - library_names_spec='$libname${shared_ext} $libname.a' - dynamic_linker='OS/2 ld.exe' - shlibpath_var=LIBPATH - ;; - -osf3* | osf4* | osf5*) - version_type=osf - need_lib_prefix=no - need_version=no - soname_spec='${libname}${release}${shared_ext}$major' - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - shlibpath_var=LD_LIBRARY_PATH - sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" - sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec" - ;; - -sco3.2v5*) - version_type=osf - soname_spec='${libname}${release}${shared_ext}$major' - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - shlibpath_var=LD_LIBRARY_PATH - ;; - -solaris*) - version_type=linux - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - # ldd complains unless libraries are executable - postinstall_cmds='chmod +x $lib' - ;; - -sunos4*) - version_type=sunos - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' - finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - if test "$with_gnu_ld" = yes; then - need_lib_prefix=no - fi - need_version=yes - ;; - -sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) - version_type=linux - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - case $host_vendor in - sni) - shlibpath_overrides_runpath=no - need_lib_prefix=no - export_dynamic_flag_spec='${wl}-Blargedynsym' - runpath_var=LD_RUN_PATH - ;; - siemens) - need_lib_prefix=no - ;; - motorola) - need_lib_prefix=no - need_version=no - shlibpath_overrides_runpath=no - sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' - ;; - esac - ;; - -sysv4*MP*) - if test -d /usr/nec ;then - version_type=linux - library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}' - soname_spec='$libname${shared_ext}.$major' - shlibpath_var=LD_LIBRARY_PATH - fi - ;; - -uts4*) - version_type=linux - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - ;; - -*) - dynamic_linker=no - ;; -esac -AC_MSG_RESULT([$dynamic_linker]) -test "$dynamic_linker" = no && can_build_shared=no -])# AC_LIBTOOL_SYS_DYNAMIC_LINKER - - -# _LT_AC_TAGCONFIG -# ---------------- -AC_DEFUN([_LT_AC_TAGCONFIG], -[AC_ARG_WITH([tags], - [AS_HELP_STRING([--with-tags@<:@=TAGS@:>@], - [include additional configurations @<:@automatic@:>@])], - [tagnames="$withval"]) - -if test -f "$ltmain" && test -n "$tagnames"; then - if test ! -f "${ofile}"; then - AC_MSG_WARN([output file `$ofile' does not exist]) - fi - - if test -z "$LTCC"; then - eval "`$SHELL ${ofile} --config | grep '^LTCC='`" - if test -z "$LTCC"; then - AC_MSG_WARN([output file `$ofile' does not look like a libtool script]) - else - AC_MSG_WARN([using `LTCC=$LTCC', extracted from `$ofile']) - fi - fi - - # Extract list of available tagged configurations in $ofile. - # Note that this assumes the entire list is on one line. - available_tags=`grep "^available_tags=" "${ofile}" | $SED -e 's/available_tags=\(.*$\)/\1/' -e 's/\"//g'` - - lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," - for tagname in $tagnames; do - IFS="$lt_save_ifs" - # Check whether tagname contains only valid characters - case `$echo "X$tagname" | $Xsed -e 's:[[-_ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz1234567890,/]]::g'` in - "") ;; - *) AC_MSG_ERROR([invalid tag name: $tagname]) - ;; - esac - - if grep "^# ### BEGIN LIBTOOL TAG CONFIG: $tagname$" < "${ofile}" > /dev/null - then - AC_MSG_ERROR([tag name \"$tagname\" already exists]) - fi - - # Update the list of available tags. - if test -n "$tagname"; then - echo appending configuration tag \"$tagname\" to $ofile - - case $tagname in - CXX) - if test -n "$CXX" && ( test "X$CXX" != "Xno" && - ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) || - (test "X$CXX" != "Xg++"))) ; then - AC_LIBTOOL_LANG_CXX_CONFIG - else - tagname="" - fi - ;; - - F77) - if test -n "$F77" && test "X$F77" != "Xno"; then - AC_LIBTOOL_LANG_F77_CONFIG - else - tagname="" - fi - ;; - - GCJ) - if test -n "$GCJ" && test "X$GCJ" != "Xno"; then - AC_LIBTOOL_LANG_GCJ_CONFIG - else - tagname="" - fi - ;; - - RC) - AC_LIBTOOL_LANG_RC_CONFIG - ;; - - *) - AC_MSG_ERROR([Unsupported tag name: $tagname]) - ;; - esac - - # Append the new tag name to the list of available tags. - if test -n "$tagname" ; then - available_tags="$available_tags $tagname" - fi - fi - done - IFS="$lt_save_ifs" - - # Now substitute the updated list of available tags. - if eval "sed -e 's/^available_tags=.*\$/available_tags=\"$available_tags\"/' \"$ofile\" > \"${ofile}T\""; then - mv "${ofile}T" "$ofile" - chmod +x "$ofile" - else - rm -f "${ofile}T" - AC_MSG_ERROR([unable to update list of available tagged configurations.]) - fi -fi -])# _LT_AC_TAGCONFIG - - -# AC_LIBTOOL_DLOPEN -# ----------------- -# enable checks for dlopen support -AC_DEFUN([AC_LIBTOOL_DLOPEN], - [AC_BEFORE([$0],[AC_LIBTOOL_SETUP]) -])# AC_LIBTOOL_DLOPEN - - -# AC_LIBTOOL_WIN32_DLL -# -------------------- -# declare package support for building win32 dll's -AC_DEFUN([AC_LIBTOOL_WIN32_DLL], -[AC_BEFORE([$0], [AC_LIBTOOL_SETUP]) -])# AC_LIBTOOL_WIN32_DLL - - -# AC_ENABLE_SHARED([DEFAULT]) -# --------------------------- -# implement the --enable-shared flag -# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'. -AC_DEFUN([AC_ENABLE_SHARED], -[define([AC_ENABLE_SHARED_DEFAULT], ifelse($1, no, no, yes))dnl -AC_ARG_ENABLE([shared], - [AS_HELP_STRING([--enable-shared@<:@=PKGS@:>@], - [build shared libraries @<:@default=]AC_ENABLE_SHARED_DEFAULT[@:>@])], - [p=${PACKAGE-default} - case $enableval in - yes) enable_shared=yes ;; - no) enable_shared=no ;; - *) - enable_shared=no - # Look at the argument we got. We use all the common list separators. - lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," - for pkg in $enableval; do - IFS="$lt_save_ifs" - if test "X$pkg" = "X$p"; then - enable_shared=yes - fi - done - IFS="$lt_save_ifs" - ;; - esac], - [enable_shared=]AC_ENABLE_SHARED_DEFAULT) -])# AC_ENABLE_SHARED - - -# AC_DISABLE_SHARED -# ----------------- -#- set the default shared flag to --disable-shared -AC_DEFUN([AC_DISABLE_SHARED], -[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl -AC_ENABLE_SHARED(no) -])# AC_DISABLE_SHARED - - -# AC_ENABLE_STATIC([DEFAULT]) -# --------------------------- -# implement the --enable-static flag -# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'. -AC_DEFUN([AC_ENABLE_STATIC], -[define([AC_ENABLE_STATIC_DEFAULT], ifelse($1, no, no, yes))dnl -AC_ARG_ENABLE([static], - [AS_HELP_STRING([--enable-static@<:@=PKGS@:>@], - [build static libraries @<:@default=]AC_ENABLE_STATIC_DEFAULT[@:>@])], - [p=${PACKAGE-default} - case $enableval in - yes) enable_static=yes ;; - no) enable_static=no ;; - *) - enable_static=no - # Look at the argument we got. We use all the common list separators. - lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," - for pkg in $enableval; do - IFS="$lt_save_ifs" - if test "X$pkg" = "X$p"; then - enable_static=yes - fi - done - IFS="$lt_save_ifs" - ;; - esac], - [enable_static=]AC_ENABLE_STATIC_DEFAULT) -])# AC_ENABLE_STATIC - - -# AC_DISABLE_STATIC -# ----------------- -# set the default static flag to --disable-static -AC_DEFUN([AC_DISABLE_STATIC], -[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl -AC_ENABLE_STATIC(no) -])# AC_DISABLE_STATIC - - -# AC_ENABLE_FAST_INSTALL([DEFAULT]) -# --------------------------------- -# implement the --enable-fast-install flag -# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'. -AC_DEFUN([AC_ENABLE_FAST_INSTALL], -[define([AC_ENABLE_FAST_INSTALL_DEFAULT], ifelse($1, no, no, yes))dnl -AC_ARG_ENABLE([fast-install], - [AS_HELP_STRING([--enable-fast-install@<:@=PKGS@:>@], - [optimize for fast installation @<:@default=]AC_ENABLE_FAST_INSTALL_DEFAULT[@:>@])], - [p=${PACKAGE-default} - case $enableval in - yes) enable_fast_install=yes ;; - no) enable_fast_install=no ;; - *) - enable_fast_install=no - # Look at the argument we got. We use all the common list separators. - lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," - for pkg in $enableval; do - IFS="$lt_save_ifs" - if test "X$pkg" = "X$p"; then - enable_fast_install=yes - fi - done - IFS="$lt_save_ifs" - ;; - esac], - [enable_fast_install=]AC_ENABLE_FAST_INSTALL_DEFAULT) -])# AC_ENABLE_FAST_INSTALL - - -# AC_DISABLE_FAST_INSTALL -# ----------------------- -# set the default to --disable-fast-install -AC_DEFUN([AC_DISABLE_FAST_INSTALL], -[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl -AC_ENABLE_FAST_INSTALL(no) -])# AC_DISABLE_FAST_INSTALL - - -# AC_LIBTOOL_PICMODE([MODE]) -# -------------------------- -# implement the --with-pic flag -# MODE is either `yes' or `no'. If omitted, it defaults to `both'. -AC_DEFUN([AC_LIBTOOL_PICMODE], -[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl -pic_mode=ifelse($#,1,$1,default) -])# AC_LIBTOOL_PICMODE - - -# AC_PROG_EGREP -# ------------- -# This is predefined starting with Autoconf 2.54, so this conditional -# definition can be removed once we require Autoconf 2.54 or later. -m4_ifndef([AC_PROG_EGREP], [AC_DEFUN([AC_PROG_EGREP], -[AC_CACHE_CHECK([for egrep], [ac_cv_prog_egrep], - [if echo a | (grep -E '(a|b)') >/dev/null 2>&1 - then ac_cv_prog_egrep='grep -E' - else ac_cv_prog_egrep='egrep' - fi]) - EGREP=$ac_cv_prog_egrep - AC_SUBST([EGREP]) -])]) - - -# AC_PATH_TOOL_PREFIX -# ------------------- -# find a file program which can recognise shared library -AC_DEFUN([AC_PATH_TOOL_PREFIX], -[AC_REQUIRE([AC_PROG_EGREP])dnl -AC_MSG_CHECKING([for $1]) -AC_CACHE_VAL(lt_cv_path_MAGIC_CMD, -[case $MAGIC_CMD in -[[\\/*] | ?:[\\/]*]) - lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path. - ;; -*) - lt_save_MAGIC_CMD="$MAGIC_CMD" - lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR -dnl $ac_dummy forces splitting on constant user-supplied paths. -dnl POSIX.2 word splitting is done only on the output of word expansions, -dnl not every word. This closes a longstanding sh security hole. - ac_dummy="ifelse([$2], , $PATH, [$2])" - for ac_dir in $ac_dummy; do - IFS="$lt_save_ifs" - test -z "$ac_dir" && ac_dir=. - if test -f $ac_dir/$1; then - lt_cv_path_MAGIC_CMD="$ac_dir/$1" - if test -n "$file_magic_test_file"; then - case $deplibs_check_method in - "file_magic "*) - file_magic_regex="`expr \"$deplibs_check_method\" : \"file_magic \(.*\)\"`" - MAGIC_CMD="$lt_cv_path_MAGIC_CMD" - if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | - $EGREP "$file_magic_regex" > /dev/null; then - : - else - cat <<EOF 1>&2 - -*** Warning: the command libtool uses to detect shared libraries, -*** $file_magic_cmd, produces output that libtool cannot recognize. -*** The result is that libtool may fail to recognize shared libraries -*** as such. This will affect the creation of libtool libraries that -*** depend on shared libraries, but programs linked with such libtool -*** libraries will work regardless of this problem. Nevertheless, you -*** may want to report the problem to your system manager and/or to -*** bug-libtool@gnu.org - -EOF - fi ;; - esac - fi - break - fi - done - IFS="$lt_save_ifs" - MAGIC_CMD="$lt_save_MAGIC_CMD" - ;; -esac]) -MAGIC_CMD="$lt_cv_path_MAGIC_CMD" -if test -n "$MAGIC_CMD"; then - AC_MSG_RESULT($MAGIC_CMD) -else - AC_MSG_RESULT(no) -fi -])# AC_PATH_TOOL_PREFIX - - -# AC_PATH_MAGIC -# ------------- -# find a file program which can recognise a shared library -AC_DEFUN([AC_PATH_MAGIC], -[AC_PATH_TOOL_PREFIX(${ac_tool_prefix}file, /usr/bin$PATH_SEPARATOR$PATH) -if test -z "$lt_cv_path_MAGIC_CMD"; then - if test -n "$ac_tool_prefix"; then - AC_PATH_TOOL_PREFIX(file, /usr/bin$PATH_SEPARATOR$PATH) - else - MAGIC_CMD=: - fi -fi -])# AC_PATH_MAGIC - - -# AC_PROG_LD -# ---------- -# find the pathname to the GNU or non-GNU linker -AC_DEFUN([AC_PROG_LD], -[AC_ARG_WITH([gnu-ld], - [AS_HELP_STRING([--with-gnu-ld], - [assume the C compiler uses GNU ld @<:@default=no@:>@])], - [test "$withval" = no || with_gnu_ld=yes], - [with_gnu_ld=no]) -AC_REQUIRE([LT_AC_PROG_SED])dnl -AC_REQUIRE([AC_PROG_CC])dnl -AC_REQUIRE([AC_CANONICAL_HOST])dnl -AC_REQUIRE([AC_CANONICAL_BUILD])dnl -ac_prog=ld -if test "$GCC" = yes; then - # Check if gcc -print-prog-name=ld gives a path. - AC_MSG_CHECKING([for ld used by $CC]) - case $host in - *-*-mingw*) - # gcc leaves a trailing carriage return which upsets mingw - ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; - *) - ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; - esac - case $ac_prog in - # Accept absolute paths. - [[\\/]]* | ?:[[\\/]]*) - re_direlt='/[[^/]][[^/]]*/\.\./' - # Canonicalize the pathname of ld - ac_prog=`echo $ac_prog| $SED 's%\\\\%/%g'` - while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do - ac_prog=`echo $ac_prog| $SED "s%$re_direlt%/%"` - done - test -z "$LD" && LD="$ac_prog" - ;; - "") - # If it fails, then pretend we aren't using GCC. - ac_prog=ld - ;; - *) - # If it is relative, then search for the first ld in PATH. - with_gnu_ld=unknown - ;; - esac -elif test "$with_gnu_ld" = yes; then - AC_MSG_CHECKING([for GNU ld]) -else - AC_MSG_CHECKING([for non-GNU ld]) -fi -AC_CACHE_VAL(lt_cv_path_LD, -[if test -z "$LD"; then - lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR - for ac_dir in $PATH; do - IFS="$lt_save_ifs" - test -z "$ac_dir" && ac_dir=. - if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then - lt_cv_path_LD="$ac_dir/$ac_prog" - # Check to see if the program is GNU ld. I'd rather use --version, - # but apparently some GNU ld's only accept -v. - # Break only if it was the GNU/non-GNU ld that we prefer. - case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in - *GNU* | *'with BFD'*) - test "$with_gnu_ld" != no && break - ;; - *) - test "$with_gnu_ld" != yes && break - ;; - esac - fi - done - IFS="$lt_save_ifs" -else - lt_cv_path_LD="$LD" # Let the user override the test with a path. -fi]) -LD="$lt_cv_path_LD" -if test -n "$LD"; then - AC_MSG_RESULT($LD) -else - AC_MSG_RESULT(no) -fi -test -z "$LD" && AC_MSG_ERROR([no acceptable ld found in \$PATH]) -AC_PROG_LD_GNU -])# AC_PROG_LD - - -# AC_PROG_LD_GNU -# -------------- -AC_DEFUN([AC_PROG_LD_GNU], -[AC_REQUIRE([AC_PROG_EGREP])dnl -AC_CACHE_CHECK([if the linker ($LD) is GNU ld], lt_cv_prog_gnu_ld, -[# I'd rather use --version here, but apparently some GNU ld's only accept -v. -case `$LD -v 2>&1 </dev/null` in -*GNU* | *'with BFD'*) - lt_cv_prog_gnu_ld=yes - ;; -*) - lt_cv_prog_gnu_ld=no - ;; -esac]) -with_gnu_ld=$lt_cv_prog_gnu_ld -])# AC_PROG_LD_GNU - - -# AC_PROG_LD_RELOAD_FLAG -# ---------------------- -# find reload flag for linker -# -- PORTME Some linkers may need a different reload flag. -AC_DEFUN([AC_PROG_LD_RELOAD_FLAG], -[AC_CACHE_CHECK([for $LD option to reload object files], - lt_cv_ld_reload_flag, - [lt_cv_ld_reload_flag='-r']) -reload_flag=$lt_cv_ld_reload_flag -case $reload_flag in -"" | " "*) ;; -*) reload_flag=" $reload_flag" ;; -esac -reload_cmds='$LD$reload_flag -o $output$reload_objs' -case $host_os in - darwin*) - if test "$GCC" = yes; then - reload_cmds='$CC -nostdlib ${wl}-r -o $output$reload_objs' - else - reload_cmds='$LD$reload_flag -o $output$reload_objs' - fi - ;; -esac -])# AC_PROG_LD_RELOAD_FLAG - - -# AC_DEPLIBS_CHECK_METHOD -# ----------------------- -# how to check for library dependencies -# -- PORTME fill in with the dynamic library characteristics -AC_DEFUN([AC_DEPLIBS_CHECK_METHOD], -[AC_CACHE_CHECK([how to recognise dependent libraries], -lt_cv_deplibs_check_method, -[lt_cv_file_magic_cmd='$MAGIC_CMD' -lt_cv_file_magic_test_file= -lt_cv_deplibs_check_method='unknown' -# Need to set the preceding variable on all platforms that support -# interlibrary dependencies. -# 'none' -- dependencies not supported. -# `unknown' -- same as none, but documents that we really don't know. -# 'pass_all' -- all dependencies passed with no checks. -# 'test_compile' -- check by making test program. -# 'file_magic [[regex]]' -- check by looking for files in library path -# which responds to the $file_magic_cmd with a given extended regex. -# If you have `file' or equivalent on your system and you're not sure -# whether `pass_all' will *always* work, you probably want this one. - -case $host_os in -aix4* | aix5*) - lt_cv_deplibs_check_method=pass_all - ;; - -beos*) - lt_cv_deplibs_check_method=pass_all - ;; - -bsdi[[45]]*) - lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib)' - lt_cv_file_magic_cmd='/usr/bin/file -L' - lt_cv_file_magic_test_file=/shlib/libc.so - ;; - -cygwin*) - # func_win32_libid is a shell function defined in ltmain.sh - lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' - lt_cv_file_magic_cmd='func_win32_libid' - ;; - -mingw* | pw32*) - # Base MSYS/MinGW do not provide the 'file' command needed by - # func_win32_libid shell function, so use a weaker test based on 'objdump'. - lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?' - lt_cv_file_magic_cmd='$OBJDUMP -f' - ;; - -darwin* | rhapsody*) - lt_cv_deplibs_check_method=pass_all - ;; - -freebsd* | kfreebsd*-gnu | dragonfly*) - if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then - case $host_cpu in - i*86 ) - # Not sure whether the presence of OpenBSD here was a mistake. - # Let's accept both of them until this is cleared up. - lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[[3-9]]86 (compact )?demand paged shared library' - lt_cv_file_magic_cmd=/usr/bin/file - lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*` - ;; - esac - else - lt_cv_deplibs_check_method=pass_all - fi - ;; - -gnu*) - lt_cv_deplibs_check_method=pass_all - ;; - -hpux10.20* | hpux11*) - lt_cv_file_magic_cmd=/usr/bin/file - case "$host_cpu" in - ia64*) - lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|ELF-[[0-9]][[0-9]]) shared object file - IA64' - lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so - ;; - hppa*64*) - [lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - PA-RISC [0-9].[0-9]'] - lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl - ;; - *) - lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|PA-RISC[[0-9]].[[0-9]]) shared library' - lt_cv_file_magic_test_file=/usr/lib/libc.sl - ;; - esac - ;; - -irix5* | irix6* | nonstopux*) - case $LD in - *-32|*"-32 ") libmagic=32-bit;; - *-n32|*"-n32 ") libmagic=N32;; - *-64|*"-64 ") libmagic=64-bit;; - *) libmagic=never-match;; - esac - lt_cv_deplibs_check_method=pass_all - ;; - -# This must be Linux ELF. -linux*) - lt_cv_deplibs_check_method=pass_all - ;; - -netbsd*) - if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then - lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$' - else - lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|_pic\.a)$' - fi - ;; - -newos6*) - lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (executable|dynamic lib)' - lt_cv_file_magic_cmd=/usr/bin/file - lt_cv_file_magic_test_file=/usr/lib/libnls.so - ;; - -nto-qnx*) - lt_cv_deplibs_check_method=unknown - ;; - -openbsd*) - if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then - lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|\.so|_pic\.a)$' - else - lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$' - fi - ;; - -osf3* | osf4* | osf5*) - lt_cv_deplibs_check_method=pass_all - ;; - -sco3.2v5*) - lt_cv_deplibs_check_method=pass_all - ;; - -solaris*) - lt_cv_deplibs_check_method=pass_all - ;; - -sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) - case $host_vendor in - motorola) - lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib) M[[0-9]][[0-9]]* Version [[0-9]]' - lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*` - ;; - ncr) - lt_cv_deplibs_check_method=pass_all - ;; - sequent) - lt_cv_file_magic_cmd='/bin/file' - lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB (shared object|dynamic lib )' - ;; - sni) - lt_cv_file_magic_cmd='/bin/file' - lt_cv_deplibs_check_method="file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB dynamic lib" - lt_cv_file_magic_test_file=/lib/libc.so - ;; - siemens) - lt_cv_deplibs_check_method=pass_all - ;; - esac - ;; - -sysv5OpenUNIX8* | sysv5UnixWare7* | sysv5uw[[78]]* | unixware7* | sysv4*uw2*) - lt_cv_deplibs_check_method=pass_all - ;; -esac -]) -file_magic_cmd=$lt_cv_file_magic_cmd -deplibs_check_method=$lt_cv_deplibs_check_method -test -z "$deplibs_check_method" && deplibs_check_method=unknown -])# AC_DEPLIBS_CHECK_METHOD - - -# AC_PROG_NM -# ---------- -# find the pathname to a BSD-compatible name lister -AC_DEFUN([AC_PROG_NM], -[AC_CACHE_CHECK([for BSD-compatible nm], lt_cv_path_NM, -[if test -n "$NM"; then - # Let the user override the test. - lt_cv_path_NM="$NM" -else - lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR - for ac_dir in $PATH /usr/ccs/bin /usr/ucb /bin; do - IFS="$lt_save_ifs" - test -z "$ac_dir" && ac_dir=. - tmp_nm="$ac_dir/${ac_tool_prefix}nm" - if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then - # Check to see if the nm accepts a BSD-compat flag. - # Adding the `sed 1q' prevents false positives on HP-UX, which says: - # nm: unknown option "B" ignored - # Tru64's nm complains that /dev/null is an invalid object file - case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in - */dev/null* | *'Invalid file or object type'*) - lt_cv_path_NM="$tmp_nm -B" - break - ;; - *) - case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in - */dev/null*) - lt_cv_path_NM="$tmp_nm -p" - break - ;; - *) - lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but - continue # so that we can try to find one that supports BSD flags - ;; - esac - esac - fi - done - IFS="$lt_save_ifs" - test -z "$lt_cv_path_NM" && lt_cv_path_NM=nm -fi]) -NM="$lt_cv_path_NM" -])# AC_PROG_NM - - -# AC_CHECK_LIBM -# ------------- -# check for math library -AC_DEFUN([AC_CHECK_LIBM], -[AC_REQUIRE([AC_CANONICAL_HOST])dnl -LIBM= -case $host in -*-*-beos* | *-*-cygwin* | *-*-pw32* | *-*-darwin*) - # These system don't have libm, or don't need it - ;; -*-ncr-sysv4.3*) - AC_CHECK_LIB(mw, _mwvalidcheckl, LIBM="-lmw") - AC_CHECK_LIB(m, cos, LIBM="$LIBM -lm") - ;; -*) - AC_CHECK_LIB(m, cos, LIBM="-lm") - ;; -esac -])# AC_CHECK_LIBM - - -# AC_LIBLTDL_CONVENIENCE([DIRECTORY]) -# ----------------------------------- -# sets LIBLTDL to the link flags for the libltdl convenience library and -# LTDLINCL to the include flags for the libltdl header and adds -# --enable-ltdl-convenience to the configure arguments. Note that LIBLTDL -# and LTDLINCL are not AC_SUBSTed, nor is AC_CONFIG_SUBDIRS called. If -# DIRECTORY is not provided, it is assumed to be `libltdl'. LIBLTDL will -# be prefixed with '${top_builddir}/' and LTDLINCL will be prefixed with -# '${top_srcdir}/' (note the single quotes!). If your package is not -# flat and you're not using automake, define top_builddir and -# top_srcdir appropriately in the Makefiles. -AC_DEFUN([AC_LIBLTDL_CONVENIENCE], -[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl - case $enable_ltdl_convenience in - no) AC_MSG_ERROR([this package needs a convenience libltdl]) ;; - "") enable_ltdl_convenience=yes - ac_configure_args="$ac_configure_args --enable-ltdl-convenience" ;; - esac - LIBLTDL='${top_builddir}/'ifelse($#,1,[$1],['libltdl'])/libltdlc.la - LTDLINCL='-I${top_srcdir}/'ifelse($#,1,[$1],['libltdl']) - # For backwards non-gettext consistent compatibility... - INCLTDL="$LTDLINCL" -])# AC_LIBLTDL_CONVENIENCE - - -# AC_LIBLTDL_INSTALLABLE([DIRECTORY]) -# ----------------------------------- -# sets LIBLTDL to the link flags for the libltdl installable library and -# LTDLINCL to the include flags for the libltdl header and adds -# --enable-ltdl-install to the configure arguments. Note that LIBLTDL -# and LTDLINCL are not AC_SUBSTed, nor is AC_CONFIG_SUBDIRS called. If -# DIRECTORY is not provided and an installed libltdl is not found, it is -# assumed to be `libltdl'. LIBLTDL will be prefixed with '${top_builddir}/' -# and LTDLINCL will be prefixed with '${top_srcdir}/' (note the single -# quotes!). If your package is not flat and you're not using automake, -# define top_builddir and top_srcdir appropriately in the Makefiles. -# In the future, this macro may have to be called after AC_PROG_LIBTOOL. -AC_DEFUN([AC_LIBLTDL_INSTALLABLE], -[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl - AC_CHECK_LIB(ltdl, lt_dlinit, - [test x"$enable_ltdl_install" != xyes && enable_ltdl_install=no], - [if test x"$enable_ltdl_install" = xno; then - AC_MSG_WARN([libltdl not installed, but installation disabled]) - else - enable_ltdl_install=yes - fi - ]) - if test x"$enable_ltdl_install" = x"yes"; then - ac_configure_args="$ac_configure_args --enable-ltdl-install" - LIBLTDL='${top_builddir}/'ifelse($#,1,[$1],['libltdl'])/libltdl.la - LTDLINCL='-I${top_srcdir}/'ifelse($#,1,[$1],['libltdl']) - else - ac_configure_args="$ac_configure_args --enable-ltdl-install=no" - LIBLTDL="-lltdl" - LTDLINCL= - fi - # For backwards non-gettext consistent compatibility... - INCLTDL="$LTDLINCL" -])# AC_LIBLTDL_INSTALLABLE - - -# AC_LIBTOOL_CXX -# -------------- -# enable support for C++ libraries -AC_DEFUN([AC_LIBTOOL_CXX], -[AC_REQUIRE([_LT_AC_LANG_CXX]) -])# AC_LIBTOOL_CXX - - -# _LT_AC_LANG_CXX -# --------------- -AC_DEFUN([_LT_AC_LANG_CXX], -[AC_REQUIRE([AC_PROG_CXX]) -AC_REQUIRE([_LT_AC_PROG_CXXCPP]) -_LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}CXX]) -])# _LT_AC_LANG_CXX - -# _LT_AC_PROG_CXXCPP -# --------------- -AC_DEFUN([_LT_AC_PROG_CXXCPP], -[ -AC_REQUIRE([AC_PROG_CXX]) -if test -n "$CXX" && ( test "X$CXX" != "Xno" && - ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) || - (test "X$CXX" != "Xg++"))) ; then - AC_PROG_CXXCPP -fi -])# _LT_AC_PROG_CXXCPP - -# AC_LIBTOOL_F77 -# -------------- -# enable support for Fortran 77 libraries -AC_DEFUN([AC_LIBTOOL_F77], -[AC_REQUIRE([_LT_AC_LANG_F77]) -])# AC_LIBTOOL_F77 - - -# _LT_AC_LANG_F77 -# --------------- -AC_DEFUN([_LT_AC_LANG_F77], -[AC_REQUIRE([AC_PROG_F77]) -_LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}F77]) -])# _LT_AC_LANG_F77 - - -# AC_LIBTOOL_GCJ -# -------------- -# enable support for GCJ libraries -AC_DEFUN([AC_LIBTOOL_GCJ], -[AC_REQUIRE([_LT_AC_LANG_GCJ]) -])# AC_LIBTOOL_GCJ - - -# _LT_AC_LANG_GCJ -# --------------- -AC_DEFUN([_LT_AC_LANG_GCJ], -[AC_PROVIDE_IFELSE([AC_PROG_GCJ],[], - [AC_PROVIDE_IFELSE([A][M_PROG_GCJ],[], - [AC_PROVIDE_IFELSE([LT_AC_PROG_GCJ],[], - [ifdef([AC_PROG_GCJ],[AC_REQUIRE([AC_PROG_GCJ])], - [ifdef([A][M_PROG_GCJ],[AC_REQUIRE([A][M_PROG_GCJ])], - [AC_REQUIRE([A][C_PROG_GCJ_OR_A][M_PROG_GCJ])])])])])]) -_LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}GCJ]) -])# _LT_AC_LANG_GCJ - - -# AC_LIBTOOL_RC -# -------------- -# enable support for Windows resource files -AC_DEFUN([AC_LIBTOOL_RC], -[AC_REQUIRE([LT_AC_PROG_RC]) -_LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}RC]) -])# AC_LIBTOOL_RC - - -# AC_LIBTOOL_LANG_C_CONFIG -# ------------------------ -# Ensure that the configuration vars for the C compiler are -# suitably defined. Those variables are subsequently used by -# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'. -AC_DEFUN([AC_LIBTOOL_LANG_C_CONFIG], [_LT_AC_LANG_C_CONFIG]) -AC_DEFUN([_LT_AC_LANG_C_CONFIG], -[lt_save_CC="$CC" -AC_LANG_PUSH(C) - -# Source file extension for C test sources. -ac_ext=c - -# Object file extension for compiled C test sources. -objext=o -_LT_AC_TAGVAR(objext, $1)=$objext - -# Code to be used in simple compile tests -lt_simple_compile_test_code="int some_variable = 0;\n" - -# Code to be used in simple link tests -lt_simple_link_test_code='int main(){return(0);}\n' - -_LT_AC_SYS_COMPILER - -# save warnings/boilerplate of simple test code -_LT_COMPILER_BOILERPLATE -_LT_LINKER_BOILERPLATE - -# -# Check for any special shared library compilation flags. -# -_LT_AC_TAGVAR(lt_prog_cc_shlib, $1)= -if test "$GCC" = no; then - case $host_os in - sco3.2v5*) - _LT_AC_TAGVAR(lt_prog_cc_shlib, $1)='-belf' - ;; - esac -fi -if test -n "$_LT_AC_TAGVAR(lt_prog_cc_shlib, $1)"; then - AC_MSG_WARN([`$CC' requires `$_LT_AC_TAGVAR(lt_prog_cc_shlib, $1)' to build shared libraries]) - if echo "$old_CC $old_CFLAGS " | grep "[[ ]]$_LT_AC_TAGVAR(lt_prog_cc_shlib, $1)[[ ]]" >/dev/null; then : - else - AC_MSG_WARN([add `$_LT_AC_TAGVAR(lt_prog_cc_shlib, $1)' to the CC or CFLAGS env variable and reconfigure]) - _LT_AC_TAGVAR(lt_cv_prog_cc_can_build_shared, $1)=no - fi -fi - - -# -# Check to make sure the static flag actually works. -# -AC_LIBTOOL_LINKER_OPTION([if $compiler static flag $_LT_AC_TAGVAR(lt_prog_compiler_static, $1) works], - _LT_AC_TAGVAR(lt_prog_compiler_static_works, $1), - $_LT_AC_TAGVAR(lt_prog_compiler_static, $1), - [], - [_LT_AC_TAGVAR(lt_prog_compiler_static, $1)=]) - - -## CAVEAT EMPTOR: -## There is no encapsulation within the following macros, do not change -## the running order or otherwise move them around unless you know exactly -## what you are doing... -AC_LIBTOOL_PROG_COMPILER_NO_RTTI($1) -AC_LIBTOOL_PROG_COMPILER_PIC($1) -AC_LIBTOOL_PROG_CC_C_O($1) -AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1) -AC_LIBTOOL_PROG_LD_SHLIBS($1) -AC_LIBTOOL_SYS_DYNAMIC_LINKER($1) -AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1) -AC_LIBTOOL_SYS_LIB_STRIP -AC_LIBTOOL_DLOPEN_SELF($1) - -# Report which librarie types wil actually be built -AC_MSG_CHECKING([if libtool supports shared libraries]) -AC_MSG_RESULT([$can_build_shared]) - -AC_MSG_CHECKING([whether to build shared libraries]) -test "$can_build_shared" = "no" && enable_shared=no - -# On AIX, shared libraries and static libraries use the same namespace, and -# are all built from PIC. -case "$host_os" in -aix3*) - test "$enable_shared" = yes && enable_static=no - if test -n "$RANLIB"; then - archive_cmds="$archive_cmds~\$RANLIB \$lib" - postinstall_cmds='$RANLIB $lib' - fi - ;; - -aix4* | aix5*) - if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then - test "$enable_shared" = yes && enable_static=no - fi - ;; -esac -AC_MSG_RESULT([$enable_shared]) - -AC_MSG_CHECKING([whether to build static libraries]) -# Make sure either enable_shared or enable_static is yes. -test "$enable_shared" = yes || enable_static=yes -AC_MSG_RESULT([$enable_static]) - -AC_LIBTOOL_CONFIG($1) - -AC_LANG_POP -CC="$lt_save_CC" -])# AC_LIBTOOL_LANG_C_CONFIG - - -# AC_LIBTOOL_LANG_CXX_CONFIG -# -------------------------- -# Ensure that the configuration vars for the C compiler are -# suitably defined. Those variables are subsequently used by -# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'. -AC_DEFUN([AC_LIBTOOL_LANG_CXX_CONFIG], [_LT_AC_LANG_CXX_CONFIG(CXX)]) -AC_DEFUN([_LT_AC_LANG_CXX_CONFIG], -[AC_LANG_PUSH(C++) -AC_REQUIRE([AC_PROG_CXX]) -AC_REQUIRE([_LT_AC_PROG_CXXCPP]) - -_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no -_LT_AC_TAGVAR(allow_undefined_flag, $1)= -_LT_AC_TAGVAR(always_export_symbols, $1)=no -_LT_AC_TAGVAR(archive_expsym_cmds, $1)= -_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)= -_LT_AC_TAGVAR(hardcode_direct, $1)=no -_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)= -_LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)= -_LT_AC_TAGVAR(hardcode_libdir_separator, $1)= -_LT_AC_TAGVAR(hardcode_minus_L, $1)=no -_LT_AC_TAGVAR(hardcode_automatic, $1)=no -_LT_AC_TAGVAR(module_cmds, $1)= -_LT_AC_TAGVAR(module_expsym_cmds, $1)= -_LT_AC_TAGVAR(link_all_deplibs, $1)=unknown -_LT_AC_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds -_LT_AC_TAGVAR(no_undefined_flag, $1)= -_LT_AC_TAGVAR(whole_archive_flag_spec, $1)= -_LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=no - -# Dependencies to place before and after the object being linked: -_LT_AC_TAGVAR(predep_objects, $1)= -_LT_AC_TAGVAR(postdep_objects, $1)= -_LT_AC_TAGVAR(predeps, $1)= -_LT_AC_TAGVAR(postdeps, $1)= -_LT_AC_TAGVAR(compiler_lib_search_path, $1)= - -# Source file extension for C++ test sources. -ac_ext=cc - -# Object file extension for compiled C++ test sources. -objext=o -_LT_AC_TAGVAR(objext, $1)=$objext - -# Code to be used in simple compile tests -lt_simple_compile_test_code="int some_variable = 0;\n" - -# Code to be used in simple link tests -lt_simple_link_test_code='int main(int, char *[]) { return(0); }\n' - -# ltmain only uses $CC for tagged configurations so make sure $CC is set. -_LT_AC_SYS_COMPILER - -# save warnings/boilerplate of simple test code -_LT_COMPILER_BOILERPLATE -_LT_LINKER_BOILERPLATE - -# Allow CC to be a program name with arguments. -lt_save_CC=$CC -lt_save_LD=$LD -lt_save_GCC=$GCC -GCC=$GXX -lt_save_with_gnu_ld=$with_gnu_ld -lt_save_path_LD=$lt_cv_path_LD -if test -n "${lt_cv_prog_gnu_ldcxx+set}"; then - lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx -else - unset lt_cv_prog_gnu_ld -fi -if test -n "${lt_cv_path_LDCXX+set}"; then - lt_cv_path_LD=$lt_cv_path_LDCXX -else - unset lt_cv_path_LD -fi -test -z "${LDCXX+set}" || LD=$LDCXX -CC=${CXX-"c++"} -compiler=$CC -_LT_AC_TAGVAR(compiler, $1)=$CC -_LT_CC_BASENAME([$compiler]) - -# We don't want -fno-exception wen compiling C++ code, so set the -# no_builtin_flag separately -if test "$GXX" = yes; then - _LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin' -else - _LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)= -fi - -if test "$GXX" = yes; then - # Set up default GNU C++ configuration - - AC_PROG_LD - - # Check if GNU C++ uses GNU ld as the underlying linker, since the - # archiving commands below assume that GNU ld is being used. - if test "$with_gnu_ld" = yes; then - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' - - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir' - _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' - - # If archive_cmds runs LD, not CC, wlarc should be empty - # XXX I think wlarc can be eliminated in ltcf-cxx, but I need to - # investigate it a little bit more. (MM) - wlarc='${wl}' - - # ancient GNU ld didn't support --whole-archive et. al. - if eval "`$CC -print-prog-name=ld` --help 2>&1" | \ - grep 'no-whole-archive' > /dev/null; then - _LT_AC_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' - else - _LT_AC_TAGVAR(whole_archive_flag_spec, $1)= - fi - else - with_gnu_ld=no - wlarc= - - # A generic and very simple default shared library creation - # command for GNU C++ for the case where it uses the native - # linker, instead of GNU ld. If possible, this setting should - # overridden to take advantage of the native linker features on - # the platform it is being used on. - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' - fi - - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "\-L"' - -else - GXX=no - with_gnu_ld=no - wlarc= -fi - -# PORTME: fill in a description of your system's C++ link characteristics -AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries]) -_LT_AC_TAGVAR(ld_shlibs, $1)=yes -case $host_os in - aix3*) - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - aix4* | aix5*) - if test "$host_cpu" = ia64; then - # On IA64, the linker does run time linking by default, so we don't - # have to do anything special. - aix_use_runtimelinking=no - exp_sym_flag='-Bexport' - no_entry_flag="" - else - aix_use_runtimelinking=no - - # Test if we are trying to use run time linking or normal - # AIX style linking. If -brtl is somewhere in LDFLAGS, we - # need to do runtime linking. - case $host_os in aix4.[[23]]|aix4.[[23]].*|aix5*) - for ld_flag in $LDFLAGS; do - case $ld_flag in - *-brtl*) - aix_use_runtimelinking=yes - break - ;; - esac - done - esac - - exp_sym_flag='-bexport' - no_entry_flag='-bnoentry' - fi - - # When large executables or shared objects are built, AIX ld can - # have problems creating the table of contents. If linking a library - # or program results in "error TOC overflow" add -mminimal-toc to - # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not - # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. - - _LT_AC_TAGVAR(archive_cmds, $1)='' - _LT_AC_TAGVAR(hardcode_direct, $1)=yes - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=':' - _LT_AC_TAGVAR(link_all_deplibs, $1)=yes - - if test "$GXX" = yes; then - case $host_os in aix4.[[012]]|aix4.[[012]].*) - # We only want to do this on AIX 4.2 and lower, the check - # below for broken collect2 doesn't work under 4.3+ - collect2name=`${CC} -print-prog-name=collect2` - if test -f "$collect2name" && \ - strings "$collect2name" | grep resolve_lib_name >/dev/null - then - # We have reworked collect2 - _LT_AC_TAGVAR(hardcode_direct, $1)=yes - else - # We have old collect2 - _LT_AC_TAGVAR(hardcode_direct, $1)=unsupported - # It fails to find uninstalled libraries when the uninstalled - # path is not listed in the libpath. Setting hardcode_minus_L - # to unsupported forces relinking - _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)= - fi - esac - shared_flag='-shared' - if test "$aix_use_runtimelinking" = yes; then - shared_flag="$shared_flag "'${wl}-G' - fi - else - # not using gcc - if test "$host_cpu" = ia64; then - # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release - # chokes on -Wl,-G. The following line is correct: - shared_flag='-G' - else - if test "$aix_use_runtimelinking" = yes; then - shared_flag='${wl}-G' - else - shared_flag='${wl}-bM:SRE' - fi - fi - fi - - # It seems that -bexpall does not export symbols beginning with - # underscore (_), so it is better to generate a list of symbols to export. - _LT_AC_TAGVAR(always_export_symbols, $1)=yes - if test "$aix_use_runtimelinking" = yes; then - # Warning - without using the other runtime loading flags (-brtl), - # -berok will link without error, but may produce a broken library. - _LT_AC_TAGVAR(allow_undefined_flag, $1)='-berok' - # Determine the default libpath from the value encoded in an empty executable. - _LT_AC_SYS_LIBPATH_AIX - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" - - _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols $shared_flag" - else - if test "$host_cpu" = ia64; then - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib' - _LT_AC_TAGVAR(allow_undefined_flag, $1)="-z nodefs" - _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols" - else - # Determine the default libpath from the value encoded in an empty executable. - _LT_AC_SYS_LIBPATH_AIX - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" - # Warning - without using the other run time loading flags, - # -berok will link without error, but may produce a broken library. - _LT_AC_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok' - _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok' - # -bexpall does not export symbols beginning with underscore (_) - _LT_AC_TAGVAR(always_export_symbols, $1)=yes - # Exported symbols can be pulled into shared objects from archives - _LT_AC_TAGVAR(whole_archive_flag_spec, $1)=' ' - _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes - # This is similar to how AIX traditionally builds it's shared libraries. - _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}-bE:$export_symbols ${wl}-bnoentry${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname' - fi - fi - ;; - chorus*) - case $cc_basename in - *) - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - esac - ;; - - - cygwin* | mingw* | pw32*) - # _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless, - # as there is no search path for DLLs. - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported - _LT_AC_TAGVAR(always_export_symbols, $1)=no - _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=yes - - if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000 ${wl}--out-implib,$lib' - # If the export-symbols file already is a .def file (1st line - # is EXPORTS), use it as is; otherwise, prepend... - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then - cp $export_symbols $output_objdir/$soname.def; - else - echo EXPORTS > $output_objdir/$soname.def; - cat $export_symbols >> $output_objdir/$soname.def; - fi~ - $CC -shared -nostdlib $output_objdir/$soname.def $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000 ${wl}--out-implib,$lib' - else - _LT_AC_TAGVAR(ld_shlibs, $1)=no - fi - ;; - darwin* | rhapsody*) - case "$host_os" in - rhapsody* | darwin1.[[012]]) - _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-undefined ${wl}suppress' - ;; - *) # Darwin 1.3 on - if test -z ${MACOSX_DEPLOYMENT_TARGET} ; then - _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' - else - case ${MACOSX_DEPLOYMENT_TARGET} in - 10.[[012]]) - _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' - ;; - 10.*) - _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-undefined ${wl}dynamic_lookup' - ;; - esac - fi - ;; - esac - _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no - _LT_AC_TAGVAR(hardcode_direct, $1)=no - _LT_AC_TAGVAR(hardcode_automatic, $1)=yes - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported - _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='' - _LT_AC_TAGVAR(link_all_deplibs, $1)=yes - - if test "$GXX" = yes ; then - lt_int_apple_cc_single_mod=no - output_verbose_link_cmd='echo' - if $CC -dumpspecs 2>&1 | $EGREP 'single_module' >/dev/null ; then - lt_int_apple_cc_single_mod=yes - fi - if test "X$lt_int_apple_cc_single_mod" = Xyes ; then - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -dynamiclib -single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring' - else - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -r -keep_private_externs -nostdlib -o ${lib}-master.o $libobjs~$CC -dynamiclib $allow_undefined_flag -o $lib ${lib}-master.o $deplibs $compiler_flags -install_name $rpath/$soname $verstring' - fi - _LT_AC_TAGVAR(module_cmds, $1)='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags' - # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin ld's - if test "X$lt_int_apple_cc_single_mod" = Xyes ; then - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -dynamiclib -single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' - else - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -r -keep_private_externs -nostdlib -o ${lib}-master.o $libobjs~$CC -dynamiclib $allow_undefined_flag -o $lib ${lib}-master.o $deplibs $compiler_flags -install_name $rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' - fi - _LT_AC_TAGVAR(module_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' - else - case $cc_basename in - xlc*) - output_verbose_link_cmd='echo' - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj ${wl}-single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`echo $rpath/$soname` $verstring' - _LT_AC_TAGVAR(module_cmds, $1)='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags' - # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin ld's - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -qmkshrobj ${wl}-single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}$rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' - _LT_AC_TAGVAR(module_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' - ;; - *) - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - esac - fi - ;; - - dgux*) - case $cc_basename in - ec++*) - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - ghcx*) - # Green Hills C++ Compiler - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - *) - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - esac - ;; - freebsd[[12]]*) - # C++ shared libraries reported to be fairly broken before switch to ELF - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - freebsd-elf*) - _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no - ;; - freebsd* | kfreebsd*-gnu | dragonfly*) - # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF - # conventions - _LT_AC_TAGVAR(ld_shlibs, $1)=yes - ;; - gnu*) - ;; - hpux9*) - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: - _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' - _LT_AC_TAGVAR(hardcode_direct, $1)=yes - _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH, - # but as the default - # location of the library. - - case $cc_basename in - CC*) - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - aCC*) - _LT_AC_TAGVAR(archive_cmds, $1)='$rm $output_objdir/$soname~$CC -b ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - # - # There doesn't appear to be a way to prevent this compiler from - # explicitly linking system object files so we need to strip them - # from the output so that they don't get included in the library - # dependencies. - output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | grep "[[-]]L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list' - ;; - *) - if test "$GXX" = yes; then - _LT_AC_TAGVAR(archive_cmds, $1)='$rm $output_objdir/$soname~$CC -shared -nostdlib -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' - else - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - fi - ;; - esac - ;; - hpux10*|hpux11*) - if test $with_gnu_ld = no; then - case "$host_cpu" in - hppa*64*) - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' - _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='+b $libdir' - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: - ;; - ia64*) - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - ;; - *) - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: - _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' - ;; - esac - fi - case "$host_cpu" in - hppa*64*) - _LT_AC_TAGVAR(hardcode_direct, $1)=no - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - ia64*) - _LT_AC_TAGVAR(hardcode_direct, $1)=no - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH, - # but as the default - # location of the library. - ;; - *) - _LT_AC_TAGVAR(hardcode_direct, $1)=yes - _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH, - # but as the default - # location of the library. - ;; - esac - - case $cc_basename in - CC*) - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - aCC*) - case "$host_cpu" in - hppa*64*|ia64*) - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -b +h $soname -o $lib $linker_flags $libobjs $deplibs' - ;; - *) - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' - ;; - esac - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - # - # There doesn't appear to be a way to prevent this compiler from - # explicitly linking system object files so we need to strip them - # from the output so that they don't get included in the library - # dependencies. - output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | grep "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list' - ;; - *) - if test "$GXX" = yes; then - if test $with_gnu_ld = no; then - case "$host_cpu" in - ia64*|hppa*64*) - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -b +h $soname -o $lib $linker_flags $libobjs $deplibs' - ;; - *) - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' - ;; - esac - fi - else - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - fi - ;; - esac - ;; - irix5* | irix6*) - case $cc_basename in - CC*) - # SGI C++ - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' - - # Archives containing C++ object files must be created using - # "CC -ar", where "CC" is the IRIX C++ compiler. This is - # necessary to make sure instantiated templates are included - # in the archive. - _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -ar -WR,-u -o $oldlib $oldobjs' - ;; - *) - if test "$GXX" = yes; then - if test "$with_gnu_ld" = no; then - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' - else - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` -o $lib' - fi - fi - _LT_AC_TAGVAR(link_all_deplibs, $1)=yes - ;; - esac - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: - ;; - linux*) - case $cc_basename in - KCC*) - # Kuck and Associates, Inc. (KAI) C++ Compiler - - # KCC will only create a shared library if the output file - # ends with ".so" (or ".sl" for HP-UX), so rename the library - # to its proper name (with version) after linking. - _LT_AC_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib ${wl}-retain-symbols-file,$export_symbols; mv \$templib $lib' - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - # - # There doesn't appear to be a way to prevent this compiler from - # explicitly linking system object files so we need to strip them - # from the output so that they don't get included in the library - # dependencies. - output_verbose_link_cmd='templist=`$CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 | grep "ld"`; rm -f libconftest$shared_ext; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list' - - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath,$libdir' - _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' - - # Archives containing C++ object files must be created using - # "CC -Bstatic", where "CC" is the KAI C++ compiler. - _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs' - ;; - icpc*) - # Intel C++ - with_gnu_ld=yes - # version 8.0 and above of icpc choke on multiply defined symbols - # if we add $predep_objects and $postdep_objects, however 7.1 and - # earlier do not add the objects themselves. - case `$CC -V 2>&1` in - *"Version 7."*) - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' - ;; - *) # Version 8.0 or newer - tmp_idyn= - case $host_cpu in - ia64*) tmp_idyn=' -i_dynamic';; - esac - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' - ;; - esac - _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' - _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' - _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive' - ;; - pgCC*) - # Portland Group C++ compiler - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib' - - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir' - _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' - _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive,`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' - ;; - cxx*) - # Compaq C++ - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib ${wl}-retain-symbols-file $wl$export_symbols' - - runpath_var=LD_RUN_PATH - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: - - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - # - # There doesn't appear to be a way to prevent this compiler from - # explicitly linking system object files so we need to strip them - # from the output so that they don't get included in the library - # dependencies. - output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "ld"`; templist=`echo $templist | $SED "s/\(^.*ld.*\)\( .*ld .*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list' - ;; - esac - ;; - lynxos*) - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - m88k*) - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - mvs*) - case $cc_basename in - cxx*) - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - *) - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - esac - ;; - netbsd*) - if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags' - wlarc= - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' - _LT_AC_TAGVAR(hardcode_direct, $1)=yes - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - fi - # Workaround some broken pre-1.5 toolchains - output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"' - ;; - openbsd2*) - # C++ shared libraries are fairly broken - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - openbsd*) - _LT_AC_TAGVAR(hardcode_direct, $1)=yes - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' - if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file,$export_symbols -o $lib' - _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' - _LT_AC_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' - fi - output_verbose_link_cmd='echo' - ;; - osf3*) - case $cc_basename in - KCC*) - # Kuck and Associates, Inc. (KAI) C++ Compiler - - # KCC will only create a shared library if the output file - # ends with ".so" (or ".sl" for HP-UX), so rename the library - # to its proper name (with version) after linking. - _LT_AC_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' - - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: - - # Archives containing C++ object files must be created using - # "CC -Bstatic", where "CC" is the KAI C++ compiler. - _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs' - - ;; - RCC*) - # Rational C++ 2.4.1 - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - cxx*) - _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $soname `test -n "$verstring" && echo ${wl}-set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' - - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: - - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - # - # There doesn't appear to be a way to prevent this compiler from - # explicitly linking system object files so we need to strip them - # from the output so that they don't get included in the library - # dependencies. - output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "ld" | grep -v "ld:"`; templist=`echo $templist | $SED "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list' - ;; - *) - if test "$GXX" = yes && test "$with_gnu_ld" = no; then - _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' - - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: - - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "\-L"' - - else - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - fi - ;; - esac - ;; - osf4* | osf5*) - case $cc_basename in - KCC*) - # Kuck and Associates, Inc. (KAI) C++ Compiler - - # KCC will only create a shared library if the output file - # ends with ".so" (or ".sl" for HP-UX), so rename the library - # to its proper name (with version) after linking. - _LT_AC_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' - - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: - - # Archives containing C++ object files must be created using - # the KAI C++ compiler. - _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -o $oldlib $oldobjs' - ;; - RCC*) - # Rational C++ 2.4.1 - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - cxx*) - _LT_AC_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~ - echo "-hidden">> $lib.exp~ - $CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname -Wl,-input -Wl,$lib.exp `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib~ - $rm $lib.exp' - - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: - - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - # - # There doesn't appear to be a way to prevent this compiler from - # explicitly linking system object files so we need to strip them - # from the output so that they don't get included in the library - # dependencies. - output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "ld" | grep -v "ld:"`; templist=`echo $templist | $SED "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list' - ;; - *) - if test "$GXX" = yes && test "$with_gnu_ld" = no; then - _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' - - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: - - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "\-L"' - - else - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - fi - ;; - esac - ;; - psos*) - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - sco*) - _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no - case $cc_basename in - CC*) - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - *) - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - esac - ;; - sunos4*) - case $cc_basename in - CC*) - # Sun C++ 4.x - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - lcc*) - # Lucid - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - *) - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - esac - ;; - solaris*) - case $cc_basename in - CC*) - # Sun C++ 4.2, 5.x and Centerline C++ - _LT_AC_TAGVAR(no_undefined_flag, $1)=' -zdefs' - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -nolib -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ - $CC -G${allow_undefined_flag} -nolib ${wl}-M ${wl}$lib.exp -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp' - - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - case $host_os in - solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; - *) - # The C++ compiler is used as linker so we must use $wl - # flag to pass the commands to the underlying system - # linker. We must also pass each convience library through - # to the system linker between allextract/defaultextract. - # The C++ compiler will combine linker options so we - # cannot just pass the convience library names through - # without $wl. - # Supported since Solaris 2.6 (maybe 2.5.1?) - _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}-z ${wl}defaultextract' - ;; - esac - _LT_AC_TAGVAR(link_all_deplibs, $1)=yes - - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - # - # There doesn't appear to be a way to prevent this compiler from - # explicitly linking system object files so we need to strip them - # from the output so that they don't get included in the library - # dependencies. - output_verbose_link_cmd='templist=`$CC -G $CFLAGS -v conftest.$objext 2>&1 | grep "\-[[LR]]"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list' - - # Archives containing C++ object files must be created using - # "CC -xar", where "CC" is the Sun C++ compiler. This is - # necessary to make sure instantiated templates are included - # in the archive. - _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs' - ;; - gcx*) - # Green Hills C++ Compiler - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' - - # The C++ compiler must be used to create the archive. - _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC $LDFLAGS -archive -o $oldlib $oldobjs' - ;; - *) - # GNU C++ compiler with Solaris linker - if test "$GXX" = yes && test "$with_gnu_ld" = no; then - _LT_AC_TAGVAR(no_undefined_flag, $1)=' ${wl}-z ${wl}defs' - if $CC --version | grep -v '^2\.7' > /dev/null; then - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ - $CC -shared -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp' - - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - output_verbose_link_cmd="$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep \"\-L\"" - else - # g++ 2.7 appears to require `-G' NOT `-shared' on this - # platform. - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ - $CC -G -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp' - - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - output_verbose_link_cmd="$CC -G $CFLAGS -v conftest.$objext 2>&1 | grep \"\-L\"" - fi - - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $wl$libdir' - fi - ;; - esac - ;; - sysv5OpenUNIX8* | sysv5UnixWare7* | sysv5uw[[78]]* | unixware7*) - _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no - ;; - tandem*) - case $cc_basename in - NCC*) - # NonStop-UX NCC 3.20 - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - *) - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - esac - ;; - vxworks*) - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - *) - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; -esac -AC_MSG_RESULT([$_LT_AC_TAGVAR(ld_shlibs, $1)]) -test "$_LT_AC_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no - -_LT_AC_TAGVAR(GCC, $1)="$GXX" -_LT_AC_TAGVAR(LD, $1)="$LD" - -## CAVEAT EMPTOR: -## There is no encapsulation within the following macros, do not change -## the running order or otherwise move them around unless you know exactly -## what you are doing... -AC_LIBTOOL_POSTDEP_PREDEP($1) -AC_LIBTOOL_PROG_COMPILER_PIC($1) -AC_LIBTOOL_PROG_CC_C_O($1) -AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1) -AC_LIBTOOL_PROG_LD_SHLIBS($1) -AC_LIBTOOL_SYS_DYNAMIC_LINKER($1) -AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1) -AC_LIBTOOL_SYS_LIB_STRIP -AC_LIBTOOL_DLOPEN_SELF($1) - -AC_LIBTOOL_CONFIG($1) - -AC_LANG_POP -CC=$lt_save_CC -LDCXX=$LD -LD=$lt_save_LD -GCC=$lt_save_GCC -with_gnu_ldcxx=$with_gnu_ld -with_gnu_ld=$lt_save_with_gnu_ld -lt_cv_path_LDCXX=$lt_cv_path_LD -lt_cv_path_LD=$lt_save_path_LD -lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld -lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld -])# AC_LIBTOOL_LANG_CXX_CONFIG - -# AC_LIBTOOL_POSTDEP_PREDEP([TAGNAME]) -# ------------------------ -# Figure out "hidden" library dependencies from verbose -# compiler output when linking a shared library. -# Parse the compiler output and extract the necessary -# objects, libraries and library flags. -AC_DEFUN([AC_LIBTOOL_POSTDEP_PREDEP],[ -dnl we can't use the lt_simple_compile_test_code here, -dnl because it contains code intended for an executable, -dnl not a library. It's possible we should let each -dnl tag define a new lt_????_link_test_code variable, -dnl but it's only used here... -ifelse([$1],[],[cat > conftest.$ac_ext <<EOF -int a; -void foo (void) { a = 0; } -EOF -],[$1],[CXX],[cat > conftest.$ac_ext <<EOF -class Foo -{ -public: - Foo (void) { a = 0; } -private: - int a; -}; -EOF -],[$1],[F77],[cat > conftest.$ac_ext <<EOF - subroutine foo - implicit none - integer*4 a - a=0 - return - end -EOF -],[$1],[GCJ],[cat > conftest.$ac_ext <<EOF -public class foo { - private int a; - public void bar (void) { - a = 0; - } -}; -EOF -]) -dnl Parse the compiler output and extract the necessary -dnl objects, libraries and library flags. -if AC_TRY_EVAL(ac_compile); then - # Parse the compiler output and extract the necessary - # objects, libraries and library flags. - - # Sentinel used to keep track of whether or not we are before - # the conftest object file. - pre_test_object_deps_done=no - - # The `*' in the case matches for architectures that use `case' in - # $output_verbose_cmd can trigger glob expansion during the loop - # eval without this substitution. - output_verbose_link_cmd="`$echo \"X$output_verbose_link_cmd\" | $Xsed -e \"$no_glob_subst\"`" - - for p in `eval $output_verbose_link_cmd`; do - case $p in - - -L* | -R* | -l*) - # Some compilers place space between "-{L,R}" and the path. - # Remove the space. - if test $p = "-L" \ - || test $p = "-R"; then - prev=$p - continue - else - prev= - fi - - if test "$pre_test_object_deps_done" = no; then - case $p in - -L* | -R*) - # Internal compiler library paths should come after those - # provided the user. The postdeps already come after the - # user supplied libs so there is no need to process them. - if test -z "$_LT_AC_TAGVAR(compiler_lib_search_path, $1)"; then - _LT_AC_TAGVAR(compiler_lib_search_path, $1)="${prev}${p}" - else - _LT_AC_TAGVAR(compiler_lib_search_path, $1)="${_LT_AC_TAGVAR(compiler_lib_search_path, $1)} ${prev}${p}" - fi - ;; - # The "-l" case would never come before the object being - # linked, so don't bother handling this case. - esac - else - if test -z "$_LT_AC_TAGVAR(postdeps, $1)"; then - _LT_AC_TAGVAR(postdeps, $1)="${prev}${p}" - else - _LT_AC_TAGVAR(postdeps, $1)="${_LT_AC_TAGVAR(postdeps, $1)} ${prev}${p}" - fi - fi - ;; - - *.$objext) - # This assumes that the test object file only shows up - # once in the compiler output. - if test "$p" = "conftest.$objext"; then - pre_test_object_deps_done=yes - continue - fi - - if test "$pre_test_object_deps_done" = no; then - if test -z "$_LT_AC_TAGVAR(predep_objects, $1)"; then - _LT_AC_TAGVAR(predep_objects, $1)="$p" - else - _LT_AC_TAGVAR(predep_objects, $1)="$_LT_AC_TAGVAR(predep_objects, $1) $p" - fi - else - if test -z "$_LT_AC_TAGVAR(postdep_objects, $1)"; then - _LT_AC_TAGVAR(postdep_objects, $1)="$p" - else - _LT_AC_TAGVAR(postdep_objects, $1)="$_LT_AC_TAGVAR(postdep_objects, $1) $p" - fi - fi - ;; - - *) ;; # Ignore the rest. - - esac - done - - # Clean up. - rm -f a.out a.exe -else - echo "libtool.m4: error: problem compiling $1 test program" -fi - -$rm -f confest.$objext - -case " $_LT_AC_TAGVAR(postdeps, $1) " in -*" -lc "*) _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no ;; -esac -])# AC_LIBTOOL_POSTDEP_PREDEP - -# AC_LIBTOOL_LANG_F77_CONFIG -# ------------------------ -# Ensure that the configuration vars for the C compiler are -# suitably defined. Those variables are subsequently used by -# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'. -AC_DEFUN([AC_LIBTOOL_LANG_F77_CONFIG], [_LT_AC_LANG_F77_CONFIG(F77)]) -AC_DEFUN([_LT_AC_LANG_F77_CONFIG], -[AC_REQUIRE([AC_PROG_F77]) -AC_LANG_PUSH(Fortran 77) - -_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no -_LT_AC_TAGVAR(allow_undefined_flag, $1)= -_LT_AC_TAGVAR(always_export_symbols, $1)=no -_LT_AC_TAGVAR(archive_expsym_cmds, $1)= -_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)= -_LT_AC_TAGVAR(hardcode_direct, $1)=no -_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)= -_LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)= -_LT_AC_TAGVAR(hardcode_libdir_separator, $1)= -_LT_AC_TAGVAR(hardcode_minus_L, $1)=no -_LT_AC_TAGVAR(hardcode_automatic, $1)=no -_LT_AC_TAGVAR(module_cmds, $1)= -_LT_AC_TAGVAR(module_expsym_cmds, $1)= -_LT_AC_TAGVAR(link_all_deplibs, $1)=unknown -_LT_AC_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds -_LT_AC_TAGVAR(no_undefined_flag, $1)= -_LT_AC_TAGVAR(whole_archive_flag_spec, $1)= -_LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=no - -# Source file extension for f77 test sources. -ac_ext=f - -# Object file extension for compiled f77 test sources. -objext=o -_LT_AC_TAGVAR(objext, $1)=$objext - -# Code to be used in simple compile tests -lt_simple_compile_test_code=" subroutine t\n return\n end\n" - -# Code to be used in simple link tests -lt_simple_link_test_code=" program t\n end\n" - -# ltmain only uses $CC for tagged configurations so make sure $CC is set. -_LT_AC_SYS_COMPILER - -# save warnings/boilerplate of simple test code -_LT_COMPILER_BOILERPLATE -_LT_LINKER_BOILERPLATE - -# Allow CC to be a program name with arguments. -lt_save_CC="$CC" -CC=${F77-"f77"} -compiler=$CC -_LT_AC_TAGVAR(compiler, $1)=$CC -_LT_CC_BASENAME([$compiler]) - -AC_MSG_CHECKING([if libtool supports shared libraries]) -AC_MSG_RESULT([$can_build_shared]) - -AC_MSG_CHECKING([whether to build shared libraries]) -test "$can_build_shared" = "no" && enable_shared=no - -# On AIX, shared libraries and static libraries use the same namespace, and -# are all built from PIC. -case "$host_os" in -aix3*) - test "$enable_shared" = yes && enable_static=no - if test -n "$RANLIB"; then - archive_cmds="$archive_cmds~\$RANLIB \$lib" - postinstall_cmds='$RANLIB $lib' - fi - ;; -aix4* | aix5*) - if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then - test "$enable_shared" = yes && enable_static=no - fi - ;; -esac -AC_MSG_RESULT([$enable_shared]) - -AC_MSG_CHECKING([whether to build static libraries]) -# Make sure either enable_shared or enable_static is yes. -test "$enable_shared" = yes || enable_static=yes -AC_MSG_RESULT([$enable_static]) - -test "$_LT_AC_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no - -_LT_AC_TAGVAR(GCC, $1)="$G77" -_LT_AC_TAGVAR(LD, $1)="$LD" - -AC_LIBTOOL_PROG_COMPILER_PIC($1) -AC_LIBTOOL_PROG_CC_C_O($1) -AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1) -AC_LIBTOOL_PROG_LD_SHLIBS($1) -AC_LIBTOOL_SYS_DYNAMIC_LINKER($1) -AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1) -AC_LIBTOOL_SYS_LIB_STRIP - - -AC_LIBTOOL_CONFIG($1) - -AC_LANG_POP -CC="$lt_save_CC" -])# AC_LIBTOOL_LANG_F77_CONFIG - - -# AC_LIBTOOL_LANG_GCJ_CONFIG -# -------------------------- -# Ensure that the configuration vars for the C compiler are -# suitably defined. Those variables are subsequently used by -# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'. -AC_DEFUN([AC_LIBTOOL_LANG_GCJ_CONFIG], [_LT_AC_LANG_GCJ_CONFIG(GCJ)]) -AC_DEFUN([_LT_AC_LANG_GCJ_CONFIG], -[AC_LANG_SAVE - -# Source file extension for Java test sources. -ac_ext=java - -# Object file extension for compiled Java test sources. -objext=o -_LT_AC_TAGVAR(objext, $1)=$objext - -# Code to be used in simple compile tests -lt_simple_compile_test_code="class foo {}\n" - -# Code to be used in simple link tests -lt_simple_link_test_code='public class conftest { public static void main(String[[]] argv) {}; }\n' - -# ltmain only uses $CC for tagged configurations so make sure $CC is set. -_LT_AC_SYS_COMPILER - -# save warnings/boilerplate of simple test code -_LT_COMPILER_BOILERPLATE -_LT_LINKER_BOILERPLATE - -# Allow CC to be a program name with arguments. -lt_save_CC="$CC" -CC=${GCJ-"gcj"} -compiler=$CC -_LT_AC_TAGVAR(compiler, $1)=$CC -_LT_CC_BASENAME([$compiler]) - -# GCJ did not exist at the time GCC didn't implicitly link libc in. -_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no - -_LT_AC_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds - -## CAVEAT EMPTOR: -## There is no encapsulation within the following macros, do not change -## the running order or otherwise move them around unless you know exactly -## what you are doing... -AC_LIBTOOL_PROG_COMPILER_NO_RTTI($1) -AC_LIBTOOL_PROG_COMPILER_PIC($1) -AC_LIBTOOL_PROG_CC_C_O($1) -AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1) -AC_LIBTOOL_PROG_LD_SHLIBS($1) -AC_LIBTOOL_SYS_DYNAMIC_LINKER($1) -AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1) -AC_LIBTOOL_SYS_LIB_STRIP -AC_LIBTOOL_DLOPEN_SELF($1) - -AC_LIBTOOL_CONFIG($1) - -AC_LANG_RESTORE -CC="$lt_save_CC" -])# AC_LIBTOOL_LANG_GCJ_CONFIG - - -# AC_LIBTOOL_LANG_RC_CONFIG -# -------------------------- -# Ensure that the configuration vars for the Windows resource compiler are -# suitably defined. Those variables are subsequently used by -# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'. -AC_DEFUN([AC_LIBTOOL_LANG_RC_CONFIG], [_LT_AC_LANG_RC_CONFIG(RC)]) -AC_DEFUN([_LT_AC_LANG_RC_CONFIG], -[AC_LANG_SAVE - -# Source file extension for RC test sources. -ac_ext=rc - -# Object file extension for compiled RC test sources. -objext=o -_LT_AC_TAGVAR(objext, $1)=$objext - -# Code to be used in simple compile tests -lt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }\n' - -# Code to be used in simple link tests -lt_simple_link_test_code="$lt_simple_compile_test_code" - -# ltmain only uses $CC for tagged configurations so make sure $CC is set. -_LT_AC_SYS_COMPILER - -# save warnings/boilerplate of simple test code -_LT_COMPILER_BOILERPLATE -_LT_LINKER_BOILERPLATE - -# Allow CC to be a program name with arguments. -lt_save_CC="$CC" -CC=${RC-"windres"} -compiler=$CC -_LT_AC_TAGVAR(compiler, $1)=$CC -_LT_CC_BASENAME([$compiler]) -_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes - -AC_LIBTOOL_CONFIG($1) - -AC_LANG_RESTORE -CC="$lt_save_CC" -])# AC_LIBTOOL_LANG_RC_CONFIG - - -# AC_LIBTOOL_CONFIG([TAGNAME]) -# ---------------------------- -# If TAGNAME is not passed, then create an initial libtool script -# with a default configuration from the untagged config vars. Otherwise -# add code to config.status for appending the configuration named by -# TAGNAME from the matching tagged config vars. -AC_DEFUN([AC_LIBTOOL_CONFIG], -[# The else clause should only fire when bootstrapping the -# libtool distribution, otherwise you forgot to ship ltmain.sh -# with your package, and you will get complaints that there are -# no rules to generate ltmain.sh. -if test -f "$ltmain"; then - # See if we are running on zsh, and set the options which allow our commands through - # without removal of \ escapes. - if test -n "${ZSH_VERSION+set}" ; then - setopt NO_GLOB_SUBST - fi - # Now quote all the things that may contain metacharacters while being - # careful not to overquote the AC_SUBSTed values. We take copies of the - # variables and quote the copies for generation of the libtool script. - for var in echo old_CC old_CFLAGS AR AR_FLAGS EGREP RANLIB LN_S LTCC NM \ - SED SHELL STRIP \ - libname_spec library_names_spec soname_spec extract_expsyms_cmds \ - old_striplib striplib file_magic_cmd finish_cmds finish_eval \ - deplibs_check_method reload_flag reload_cmds need_locks \ - lt_cv_sys_global_symbol_pipe lt_cv_sys_global_symbol_to_cdecl \ - lt_cv_sys_global_symbol_to_c_name_address \ - sys_lib_search_path_spec sys_lib_dlsearch_path_spec \ - old_postinstall_cmds old_postuninstall_cmds \ - _LT_AC_TAGVAR(compiler, $1) \ - _LT_AC_TAGVAR(CC, $1) \ - _LT_AC_TAGVAR(LD, $1) \ - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1) \ - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1) \ - _LT_AC_TAGVAR(lt_prog_compiler_static, $1) \ - _LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) \ - _LT_AC_TAGVAR(export_dynamic_flag_spec, $1) \ - _LT_AC_TAGVAR(thread_safe_flag_spec, $1) \ - _LT_AC_TAGVAR(whole_archive_flag_spec, $1) \ - _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1) \ - _LT_AC_TAGVAR(old_archive_cmds, $1) \ - _LT_AC_TAGVAR(old_archive_from_new_cmds, $1) \ - _LT_AC_TAGVAR(predep_objects, $1) \ - _LT_AC_TAGVAR(postdep_objects, $1) \ - _LT_AC_TAGVAR(predeps, $1) \ - _LT_AC_TAGVAR(postdeps, $1) \ - _LT_AC_TAGVAR(compiler_lib_search_path, $1) \ - _LT_AC_TAGVAR(archive_cmds, $1) \ - _LT_AC_TAGVAR(archive_expsym_cmds, $1) \ - _LT_AC_TAGVAR(postinstall_cmds, $1) \ - _LT_AC_TAGVAR(postuninstall_cmds, $1) \ - _LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1) \ - _LT_AC_TAGVAR(allow_undefined_flag, $1) \ - _LT_AC_TAGVAR(no_undefined_flag, $1) \ - _LT_AC_TAGVAR(export_symbols_cmds, $1) \ - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) \ - _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1) \ - _LT_AC_TAGVAR(hardcode_libdir_separator, $1) \ - _LT_AC_TAGVAR(hardcode_automatic, $1) \ - _LT_AC_TAGVAR(module_cmds, $1) \ - _LT_AC_TAGVAR(module_expsym_cmds, $1) \ - _LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1) \ - _LT_AC_TAGVAR(exclude_expsyms, $1) \ - _LT_AC_TAGVAR(include_expsyms, $1); do - - case $var in - _LT_AC_TAGVAR(old_archive_cmds, $1) | \ - _LT_AC_TAGVAR(old_archive_from_new_cmds, $1) | \ - _LT_AC_TAGVAR(archive_cmds, $1) | \ - _LT_AC_TAGVAR(archive_expsym_cmds, $1) | \ - _LT_AC_TAGVAR(module_cmds, $1) | \ - _LT_AC_TAGVAR(module_expsym_cmds, $1) | \ - _LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1) | \ - _LT_AC_TAGVAR(export_symbols_cmds, $1) | \ - extract_expsyms_cmds | reload_cmds | finish_cmds | \ - postinstall_cmds | postuninstall_cmds | \ - old_postinstall_cmds | old_postuninstall_cmds | \ - sys_lib_search_path_spec | sys_lib_dlsearch_path_spec) - # Double-quote double-evaled strings. - eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$double_quote_subst\" -e \"\$sed_quote_subst\" -e \"\$delay_variable_subst\"\`\\\"" - ;; - *) - eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$sed_quote_subst\"\`\\\"" - ;; - esac - done - - case $lt_echo in - *'\[$]0 --fallback-echo"') - lt_echo=`$echo "X$lt_echo" | $Xsed -e 's/\\\\\\\[$]0 --fallback-echo"[$]/[$]0 --fallback-echo"/'` - ;; - esac - -ifelse([$1], [], - [cfgfile="${ofile}T" - trap "$rm \"$cfgfile\"; exit 1" 1 2 15 - $rm -f "$cfgfile" - AC_MSG_NOTICE([creating $ofile])], - [cfgfile="$ofile"]) - - cat <<__EOF__ >> "$cfgfile" -ifelse([$1], [], -[#! $SHELL - -# `$echo "$cfgfile" | sed 's%^.*/%%'` - Provide generalized library-building support services. -# Generated automatically by $PROGRAM (GNU $PACKAGE $VERSION$TIMESTAMP) -# NOTE: Changes made to this file will be lost: look at ltmain.sh. -# -# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001 -# Free Software Foundation, Inc. -# -# This file is part of GNU Libtool: -# Originally by Gordon Matzigkeit <gord@gnu.ai.mit.edu>, 1996 -# -# This program is free software; you can redistribute it and/or modify -# it under the terms of the GNU General Public License as published by -# the Free Software Foundation; either version 2 of the License, or -# (at your option) any later version. -# -# This program is distributed in the hope that it will be useful, but -# WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -# General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with this program; if not, write to the Free Software -# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. -# -# As a special exception to the GNU General Public License, if you -# distribute this file as part of a program that contains a -# configuration script generated by Autoconf, you may include it under -# the same distribution terms that you use for the rest of that program. - -# A sed program that does not truncate output. -SED=$lt_SED - -# Sed that helps us avoid accidentally triggering echo(1) options like -n. -Xsed="$SED -e 1s/^X//" - -# The HP-UX ksh and POSIX shell print the target directory to stdout -# if CDPATH is set. -(unset CDPATH) >/dev/null 2>&1 && unset CDPATH - -# The names of the tagged configurations supported by this script. -available_tags= - -# ### BEGIN LIBTOOL CONFIG], -[# ### BEGIN LIBTOOL TAG CONFIG: $tagname]) - -# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: - -# Shell to use when invoking shell scripts. -SHELL=$lt_SHELL - -# Whether or not to build shared libraries. -build_libtool_libs=$enable_shared - -# Whether or not to build static libraries. -build_old_libs=$enable_static - -# Whether or not to add -lc for building shared libraries. -build_libtool_need_lc=$_LT_AC_TAGVAR(archive_cmds_need_lc, $1) - -# Whether or not to disallow shared libs when runtime libs are static -allow_libtool_libs_with_static_runtimes=$_LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1) - -# Whether or not to optimize for fast installation. -fast_install=$enable_fast_install - -# The host system. -host_alias=$host_alias -host=$host -host_os=$host_os - -# The build system. -build_alias=$build_alias -build=$build -build_os=$build_os - -# An echo program that does not interpret backslashes. -echo=$lt_echo - -# The archiver. -AR=$lt_AR -AR_FLAGS=$lt_AR_FLAGS - -# A C compiler. -LTCC=$lt_LTCC - -# A language-specific compiler. -CC=$lt_[]_LT_AC_TAGVAR(compiler, $1) - -# Is the compiler the GNU C compiler? -with_gcc=$_LT_AC_TAGVAR(GCC, $1) - -# An ERE matcher. -EGREP=$lt_EGREP - -# The linker used to build libraries. -LD=$lt_[]_LT_AC_TAGVAR(LD, $1) - -# Whether we need hard or soft links. -LN_S=$lt_LN_S - -# A BSD-compatible nm program. -NM=$lt_NM - -# A symbol stripping program -STRIP=$lt_STRIP - -# Used to examine libraries when file_magic_cmd begins "file" -MAGIC_CMD=$MAGIC_CMD - -# Used on cygwin: DLL creation program. -DLLTOOL="$DLLTOOL" - -# Used on cygwin: object dumper. -OBJDUMP="$OBJDUMP" - -# Used on cygwin: assembler. -AS="$AS" - -# The name of the directory that contains temporary libtool files. -objdir=$objdir - -# How to create reloadable object files. -reload_flag=$lt_reload_flag -reload_cmds=$lt_reload_cmds - -# How to pass a linker flag through the compiler. -wl=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_wl, $1) - -# Object file suffix (normally "o"). -objext="$ac_objext" - -# Old archive suffix (normally "a"). -libext="$libext" - -# Shared library suffix (normally ".so"). -shrext_cmds='$shrext_cmds'; shrext="$shrext_cmds" - -# Executable file suffix (normally ""). -exeext="$exeext" - -# Additional compiler flags for building library objects. -pic_flag=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_pic, $1) -pic_mode=$pic_mode - -# What is the maximum length of a command? -max_cmd_len=$lt_cv_sys_max_cmd_len - -# Does compiler simultaneously support -c and -o options? -compiler_c_o=$lt_[]_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1) - -# Must we lock files when doing compilation? -need_locks=$lt_need_locks - -# Do we need the lib prefix for modules? -need_lib_prefix=$need_lib_prefix - -# Do we need a version for libraries? -need_version=$need_version - -# Whether dlopen is supported. -dlopen_support=$enable_dlopen - -# Whether dlopen of programs is supported. -dlopen_self=$enable_dlopen_self - -# Whether dlopen of statically linked programs is supported. -dlopen_self_static=$enable_dlopen_self_static - -# Compiler flag to prevent dynamic linking. -link_static_flag=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_static, $1) - -# Compiler flag to turn off builtin functions. -no_builtin_flag=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) - -# Compiler flag to allow reflexive dlopens. -export_dynamic_flag_spec=$lt_[]_LT_AC_TAGVAR(export_dynamic_flag_spec, $1) - -# Compiler flag to generate shared objects directly from archives. -whole_archive_flag_spec=$lt_[]_LT_AC_TAGVAR(whole_archive_flag_spec, $1) - -# Compiler flag to generate thread-safe objects. -thread_safe_flag_spec=$lt_[]_LT_AC_TAGVAR(thread_safe_flag_spec, $1) - -# Library versioning type. -version_type=$version_type - -# Format of library name prefix. -libname_spec=$lt_libname_spec - -# List of archive names. First name is the real one, the rest are links. -# The last name is the one that the linker finds with -lNAME. -library_names_spec=$lt_library_names_spec - -# The coded name of the library, if different from the real name. -soname_spec=$lt_soname_spec - -# Commands used to build and install an old-style archive. -RANLIB=$lt_RANLIB -old_archive_cmds=$lt_[]_LT_AC_TAGVAR(old_archive_cmds, $1) -old_postinstall_cmds=$lt_old_postinstall_cmds -old_postuninstall_cmds=$lt_old_postuninstall_cmds - -# Create an old-style archive from a shared archive. -old_archive_from_new_cmds=$lt_[]_LT_AC_TAGVAR(old_archive_from_new_cmds, $1) - -# Create a temporary old-style archive to link instead of a shared archive. -old_archive_from_expsyms_cmds=$lt_[]_LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1) - -# Commands used to build and install a shared archive. -archive_cmds=$lt_[]_LT_AC_TAGVAR(archive_cmds, $1) -archive_expsym_cmds=$lt_[]_LT_AC_TAGVAR(archive_expsym_cmds, $1) -postinstall_cmds=$lt_postinstall_cmds -postuninstall_cmds=$lt_postuninstall_cmds - -# Commands used to build a loadable module (assumed same as above if empty) -module_cmds=$lt_[]_LT_AC_TAGVAR(module_cmds, $1) -module_expsym_cmds=$lt_[]_LT_AC_TAGVAR(module_expsym_cmds, $1) - -# Commands to strip libraries. -old_striplib=$lt_old_striplib -striplib=$lt_striplib - -# Dependencies to place before the objects being linked to create a -# shared library. -predep_objects=$lt_[]_LT_AC_TAGVAR(predep_objects, $1) - -# Dependencies to place after the objects being linked to create a -# shared library. -postdep_objects=$lt_[]_LT_AC_TAGVAR(postdep_objects, $1) - -# Dependencies to place before the objects being linked to create a -# shared library. -predeps=$lt_[]_LT_AC_TAGVAR(predeps, $1) - -# Dependencies to place after the objects being linked to create a -# shared library. -postdeps=$lt_[]_LT_AC_TAGVAR(postdeps, $1) - -# The library search path used internally by the compiler when linking -# a shared library. -compiler_lib_search_path=$lt_[]_LT_AC_TAGVAR(compiler_lib_search_path, $1) - -# Method to check whether dependent libraries are shared objects. -deplibs_check_method=$lt_deplibs_check_method - -# Command to use when deplibs_check_method == file_magic. -file_magic_cmd=$lt_file_magic_cmd - -# Flag that allows shared libraries with undefined symbols to be built. -allow_undefined_flag=$lt_[]_LT_AC_TAGVAR(allow_undefined_flag, $1) - -# Flag that forces no undefined symbols. -no_undefined_flag=$lt_[]_LT_AC_TAGVAR(no_undefined_flag, $1) - -# Commands used to finish a libtool library installation in a directory. -finish_cmds=$lt_finish_cmds - -# Same as above, but a single script fragment to be evaled but not shown. -finish_eval=$lt_finish_eval - -# Take the output of nm and produce a listing of raw symbols and C names. -global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe - -# Transform the output of nm in a proper C declaration -global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl - -# Transform the output of nm in a C name address pair -global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address - -# This is the shared library runtime path variable. -runpath_var=$runpath_var - -# This is the shared library path variable. -shlibpath_var=$shlibpath_var - -# Is shlibpath searched before the hard-coded library search path? -shlibpath_overrides_runpath=$shlibpath_overrides_runpath - -# How to hardcode a shared library path into an executable. -hardcode_action=$_LT_AC_TAGVAR(hardcode_action, $1) - -# Whether we should hardcode library paths into libraries. -hardcode_into_libs=$hardcode_into_libs - -# Flag to hardcode \$libdir into a binary during linking. -# This must work even if \$libdir does not exist. -hardcode_libdir_flag_spec=$lt_[]_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) - -# If ld is used when linking, flag to hardcode \$libdir into -# a binary during linking. This must work even if \$libdir does -# not exist. -hardcode_libdir_flag_spec_ld=$lt_[]_LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1) - -# Whether we need a single -rpath flag with a separated argument. -hardcode_libdir_separator=$lt_[]_LT_AC_TAGVAR(hardcode_libdir_separator, $1) - -# Set to yes if using DIR/libNAME${shared_ext} during linking hardcodes DIR into the -# resulting binary. -hardcode_direct=$_LT_AC_TAGVAR(hardcode_direct, $1) - -# Set to yes if using the -LDIR flag during linking hardcodes DIR into the -# resulting binary. -hardcode_minus_L=$_LT_AC_TAGVAR(hardcode_minus_L, $1) - -# Set to yes if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into -# the resulting binary. -hardcode_shlibpath_var=$_LT_AC_TAGVAR(hardcode_shlibpath_var, $1) - -# Set to yes if building a shared library automatically hardcodes DIR into the library -# and all subsequent libraries and executables linked against it. -hardcode_automatic=$_LT_AC_TAGVAR(hardcode_automatic, $1) - -# Variables whose values should be saved in libtool wrapper scripts and -# restored at relink time. -variables_saved_for_relink="$variables_saved_for_relink" - -# Whether libtool must link a program against all its dependency libraries. -link_all_deplibs=$_LT_AC_TAGVAR(link_all_deplibs, $1) - -# Compile-time system search path for libraries -sys_lib_search_path_spec=$lt_sys_lib_search_path_spec - -# Run-time system search path for libraries -sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec - -# Fix the shell variable \$srcfile for the compiler. -fix_srcfile_path="$_LT_AC_TAGVAR(fix_srcfile_path, $1)" - -# Set to yes if exported symbols are required. -always_export_symbols=$_LT_AC_TAGVAR(always_export_symbols, $1) - -# The commands to list exported symbols. -export_symbols_cmds=$lt_[]_LT_AC_TAGVAR(export_symbols_cmds, $1) - -# The commands to extract the exported symbol list from a shared archive. -extract_expsyms_cmds=$lt_extract_expsyms_cmds - -# Symbols that should not be listed in the preloaded symbols. -exclude_expsyms=$lt_[]_LT_AC_TAGVAR(exclude_expsyms, $1) - -# Symbols that must always be exported. -include_expsyms=$lt_[]_LT_AC_TAGVAR(include_expsyms, $1) - -ifelse([$1],[], -[# ### END LIBTOOL CONFIG], -[# ### END LIBTOOL TAG CONFIG: $tagname]) - -__EOF__ - -ifelse([$1],[], [ - case $host_os in - aix3*) - cat <<\EOF >> "$cfgfile" - -# AIX sometimes has problems with the GCC collect2 program. For some -# reason, if we set the COLLECT_NAMES environment variable, the problems -# vanish in a puff of smoke. -if test "X${COLLECT_NAMES+set}" != Xset; then - COLLECT_NAMES= - export COLLECT_NAMES -fi -EOF - ;; - esac - - # We use sed instead of cat because bash on DJGPP gets confused if - # if finds mixed CR/LF and LF-only lines. Since sed operates in - # text mode, it properly converts lines to CR/LF. This bash problem - # is reportedly fixed, but why not run on old versions too? - sed '$q' "$ltmain" >> "$cfgfile" || (rm -f "$cfgfile"; exit 1) - - mv -f "$cfgfile" "$ofile" || \ - (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile") - chmod +x "$ofile" -]) -else - # If there is no Makefile yet, we rely on a make rule to execute - # `config.status --recheck' to rerun these tests and create the - # libtool script then. - ltmain_in=`echo $ltmain | sed -e 's/\.sh$/.in/'` - if test -f "$ltmain_in"; then - test -f Makefile && make "$ltmain" - fi -fi -])# AC_LIBTOOL_CONFIG - - -# AC_LIBTOOL_PROG_COMPILER_NO_RTTI([TAGNAME]) -# ------------------------------------------- -AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_NO_RTTI], -[AC_REQUIRE([_LT_AC_SYS_COMPILER])dnl - -_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)= - -if test "$GCC" = yes; then - _LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin' - - AC_LIBTOOL_COMPILER_OPTION([if $compiler supports -fno-rtti -fno-exceptions], - lt_cv_prog_compiler_rtti_exceptions, - [-fno-rtti -fno-exceptions], [], - [_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)="$_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) -fno-rtti -fno-exceptions"]) -fi -])# AC_LIBTOOL_PROG_COMPILER_NO_RTTI - - -# AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE -# --------------------------------- -AC_DEFUN([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE], -[AC_REQUIRE([AC_CANONICAL_HOST]) -AC_REQUIRE([AC_PROG_NM]) -AC_REQUIRE([AC_OBJEXT]) -# Check for command to grab the raw symbol name followed by C symbol from nm. -AC_MSG_CHECKING([command to parse $NM output from $compiler object]) -AC_CACHE_VAL([lt_cv_sys_global_symbol_pipe], -[ -# These are sane defaults that work on at least a few old systems. -# [They come from Ultrix. What could be older than Ultrix?!! ;)] - -# Character class describing NM global symbol codes. -symcode='[[BCDEGRST]]' - -# Regexp to match symbols that can be accessed directly from C. -sympat='\([[_A-Za-z]][[_A-Za-z0-9]]*\)' - -# Transform an extracted symbol line into a proper C declaration -lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^. .* \(.*\)$/extern int \1;/p'" - -# Transform an extracted symbol line into symbol name and symbol address -lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\) $/ {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode \([[^ ]]*\) \([[^ ]]*\)$/ {\"\2\", (lt_ptr) \&\2},/p'" - -# Define system-specific variables. -case $host_os in -aix*) - symcode='[[BCDT]]' - ;; -cygwin* | mingw* | pw32*) - symcode='[[ABCDGISTW]]' - ;; -hpux*) # Its linker distinguishes data from code symbols - if test "$host_cpu" = ia64; then - symcode='[[ABCDEGRST]]' - fi - lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'" - lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\) $/ {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"\2\", (lt_ptr) \&\2},/p'" - ;; -linux*) - if test "$host_cpu" = ia64; then - symcode='[[ABCDGIRSTW]]' - lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'" - lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\) $/ {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"\2\", (lt_ptr) \&\2},/p'" - fi - ;; -irix* | nonstopux*) - symcode='[[BCDEGRST]]' - ;; -osf*) - symcode='[[BCDEGQRST]]' - ;; -solaris* | sysv5*) - symcode='[[BDRT]]' - ;; -sysv4) - symcode='[[DFNSTU]]' - ;; -esac - -# Handle CRLF in mingw tool chain -opt_cr= -case $build_os in -mingw*) - opt_cr=`echo 'x\{0,1\}' | tr x '\015'` # option cr in regexp - ;; -esac - -# If we're using GNU nm, then use its standard symbol codes. -case `$NM -V 2>&1` in -*GNU* | *'with BFD'*) - symcode='[[ABCDGIRSTW]]' ;; -esac - -# Try without a prefix undercore, then with it. -for ac_symprfx in "" "_"; do - - # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol. - symxfrm="\\1 $ac_symprfx\\2 \\2" - - # Write the raw and C identifiers. - lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[[ ]]\($symcode$symcode*\)[[ ]][[ ]]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'" - - # Check to see that the pipe works correctly. - pipe_works=no - - rm -f conftest* - cat > conftest.$ac_ext <<EOF -#ifdef __cplusplus -extern "C" { -#endif -char nm_test_var; -void nm_test_func(){} -#ifdef __cplusplus -} -#endif -int main(){nm_test_var='a';nm_test_func();return(0);} -EOF - - if AC_TRY_EVAL(ac_compile); then - # Now try to grab the symbols. - nlist=conftest.nm - if AC_TRY_EVAL(NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist) && test -s "$nlist"; then - # Try sorting and uniquifying the output. - if sort "$nlist" | uniq > "$nlist"T; then - mv -f "$nlist"T "$nlist" - else - rm -f "$nlist"T - fi - - # Make sure that we snagged all the symbols we need. - if grep ' nm_test_var$' "$nlist" >/dev/null; then - if grep ' nm_test_func$' "$nlist" >/dev/null; then - cat <<EOF > conftest.$ac_ext -#ifdef __cplusplus -extern "C" { -#endif - -EOF - # Now generate the symbol file. - eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | grep -v main >> conftest.$ac_ext' - - cat <<EOF >> conftest.$ac_ext -#if defined (__STDC__) && __STDC__ -# define lt_ptr_t void * -#else -# define lt_ptr_t char * -# define const -#endif - -/* The mapping between symbol names and symbols. */ -const struct { - const char *name; - lt_ptr_t address; -} -lt_preloaded_symbols[[]] = -{ -EOF - $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (lt_ptr_t) \&\2},/" < "$nlist" | grep -v main >> conftest.$ac_ext - cat <<\EOF >> conftest.$ac_ext - {0, (lt_ptr_t) 0} -}; - -#ifdef __cplusplus -} -#endif -EOF - # Now try linking the two files. - mv conftest.$ac_objext conftstm.$ac_objext - lt_save_LIBS="$LIBS" - lt_save_CFLAGS="$CFLAGS" - LIBS="conftstm.$ac_objext" - CFLAGS="$CFLAGS$_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)" - if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext}; then - pipe_works=yes - fi - LIBS="$lt_save_LIBS" - CFLAGS="$lt_save_CFLAGS" - else - echo "cannot find nm_test_func in $nlist" >&AS_MESSAGE_LOG_FD - fi - else - echo "cannot find nm_test_var in $nlist" >&AS_MESSAGE_LOG_FD - fi - else - echo "cannot run $lt_cv_sys_global_symbol_pipe" >&AS_MESSAGE_LOG_FD - fi - else - echo "$progname: failed program was:" >&AS_MESSAGE_LOG_FD - cat conftest.$ac_ext >&5 - fi - rm -f conftest* conftst* - - # Do not use the global_symbol_pipe unless it works. - if test "$pipe_works" = yes; then - break - else - lt_cv_sys_global_symbol_pipe= - fi -done -]) -if test -z "$lt_cv_sys_global_symbol_pipe"; then - lt_cv_sys_global_symbol_to_cdecl= -fi -if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then - AC_MSG_RESULT(failed) -else - AC_MSG_RESULT(ok) -fi -]) # AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE - - -# AC_LIBTOOL_PROG_COMPILER_PIC([TAGNAME]) -# --------------------------------------- -AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_PIC], -[_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)= -_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)= -_LT_AC_TAGVAR(lt_prog_compiler_static, $1)= - -AC_MSG_CHECKING([for $compiler option to produce PIC]) - ifelse([$1],[CXX],[ - # C++ specific cases for pic, static, wl, etc. - if test "$GXX" = yes; then - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static' - - case $host_os in - aix*) - # All AIX code is PIC. - if test "$host_cpu" = ia64; then - # AIX 5 now supports IA64 processor - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - fi - ;; - amigaos*) - # FIXME: we need at least 68020 code to build shared libraries, but - # adding the `-m68020' flag to GCC prevents building anything better, - # like `-m68040'. - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4' - ;; - beos* | cygwin* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) - # PIC is the default for these OSes. - ;; - mingw* | os2* | pw32*) - # This hack is so that the source file can tell whether it is being - # built for inclusion in a dll (and should export symbols for example). - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT' - ;; - darwin* | rhapsody*) - # PIC is the default on this platform - # Common symbols not allowed in MH_DYLIB files - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common' - ;; - *djgpp*) - # DJGPP does not support shared libraries at all - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)= - ;; - sysv4*MP*) - if test -d /usr/nec; then - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic - fi - ;; - hpux*) - # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but - # not for PA HP-UX. - case "$host_cpu" in - hppa*64*|ia64*) - ;; - *) - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' - ;; - esac - ;; - *) - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' - ;; - esac - else - case $host_os in - aix4* | aix5*) - # All AIX code is PIC. - if test "$host_cpu" = ia64; then - # AIX 5 now supports IA64 processor - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - else - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp' - fi - ;; - chorus*) - case $cc_basename in - cxch68*) - # Green Hills C++ Compiler - # _LT_AC_TAGVAR(lt_prog_compiler_static, $1)="--no_auto_instantiation -u __main -u __premain -u _abort -r $COOL_DIR/lib/libOrb.a $MVME_DIR/lib/CC/libC.a $MVME_DIR/lib/classix/libcx.s.a" - ;; - esac - ;; - darwin*) - # PIC is the default on this platform - # Common symbols not allowed in MH_DYLIB files - case $cc_basename in - xlc*) - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-qnocommon' - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - ;; - esac - ;; - dgux*) - case $cc_basename in - ec++*) - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - ;; - ghcx*) - # Green Hills C++ Compiler - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic' - ;; - *) - ;; - esac - ;; - freebsd* | kfreebsd*-gnu | dragonfly*) - # FreeBSD uses GNU C++ - ;; - hpux9* | hpux10* | hpux11*) - case $cc_basename in - CC*) - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)="${ac_cv_prog_cc_wl}-a ${ac_cv_prog_cc_wl}archive" - if test "$host_cpu" != ia64; then - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='+Z' - fi - ;; - aCC*) - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)="${ac_cv_prog_cc_wl}-a ${ac_cv_prog_cc_wl}archive" - case "$host_cpu" in - hppa*64*|ia64*) - # +Z the default - ;; - *) - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='+Z' - ;; - esac - ;; - *) - ;; - esac - ;; - irix5* | irix6* | nonstopux*) - case $cc_basename in - CC*) - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' - # CC pic flag -KPIC is the default. - ;; - *) - ;; - esac - ;; - linux*) - case $cc_basename in - KCC*) - # KAI C++ Compiler - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,' - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' - ;; - icpc* | ecpc*) - # Intel C++ - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static' - ;; - pgCC*) - # Portland Group C++ compiler. - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static' - ;; - cxx*) - # Compaq C++ - # Make sure the PIC flag is empty. It appears that all Alpha - # Linux and Compaq Tru64 Unix objects are PIC. - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)= - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' - ;; - *) - ;; - esac - ;; - lynxos*) - ;; - m88k*) - ;; - mvs*) - case $cc_basename in - cxx*) - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-W c,exportall' - ;; - *) - ;; - esac - ;; - netbsd*) - ;; - osf3* | osf4* | osf5*) - case $cc_basename in - KCC*) - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,' - ;; - RCC*) - # Rational C++ 2.4.1 - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic' - ;; - cxx*) - # Digital/Compaq C++ - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - # Make sure the PIC flag is empty. It appears that all Alpha - # Linux and Compaq Tru64 Unix objects are PIC. - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)= - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' - ;; - *) - ;; - esac - ;; - psos*) - ;; - sco*) - case $cc_basename in - CC*) - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' - ;; - *) - ;; - esac - ;; - solaris*) - case $cc_basename in - CC*) - # Sun C++ 4.2, 5.x and Centerline C++ - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' - ;; - gcx*) - # Green Hills C++ Compiler - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' - ;; - *) - ;; - esac - ;; - sunos4*) - case $cc_basename in - CC*) - # Sun C++ 4.x - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic' - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - ;; - lcc*) - # Lucid - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic' - ;; - *) - ;; - esac - ;; - tandem*) - case $cc_basename in - NCC*) - # NonStop-UX NCC 3.20 - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - ;; - *) - ;; - esac - ;; - unixware*) - ;; - vxworks*) - ;; - *) - _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no - ;; - esac - fi -], -[ - if test "$GCC" = yes; then - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static' - - case $host_os in - aix*) - # All AIX code is PIC. - if test "$host_cpu" = ia64; then - # AIX 5 now supports IA64 processor - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - fi - ;; - - amigaos*) - # FIXME: we need at least 68020 code to build shared libraries, but - # adding the `-m68020' flag to GCC prevents building anything better, - # like `-m68040'. - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4' - ;; - - beos* | cygwin* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) - # PIC is the default for these OSes. - ;; - - mingw* | pw32* | os2*) - # This hack is so that the source file can tell whether it is being - # built for inclusion in a dll (and should export symbols for example). - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT' - ;; - - darwin* | rhapsody*) - # PIC is the default on this platform - # Common symbols not allowed in MH_DYLIB files - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common' - ;; - - msdosdjgpp*) - # Just because we use GCC doesn't mean we suddenly get shared libraries - # on systems that don't support them. - _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no - enable_shared=no - ;; - - sysv4*MP*) - if test -d /usr/nec; then - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic - fi - ;; - - hpux*) - # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but - # not for PA HP-UX. - case "$host_cpu" in - hppa*64*|ia64*) - # +Z the default - ;; - *) - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' - ;; - esac - ;; - - *) - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' - ;; - esac - else - # PORTME Check for flag to pass linker flags through the system compiler. - case $host_os in - aix*) - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - if test "$host_cpu" = ia64; then - # AIX 5 now supports IA64 processor - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - else - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp' - fi - ;; - darwin*) - # PIC is the default on this platform - # Common symbols not allowed in MH_DYLIB files - case $cc_basename in - xlc*) - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-qnocommon' - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - ;; - esac - ;; - - mingw* | pw32* | os2*) - # This hack is so that the source file can tell whether it is being - # built for inclusion in a dll (and should export symbols for example). - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT' - ;; - - hpux9* | hpux10* | hpux11*) - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but - # not for PA HP-UX. - case "$host_cpu" in - hppa*64*|ia64*) - # +Z the default - ;; - *) - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='+Z' - ;; - esac - # Is there a better lt_prog_compiler_static that works with the bundled CC? - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive' - ;; - - irix5* | irix6* | nonstopux*) - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - # PIC (with -KPIC) is the default. - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' - ;; - - newsos6) - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - ;; - - linux*) - case $cc_basename in - icc* | ecc*) - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static' - ;; - pgcc* | pgf77* | pgf90*) - # Portland Group compilers (*not* the Pentium gcc compiler, - # which looks to be a dead project) - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static' - ;; - ccc*) - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - # All Alpha code is PIC. - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' - ;; - esac - ;; - - osf3* | osf4* | osf5*) - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - # All OSF/1 code is PIC. - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' - ;; - - sco3.2v5*) - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-Kpic' - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-dn' - ;; - - solaris*) - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - case $cc_basename in - f77* | f90* | f95*) - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ';; - *) - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,';; - esac - ;; - - sunos4*) - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - ;; - - sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - ;; - - sysv4*MP*) - if test -d /usr/nec ;then - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-Kconform_pic' - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - fi - ;; - - unicos*) - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no - ;; - - uts4*) - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic' - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - ;; - - *) - _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no - ;; - esac - fi -]) -AC_MSG_RESULT([$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)]) - -# -# Check to make sure the PIC flag actually works. -# -if test -n "$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)"; then - AC_LIBTOOL_COMPILER_OPTION([if $compiler PIC flag $_LT_AC_TAGVAR(lt_prog_compiler_pic, $1) works], - _LT_AC_TAGVAR(lt_prog_compiler_pic_works, $1), - [$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)ifelse([$1],[],[ -DPIC],[ifelse([$1],[CXX],[ -DPIC],[])])], [], - [case $_LT_AC_TAGVAR(lt_prog_compiler_pic, $1) in - "" | " "*) ;; - *) _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=" $_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)" ;; - esac], - [_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)= - _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no]) -fi -case "$host_os" in - # For platforms which do not support PIC, -DPIC is meaningless: - *djgpp*) - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)= - ;; - *) - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)="$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)ifelse([$1],[],[ -DPIC],[ifelse([$1],[CXX],[ -DPIC],[])])" - ;; -esac -]) - - -# AC_LIBTOOL_PROG_LD_SHLIBS([TAGNAME]) -# ------------------------------------ -# See if the linker supports building shared libraries. -AC_DEFUN([AC_LIBTOOL_PROG_LD_SHLIBS], -[AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries]) -ifelse([$1],[CXX],[ - _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' - case $host_os in - aix4* | aix5*) - # If we're using GNU nm, then we don't want the "-C" option. - # -C means demangle to AIX nm, but means don't demangle with GNU nm - if $NM -V 2>&1 | grep 'GNU' > /dev/null; then - _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\[$]2 == "T") || (\[$]2 == "D") || (\[$]2 == "B")) && ([substr](\[$]3,1,1) != ".")) { print \[$]3 } }'\'' | sort -u > $export_symbols' - else - _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\[$]2 == "T") || (\[$]2 == "D") || (\[$]2 == "B")) && ([substr](\[$]3,1,1) != ".")) { print \[$]3 } }'\'' | sort -u > $export_symbols' - fi - ;; - pw32*) - _LT_AC_TAGVAR(export_symbols_cmds, $1)="$ltdll_cmds" - ;; - cygwin* | mingw*) - _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]] /s/.* \([[^ ]]*\)/\1 DATA/;/^.* __nm__/s/^.* __nm__\([[^ ]]*\) [[^ ]]*/\1 DATA/;/^I /d;/^[[AITW]] /s/.* //'\'' | sort | uniq > $export_symbols' - ;; - *) - _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' - ;; - esac -],[ - runpath_var= - _LT_AC_TAGVAR(allow_undefined_flag, $1)= - _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=no - _LT_AC_TAGVAR(archive_cmds, $1)= - _LT_AC_TAGVAR(archive_expsym_cmds, $1)= - _LT_AC_TAGVAR(old_archive_From_new_cmds, $1)= - _LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1)= - _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)= - _LT_AC_TAGVAR(whole_archive_flag_spec, $1)= - _LT_AC_TAGVAR(thread_safe_flag_spec, $1)= - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)= - _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)= - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)= - _LT_AC_TAGVAR(hardcode_direct, $1)=no - _LT_AC_TAGVAR(hardcode_minus_L, $1)=no - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported - _LT_AC_TAGVAR(link_all_deplibs, $1)=unknown - _LT_AC_TAGVAR(hardcode_automatic, $1)=no - _LT_AC_TAGVAR(module_cmds, $1)= - _LT_AC_TAGVAR(module_expsym_cmds, $1)= - _LT_AC_TAGVAR(always_export_symbols, $1)=no - _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' - # include_expsyms should be a list of space-separated symbols to be *always* - # included in the symbol list - _LT_AC_TAGVAR(include_expsyms, $1)= - # exclude_expsyms can be an extended regexp of symbols to exclude - # it will be wrapped by ` (' and `)$', so one must not match beginning or - # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc', - # as well as any symbol that contains `d'. - _LT_AC_TAGVAR(exclude_expsyms, $1)="_GLOBAL_OFFSET_TABLE_" - # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out - # platforms (ab)use it in PIC code, but their linkers get confused if - # the symbol is explicitly referenced. Since portable code cannot - # rely on this symbol name, it's probably fine to never include it in - # preloaded symbol tables. - extract_expsyms_cmds= - # Just being paranoid about ensuring that cc_basename is set. - _LT_CC_BASENAME([$compiler]) - case $host_os in - cygwin* | mingw* | pw32*) - # FIXME: the MSVC++ port hasn't been tested in a loooong time - # When not using gcc, we currently assume that we are using - # Microsoft Visual C++. - if test "$GCC" != yes; then - with_gnu_ld=no - fi - ;; - openbsd*) - with_gnu_ld=no - ;; - esac - - _LT_AC_TAGVAR(ld_shlibs, $1)=yes - if test "$with_gnu_ld" = yes; then - # If archive_cmds runs LD, not CC, wlarc should be empty - wlarc='${wl}' - - # Set some defaults for GNU ld with shared library support. These - # are reset later if shared libraries are not supported. Putting them - # here allows them to be overridden if necessary. - runpath_var=LD_RUN_PATH - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir' - _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' - # ancient GNU ld didn't support --whole-archive et. al. - if $LD --help 2>&1 | grep 'no-whole-archive' > /dev/null; then - _LT_AC_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' - else - _LT_AC_TAGVAR(whole_archive_flag_spec, $1)= - fi - supports_anon_versioning=no - case `$LD -v 2>/dev/null` in - *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.10.*) ;; # catch versions < 2.11 - *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ... - *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ... - *\ 2.11.*) ;; # other 2.11 versions - *) supports_anon_versioning=yes ;; - esac - - # See if GNU ld supports shared libraries. - case $host_os in - aix3* | aix4* | aix5*) - # On AIX/PPC, the GNU linker is very broken - if test "$host_cpu" != ia64; then - _LT_AC_TAGVAR(ld_shlibs, $1)=no - cat <<EOF 1>&2 - -*** Warning: the GNU linker, at least up to release 2.9.1, is reported -*** to be unable to reliably create shared libraries on AIX. -*** Therefore, libtool is disabling shared libraries support. If you -*** really care for shared libraries, you may want to modify your PATH -*** so that a non-GNU linker is found, and then restart. - -EOF - fi - ;; - - amigaos*) - _LT_AC_TAGVAR(archive_cmds, $1)='$rm $output_objdir/a2ixlibrary.data~$echo "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$echo "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$echo "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$echo "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes - - # Samuel A. Falvo II <kc5tja@dolphin.openprojects.net> reports - # that the semantics of dynamic libraries on AmigaOS, at least up - # to version 4, is to share data among multiple programs linked - # with the same dynamic library. Since this doesn't match the - # behavior of shared libraries on other platforms, we can't use - # them. - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - - beos*) - if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then - _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported - # Joseph Beckenbach <jrb3@best.com> says some releases of gcc - # support --undefined. This deserves some investigation. FIXME - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - else - _LT_AC_TAGVAR(ld_shlibs, $1)=no - fi - ;; - - cygwin* | mingw* | pw32*) - # _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless, - # as there is no search path for DLLs. - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported - _LT_AC_TAGVAR(always_export_symbols, $1)=no - _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=yes - _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]] /s/.* \([[^ ]]*\)/\1 DATA/'\'' | $SED -e '\''/^[[AITW]] /s/.* //'\'' | sort | uniq > $export_symbols' - - if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000 ${wl}--out-implib,$lib' - # If the export-symbols file already is a .def file (1st line - # is EXPORTS), use it as is; otherwise, prepend... - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then - cp $export_symbols $output_objdir/$soname.def; - else - echo EXPORTS > $output_objdir/$soname.def; - cat $export_symbols >> $output_objdir/$soname.def; - fi~ - $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000 ${wl}--out-implib,$lib' - else - _LT_AC_TAGVAR(ld_shlibs, $1)=no - fi - ;; - - linux*) - if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then - tmp_addflag= - case $cc_basename,$host_cpu in - pgcc*) # Portland Group C compiler - _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive,`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' - tmp_addflag=' $pic_flag' - ;; - pgf77* | pgf90* ) # Portland Group f77 and f90 compilers - _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive,`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' - tmp_addflag=' $pic_flag -Mnomain' ;; - ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64 - tmp_addflag=' -i_dynamic' ;; - efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64 - tmp_addflag=' -i_dynamic -nofor_main' ;; - ifc* | ifort*) # Intel Fortran compiler - tmp_addflag=' -nofor_main' ;; - esac - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared'"$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - - if test $supports_anon_versioning = yes; then - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $output_objdir/$libname.ver~ - cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ - $echo "local: *; };" >> $output_objdir/$libname.ver~ - $CC -shared'"$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib' - fi - else - _LT_AC_TAGVAR(ld_shlibs, $1)=no - fi - ;; - - netbsd*) - if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib' - wlarc= - else - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' - fi - ;; - - solaris* | sysv5*) - if $LD -v 2>&1 | grep 'BFD 2\.8' > /dev/null; then - _LT_AC_TAGVAR(ld_shlibs, $1)=no - cat <<EOF 1>&2 - -*** Warning: The releases 2.8.* of the GNU linker cannot reliably -*** create shared libraries on Solaris systems. Therefore, libtool -*** is disabling shared libraries support. We urge you to upgrade GNU -*** binutils to release 2.9.1 or newer. Another option is to modify -*** your PATH or compiler configuration so that the native linker is -*** used, and then restart. - -EOF - elif $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' - else - _LT_AC_TAGVAR(ld_shlibs, $1)=no - fi - ;; - - sunos4*) - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags' - wlarc= - _LT_AC_TAGVAR(hardcode_direct, $1)=yes - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - - *) - if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' - else - _LT_AC_TAGVAR(ld_shlibs, $1)=no - fi - ;; - esac - - if test "$_LT_AC_TAGVAR(ld_shlibs, $1)" = no; then - runpath_var= - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)= - _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)= - _LT_AC_TAGVAR(whole_archive_flag_spec, $1)= - fi - else - # PORTME fill in a description of your system's linker (not GNU ld) - case $host_os in - aix3*) - _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported - _LT_AC_TAGVAR(always_export_symbols, $1)=yes - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname' - # Note: this linker hardcodes the directories in LIBPATH if there - # are no directories specified by -L. - _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes - if test "$GCC" = yes && test -z "$link_static_flag"; then - # Neither direct hardcoding nor static linking is supported with a - # broken collect2. - _LT_AC_TAGVAR(hardcode_direct, $1)=unsupported - fi - ;; - - aix4* | aix5*) - if test "$host_cpu" = ia64; then - # On IA64, the linker does run time linking by default, so we don't - # have to do anything special. - aix_use_runtimelinking=no - exp_sym_flag='-Bexport' - no_entry_flag="" - else - # If we're using GNU nm, then we don't want the "-C" option. - # -C means demangle to AIX nm, but means don't demangle with GNU nm - if $NM -V 2>&1 | grep 'GNU' > /dev/null; then - _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\[$]2 == "T") || (\[$]2 == "D") || (\[$]2 == "B")) && ([substr](\[$]3,1,1) != ".")) { print \[$]3 } }'\'' | sort -u > $export_symbols' - else - _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\[$]2 == "T") || (\[$]2 == "D") || (\[$]2 == "B")) && ([substr](\[$]3,1,1) != ".")) { print \[$]3 } }'\'' | sort -u > $export_symbols' - fi - aix_use_runtimelinking=no - - # Test if we are trying to use run time linking or normal - # AIX style linking. If -brtl is somewhere in LDFLAGS, we - # need to do runtime linking. - case $host_os in aix4.[[23]]|aix4.[[23]].*|aix5*) - for ld_flag in $LDFLAGS; do - if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then - aix_use_runtimelinking=yes - break - fi - done - esac - - exp_sym_flag='-bexport' - no_entry_flag='-bnoentry' - fi - - # When large executables or shared objects are built, AIX ld can - # have problems creating the table of contents. If linking a library - # or program results in "error TOC overflow" add -mminimal-toc to - # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not - # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. - - _LT_AC_TAGVAR(archive_cmds, $1)='' - _LT_AC_TAGVAR(hardcode_direct, $1)=yes - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=':' - _LT_AC_TAGVAR(link_all_deplibs, $1)=yes - - if test "$GCC" = yes; then - case $host_os in aix4.[[012]]|aix4.[[012]].*) - # We only want to do this on AIX 4.2 and lower, the check - # below for broken collect2 doesn't work under 4.3+ - collect2name=`${CC} -print-prog-name=collect2` - if test -f "$collect2name" && \ - strings "$collect2name" | grep resolve_lib_name >/dev/null - then - # We have reworked collect2 - _LT_AC_TAGVAR(hardcode_direct, $1)=yes - else - # We have old collect2 - _LT_AC_TAGVAR(hardcode_direct, $1)=unsupported - # It fails to find uninstalled libraries when the uninstalled - # path is not listed in the libpath. Setting hardcode_minus_L - # to unsupported forces relinking - _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)= - fi - esac - shared_flag='-shared' - if test "$aix_use_runtimelinking" = yes; then - shared_flag="$shared_flag "'${wl}-G' - fi - else - # not using gcc - if test "$host_cpu" = ia64; then - # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release - # chokes on -Wl,-G. The following line is correct: - shared_flag='-G' - else - if test "$aix_use_runtimelinking" = yes; then - shared_flag='${wl}-G' - else - shared_flag='${wl}-bM:SRE' - fi - fi - fi - - # It seems that -bexpall does not export symbols beginning with - # underscore (_), so it is better to generate a list of symbols to export. - _LT_AC_TAGVAR(always_export_symbols, $1)=yes - if test "$aix_use_runtimelinking" = yes; then - # Warning - without using the other runtime loading flags (-brtl), - # -berok will link without error, but may produce a broken library. - _LT_AC_TAGVAR(allow_undefined_flag, $1)='-berok' - # Determine the default libpath from the value encoded in an empty executable. - _LT_AC_SYS_LIBPATH_AIX - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" - _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols $shared_flag" - else - if test "$host_cpu" = ia64; then - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib' - _LT_AC_TAGVAR(allow_undefined_flag, $1)="-z nodefs" - _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols" - else - # Determine the default libpath from the value encoded in an empty executable. - _LT_AC_SYS_LIBPATH_AIX - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" - # Warning - without using the other run time loading flags, - # -berok will link without error, but may produce a broken library. - _LT_AC_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok' - _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok' - # -bexpall does not export symbols beginning with underscore (_) - _LT_AC_TAGVAR(always_export_symbols, $1)=yes - # Exported symbols can be pulled into shared objects from archives - _LT_AC_TAGVAR(whole_archive_flag_spec, $1)=' ' - _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes - # This is similar to how AIX traditionally builds it's shared libraries. - _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}-bE:$export_symbols ${wl}-bnoentry${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname' - fi - fi - ;; - - amigaos*) - _LT_AC_TAGVAR(archive_cmds, $1)='$rm $output_objdir/a2ixlibrary.data~$echo "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$echo "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$echo "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$echo "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes - # see comment about different semantics on the GNU ld section - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - - bsdi[[45]]*) - _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)=-rdynamic - ;; - - cygwin* | mingw* | pw32*) - # When not using gcc, we currently assume that we are using - # Microsoft Visual C++. - # hardcode_libdir_flag_spec is actually meaningless, as there is - # no search path for DLLs. - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=' ' - _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported - # Tell ltmain to make .lib files, not .a files. - libext=lib - # Tell ltmain to make .dll files, not .so files. - shrext_cmds=".dll"; shrext="$shrext_cmds" - # FIXME: Setting linknames here is a bad hack. - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -o $lib $libobjs $compiler_flags `echo "$deplibs" | $SED -e '\''s/ -lc$//'\''` -link -dll~linknames=' - # The linker will automatically build a .lib file if we build a DLL. - _LT_AC_TAGVAR(old_archive_From_new_cmds, $1)='true' - # FIXME: Should let the user specify the lib program. - _LT_AC_TAGVAR(old_archive_cmds, $1)='lib /OUT:$oldlib$oldobjs$old_deplibs' - _LT_AC_TAGVAR(fix_srcfile_path, $1)='`cygpath -w "$srcfile"`' - _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=yes - ;; - - darwin* | rhapsody*) - case "$host_os" in - rhapsody* | darwin1.[[012]]) - _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-undefined ${wl}suppress' - ;; - *) # Darwin 1.3 on - if test -z ${MACOSX_DEPLOYMENT_TARGET} ; then - _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' - else - case ${MACOSX_DEPLOYMENT_TARGET} in - 10.[[012]]) - _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' - ;; - 10.*) - _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-undefined ${wl}dynamic_lookup' - ;; - esac - fi - ;; - esac - _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no - _LT_AC_TAGVAR(hardcode_direct, $1)=no - _LT_AC_TAGVAR(hardcode_automatic, $1)=yes - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported - _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='' - _LT_AC_TAGVAR(link_all_deplibs, $1)=yes - if test "$GCC" = yes ; then - output_verbose_link_cmd='echo' - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -dynamiclib $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring' - _LT_AC_TAGVAR(module_cmds, $1)='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags' - # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin ld's - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -dynamiclib $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' - _LT_AC_TAGVAR(module_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' - else - case $cc_basename in - xlc*) - output_verbose_link_cmd='echo' - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`echo $rpath/$soname` $verstring' - _LT_AC_TAGVAR(module_cmds, $1)='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags' - # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin ld's - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}$rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' - _LT_AC_TAGVAR(module_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' - ;; - *) - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - esac - fi - ;; - - dgux*) - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - - freebsd1*) - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - - # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor - # support. Future versions do this automatically, but an explicit c++rt0.o - # does not break anything, and helps significantly (at the cost of a little - # extra space). - freebsd2.2*) - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o' - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' - _LT_AC_TAGVAR(hardcode_direct, $1)=yes - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - - # Unfortunately, older versions of FreeBSD 2 do not have this feature. - freebsd2*) - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' - _LT_AC_TAGVAR(hardcode_direct, $1)=yes - _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - - # FreeBSD 3 and greater uses gcc -shared to do shared libraries. - freebsd* | kfreebsd*-gnu | dragonfly*) - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -o $lib $libobjs $deplibs $compiler_flags' - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' - _LT_AC_TAGVAR(hardcode_direct, $1)=yes - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - - hpux9*) - if test "$GCC" = yes; then - _LT_AC_TAGVAR(archive_cmds, $1)='$rm $output_objdir/$soname~$CC -shared -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' - else - _LT_AC_TAGVAR(archive_cmds, $1)='$rm $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' - fi - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: - _LT_AC_TAGVAR(hardcode_direct, $1)=yes - - # hardcode_minus_L: Not really in the search PATH, - # but as the default location of the library. - _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes - _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' - ;; - - hpux10* | hpux11*) - if test "$GCC" = yes -a "$with_gnu_ld" = no; then - case "$host_cpu" in - hppa*64*|ia64*) - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' - ;; - *) - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' - ;; - esac - else - case "$host_cpu" in - hppa*64*|ia64*) - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -b +h $soname -o $lib $libobjs $deplibs $linker_flags' - ;; - *) - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' - ;; - esac - fi - if test "$with_gnu_ld" = no; then - case "$host_cpu" in - hppa*64*) - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' - _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='+b $libdir' - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: - _LT_AC_TAGVAR(hardcode_direct, $1)=no - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - ia64*) - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_AC_TAGVAR(hardcode_direct, $1)=no - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - - # hardcode_minus_L: Not really in the search PATH, - # but as the default location of the library. - _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes - ;; - *) - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: - _LT_AC_TAGVAR(hardcode_direct, $1)=yes - _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' - - # hardcode_minus_L: Not really in the search PATH, - # but as the default location of the library. - _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes - ;; - esac - fi - ;; - - irix5* | irix6* | nonstopux*) - if test "$GCC" = yes; then - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' - else - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -shared $libobjs $deplibs $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' - _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='-rpath $libdir' - fi - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: - _LT_AC_TAGVAR(link_all_deplibs, $1)=yes - ;; - - netbsd*) - if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out - else - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF - fi - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' - _LT_AC_TAGVAR(hardcode_direct, $1)=yes - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - - newsos6) - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - _LT_AC_TAGVAR(hardcode_direct, $1)=yes - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - - openbsd*) - _LT_AC_TAGVAR(hardcode_direct, $1)=yes - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols' - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' - _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' - else - case $host_os in - openbsd[[01]].* | openbsd2.[[0-7]] | openbsd2.[[0-7]].*) - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' - ;; - *) - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' - ;; - esac - fi - ;; - - os2*) - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes - _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported - _LT_AC_TAGVAR(archive_cmds, $1)='$echo "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$echo "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~$echo DATA >> $output_objdir/$libname.def~$echo " SINGLE NONSHARED" >> $output_objdir/$libname.def~$echo EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def' - _LT_AC_TAGVAR(old_archive_From_new_cmds, $1)='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def' - ;; - - osf3*) - if test "$GCC" = yes; then - _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' - else - _LT_AC_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' - fi - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: - ;; - - osf4* | osf5*) # as osf3* with the addition of -msym flag - if test "$GCC" = yes; then - _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' - else - _LT_AC_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linker_flags -msym -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; echo "-hidden">> $lib.exp~ - $LD -shared${allow_undefined_flag} -input $lib.exp $linker_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib~$rm $lib.exp' - - # Both c and cxx compiler support -rpath directly - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' - fi - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: - ;; - - sco3.2v5*) - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport' - runpath_var=LD_RUN_PATH - hardcode_runpath_var=yes - ;; - - solaris*) - _LT_AC_TAGVAR(no_undefined_flag, $1)=' -z text' - if test "$GCC" = yes; then - wlarc='${wl}' - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ - $CC -shared ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$rm $lib.exp' - else - wlarc='' - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ - $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp' - fi - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - case $host_os in - solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; - *) - # The compiler driver will combine linker options so we - # cannot just pass the convience library names through - # without $wl, iff we do not link with $LD. - # Luckily, gcc supports the same syntax we need for Sun Studio. - # Supported since Solaris 2.6 (maybe 2.5.1?) - case $wlarc in - '') - _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract' ;; - *) - _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}-z ${wl}defaultextract' ;; - esac ;; - esac - _LT_AC_TAGVAR(link_all_deplibs, $1)=yes - ;; - - sunos4*) - if test "x$host_vendor" = xsequent; then - # Use $CC to link under sequent, because it throws in some extra .o - # files that make .init and .fini sections work. - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags' - else - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags' - fi - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_AC_TAGVAR(hardcode_direct, $1)=yes - _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - - sysv4) - case $host_vendor in - sni) - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - _LT_AC_TAGVAR(hardcode_direct, $1)=yes # is this really true??? - ;; - siemens) - ## LD is ld it makes a PLAMLIB - ## CC just makes a GrossModule. - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -o $lib $libobjs $deplibs $linker_flags' - _LT_AC_TAGVAR(reload_cmds, $1)='$CC -r -o $output$reload_objs' - _LT_AC_TAGVAR(hardcode_direct, $1)=no - ;; - motorola) - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - _LT_AC_TAGVAR(hardcode_direct, $1)=no #Motorola manual says yes, but my tests say they lie - ;; - esac - runpath_var='LD_RUN_PATH' - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - - sysv4.3*) - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='-Bexport' - ;; - - sysv4*MP*) - if test -d /usr/nec; then - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - runpath_var=LD_RUN_PATH - hardcode_runpath_var=yes - _LT_AC_TAGVAR(ld_shlibs, $1)=yes - fi - ;; - - sysv4.2uw2*) - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -o $lib $libobjs $deplibs $linker_flags' - _LT_AC_TAGVAR(hardcode_direct, $1)=yes - _LT_AC_TAGVAR(hardcode_minus_L, $1)=no - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - hardcode_runpath_var=yes - runpath_var=LD_RUN_PATH - ;; - - sysv5OpenUNIX8* | sysv5UnixWare7* | sysv5uw[[78]]* | unixware7*) - _LT_AC_TAGVAR(no_undefined_flag, $1)='${wl}-z ${wl}text' - if test "$GCC" = yes; then - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' - else - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' - fi - runpath_var='LD_RUN_PATH' - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - - sysv5*) - _LT_AC_TAGVAR(no_undefined_flag, $1)=' -z text' - # $CC -shared without GNU ld will not create a library from C++ - # object files and a static libstdc++, better avoid it by now - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ - $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp' - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)= - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - runpath_var='LD_RUN_PATH' - ;; - - uts4*) - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - - *) - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - esac - fi -]) -AC_MSG_RESULT([$_LT_AC_TAGVAR(ld_shlibs, $1)]) -test "$_LT_AC_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no - -variables_saved_for_relink="PATH $shlibpath_var $runpath_var" -if test "$GCC" = yes; then - variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" -fi - -# -# Do we need to explicitly link libc? -# -case "x$_LT_AC_TAGVAR(archive_cmds_need_lc, $1)" in -x|xyes) - # Assume -lc should be added - _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes - - if test "$enable_shared" = yes && test "$GCC" = yes; then - case $_LT_AC_TAGVAR(archive_cmds, $1) in - *'~'*) - # FIXME: we may have to deal with multi-command sequences. - ;; - '$CC '*) - # Test whether the compiler implicitly links with -lc since on some - # systems, -lgcc has to come before -lc. If gcc already passes -lc - # to ld, don't add -lc before -lgcc. - AC_MSG_CHECKING([whether -lc should be explicitly linked in]) - $rm conftest* - printf "$lt_simple_compile_test_code" > conftest.$ac_ext - - if AC_TRY_EVAL(ac_compile) 2>conftest.err; then - soname=conftest - lib=conftest - libobjs=conftest.$ac_objext - deplibs= - wl=$_LT_AC_TAGVAR(lt_prog_compiler_wl, $1) - compiler_flags=-v - linker_flags=-v - verstring= - output_objdir=. - libname=conftest - lt_save_allow_undefined_flag=$_LT_AC_TAGVAR(allow_undefined_flag, $1) - _LT_AC_TAGVAR(allow_undefined_flag, $1)= - if AC_TRY_EVAL(_LT_AC_TAGVAR(archive_cmds, $1) 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1) - then - _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no - else - _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes - fi - _LT_AC_TAGVAR(allow_undefined_flag, $1)=$lt_save_allow_undefined_flag - else - cat conftest.err 1>&5 - fi - $rm conftest* - AC_MSG_RESULT([$_LT_AC_TAGVAR(archive_cmds_need_lc, $1)]) - ;; - esac - fi - ;; -esac -])# AC_LIBTOOL_PROG_LD_SHLIBS - - -# _LT_AC_FILE_LTDLL_C -# ------------------- -# Be careful that the start marker always follows a newline. -AC_DEFUN([_LT_AC_FILE_LTDLL_C], [ -# /* ltdll.c starts here */ -# #define WIN32_LEAN_AND_MEAN -# #include <windows.h> -# #undef WIN32_LEAN_AND_MEAN -# #include <stdio.h> -# -# #ifndef __CYGWIN__ -# # ifdef __CYGWIN32__ -# # define __CYGWIN__ __CYGWIN32__ -# # endif -# #endif -# -# #ifdef __cplusplus -# extern "C" { -# #endif -# BOOL APIENTRY DllMain (HINSTANCE hInst, DWORD reason, LPVOID reserved); -# #ifdef __cplusplus -# } -# #endif -# -# #ifdef __CYGWIN__ -# #include <cygwin/cygwin_dll.h> -# DECLARE_CYGWIN_DLL( DllMain ); -# #endif -# HINSTANCE __hDllInstance_base; -# -# BOOL APIENTRY -# DllMain (HINSTANCE hInst, DWORD reason, LPVOID reserved) -# { -# __hDllInstance_base = hInst; -# return TRUE; -# } -# /* ltdll.c ends here */ -])# _LT_AC_FILE_LTDLL_C - - -# _LT_AC_TAGVAR(VARNAME, [TAGNAME]) -# --------------------------------- -AC_DEFUN([_LT_AC_TAGVAR], [ifelse([$2], [], [$1], [$1_$2])]) - - -# old names -AC_DEFUN([AM_PROG_LIBTOOL], [AC_PROG_LIBTOOL]) -AC_DEFUN([AM_ENABLE_SHARED], [AC_ENABLE_SHARED($@)]) -AC_DEFUN([AM_ENABLE_STATIC], [AC_ENABLE_STATIC($@)]) -AC_DEFUN([AM_DISABLE_SHARED], [AC_DISABLE_SHARED($@)]) -AC_DEFUN([AM_DISABLE_STATIC], [AC_DISABLE_STATIC($@)]) -AC_DEFUN([AM_PROG_LD], [AC_PROG_LD]) -AC_DEFUN([AM_PROG_NM], [AC_PROG_NM]) - -# This is just to silence aclocal about the macro not being used -ifelse([AC_DISABLE_FAST_INSTALL]) - -AC_DEFUN([LT_AC_PROG_GCJ], -[AC_CHECK_TOOL(GCJ, gcj, no) - test "x${GCJFLAGS+set}" = xset || GCJFLAGS="-g -O2" - AC_SUBST(GCJFLAGS) -]) - -AC_DEFUN([LT_AC_PROG_RC], -[AC_CHECK_TOOL(RC, windres, no) -]) - -############################################################ -# NOTE: This macro has been submitted for inclusion into # -# GNU Autoconf as AC_PROG_SED. When it is available in # -# a released version of Autoconf we should remove this # -# macro and use it instead. # -############################################################ -# LT_AC_PROG_SED -# -------------- -# Check for a fully-functional sed program, that truncates -# as few characters as possible. Prefer GNU sed if found. -AC_DEFUN([LT_AC_PROG_SED], -[AC_MSG_CHECKING([for a sed that does not truncate output]) -AC_CACHE_VAL(lt_cv_path_SED, -[# Loop through the user's path and test for sed and gsed. -# Then use that list of sed's as ones to test for truncation. -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for lt_ac_prog in sed gsed; do - for ac_exec_ext in '' $ac_executable_extensions; do - if $as_executable_p "$as_dir/$lt_ac_prog$ac_exec_ext"; then - lt_ac_sed_list="$lt_ac_sed_list $as_dir/$lt_ac_prog$ac_exec_ext" - fi - done - done -done -lt_ac_max=0 -lt_ac_count=0 -# Add /usr/xpg4/bin/sed as it is typically found on Solaris -# along with /bin/sed that truncates output. -for lt_ac_sed in $lt_ac_sed_list /usr/xpg4/bin/sed; do - test ! -f $lt_ac_sed && continue - cat /dev/null > conftest.in - lt_ac_count=0 - echo $ECHO_N "0123456789$ECHO_C" >conftest.in - # Check for GNU sed and select it if it is found. - if "$lt_ac_sed" --version 2>&1 < /dev/null | grep 'GNU' > /dev/null; then - lt_cv_path_SED=$lt_ac_sed - break - fi - while true; do - cat conftest.in conftest.in >conftest.tmp - mv conftest.tmp conftest.in - cp conftest.in conftest.nl - echo >>conftest.nl - $lt_ac_sed -e 's/a$//' < conftest.nl >conftest.out || break - cmp -s conftest.out conftest.nl || break - # 10000 chars as input seems more than enough - test $lt_ac_count -gt 10 && break - lt_ac_count=`expr $lt_ac_count + 1` - if test $lt_ac_count -gt $lt_ac_max; then - lt_ac_max=$lt_ac_count - lt_cv_path_SED=$lt_ac_sed - fi - done -done -]) -SED=$lt_cv_path_SED -AC_MSG_RESULT([$SED]) -]) diff --git a/m4/macosx.m4 b/m4/macosx.m4 new file mode 100644 index 000000000..1c1becd2e --- /dev/null +++ b/m4/macosx.m4 @@ -0,0 +1,58 @@ +AC_DEFUN([MACOSX_UNIVERSAL_BINARIES], [ + AC_ARG_ENABLE([macosx-universal], + AS_HELP_STRING([--enable-macosx-universal], [build universal binaries for Mac OS X)]), + [], [enable_macosx_universal="no"]) + if test x"$enable_macosx_universal" != x"no" ; then + case "$host_os" in + *darwin*) + dnl x64_64 and ppc64 binaries could also be built, but there is no + dnl version of Mac OS X currently shipping that can run them, so + dnl do not enable them by default for now. + if test x"$enable_macosx_universal" = x"yes" ; then + UNIVERSAL_ARCHES="i386 ppc" + else + UNIVERSAL_ARCHES=`echo "$enable_macosx_universal" | sed -e 's/,/ /g'` + fi + ;; + *) + AC_MSG_ERROR([Universal binaries can only be built on Darwin]) + ;; + esac + + UNIVERSAL_CFLAGS="$UNIVERSAL_CFLAGS -isysroot /Developer/SDKs/MacOSX10.4u.sdk" + UNIVERSAL_LDFLAGS="$UNIVERSAL_LDFLAGS -Wl,-syslibroot,/Developer/SDKs/MacOSX10.4u.sdk" + if test x"$UNIVERSAL_ARCHES" != x"" ; then + # Forcibly disable dependency tracking for Universal builds, because -M + # does not work with multiple -arch arguments on the gcc command-line. + ac_tool_warned=yes + cross_compiling=yes + enable_dependency_tracking=no + host="`echo $host | sed -e s/$host_cpu/universal/g`" + host_cpu=universal + + AC_DEFINE(XINE_MACOSX_UNIVERSAL_BINARY, 1, [Define this if a universal binary is being built for Mac OS X]) + for arch in $UNIVERSAL_ARCHES ; do + UNIVERSAL_CFLAGS="$UNIVERSAL_CFLAGS -arch $arch" + UNIVERSAL_LDFLAGS="$UNIVERSAL_LDFLAGS -arch $arch" + done + fi + fi + AM_CONDITIONAL([MACOSX_UNIVERSAL_BINARY], [test x"$enable_macosx_universal" = x"yes"]) + AC_SUBST(UNIVERSAL_ARCHES) + AC_SUBST(UNIVERSAL_CFLAGS) + AC_SUBST(UNIVERSAL_LDFLAGS) +])dnl MACOSX_UNIVERSAL_BINARIES + +AC_DEFUN([MACOSX_AUDIO_SUPPORT], [ + AC_ARG_ENABLE([coreaudio], + AS_HELP_STRING([--enable-coreaudio], [enable support for Mac OS X CoreAudio output]), + [have_coreaudio="$enableval"], [have_coreaudio="no"]) + AM_CONDITIONAL([HAVE_COREAUDIO], [test x"$have_coreaudio" = x"yes"]) +])dnl MACOSX_AUDIO_SUPPORT + +AC_DEFUN([MACOSX_VIDEO_SUPPORT], [ + AC_ARG_ENABLE([macosx-video], + AS_HELP_STRING([--enable-macosx-video], [enable support for Mac OS X OpenGL video output]), + [have_macosx_video="$enableval"], [have_macosx_video="no"]) + AM_CONDITIONAL([HAVE_MACOSX_VIDEO], [test x"$have_macosx_video" = x"yes"]) +])dnl MACOSX_VIDEO_SUPPORT diff --git a/m4/objc.m4 b/m4/objc.m4 new file mode 100644 index 000000000..1e3b3cb41 --- /dev/null +++ b/m4/objc.m4 @@ -0,0 +1,194 @@ +# Extracted from autoconf 2.61 to obtain Objective C macros. + +# This file is part of Autoconf. -*- Autoconf -*- +# Programming languages support. +# Copyright (C) 2001, 2002, 2003, 2004, 2005, 2006 Free Software +# Foundation, Inc. +# +# This program is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 2, or (at your option) +# any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program; if not, write to the Free Software +# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA +# 02110-1301, USA. +# +# As a special exception, the Free Software Foundation gives unlimited +# permission to copy, distribute and modify the configure scripts that +# are the output of Autoconf. You need not follow the terms of the GNU +# General Public License when using or distributing such scripts, even +# though portions of the text of Autoconf appear in them. The GNU +# General Public License (GPL) does govern all other use of the material +# that constitutes the Autoconf program. +# +# Certain portions of the Autoconf source text are designed to be copied +# (in certain cases, depending on the input) into the output of +# Autoconf. We call these the "data" portions. The rest of the Autoconf +# source text consists of comments plus executable code that decides which +# of the data portions to output in any given case. We call these +# comments and executable code the "non-data" portions. Autoconf never +# copies any of the non-data portions into its output. +# +# This special exception to the GPL applies to versions of Autoconf +# released by the Free Software Foundation. When you make and +# distribute a modified version of Autoconf, you may extend this special +# exception to the GPL to apply to your modified version as well, *unless* +# your modified version has the potential to copy into its output some +# of the text that was the non-data portion of the version that you started +# with. (In other words, unless your change moves or copies text from +# the non-data portions to the data portions.) If your modification has +# such potential, you must delete any notice of this special exception +# to the GPL from your modified version. +# +# Written by David MacKenzie, with help from +# Akim Demaille, Paul Eggert, +# Franc,ois Pinard, Karl Berry, Richard Pixley, Ian Lance Taylor, +# Roland McGrath, Noah Friedman, david d zuhn, and many others. + +# ------------------------------ # +# 3d. The Objective C compiler. # +# ------------------------------ # + +m4_ifdef([AC_PROG_OBJCPP], [], [ + +dnl Commented out, because aclocal freaks out about the ()'s +dnl # AC_LANG_PREPROC(Objective C) +dnl # ---------------------------- +dnl # Find the Objective C preprocessor. Must be AC_DEFUN'd to be AC_REQUIRE'able. +dnl AC_DEFUN([AC_LANG_PREPROC(Objective C)], +dnl [AC_REQUIRE([AC_PROG_OBJCPP])]) + + +# AC_PROG_OBJCPP +# -------------- +# Find a working Objective C preprocessor. +AC_DEFUN([AC_PROG_OBJCPP], +[AC_REQUIRE([AC_PROG_OBJC])dnl +AC_ARG_VAR([OBJCPP], [Objective C preprocessor])dnl +_AC_ARG_VAR_CPPFLAGS()dnl +AC_LANG_PUSH(Objective C)dnl +AC_MSG_CHECKING([how to run the Objective C preprocessor]) +if test -z "$OBJCPP"; then + AC_CACHE_VAL(ac_cv_prog_OBJCPP, + [dnl + # Double quotes because OBJCPP needs to be expanded + for OBJCPP in "$OBJC -E" "/lib/cpp" + do + _AC_PROG_PREPROC_WORKS_IFELSE([break]) + done + ac_cv_prog_OBJCPP=$OBJCPP + ])dnl + OBJCPP=$ac_cv_prog_OBJCPP +else + ac_cv_prog_OBJCPP=$OBJCPP +fi +AC_MSG_RESULT([$OBJCPP]) +_AC_PROG_PREPROC_WORKS_IFELSE([], + [AC_MSG_FAILURE([Objective C preprocessor "$OBJCPP" fails sanity check])]) +AC_SUBST(OBJCPP)dnl +AC_LANG_POP(Objective C)dnl +])# AC_PROG_OBJCPP + +])dnl m4_ifdef([AC_PROG_OBJCPP]) + + +m4_ifdef([AC_PROG_OBJC], [], [ + +dnl Commented out, because aclocal freaks out about the ()'s +dnl # AC_LANG_COMPILER(Objective C) +dnl # ----------------------------- +dnl # Find the Objective C compiler. Must be AC_DEFUN'd to be AC_REQUIRE'able. +dnl AC_DEFUN([AC_LANG_COMPILER(Objective C)], +dnl [AC_REQUIRE([AC_PROG_OBJC])]) + + + +# AC_PROG_OBJC([LIST-OF-COMPILERS]) +# --------------------------------- +# LIST-OF-COMPILERS is a space separated list of Objective C compilers to +# search for (if not specified, a default list is used). This just gives +# the user an opportunity to specify an alternative search list for the +# Objective C compiler. +# objcc StepStone Objective-C compiler (also "standard" name for OBJC) +# objc David Stes' POC. If you installed this, you likely want it. +# cc Native C compiler (for instance, Apple). +# CC You never know. +AN_MAKEVAR([OBJC], [AC_PROG_OBJC]) +AN_PROGRAM([objcc], [AC_PROG_OBJC]) +AN_PROGRAM([objc], [AC_PROG_OBJC]) +AC_DEFUN([AC_PROG_OBJC], +[AC_LANG_PUSH(Objective C)dnl +AC_ARG_VAR([OBJC], [Objective C compiler command])dnl +AC_ARG_VAR([OBJCFLAGS], [Objective C compiler flags])dnl +_AC_ARG_VAR_LDFLAGS()dnl +_AC_ARG_VAR_LIBS()dnl +_AC_ARG_VAR_CPPFLAGS()dnl +_AC_ARG_VAR_PRECIOUS([OBJC])dnl +AC_CHECK_TOOLS(OBJC, + [m4_default([$1], [gcc objcc objc cc CC])], + gcc) +# Provide some information about the compiler. +_AS_ECHO_LOG([checking for _AC_LANG compiler version]) +ac_compiler=`set X $ac_compile; echo $[2]` +_AC_DO([$ac_compiler --version >&AS_MESSAGE_LOG_FD]) +_AC_DO([$ac_compiler -v >&AS_MESSAGE_LOG_FD]) +_AC_DO([$ac_compiler -V >&AS_MESSAGE_LOG_FD]) + +m4_expand_once([_AC_COMPILER_EXEEXT])[]dnl +m4_expand_once([_AC_COMPILER_OBJEXT])[]dnl +_AC_LANG_COMPILER_GNU +GOBJC=`test $ac_compiler_gnu = yes && echo yes` +_AC_PROG_OBJC_G +AC_LANG_POP(Objective C)dnl +])# AC_PROG_OBJC + + +# _AC_PROG_OBJC_G +# --------------- +# Check whether -g works, even if OBJCFLAGS is set, in case the package +# plays around with OBJCFLAGS (such as to build both debugging and +# normal versions of a library), tasteless as that idea is. +# Don't consider -g to work if it generates warnings when plain compiles don't. +m4_define([_AC_PROG_OBJC_G], +[ac_test_OBJCFLAGS=${OBJCFLAGS+set} +ac_save_OBJCFLAGS=$OBJCFLAGS +AC_CACHE_CHECK(whether $OBJC accepts -g, ac_cv_prog_objc_g, + [ac_save_objc_werror_flag=$ac_objc_werror_flag + ac_objc_werror_flag=yes + ac_cv_prog_objc_g=no + OBJCFLAGS="-g" + _AC_COMPILE_IFELSE([AC_LANG_PROGRAM()], + [ac_cv_prog_objc_g=yes], + [OBJCFLAGS="" + _AC_COMPILE_IFELSE([AC_LANG_PROGRAM()], + [], + [ac_objc_werror_flag=$ac_save_objc_werror_flag + OBJCFLAGS="-g" + _AC_COMPILE_IFELSE([AC_LANG_PROGRAM()], + [ac_cv_prog_objc_g=yes])])]) + ac_objc_werror_flag=$ac_save_objc_werror_flag]) +if test "$ac_test_OBJCFLAGS" = set; then + OBJCFLAGS=$ac_save_OBJCFLAGS +elif test $ac_cv_prog_objc_g = yes; then + if test "$GOBJC" = yes; then + OBJCFLAGS="-g -O2" + else + OBJCFLAGS="-g" + fi +else + if test "$GOBJC" = yes; then + OBJCFLAGS="-O2" + else + OBJCFLAGS= + fi +fi[]dnl +])# _AC_PROG_OBJC_G + +])dnl m4_ifdef([AC_PROG_OBJC]) diff --git a/m4/optimizations.m4 b/m4/optimizations.m4 deleted file mode 100644 index cc5e7c524..000000000 --- a/m4/optimizations.m4 +++ /dev/null @@ -1,259 +0,0 @@ -dnl -dnl M4 macro to add support for extra optimizations -dnl -dnl It understand --enable/--disable-optimizations . -dnl when optimizations are disabled, it does not touch cflags -dnl -dnl Note: always disable while crosscompiling -dnl - -AC_DEFUN([AC_OPTIMIZATIONS], [ - AC_ARG_ENABLE([optimizations], - AS_HELP_STRING([--disable-optimizations], [Don't try to guess what optimization to enable])) - - if test "x$enable_optimizations" != "xno"; then - INLINE_FUNCTIONS=-finline-functions - - if test "$GCC" = yes; then - dnl - dnl check cflags not supported by all gcc versions - AC_TRY_CFLAGS("-fschedule-insns2", f_si="-fschedule-insns2", f_si="") - AC_TRY_CFLAGS("-mwide-multiply", m_wm="-mwide-multiply", m_wm="") - dnl - dnl gcc 3.1 uses the -f version - dnl - AC_TRY_CFLAGS("-falign-functions=4", f_af="-falign-functions=4", - f_af="-malign-functions=4") - AC_TRY_CFLAGS("-falign-loops=4", f_al="-falign-loops=4", - f_al="-malign-loops=4") - AC_TRY_CFLAGS("-falign-jumps=4", f_aj="-falign-jumps=4", - f_aj="-malign-jumps=4") - dnl - dnl Check for some optimization disabling - dnl needed for win32 code - dnl - AC_TRY_CFLAGS("-fno-omit-frame-pointer", W32_NO_OPTIMIZE="$W32_NO_OPTIMIZE -fno-omit-frame-pointer",) - AC_TRY_CFLAGS("-fno-inline-functions", W32_NO_OPTIMIZE="$W32_NO_OPTIMIZE -fno-inline-functions",) - AC_TRY_CFLAGS("-fno-rename-registers", W32_NO_OPTIMIZE="$W32_NO_OPTIMIZE -fno-rename-registers",) - AC_SUBST(W32_NO_OPTIMIZE) - dnl - dnl Multipass compilation - dnl - AC_TRY_CFLAGS("-fprofile-arcs", PASS1_CFLAGS="-fprofile_arcs $PASS1_CFLAGS",) - AC_TRY_CFLAGS("-fbranch-probabilities", PASS2_CFLAGS="-fbranch-probabilities $PASS2_CFLAGS",) - AC_SUBST(PASS1_CFLAGS) - AC_SUBST(PASS2_CFLAGS) - dnl - dnl Warnings - dnl - CFLAGS="-Wchar-subscripts -Wmissing-declarations -Wmissing-prototypes $CFLAGS" - CFLAGS="-Wnested-externs -Wcast-align $CFLAGS" - dnl some combinations of gcc+glibc produce useless warnings on memset - dnl when compiling with -Wpointer-arith, so we check for this first - AC_MSG_CHECKING(for sane -Wpointer-arith) - SAVE_CFLAGS="$CFLAGS" - CFLAGS="-O2 -Wpointer-arith -Werror $CFLAGS" - AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include <string.h>]], [[int a; memset(&a, 0, sizeof(int));]])], - [AC_MSG_RESULT(yes); CFLAGS="-Wpointer-arith $SAVE_CFLAGS"], - [AC_MSG_RESULT(no); CFLAGS="$SAVE_CFLAGS"]); - - dnl gcc 3.3.5 (at least) is known to be buggy wrt optimisation and - dnl -finline-functions. Use -fno-inline-functions for gcc < 3.4.0. - - AC_MSG_CHECKING(for gcc 3.4.0 or later) - newGCC="`"$CC" -dumpversion | - awk -F. '{ if ((@S|@1 * 10000 + @S|@2 * 100 + @S|@3) >= 30400) { print "yes" } }' - `" - AC_MSG_RESULT(${newGCC:-no - assuming bugginess in -finline-functions}) - test "$newGCC" = yes || INLINE_FUNCTIONS=-fno-inline-functions - fi - - dnl Flags not supported by all *cc* variants - AC_TRY_CFLAGS("-Wall", wall="-Wall", wall="") - - CFLAGS="$wall ${CFLAGS}" - DEBUG_CFLAGS="$wall ${DEBUG_CFLAGS}" - - if test "$enable_macosx_universal"; then - optimize_for_host="universal-darwin" - else - optimize_for_host="$host_or_hostalias" - fi - - case "$optimize_for_host" in - i?86-* | k?-* | athlon-* | pentium*) - if test "$GCC" = yes -o "${CC##*/}x" = "iccx" ; then - - if test "$GCC" = yes; then - dnl Check for gcc cpu optimization support - AC_TRY_CFLAGS("-mtune=i386", - sarchopt="-mtune", - AC_TRY_CFLAGS("-mcpu=i386", - sarchopt="-mcpu", - AC_TRY_CFLAGS("-march=i386", - sarchopt="-march", - [ AC_MSG_RESULT(** no cpu optimization supports **) - sarchopt=no - ] - ) - ) - ) - - dnl special check for k7 cpu CC support - AC_TRY_CFLAGS("$sarchopt=athlon", k7cpu="athlon", k7cpu="i686") - - dnl add x86 specific gcc CFLAGS - CFLAGS="-O3 -pipe -fomit-frame-pointer $f_af $f_al $f_aj $m_wm $m_psb -fexpensive-optimizations $f_si -ffast-math $INLINE_FUNCTIONS $CFLAGS" - - DEBUG_CFLAGS="-O $DEBUG_CFLAGS" - - if test x"$sarchopt" != "xno"; then - archopt_val= - - case "$host_or_hostalias" in - i386-*) - archopt_val="i386" ;; - i486-*) - archopt_val="i486" ;; - i586-*) - archopt_val="pentium" - ;; - pentium-mmx-*) - archopt_val="pentium-mmx" - ;; - pentiumpro-* | pentium2-* | i686-*) - archopt_val="pentiumpro" - if test x"$check_athlon" = "xyes"; then - if test -f /proc/cpuinfo; then - modelname=`cat /proc/cpuinfo | grep "model\ name\ :" | sed -e 's/ //g' | cut -d':' -f2` - case "$modelname" in - *Athlon* | *Duron* | *K7*) - archopt_val="$k7cpu" - ;; - VIAEzra) - archopt_val="c3" - ;; - esac - fi - fi - ;; - k6-2-* | k6-3-*) - archopt_val="k6-2" - ;; - k6-*) - archopt_val="k6" - ;; - pentium3-*) - archopt_val="pentium3" - ;; - pentium4-*) - archopt_val="pentium4" - ;; - athlon-4-* | athlon-xp-* | athlon-mp-*) - archopt_val="athlon-4" - ;; - k7-* | athlon-tbird-* | athlon-*) - archopt_val="athlon" - ;; - - esac - if test x"$archopt_val" != x; then - CFLAGS="$sarchopt=$archopt_val $CFLAGS" - DEBUG_CFLAGS="$sarchopt=$archopt_val $DEBUG_CFLAGS" - fi - fi - else - dnl we have the Intel compiler - CFLAGS="-unroll -ipo -ipo_obj -O3 $CFLAGS" - PASS1_CFLAGS="-prof_genx -prof_dir \$(PWD)/\$(top_builddir)/ $PASS1_CFLAGS" - PASS2_CFLAGS="-prof_use -prof_dir \$(PWD)/\$(top_builddir)/ $PASS2_CFLAGS" - AC_SUBST(PASS1_CFLAGS) - AC_SUBST(PASS2_CFLAGS) - fi - - else - dnl add x86 specific cc CFLAGS - CFLAGS="-O $CFLAGS" - DEBUG_CFLAGS="-O $DEBUG_CFLAGS" - AC_DEFINE_UNQUOTED(FPM_64BIT,,[Define to select libmad fixed point arithmetic implementation]) - fi - ;; - alphaev56-*) - CFLAGS="-O3 -mcpu=ev56 -mieee $CFLAGS" - DEBUG_CFLAGS="-O3 -mcpu=ev56 -mieee $DEBUG_CFLAGS" - ;; - alpha*) - CFLAGS="-O3 -mieee $CFLAGS" - DEBUG_CFLAGS="-O3 -mieee $DEBUG_CFLAGS" - ;; - *darwin*) - CFLAGS="-O3 -pipe -fomit-frame-pointer $m_wm $m_psb -fexpensive-optimizations $f_si -ffast-math $INLINE_FUNCTIONS -no-cpp-precomp -D_INTL_REDIRECT_MACROS $CFLAGS" - OBJCFLAGS="-O3 -pipe -fomit-frame-pointer $m_wm $m_psb -fexpensive-optimizations $f_si -ffast-math $INLINE_FUNCTIONS -no-cpp-precomp -D_INTL_REDIRECT_MACROS $CFLAGS" - DEBUG_CFLAGS="-O3 $DEBUG_CFLAGS" - ;; - ppc-*-linux* | powerpc-*) - CFLAGS="-O3 -pipe -fomit-frame-pointer $m_wm $m_psb -fexpensive-optimizations $f_si -ffast-math $INLINE_FUNCTIONS $CFLAGS" - DEBUG_CFLAGS="-O3 $DEBUG_CFLAGS" - ;; - sparc*-*-linux*) - CFLAGS="-O3 $cpu_cflags $INLINE_FUNCTIONS $CFLAGS" - DEBUG_CFLAGS="-O $cpu_cflags $INLINE_FUNCTIONS $DEBUG_CFLAGS" - - case `uname -m` in - sparc) - cpu_cflags="-mcpu=supersparc -mtune=supersparc" ;; - sparc64) - cpu_cflags="-mcpu=ultrasparc -mtune=ultrasparc" ;; - esac - ;; - sparc-*-solaris*) - if test "$GCC" = yes; then - case `uname -m` in - sun4c) cpu_cflags="-mcpu=v7 -mtune=supersparc" ;; - sun4m) cpu_cflags="-mcpu=v8 -mtune=supersparc" ;; - sun4u) - case `$CC --version 2>/dev/null` in - 1.*|2.*) - # -mcpu=ultrasparc triggers a GCC 2.95.x compiler bug when - # compiling video_out.c: - # gcc: Internal compiler error: program cc1 got fatal signal 11 - # avoid -mcpu=ultrasparc with gcc 2.* - cpu_cflags="-mcpu=v8 -mtune=ultrasparc" - ;; - *) - # GCC 3 or newer should have no problem with -mcpu=ultrasparc - cpu_cflags="-mcpu=ultrasparc -mtune=ultrasparc" - ;; - esac - ;; - esac - cc_optimize_cflags="-O3 $cpu_cflags $INLINE_FUNCTIONS" - cc_debug_cflags="-O $cpu_cflags $INLINE_FUNCTIONS" - else - case `uname -m` in - sun4c) cpu_cflags="-xarch=v7" ;; - sun4m) cpu_cflags="-xarch=v8" ;; - sun4u) cpu_cflags="-xarch=v8plusa" ;; - esac - cc_optimize_cflags="-fast $cpu_cflags -xCC" - cc_debug_cflags="-O" - fi - - CFLAGS="$cc_optimize_cflags $CFLAGS" - DEBUG_CFLAGS="$cc_debug_cflags $DEBUG_CFLAGS" - ;; - x86_64-*) - CFLAGS="-O3 -fomit-frame-pointer $m_wm $m_psb -fexpensive-optimizations $f_si -ffast-math $INLINE_FUNCTIONS $CFLAGS" - DEBUG_CFLAGS="-g $DEBUG_CFLAGS" - ;; - armv4l-*-linux*) - CFLAGS="-O2 -fsigned-char -ffast-math -mcpu=strongarm1100 -fomit-frame-pointer -fthread-jumps -fregmove $CFLAGS" - dnl CFLAGS="-O1 -fforce-mem -fforce-addr -fthread-jumps -fcse-follow-jumps -fcse-skip-blocks -fexpensive-optimizations -fregmove -fschedule-insns2 $INLINE_FUNCTIONS -fsigned-char -fomit-frame-pointer -march=armv4 -mtune=strongarm $CFLAGS" - DEBUG_CFLAGS="-O2 $DEBUG_CFLAGS" - ;; - esac - fi -]) - -dnl Kate modeline: leave at the end -dnl kate: indent-width 2; replace-trailing-space-save 1; space-indent 1; backspace-indents 1; diff --git a/m4/pthreads.m4 b/m4/pthreads.m4 index 363a8b4b2..d68cd13c8 100644 --- a/m4/pthreads.m4 +++ b/m4/pthreads.m4 @@ -61,3 +61,28 @@ AC_DEFUN([CC_PTHREAD_FLAGS], [ ifelse([$2], , [:], [$2]) fi ]) + +AC_DEFUN([CC_PTHREAD_RECURSIVE_MUTEX], [ + AC_REQUIRE([CC_PTHREAD_FLAGS]) + AC_MSG_CHECKING([for recursive mutex support in pthread]) + + ac_save_LIBS="$LIBS" + LIBS="$LIBS $PTHREAD_LIBS" + AC_COMPILE_IFELSE(AC_LANG_SOURCE([#include <pthread.h> + +int main() { + pthread_mutexattr_t attr; + pthread_mutexattr_settype(&attr, PTHREAD_MUTEX_RECURSIVE); + return 0; +} + ]), [have_recursive_mutex=yes], [have_recursive_mutex=no]) + LIBS="$ac_save_LIBS" + + AC_MSG_RESULT([$have_recursive_mutex]) + + if test x"$have_recursive_mutex" = x"yes"; then + ifelse([$1], , [:], [$1]) + else + ifelse([$2], , [:], [$2]) + fi +]) diff --git a/m4/summary.m4 b/m4/summary.m4 new file mode 100644 index 000000000..9bebcde27 --- /dev/null +++ b/m4/summary.m4 @@ -0,0 +1,437 @@ +AC_DEFUN([XINE_LIB_SUMMARY], [ + dnl --------------------------------------------- + dnl Some infos: + dnl --------------------------------------------- + + echo "xine-lib summary:" + echo "----------------" + + dnl Input + echo " * input plugins:" + echo " - file - net" + echo " - stdin_fifo - rtp" + echo " - http - mms" + echo " - pnm - rtsp" + echo " - dvb" + if test "x$external_dvdnav" = "xyes"; then + echo " - dvd (external libs)" + else + echo " - dvd (internal libs)" + fi + if test "x$have_cdrom_ioctls" = "xyes"; then + if test "x$enable_vcd" = "xyes"; then + if test "x$internal_vcdnav" = "xno"; then + echo " - vcd (external libs)" + else + echo " - vcd (internal libs)" + fi + fi + echo " - vcdo" + echo " - cdda" + fi + if test "x$no_gnome_vfs" = "xno"; then + echo " - gnome-vfs" + fi + if test "x$have_v4l" = "xyes"; then + echo " - v4l" + fi + if test "x$have_libsmbclient" = "xyes"; then + echo " - smbclient" + fi + echo "" + + dnl Demuxers + echo " * demultiplexer plugins:" + echo " - avi - mpeg" + echo " - mpeg_block - mpeg_audio" + echo " - mpeg_elem - mpeg_pes" + echo " - mpeg_ts - qt/mpeg-4" + echo " - film - roq" + echo " - fli - smjpeg" + echo " - idcin - wav" + echo " - wc3 mve - voc" + echo " - vqa - aiff" + echo " - cdda - snd/au" + echo " - yuv4mpeg2 - real/realaudio" + echo " - ea wve - raw dv" + echo " - interplay mve - psx str" + echo " - ws aud - pva" + echo " - vox - nsf" + echo " - nsv - 4xm" + echo " - FLAC - aac" + echo " - iff - matroska" + echo " - vmd - flv" + if test "x$enable_asf" = "xyes"; then + echo " - asf" + fi + if test "x$have_vorbis" = "xyes"; then + echo " - ogg" + fi + if test "x$have_libmng" = "xyes"; then + echo " - mng" + fi + if test "x$enable_modplug" != x"no"; then + echo " - mod" + fi + if test "x$have_libflac" = "xyes"; then + echo " - FLAC (with libFLAC)" + fi + if test "x$have_wavpack" = "xyes"; then + echo " - WavPack" + fi + if test "x$enable_a52dec" = "xyes"; then + if test "x$have_a52" = "xyes"; then + echo " - ac3 (external library)" + else + echo " - ac3 (internal library)" + fi + fi + echo "" + + dnl video decoders + echo " * video decoder plugins:" + echo " - MPEG 1,2 - Amiga Bitplane" + echo " - Raw RGB - Raw YUV" + if test "x$with_external_ffmpeg" = "xyes"; then + echo " - ffmpeg (external library):" + else + echo " - ffmpeg (internal library):" + fi + echo " - MPEG-4 (ISO, Microsoft, DivX*, XviD)" + echo " - Creative YUV - Motion JPEG" + echo " - Cinepak - MS Video-1" + echo " - FLI/FLC - MS RLE" + echo " - Id RoQ - Id Cin" + echo " - Apple Graphics - Apple Video" + echo " - Apple Animation - Interplay Video" + echo " - Westwood VQA - Origin Xan" + echo " - H.263 - Intel Indeo 3" + echo " - SVQ1 - SVQ3" + echo " - Real Video 1.0 - Real Video 2.0" + echo " - 4X Video - Sierra Video" + echo " - Asus v1/v2 - HuffYUV" + echo " - On2 VP3 - DV" + echo " - 8BPS - Duck TrueMotion v1" + echo " - ATI VCR1 - Flash Video" + echo " - ZLIB - MSZH" + if test "x$have_dxr3" = "xyes"; then + echo " - dxr3_video" + fi + if test "x$enable_w32dll" = "xyes"; then + echo " - w32dll" + fi + if test "x$have_imagemagick" = "xyes"; then + echo " - image" + fi + if test x"no_gdkpixbuf" != "xyes"; then + echo " - gdk-pixbuf" + fi + if test "x$have_theora" = "xyes"; then + echo " - theora" + fi + echo "" + + dnl audio decoders + echo " * audio decoder plugins:" + echo " - GSM 06.10" + echo " - linear PCM - Nosefart (NSF)" + if test "x$with_external_ffmpeg" = "xyes"; then + echo " - ffmpeg (external library):" + else + echo " - ffmpeg (internal library):" + fi + echo " - Windows Media Audio v1/v2" + echo " - DV - logarithmic PCM" + echo " - 14k4 - 28k8" + echo " - MS ADPCM - IMA ADPCM" + echo " - XA ADPCM - Game DPCM/ADPCM" + echo " - Mace 3:13 - Mace 6:1" + echo " - FLAC" + if test "x$have_libflac" = "xyes"; then + echo " - FLAC (with libFLAC)" + fi + if test "x$have_vorbis" = "xyes"; then + echo " - vorbis" + fi + if test "x$have_speex" = "xyes"; then + echo " - speex" + fi + if test "x$enable_w32dll" = "xyes"; then + echo " - w32dll" + fi + if test "x$enable_faad" = "xyes"; then + echo " - faad" + fi + if test "x$enable_libmad" = "xyes"; then + if test "x$have_mad" = "xyes"; then + echo " - MAD (MPG 1/2/3) (external library)" + else + echo " - MAD (MPG 1/2/3) (internal library)" + fi + fi + if test "x$enable_libdts" = "xyes"; then + if test "x$have_dts" = "xyes"; then + echo " - DTS (external library)" + else + echo " - DTS (internal library)" + fi + fi + if test "x$enable_a52dec" = "xyes"; then + if test "x$have_a52" = "xyes"; then + echo " - A52/ra-dnet (external library)" + else + echo " - A52/ra-dnet (internal library)" + fi + fi + if test "x$enable_musepack" != "xno"; then + if test "x$have_mpcdec" = "xyes"; then + echo " - MusePack (external library)" + else + echo " - MusePack (internal library)" + fi + fi + if test "x$have_wavpack" = "xyes"; then + echo " - WavPack" + fi + echo "" + + dnl spu decoders + echo " * subtitle decoder plugins:" + echo " - spu - spucc" + echo " - spucmml - sputext" + echo " - spudvb" + if test "x$have_dxr3" = "xyes"; then + echo " - dxr3_spu" + fi + echo "" + + dnl post plugins + echo " * post effect plugins:" + echo " * planar video effects:" + echo " - invert - expand" + echo " - eq - eq2" + echo " - boxblur - denoise3d" + echo " - unsharp - tvtime" + echo " * SFX:" + echo " - goom - oscope" + echo " - fftscope - mosaico" + echo "" + + dnl Video plugins + echo " * video driver plugins:" + if test "x$no_x" != "xyes"; then + echo " - XShm (X11 shared memory)" + dnl synfb + if test "x$enable_syncfb" != "xno"; then + echo " - SyncFB (for Matrox G200/G400 cards)" + fi + dnl Xv + if test "x$ac_have_xv" = "xyes"; then + if test "x$ac_have_xv_static" = "xyes"; then + echo " - Xv (XVideo *static*)" + else + echo " - Xv (XVideo *shared*)" + fi + fi + dnl XxMC + if test "x$ac_have_xxmc" = "xyes"; then + if test "x$ac_have_vldxvmc_h" = "xyes"; then + echo " - XxMC (XVideo extended motion compensation)" + else + echo " - XxMC (XVideo motion compensation - vld extensions DISABLED)" + fi + fi + dnl XvMC + if test "x$ac_have_xvmc" = "xyes"; then + echo " - XvMC (XVideo motion compensation)" + fi + if test "x$ac_have_opengl" = "xyes" -a "x$ac_have_glut" = "xyes" -o \ + x$"ac_have_opengl" = "xyes" -a "x$ac_have_glu" = "xyes"; then + echo " - OpenGL" + fi + if test "x$ac_have_sunfb" = "xyes"; then + if test "x$ac_have_sundga" = "xyes"; then + echo " - PGX64 (for Sun XVR100/PGX64/PGX24 cards)" + echo " - PGX32 (for Sun PGX32 cards)" + fi + fi + fi + if test "x$have_xcb" = "xyes"; then + dnl xcb-shm + if test "x$have_xcbshm" = "xyes"; then + echo " - xcb-shm (X shared memory using XCB)" + fi + dnl xcb-xv + if test "x$have_xcbxv" = "xyes"; then + echo " - xcb-xv (XVideo using XCB)" + fi + fi + if test "x$no_aalib" != "xyes"; then + echo " - aa (Ascii ART)" + fi + if test "x$have_caca" = "xyes"; then + echo " - caca (Color AsCii Art)" + fi + if test "x$have_fb" = "xyes"; then + echo " - fb (Linux framebuffer device)" + fi + if test "x$have_sdl" = "xyes"; then + echo " - sdl (Simple DirectMedia Layer)" + fi + if test "x$have_libstk" = "xyes"; then + echo " - stk (Libstk Set-top Toolkit)" + fi + if test "x$have_directfb" = "xyes"; then + echo " - directfb (DirectFB driver)" + fi + if test "x$have_dxr3" = "xyes"; then + if test "x$have_encoder" = "xyes"; then + echo " - dxr3 (Hollywood+ and Creative dxr3, both mpeg and non-mpeg video)" + else + echo " - dxr3 (Hollywood+ and Creative dxr3, mpeg video only)" + fi + fi + if test "x$enable_vidix" = "xyes"; then + echo $ECHO_N " - vidix (" + + if test "x$no_x" != "xyes"; then + echo $ECHO_N "X11" + if test "x$have_fb" = "xyes"; then + echo $ECHO_N " and " + fi + fi + + if test "x$have_fb" = "xyes"; then + echo $ECHO_N "framebuffer" + fi + + echo $ECHO_N " support" + + if test "x$enable_dha_kmod" = "xyes"; then + echo " with dhahelper)" + else + echo ")" + fi + fi + if test "x$have_directx" = "xyes"; then + echo " - directx (DirectX video driver)" + fi + if test "x$have_macosx_video" = "xyes"; then + echo " - Mac OS X OpenGL" + fi + + echo "" + + dnl Audio plugins + echo " * audio driver plugins:" + if test "x$have_ossaudio" = "xyes"; then + echo " - oss (Open Sound System)" + fi + if test "x$have_alsa" = "xyes"; then + echo " - alsa" + fi + if test "x$have_esound" = "xyes"; then + echo " - esd (Enlightened Sound Daemon)" + fi + if test "x$no_arts" != "xyes"; then + echo " - arts (aRts - KDE soundserver)" + fi + if test "x$no_fusionsound" != "xyes"; then + echo " - fusionsound (FusionSound driver)" + fi + if test "x$have_sunaudio" = "xyes"; then + echo " - sun ()" + fi + if test "x$am_cv_have_irixal" = xyes; then + echo " - irixal (Irix audio library)" + fi + if test "x$have_directx" = "xyes"; then + echo " - directx (DirectX audio driver)" + fi + if test "x$have_coreaudio" = "xyes"; then + echo " - CoreAudio (Mac OS X audio driver)" + fi + if test "x$have_pulseaudio" = "xyes"; then + echo " - pulseaudio sound server" + fi + if test "x$have_jack" = "xyes"; then + echo " - Jack" + fi + echo "---" + + + dnl --------------------------------------------- + dnl some user warnings + dnl --------------------------------------------- + + dnl some levels of variable expansion to get final install paths + final_libdir="`eval eval eval eval echo $libdir`" + final_bindir="`eval eval eval eval echo $bindir`" + + if test -r /etc/ld.so.conf && ! grep -x "$final_libdir" /etc/ld.so.conf >/dev/null ; then + if test "$final_libdir" != "/lib" -a "$final_libdir" != "/usr/lib" ; then + if ! echo "$LD_LIBRARY_PATH" | egrep "(:|^)$final_libdir(/?:|/?$)" >/dev/null ; then + echo + echo "****************************************************************" + echo "xine-lib will be installed to $final_libdir" + echo + echo "This path is not mentioned among the linker search paths in your" + echo "/etc/ld.so.conf. This means it is possible that xine-lib will" + echo "not be found when you try to compile or run a program using it." + echo "If this happens, you should add $final_libdir to" + echo "the environment variable LD_LIBRARY_PATH like that:" + echo + echo "export LD_LIBRARY_PATH=$final_libdir:\$LD_LIBRARY_PATH" + echo + echo "Alternatively you can add a line \"$final_libdir\"" + echo "to your /etc/ld.so.conf." + echo "****************************************************************" + echo + fi + fi + fi + + if ! echo "$PATH" | egrep "(:|^)$final_bindir(/?:|/?$)" >/dev/null ; then + echo + echo "****************************************************************" + echo "xine-config will be installed to $final_bindir" + echo + echo "This path is not in your search path. This means it is possible" + echo "that xine-config will not be found when you try to compile a" + echo "program using xine-lib. This will result in build failures." + echo "If this happens, you should add $final_bindir to" + echo "the environment variable PATH like that:" + echo + echo "export PATH=$final_bindir:\$PATH" + echo + echo "Note that this is only needed for compilation. It is not needed" + echo "to have xine-config in your search path at runtime. (Although" + echo "it will not cause any harm either.)" + echo "****************************************************************" + echo + fi + + dnl warn if no X11 plugins will be built + if test "x$no_x" = "xyes"; then + case $host in + *mingw*|*-cygwin) ;; + *-darwin*) ;; + *) + echo + echo "****************************************************************" + echo "WARNING! No X11 output plugins will be built." + echo + echo "For some reason, the requirements for building the X11 video" + echo "output plugins are not met. That means, that you will NOT be" + echo "able to use the resulting xine-lib to watch videos in a window" + echo "on any X11-based display (e.g. your desktop)." + echo + echo "If this is not what you want, provide the necessary X11 build" + echo "dependencies (usually done by installing a package called" + echo "XFree86-devel or similar) and run configure again." + echo "****************************************************************" + echo + ;; + esac + fi +]) diff --git a/m4/vcd.m4 b/m4/vcd.m4 new file mode 100644 index 000000000..917fc5128 --- /dev/null +++ b/m4/vcd.m4 @@ -0,0 +1,230 @@ +AC_DEFUN([VCD_SUPPORT], [ + AC_ARG_ENABLE(vcd, AS_HELP_STRING([--disable-vcd], [do not compile VCD plugin]), + enable_vcd=$enableval, enable_vcd=yes) + +dnl Force build of both vcd plugins, for now. +dnl AC_ARG_ENABLE(vcdo, AS_HELP_STRING([--disable-vcdo], [do not compile old VCD plugin]), +dnl enable_vcdo=$enableval, enable_vcdo=yes) +dnl + enable_vcdo="yes" + + AC_ARG_WITH(internal-vcdlibs, AS_HELP_STRING([--with-internal-vcdlibs], [force using internal libcdio/libvcd/libvcdinfo]), + [internal_vcdnav="$withval"], [internal_vcdnav="no"]) + + if test "x$enable_vcd" = "xyes"; then + dnl empty_array_size + AC_MSG_CHECKING([how to create empty arrays]) + + empty_array_size="xxx" + AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[]], [[struct { int foo; int bar[]; } doo;]])],[empty_array_size=""],[]) + + if test "x$empty_array_size" = "xxxx";then + AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[]], [[struct { int foo; int bar[0]; } doo;]])],[empty_array_size="0"],[]) + fi + + if test "x$empty_array_size" = "xxxx" + then + AC_MSG_ERROR([compiler is unable to creaty empty arrays]) + else + AC_DEFINE_UNQUOTED(EMPTY_ARRAY_SIZE, $empty_array_size, + [what to put between the brackets for empty arrays]) + changequote(`,') + msg="[${empty_array_size}]" + changequote([,]) + AC_MSG_RESULT($msg) + fi + dnl empty_array_size + + if test "x$internal_vcdnav" = "xno" ; then + PKG_CHECK_MODULES([LIBCDIO], [libcdio >= 0.71], [], [internal_vcdnav=yes]) + PKG_CHECK_MODULES([LIBVCDINFO], [libvcdinfo >= 0.7.23], [], [internal_vcdnav=yes]) + if test "x$internal_vcdnav" = "xyes"; then + AC_MSG_RESULT([Use included libcdio/libvcdinfo support]) + fi + fi + + dnl check twice, fallback is internal copy + if test "x$internal_vcdnav" = "xno"; then + AC_DEFINE([HAVE_VCDNAV], [1], [Define this if you use external libcdio/libvcdinfo]) + else + AC_DEFINE_UNQUOTED(HOST_ARCH, "$host_os/$host_cpu", [host os/cpu identifier]) + + AC_DEFINE(_DEVELOPMENT_, [], enable warnings about being development release) + AC_HEADER_STDC + AC_CHECK_HEADERS(sys/stat.h stdint.h glob.h inttypes.h stdbool.h) + + if test "x$ac_cv_header_stdint_h" != "xyes" + then + AC_CHECK_SIZEOF(int, 4) + AC_CHECK_SIZEOF(long, 4) + AC_CHECK_SIZEOF(long long, 8) + fi + + dnl ISOC99_PRAGMA + AC_MSG_CHECKING([whether $CC supports ISOC99 _Pragma()]) + AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[]], [[_Pragma("pack(1)")]])],[ + ISOC99_PRAGMA=yes + AC_DEFINE(HAVE_ISOC99_PRAGMA, [], [Supports ISO _Pragma() macro]) + ],[ISOC99_PRAGMA=no]) + AC_MSG_RESULT($ISOC99_PRAGMA) + + dnl + dnl bitfield order + dnl + AC_MSG_CHECKING([bitfield ordering in structs]) + + dnl basic compile test for all platforms + AC_COMPILE_IFELSE([ +int main() { + struct { char bit_0:1, bit_12:2, bit_345:3, bit_67:2; } +#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ > 4) + __attribute__((packed)) +#endif + bf = { 1,1,1,1 }; + switch (0) case 0: case sizeof(bf) == 1:; + return 0; +} +], [], AC_MSG_ERROR([compiler doesn't support bitfield structs])) + + + dnl run test + AC_RUN_IFELSE([ +int main() { + struct { char bit_0:1, bit_12:2, bit_345:3, bit_67:2; } +#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ > 4) + __attribute__((packed)) +#endif + bf = { 1,1,1,1 }; + if (sizeof (bf) != 1) return 1; + return *((unsigned char*) &bf) != 0x4b; } +], bf_lsbf=1, [ + AC_RUN_IFELSE([ +int main() { + struct { char bit_0:1, bit_12:2, bit_345:3, bit_67:2; } +#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ > 4) + __attribute__((packed)) +#endif + bf = { 1,1,1,1 }; + if (sizeof (bf) != 1) return 1; + return *((unsigned char*) &bf) != 0xa5; } +], bf_lsbf=0, AC_MSG_ERROR([unsupported bitfield ordering])) + ], + [case "$host" in + *-*-mingw32* | *-*-cygwin*) + bf_lsbf=1 + ;; + universal-*-darwin*) + bf_lsbf=0 + ;; + *) + AC_MSG_RESULT([unknown]) + AC_MSG_ERROR([value of bitfield test isn't known for $host +********************************************************************* +Value of bitfield test can't be found out for cross-compiling and we +don't know its value for host "$host". + +Because it's needed for VCD plugin, disable VCD by configure option +--disable-vcd or use external VCD library. +*********************************************************************]) + esac]) + + if test "x$cross_compiling" = "xyes"; then + TEXT=" (guessed)" + else + TEXT="" + fi + if test "x$bf_lsbf" = "x1"; then + AC_MSG_RESULT(LSBF${TEXT}) + AC_DEFINE(BITFIELD_LSBF, [], [compiler does lsbf in struct bitfields]) + else + AC_MSG_RESULT(MSBF${TEXT}) + fi + + AC_CHECK_HEADERS([errno.h fcntl.h \ + stdbool.h stdlib.h stdint.h stdio.h string.h \ + strings.h linux/version.h sys/cdio.h sys/stat.h \ + sys/types.h ]) + + LIBCDIO_CFLAGS='-I$(top_srcdir)/src/input/vcd/libcdio' + LIBCDIO_LIBS='$(top_builddir)/src/input/vcd/libcdio/libcdio.la' + LIBISO9660_LIBS='$(top_builddir)/src/input/vcd/libcdio/libiso9660.la' + LIBVCD_CFLAGS='-I$(top_srcdir)/src/input/vcd/libvcd' + LIBVCD_LIBS='$(top_builddir)/src/input/vcd/libvcd/libvcd.la' + LIBVCDINFO_LIBS='$(top_builddir)/src/input/vcd/libvcd/libvcdinfo.la' + + case $host_os in + darwin*) + AC_CHECK_HEADERS(IOKit/IOKitLib.h CoreFoundation/CFBase.h, [have_iokit_h="yes"]) + if test "x$have_iokit_h" = "xyes" ; then + AC_DEFINE([HAVE_DARWIN_CDROM], [1], [Define 1 if you have Darwin OS X-type CD-ROM support]) + fi + ;; + linux*) + AC_CHECK_HEADERS(linux/version.h) + AC_CHECK_HEADERS(linux/cdrom.h, [have_linux_cdrom_h="yes"]) + if test "x$have_linux_cdrom_h" = "xyes" ; then + AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[]], [[ +#include <linux/cdrom.h> +struct cdrom_generic_command test; +int has_timeout=sizeof(test.timeout);]])], + [AC_DEFINE([HAVE_LINUX_CDROM_TIMEOUT], [1], [Define 1 if timeout is in cdrom_generic_command struct])],[]) + AC_DEFINE([HAVE_LINUX_CDROM], [1], [Define 1 if you have Linux-type CD-ROM support]) + fi + ;; + bsdi*) + AC_CHECK_HEADERS(dvd.h, [have_bsdi_dvd_h="yes"]) + if test "x$have_bsdi_dvd_h" = "xyes" ; then + AC_DEFINE([HAVE_BSDI_CDROM], [1], [Define 1 if you have BSDI-type CD-ROM support]) + fi + ;; + sunos*|sun*|solaris*) + AC_CHECK_HEADERS(sys/cdio.h) + AC_DEFINE([HAVE_SOLARIS_CDROM], [1], [Define 1 if you have Solaris CD-ROM support]) + ;; + cygwin*) + AC_DEFINE([CYGWIN], [1], [Define 1 if you are compiling using cygwin]) + AC_DEFINE([HAVE_WIN32_CDROM], [1], [Define 1 if you have MinGW CD-ROM support]) + LIBCDIO_LIBS="$LIBCDIO_LIBS -lwinmm" + LIBVCD_LIBS="$LIBVCD_LIBS -lwinmm" + ;; + mingw*) + AC_DEFINE([MINGW32], [1], [Define 1 if you are compiling using MinGW]) + AC_DEFINE([HAVE_WIN32_CDROM], [1], [Define 1 if you have MinGW CD-ROM support]) + ;; + freebsd4.*) + AC_DEFINE([HAVE_FREEBSD_CDROM], [1], [Define 1 if you have FreeBSD CD-ROM support]) + ;; + *) + AC_MSG_WARN(Don't have OS CD-reading support for ${host_os}...) + AC_MSG_WARN(Will use generic support.) + ;; + esac + AC_SUBST(LINUX_CDROM_TIMEOUT) + AC_SUBST(HAVE_BSDI_CDROM) + AC_SUBST(HAVE_DARWIN_CDROM) + AC_SUBST(HAVE_FREEBSD_CDROM) + AC_SUBST(HAVE_LINUX_CDROM) + AC_SUBST(HAVE_SOLARIS_CDROM) + AC_SUBST(HAVE_WIN32_CDROM) + AC_SUBST(LINUX_CDROM_TIMEOUT) + AC_SUBST(LIBVCD_SYSDEP) + + AC_CHECK_FUNCS( bzero memcpy ) + + AC_CHECK_MEMBER([struct tm.tm_gmtoff], + [AC_DEFINE(HAVE_TM_GMTOFF, 1, [Define if struct tm has the tm_gmtoff member.])], + [], [#include <time.h>]) + fi + fi + + AC_DEFINE([LIBCDIO_CONFIG_H], 1, [Get of rid system libcdio build configuration]) + AC_DEFINE([EXTERNAL_LIBCDIO_CONFIG_H], 1, [Get of rid system libcdio build configuration]) + AC_SUBST(LIBCDIO_CFLAGS) + AC_SUBST(LIBCDIO_LIBS) + AC_SUBST(LIBISO9660_LIBS) + AC_SUBST(LIBVCD_CFLAGS) + AC_SUBST(LIBVCD_LIBS) + AC_SUBST(LIBVCDINFO_LIBS) + AM_CONDITIONAL(HAVE_VCDNAV, [test "x$internal_vcdnav" = "xno"]) + AM_CONDITIONAL(ENABLE_VCD, [test "x$enable_vcd" = "xyes"]) +]) diff --git a/m4/x11.m4 b/m4/x11.m4 new file mode 100644 index 000000000..d8a951b19 --- /dev/null +++ b/m4/x11.m4 @@ -0,0 +1,54 @@ +dnl --------------------------------------------- +dnl Checks for X11 +dnl --------------------------------------------- + +AC_DEFUN([XINE_X11_SUPPORT], [ + if test "x$with_x" != "xno"; then + PKG_CHECK_MODULES([X], [x11 xext], , [ + AC_PATH_XTRA + + dnl Set xv_path if its not done already + dnl we do it here before rewriting X_LIBS + if test x$xv_path = x; then + xv_path=`echo $X_LIBS | sed -e 's/\-L\(.*\)/\1/'` + fi + + dnl ---------------------------------------------- + dnl Check for XShm support (required with X) + dnl ---------------------------------------------- + + if test "x$no_x" != "xyes"; then + ac_save_CPPFLAGS="$CPPFLAGS" + CPPFLAGS="$CPPFLAGS $X_CFLAGS" + AC_CHECK_HEADERS([X11/extensions/XShm.h], [true], + [AC_MSG_ERROR([XShm extension is required])]) + AC_CHECK_LIB([Xext], [main], [true], + [AC_MSG_ERROR([libXext is required])], [$X_LIBS]) + CPPFLAGS="$ac_save_CPPFLAGS" + X_LIBS="$X_LIBS $X_PRE_LIBS -lX11 -lXext" + fi + ]) + else + no_x="yes" + fi + + if test "x$no_x" != "xyes"; then + AC_DEFINE(HAVE_X11,1,[Define this if you have X11R6 installed]) + fi + AM_CONDITIONAL(HAVE_X11, [test "x$no_x" != "xyes"]) + + + dnl --------------------------------------------- + dnl Locate libraries needed for X health check + dnl --------------------------------------------- + +soname_script="/[[0-9]]$/! d; s%^.*/%% +t q +b +:q +q" + x_lib_location="`ls -1 "${x_libraries:-/usr/local/lib}/libX11.so"* "${x_libraries:-/usr/lib}/libX11.so"* 2>/dev/null | sed -e \"${soname_script}\"`" + AC_DEFINE_UNQUOTED([LIBX11_SO], "${x_lib_location:-libX11.so}", [The soname of libX11, needed for dlopen()]) + x_lib_location="`ls -1 "${x_libraries:-/usr/local/lib}/libXv.so"* "${x_libraries:-/usr/lib}/libXv.so"* 2>/dev/null | sed -e \"${soname_script}\"`" + AC_DEFINE_UNQUOTED([LIBXV_SO], "${x_lib_location:-libXv.so}", [The soname of libXv, needed for dlopen()]) +]) @@ -91,3 +91,194 @@ AC_DEFUN([AC_FIND_LIBXV], AC_TEST_LIBXV fi ]) + +dnl ---------------------------------------------- +dnl Check for Xv and XvMC support +dnl ---------------------------------------------- + +AC_DEFUN([XINE_XV_SUPPORT], [ + dnl With recent XFree86 or Xorg, dynamic linking is preferred! + dnl Only dynamic linking is possible when using libtool < 1.4.0 + + AC_ARG_WITH(xv-path, AS_HELP_STRING([--with-xv-path=path], [where libXv is installed]), + xv_path="$withval",) + + AC_ARG_ENABLE([static-xv], + AS_HELP_STRING([--enable-static-xv],[Enable this to force linking against libXv.a])) + + if test "x$enable_static_xv" = "xyes"; then + xv_prefer_shared="no" + else + xv_prefer_shared="yes" + fi + + if test "x$no_x" != "xyes"; then + PKG_CHECK_MODULES([XV], [xv], [ + ac_have_xv="yes" + AC_DEFINE([HAVE_XV], [1], [Define this if you have libXv installed]) + ], [AC_FIND_LIBXV]) + fi + AM_CONDITIONAL(HAVE_XV, test "x$ac_have_xv" = "xyes") + + + case "$host_or_hostalias" in + hppa*) + if test "x$ac_have_xv_static" = "xyes"; then + echo "warning: hppa linker - disabling static libXv" + XV_LIBS="libXv.so" + fi + ;; + + ppc-*-linux* | powerpc-*) + ppc_arch="yes" + ;; + + *) + ;; + esac + AM_CONDITIONAL(PPC_ARCH, test "x$ppc_arch" = "xyes") + + dnl + dnl Check if we can enable the xxmc plugin. + dnl + + AC_ARG_ENABLE([xvmc], + AS_HELP_STRING([--disable-xvmc], [Disable XxMC and XvMC outplut plugins]) ) + + if test "x$no_x" = "x" && test "x$enable_xvmc" != "xno"; then + + AC_ARG_WITH(xxmc-path, AS_HELP_STRING([--with-xxmc-path=path], [where libXvMC libraries for the + xxmc plugin are installed. Defalts to the default X library path.]), + xxmc_path="$withval", xxmc_path="$x_libraries") + AC_ARG_WITH(xxmc-lib, AS_HELP_STRING([--with-xxmc-lib=XXXX], [The name of the XvMC library + libXXXX.so for the xxmc plugin.]),xxmc_stub="$withval", + xxmc_stub="XvMCW") + + saved_libs="$LIBS" + saved_CPPFLAGS="$CPPFLAGS" + if test "x$x_includes" != "x"; then + CPPFLAGS="$CPPFLAGS -I$x_includes" + fi + + XXMC_LIBS="-L$xxmc_path -l$xxmc_stub" + AC_MSG_CHECKING(whether to enable the xxmc plugin with vld extensions) + AC_MSG_RESULT() + dnl Check if vld "extended" XvMC is available + if test "x$xxmc_stub" == "xXvMCW" && test "x$ac_have_xv" == "xyes"; then + AC_CHECK_LIB($xxmc_stub, XvMCPutSlice, + ac_have_xxmc="yes", + [ac_have_xxmc="no" + AC_MSG_RESULT([*** Could not link with -l$xxmc_stub for vld extensions.])], + [-L$xxmc_path $X_LIBS $X_PRE_LIBS $XV_LIBS -lXext $X_EXTRA_LIBS]) + else + if test "x$ac_have_xv" = "xyes"; then + AC_CHECK_LIB($xxmc_stub, XvMCPutSlice, + [ac_have_xxmc="yes" + XXMC_LIBS="$XXMC_LIBS -lXvMC"], + [ac_have_xxmc="no" + AC_MSG_RESULT([*** Could not link with -l$xxmc_stub -lXvMC for vld extensions.])], + [-L$xxmc_path -lXvMC $X_LIBS $X_PRE_LIBS $XV_LIBS -lXext $X_EXTRA_LIBS]) + else + ac_have_xxmc="no", + fi + fi + + if test "x$ac_have_xxmc" = "xyes"; then + AC_CHECK_HEADERS(X11/extensions/vldXvMC.h, + [ac_have_vldxvmc_h="yes"], + ac_have_vldxvmc="no",) + if test "x$ac_have_vldxvmc_h" = "xyes"; then + AC_DEFINE([HAVE_VLDXVMC], [1], + [Define 1 if you have vldXvMC.h]) + fi + fi + dnl Try fallback to standard XvMC if vld failed + if test "x$ac_have_xxmc" = "xno"; then + if test "x$xxmc_stub" == "xXvMCW"; then + AC_CHECK_LIB($xxmc_stub, XvMCCreateContext, + ac_have_xxmc="yes", + [ac_have_xxmc="no" + AC_MSG_RESULT([*** Could not link with -l$xxmc_stub for standard XvMC.])], + [-L$xxmc_path $X_LIBS $X_PRE_LIBS $XV_LIBS -lXext $X_EXTRA_LIBS]) + else + if test "x$ac_have_xv" = "xyes"; then + AC_CHECK_LIB($xxmc_stub, XvMCCreateContext, + [ac_have_xxmc="yes" + XXMC_LIBS="$XXMC_LIBS -lXvMC"], + [ac_have_xxmc="no" + AC_MSG_RESULT([*** Could not link with -lXvMC for standard XvMC.])], + [-L$xxmc_path -lXvMC $X_LIBS $X_PRE_LIBS $XV_LIBS -lXext $X_EXTRA_LIBS]) + else + ac_have_xxmc="no", + fi + fi + fi + if test "x$ac_have_xxmc" = "xyes"; then + AC_CHECK_HEADERS(X11/extensions/XvMC.h,, + ac_have_xxmc="no",) + fi + if test "x$ac_have_xxmc" = "xyes"; then + AC_DEFINE(HAVE_XXMC,1,[Define this to compile the xxmc plugin.]) + if test "x$ac_have_vldxvmc_h" = "xyes"; then + AC_MSG_RESULT([*** Enabling xxmc plugin with vld extensions.]) + else + AC_MSG_RESULT([*** Enabling xxmc plugin for standard XvMC *only*.]) + fi + else + AC_MSG_RESULT([*** Disabling xxmc plugin due to above errors.]) + fi + LIBS="$saved_libs" + fi + AM_CONDITIONAL(HAVE_VLDXVMC, test "x$ac_have_vldxvmc_h" = "xyes") + AM_CONDITIONAL(HAVE_XXMC, test "x$ac_have_xxmc" = "xyes") + AC_SUBST(XXMC_LIBS) + + dnl + dnl Check if we can enable the xvmc plugin. + dnl + if test "x$no_x" = "x" && test "x$enable_xvmc" != "xno"; then + + AC_ARG_WITH(xvmc-path, AS_HELP_STRING([--with-xvmc-path=path], [where libXvMC libraries for the + xvmc plugin are installed. Defalts to the default X library path.]), + xvmc_path="$withval", xvmc_path="$x_libraries") + AC_ARG_WITH(xvmc-lib, AS_HELP_STRING([--with-xvmc-lib=XXXX], [The name of the XvMC library + libXXXX.so for the xvmc plugin.]),xvmc_stub="$withval", + xvmc_stub="XvMCW") + saved_libs="$LIBS" + XVMC_LIBS="-L$xvmc_path -l$xvmc_stub" + AC_MSG_CHECKING(whether to enable the xvmc plugin) + AC_MSG_RESULT() + if test "x$xvmc_stub" == "xXvMCW"; then + AC_CHECK_LIB($xvmc_stub, XvMCCreateContext, + ac_have_xvmc="yes", + [ac_have_xvmc="no" + AC_MSG_RESULT([*** Could not link with -l$xvmc_stub.])], + [-L$xvmc_path $X_LIBS $X_PRE_LIBS $XV_LIBS -lXext $X_EXTRA_LIBS]) + else + if test "x$ac_have_xv" = "xyes"; then + AC_CHECK_LIB($xvmc_stub, XvMCCreateContext, + [ac_have_xvmc="yes" + XVMC_LIBS="$XVMC_LIBS -lXvMC"], + [ac_have_xvmc="no" + AC_MSG_RESULT([*** Could not link with -lXvMC.])], + [-L$xvmc_path -lXvMC $X_LIBS $X_PRE_LIBS $XV_LIBS -lXext $X_EXTRA_LIBS]) + else + ac_have_xvmc="no", + fi + fi + if test "x$ac_have_xvmc" = "xyes"; then + AC_CHECK_HEADERS(X11/extensions/XvMC.h,, + ac_have_xvmc="no",) + fi + if test "x$ac_have_xvmc" = "xyes"; then + AC_DEFINE(HAVE_XVMC,1,[Define this if you have an XvMC library and XvMC.h installed.]) + AC_MSG_RESULT([*** Enabling old xvmc plugin.]) + else + AC_MSG_RESULT([*** Disabling old xvmc plugin due to above errors.]) + fi + CPPFLAGS="$saved_CPPFLAGS" + LIBS="$saved_libs" + fi + AM_CONDITIONAL(HAVE_XVMC, test "x$ac_have_xvmc" = "xyes") + AC_SUBST(XVMC_LIBS) +]) diff --git a/misc/Makefile.common b/misc/Makefile.common index a3fe43de6..6df3b9228 100644 --- a/misc/Makefile.common +++ b/misc/Makefile.common @@ -41,16 +41,6 @@ pass1: pass2: @$(MAKE) MULTIPASS_CFLAGS="$(PASS2_CFLAGS)" -debug: - @$(MAKE) CFLAGS="$(DEBUG_CFLAGS)" - -install-debug: debug - @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am - @list='$(SUBDIRS)'; for subdir in $$list; do \ - (cd $$subdir && $(MAKE) $@) || exit; \ - done; - $(MAKE) $(AM_MAKEFLAGS) install-data-hook - uninstall-hook: @list='$(xineplug_LTLIBRARIES)'; for p in $$list; do \ p="`echo $$p | sed -e 's/\.la$$/\.so/g;s|^.*/||'`"; \ diff --git a/misc/SlackBuild.in b/misc/SlackBuild.in index d356a1766..118613c6a 100644 --- a/misc/SlackBuild.in +++ b/misc/SlackBuild.in @@ -27,7 +27,7 @@ EOF # do_descr() { cat > package_descriptions << EOF -@PACKAGE@: @PACKAGE@ @SPEC_VERSION@. +@PACKAGE@: @PACKAGE@ @PACKAGE_VERSION@. @PACKAGE@: @PACKAGE@: xine-lib is the beating heart of xine (a free gpl-licensed @PACKAGE@: video player for unix-like systems) which among others provides @@ -53,12 +53,12 @@ do_build() { cd $CWD rm -rf $TMPBUILD mkdir -p $TMPBUILD - cd $TMPBUILD && tar -xzf $CWD/@TAR_NAME@.tar.gz + cd $TMPBUILD && tar -xzf $CWD/@PACKAGE_TARNAME@.tar.gz do_install_sh; - cd @TAR_NAME@ + cd @PACKAGE_TARNAME@ DIE=1 - echo "./configure --prefix=$PREFIX $CONFIG_OPT && make && make install-strip DESTDIR=$PKG LIBRARY_PATH=$TMPBUILD/@TAR_NAME@/src/xine-engine/.libs" && \ - ./configure --prefix=$PREFIX $CONFIG_OPT && make && make install-strip DESTDIR=$PKG LIBRARY_PATH=$TMPBUILD/@TAR_NAME@/src/xine-engine/.libs && \ + echo "./configure --prefix=$PREFIX $CONFIG_OPT && make && make install-strip DESTDIR=$PKG LIBRARY_PATH=$TMPBUILD/@PACKAGE_TARNAME@/src/xine-engine/.libs" && \ + ./configure --prefix=$PREFIX $CONFIG_OPT && make && make install-strip DESTDIR=$PKG LIBRARY_PATH=$TMPBUILD/@PACKAGE_TARNAME@/src/xine-engine/.libs && \ mkdir -p $PKG/install && cp $TMPBUILD/doinst.sh $PKG/install && \ cd $PKG && \ echo "n" | /sbin/makepkg $PACKAGE && \ @@ -172,7 +172,7 @@ main() { build_pentium build_k6 build_k7 - mv -f $CWD/@TAR_NAME@.tar.gz $SLCK + mv -f $CWD/@PACKAGE_TARNAME@.tar.gz $SLCK } @@ -184,7 +184,7 @@ build_arch() { mkdir -p $SLCK rm -f config.cache && ./autogen.sh && make dist $barch - mv -f $CWD/@TAR_NAME@.tar.gz $SLCK + mv -f $CWD/@PACKAGE_TARNAME@.tar.gz $SLCK } case "$1" in diff --git a/misc/build_rpms.sh.in b/misc/build_rpms.sh.in index b3ec065b1..c3096e5f0 100644 --- a/misc/build_rpms.sh.in +++ b/misc/build_rpms.sh.in @@ -44,9 +44,9 @@ export XINE_BUILD=i586-pc-linux-gnu eval $RPM_BA -mv /usr/src/redhat/SRPMS/libxine-@SPEC_VERSION@-$DATE.src.rpm ./rpms/ -mv /usr/src/redhat/RPMS/i386/$PKGNAME-@SPEC_VERSION@-$DATE.i386.rpm ./rpms/$PKGNAME-@SPEC_VERSION@-$DATE.i586.rpm -mv /usr/src/redhat/RPMS/i386/$PKGNAME-devel-@SPEC_VERSION@-$DATE.i386.rpm ./rpms/$PKGNAME-devel-@SPEC_VERSION@-$DATE.i586.rpm +mv /usr/src/redhat/SRPMS/libxine-@PACKAGE_VERSION@-$DATE.src.rpm ./rpms/ +mv /usr/src/redhat/RPMS/i386/$PKGNAME-@PACKAGE_VERSION@-$DATE.i386.rpm ./rpms/$PKGNAME-@PACKAGE_VERSION@-$DATE.i586.rpm +mv /usr/src/redhat/RPMS/i386/$PKGNAME-devel-@PACKAGE_VERSION@-$DATE.i386.rpm ./rpms/$PKGNAME-devel-@PACKAGE_VERSION@-$DATE.i586.rpm echo "*****************************************************" echo @@ -61,7 +61,7 @@ export XINE_BUILD=i686-pc-linux-gnu eval $RPM_BB -mv /usr/src/redhat/RPMS/i386/$PKGNAME-@SPEC_VERSION@-$DATE.i386.rpm ./rpms/$PKGNAME-@SPEC_VERSION@-$DATE.i686.rpm +mv /usr/src/redhat/RPMS/i386/$PKGNAME-@PACKAGE_VERSION@-$DATE.i386.rpm ./rpms/$PKGNAME-@PACKAGE_VERSION@-$DATE.i686.rpm echo "*****************************************************" echo @@ -76,7 +76,7 @@ export XINE_BUILD=k6-pc-linux-gnu eval $RPM_BB -mv /usr/src/redhat/RPMS/i386/$PKGNAME-@SPEC_VERSION@-$DATE.i386.rpm ./rpms/$PKGNAME-@SPEC_VERSION@-$DATE.k6.rpm +mv /usr/src/redhat/RPMS/i386/$PKGNAME-@PACKAGE_VERSION@-$DATE.i386.rpm ./rpms/$PKGNAME-@PACKAGE_VERSION@-$DATE.k6.rpm echo "*****************************************************" echo @@ -91,6 +91,6 @@ export XINE_BUILD=athlon-pc-linux-gnu eval $RPM_BB -mv /usr/src/redhat/RPMS/i386/$PKGNAME-@SPEC_VERSION@-$DATE.i386.rpm ./rpms/$PKGNAME-@SPEC_VERSION@-$DATE.k7.rpm +mv /usr/src/redhat/RPMS/i386/$PKGNAME-@PACKAGE_VERSION@-$DATE.i386.rpm ./rpms/$PKGNAME-@PACKAGE_VERSION@-$DATE.k7.rpm echo "Done." diff --git a/misc/relchk.sh.in b/misc/relchk.sh.in index 242a97486..09cce24b2 100755 --- a/misc/relchk.sh.in +++ b/misc/relchk.sh.in @@ -4,7 +4,7 @@ ## topdir="`pwd`" -distdir="@TAR_NAME@" +distdir="@PACKAGE_TARNAME@" log="$topdir/dist-log" logerror="$topdir/dist-errors" diff --git a/misc/xine-lib.spec.in b/misc/xine-lib.spec.in index 2b182e8ad..6c5d9b96c 100644 --- a/misc/xine-lib.spec.in +++ b/misc/xine-lib.spec.in @@ -1,6 +1,6 @@ %define shortname libxine %define name libxine2 -%define version @SPEC_VERSION@ +%define version @PACKAGE_VERSION@ %define release 0 %define major 1 @@ -642,7 +642,7 @@ libxine Soundausgabeplugin für den jack-Soundserver %endif %prep -%setup -q -n @TAR_NAME@ +%setup -q -n @PACKAGE_TARNAME@ %build export CFLAGS="${RPM_OPT_FLAGS}" diff --git a/po/Makefile.in.in b/po/Makefile.in.in index 2b9a10dc5..582cfc0a5 100644 --- a/po/Makefile.in.in +++ b/po/Makefile.in.in @@ -385,9 +385,6 @@ Makefile: Makefile.in.in Makevars $(top_builddir)/config.status @POMAKEFILEDEPS@ && CONFIG_FILES=$(subdir)/$@.in CONFIG_HEADERS= \ $(SHELL) ./config.status -debug: -install-debug: - force: # Tell versions [3.59,3.63) of GNU make not to export all variables. diff --git a/src/audio_out/Makefile.am b/src/audio_out/Makefile.am index 20a4e708b..d9b44557e 100644 --- a/src/audio_out/Makefile.am +++ b/src/audio_out/Makefile.am @@ -1,6 +1,7 @@ include $(top_srcdir)/misc/Makefile.common -AM_CPPFLAGS = -DXINE_COMPILE +AM_CFLAGS = $(DEFAULT_OCFLAGS) $(VISIBILITY_FLAG) +AM_LDFLAGS = $(xineplug_ldflags) EXTRA_DIST = audio_irixal_out.c @@ -70,77 +71,52 @@ xineplug_LTLIBRARIES = xineplug_ao_out_none.la xineplug_ao_out_file.la \ xineplug_ao_out_none_la_SOURCES = audio_none_out.c xineplug_ao_out_none_la_LIBADD = $(XINE_LIB) -xineplug_ao_out_none_la_CFLAGS = $(VISIBILITY_FLAG) -xineplug_ao_out_none_la_LDFLAGS = -avoid-version -module xineplug_ao_out_file_la_SOURCES = audio_file_out.c xineplug_ao_out_file_la_LIBADD = $(XINE_LIB) -xineplug_ao_out_file_la_CFLAGS = $(VISIBILITY_FLAG) -xineplug_ao_out_file_la_LDFLAGS = -avoid-version -module xineplug_ao_out_oss_la_SOURCES = audio_oss_out.c xineplug_ao_out_oss_la_LIBADD = $(XINE_LIB) -xineplug_ao_out_oss_la_CFLAGS = $(VISIBILITY_FLAG) -xineplug_ao_out_oss_la_LDFLAGS = -avoid-version -module xineplug_ao_out_alsa_la_SOURCES = audio_alsa_out.c xineplug_ao_out_alsa_la_LIBADD = $(ALSA_LIBS) $(XINE_LIB) $(PTHREAD_LIBS) -xineplug_ao_out_alsa_la_CFLAGS = $(VISIBILITY_FLAG) $(ALSA_CFLAGS) -xineplug_ao_out_alsa_la_LDFLAGS = -avoid-version -module +xineplug_ao_out_alsa_la_CFLAGS = $(AM_CFLAGS) $(ALSA_CFLAGS) xineplug_ao_out_esd_la_SOURCES = audio_esd_out.c xineplug_ao_out_esd_la_LIBADD = $(ESD_LIBS) $(XINE_LIB) -xineplug_ao_out_esd_la_CFLAGS = $(VISIBILITY_FLAG) $(ESD_CFLAGS) -xineplug_ao_out_esd_la_LDFLAGS = -avoid-version -module +xineplug_ao_out_esd_la_CFLAGS = $(AM_CFLAGS) $(ESD_CFLAGS) xineplug_ao_out_sun_la_SOURCES = audio_sun_out.c xineplug_ao_out_sun_la_LIBADD = $(XINE_LIB) -xineplug_ao_out_sun_la_CFLAGS = $(VISIBILITY_FLAG) -xineplug_ao_out_sun_la_LDFLAGS = -avoid-version -module #xineplug_ao_out_irixal_la_SOURCES = audio_irixal_out.c #xineplug_ao_out_irixal_la_LIBADD = $(IRIXAL_LIBS) -#xineplug_ao_out_irixal_la_CFLAGS = $(VISIBILITY_FLAG) $(IRIXAL_CFLAGS) -#xineplug_ao_out_irixal_la_LDFLAGS = -avoid-version -module +#xineplug_ao_out_irixal_la_CFLAGS = $(AM_CFLAGS) $(IRIXAL_CFLAGS) xineplug_ao_out_arts_la_SOURCES = audio_arts_out.c xineplug_ao_out_arts_la_LIBADD = $(ARTS_LIBS) $(XINE_LIB) -xineplug_ao_out_arts_la_CFLAGS = $(VISIBILITY_FLAG) $(ARTS_CFLAGS) -xineplug_ao_out_arts_la_LDFLAGS = -avoid-version -module +xineplug_ao_out_arts_la_CFLAGS = $(AM_CFLAGS) $(ARTS_CFLAGS) xineplug_ao_out_directx_la_SOURCES = audio_directx_out.c xineplug_ao_out_directx_la_CPPFLAGS = $(DIRECTX_CPPFLAGS) xineplug_ao_out_directx_la_LIBADD = $(DIRECTX_AUDIO_LIBS) $(XINE_LIB) -xineplug_ao_out_directx_la_CFLAGS = $(VISIBILITY_FLAG) -xineplug_ao_out_directx_la_LDFLAGS = -avoid-version -module xineplug_ao_out_coreaudio_la_SOURCES = audio_coreaudio_out.c xineplug_ao_out_coreaudio_la_LIBADD = $(XINE_LIB) -# The "-Wl,-framework -Wl,..." is needed for libtool versions before -# 1.5.x (1.257): the default version that ships with Mac OS X is 1.5 (1.1220) -xineplug_ao_out_coreaudio_la_LDFLAGS = \ - -Wl,-framework -Wl,Cocoa -framework CoreAudio \ - -Wl,-framework -Wl,AudioUnit -framework AudioUnit \ - -avoid-version -module -xineplug_ao_out_coreaudio_la_CFLAGS = -framework CoreAudio -framework AudioUnit $(VISIBILITY_FLAG) +xineplug_ao_out_coreaudio_la_LDFLAGS = $(AM_LDFLAGS) -framework CoreAudio -framework AudioUnit xineplug_ao_out_pulseaudio_la_SOURCES = audio_pulse_out.c xineplug_ao_out_pulseaudio_la_LIBADD = $(PULSEAUDIO_LIBS) $(XINE_LIB) -xineplug_ao_out_pulseaudio_la_CFLAGS = $(VISIBILITY_FLAG) $(PULSEAUDIO_CFLAGS) -xineplug_ao_out_pulseaudio_la_LDFLAGS = -avoid-version -module +xineplug_ao_out_pulseaudio_la_CFLAGS = $(AM_CFLAGS) $(PULSEAUDIO_CFLAGS) xineplug_ao_out_directx2_la_SOURCES = audio_directx2_out.c xineplug_ao_out_directx2_la_CPPFLAGS = $(DIRECTX_CPPFLAGS) xineplug_ao_out_directx2_la_LIBADD = $(XINE_LIB) $(DIRECTX_AUDIO_LIBS) $(PTHREAD_LIBS) -xineplug_ao_out_directx2_la_CFLAGS = $(VISIBILITY_FLAG) -xineplug_ao_out_directx2_la_LDFLAGS = -avoid-version -module xineplug_ao_out_fusionsound_la_SOURCES = audio_fusionsound_out.c xineplug_ao_out_fusionsound_la_LIBADD = $(FUSIONSOUND_LIBS) $(XINE_LIB) -xineplug_ao_out_fusionsound_la_CFLAGS = $(VISIBILITY_FLAG) $(FUSIONSOUND_CFLAGS) -xineplug_ao_out_fusionsound_la_LDFLAGS = -avoid-version -module +xineplug_ao_out_fusionsound_la_CFLAGS = $(AM_CFLAGS) $(FUSIONSOUND_CFLAGS) xineplug_ao_out_jack_la_SOURCES = audio_jack_out.c xineplug_ao_out_jack_la_LIBADD = $(JACK_LIBS) $(XINE_LIB) -xineplug_ao_out_jack_la_CFLAGS = $(VISIBILITY_FLAG) $(JACK_CFLAGS) -xineplug_ao_out_jack_la_LDFLAGS = -avoid-version -module +xineplug_ao_out_jack_la_CFLAGS = $(AM_FLAGS) $(JACK_CFLAGS) diff --git a/src/combined/Makefile.am b/src/combined/Makefile.am index 884fcf0cc..64655c1eb 100644 --- a/src/combined/Makefile.am +++ b/src/combined/Makefile.am @@ -1,5 +1,8 @@ include $(top_srcdir)/misc/Makefile.common +AM_CFLAGS = $(DEFAULT_OCFLAGS) $(VISIBILITY_FLAG) +AM_LDFLAGS = $(xineplug_ldflags) + if HAVE_WAVPACK xineplug_wavpack = xineplug_wavpack.la endif @@ -11,11 +14,10 @@ endif xineplug_LTLIBRARIES = $(xineplug_wavpack) $(xineplug_flac) xineplug_wavpack_la_SOURCES = demux_wavpack.c decoder_wavpack.c combined_wavpack.c combined_wavpack.h -xineplug_wavpack_la_CFLAGS = $(VISIBILITY_FLAG) $(WAVPACK_CFLAGS) -I$(srcdir)/../demuxers +xineplug_wavpack_la_CFLAGS = $(AM_CFLAGS) $(WAVPACK_CFLAGS) +xineplug_wavpack_la_CPPFLAGS = -I$(srcdir)/../demuxers xineplug_wavpack_la_LIBADD = $(XINE_LIB) $(WAVPACK_LIBS) -xineplug_wavpack_la_LDFLAGS = $(xineplug_ldflags) xineplug_flac_la_SOURCES = demux_flac.c decoder_flac.c demux_flac.h -xineplug_flac_la_CFLAGS = $(VISIBILITY_FLAG) $(LIBFLAC_CFLAGS) +xineplug_flac_la_CFLAGS = $(AM_CFLAGS) $(LIBFLAC_CFLAGS) xineplug_flac_la_LIBADD = $(XINE_LIB) $(LIBFLAC_LIBS) -xineplug_flac_la_LDFLAGS = $(xineplug_ldflags) diff --git a/src/demuxers/Makefile.am b/src/demuxers/Makefile.am index 8a931c2d6..4722a982d 100644 --- a/src/demuxers/Makefile.am +++ b/src/demuxers/Makefile.am @@ -1,6 +1,6 @@ include $(top_srcdir)/misc/Makefile.common -AM_CFLAGS = $(VISIBILITY_FLAG) +AM_CFLAGS = $(DEFAULT_OCFLAGS) $(VISIBILITY_FLAG) AM_LDFLAGS = $(xineplug_ldflags) if HAVE_VORBIS @@ -101,7 +101,6 @@ xineplug_dmx_games_la_SOURCES = group_games.c demux_eawve.c \ demux_film.c demux_smjpeg.c demux_4xm.c \ demux_vmd.c xineplug_dmx_games_la_LIBADD = $(XINE_LIB) -xineplug_dmx_games_la_LDFLAGS = -avoid-version -module xineplug_dmx_audio_la_SOURCES = group_audio.c demux_aud.c demux_aiff.c \ demux_cdda.c demux_mpgaudio.c demux_nsf.c \ diff --git a/src/dxr3/Makefile.am b/src/dxr3/Makefile.am index 5f413f804..836f57e6e 100644 --- a/src/dxr3/Makefile.am +++ b/src/dxr3/Makefile.am @@ -1,6 +1,7 @@ include $(top_srcdir)/misc/Makefile.common -AM_CFLAGS = $(X_CFLAGS) $(LIBFAME_CFLAGS) +AM_CFLAGS = $(DEFAULT_OCFLAGS) $(VISIBILITY_FLAG) $(X_CFLAGS) $(LIBFAME_CFLAGS) +AM_LDFLAGS = $(xineplug_ldflags) if HAVE_DXR3 dxr3_modules = xineplug_decode_dxr3_video.la \ @@ -21,8 +22,6 @@ xineplug_LTLIBRARIES = $(dxr3_modules) xineplug_decode_dxr3_video_la_SOURCES = dxr3_decode_video.c xineplug_decode_dxr3_video_la_LIBADD = $(XINE_LIB) -xineplug_decode_dxr3_video_la_CFLAGS = $(VISIBILITY_FLAG) $(AM_CFLAGS) -xineplug_decode_dxr3_video_la_LDFLAGS = -avoid-version -module if HAVE_DVDNAV AM_CPPFLAGS = $(DVDNAV_CFLAGS) @@ -33,8 +32,6 @@ AM_CPPFLAGS = -I$(top_srcdir)/src/input/libdvdnav xineplug_decode_dxr3_spu_la_SOURCES = dxr3_decode_spu.c nav_read.c xineplug_decode_dxr3_spu_la_LIBADD = $(XINE_LIB) endif -xineplug_decode_dxr3_spu_la_CFLAGS = $(VISIBILITY_FLAG) $(AM_CFLAGS) -xineplug_decode_dxr3_spu_la_LDFLAGS = -avoid-version -module xineplug_vo_out_dxr3_la_SOURCES = \ dxr3_mpeg_encoders.c \ @@ -43,8 +40,6 @@ xineplug_vo_out_dxr3_la_SOURCES = \ video_out_dxr3.c xineplug_vo_out_dxr3_la_LIBADD = $(link_fame) $(link_rte) $(link_x_libs) $(XINE_LIB) $(DYNAMIC_LD_LIBS) -lm -xineplug_vo_out_dxr3_la_CFLAGS = $(VISIBILITY_FLAG) $(AM_CFLAGS) -xineplug_vo_out_dxr3_la_LDFLAGS = -avoid-version -module noinst_HEADERS = \ em8300.h \ diff --git a/src/input/Makefile.am b/src/input/Makefile.am index ae38de187..ce8c2fe33 100644 --- a/src/input/Makefile.am +++ b/src/input/Makefile.am @@ -1,5 +1,11 @@ include $(top_srcdir)/misc/Makefile.common +# REVISIT: This second line here bothers me more than just a little bit +AM_CFLAGS = $(DEFAULT_OCFLAGS) $(VISIBILITY_FLAG) \ + $(GNOME_VFS_CFLAGS) $(ALSA_CFLAGS) $(DVD_CFLAGS) +AM_CPPFLAGS = -D_LARGEFILE64_SOURCE +AM_LDFLAGS = $(xineplug_ldflags) + EXTRA_DIST = input_dvd.c input_vcd.c input_gnome_vfs.c input_rtp.c if HAVE_DVDNAV @@ -48,7 +54,6 @@ in_rtp = xineplug_inp_rtp.la in_dvb = xineplug_inp_dvb.la endif -AM_CFLAGS = -D_LARGEFILE64_SOURCE $(GNOME_VFS_CFLAGS) $(ALSA_CFLAGS) $(DVD_CFLAGS) xineplug_LTLIBRARIES = \ xineplug_inp_file.la \ @@ -71,85 +76,55 @@ xineplug_LTLIBRARIES = \ xineplug_inp_file_la_SOURCES = input_file.c xineplug_inp_file_la_LIBADD = $(XINE_LIB) -xineplug_inp_file_la_CFLAGS = $(VISIBILITY_FLAG) $(AM_CFLAGS) -xineplug_inp_file_la_LDFLAGS = -avoid-version -module xineplug_inp_dvd_la_SOURCES = input_dvd.c media_helper.c xineplug_inp_dvd_la_LIBADD = $(XINE_LIB) $(link_dvdnav) $(PTHREAD_LIBS) $(DYNAMIC_LD_LIBS) -xineplug_inp_dvd_la_CFLAGS = $(VISIBILITY_FLAG) $(AM_CFLAGS) -xineplug_inp_dvd_la_LDFLAGS = -avoid-version -module xineplug_inp_net_la_SOURCES = input_net.c net_buf_ctrl.c xineplug_inp_net_la_LIBADD = $(XINE_LIB) $(NET_LIBS) $(PTHREAD_LIBS) -xineplug_inp_net_la_CFLAGS = $(VISIBILITY_FLAG) $(AM_CFLAGS) -xineplug_inp_net_la_LDFLAGS = -avoid-version -module xineplug_inp_mms_la_SOURCES = input_mms.c net_buf_ctrl.c mms.c mmsh.c http_helper.c ../demuxers/asfheader.c xineplug_inp_mms_la_LIBADD = $(XINE_LIB) @LIBICONV@ $(PTHREAD_LIBS) -xineplug_inp_mms_la_CFLAGS = $(VISIBILITY_FLAG) $(AM_CFLAGS) -xineplug_inp_mms_la_LDFLAGS = -avoid-version -module xineplug_inp_vcdo_la_SOURCES = input_vcd.c media_helper.c xineplug_inp_vcdo_la_LIBADD = $(XINE_LIB) -xineplug_inp_vcdo_la_CFLAGS = $(VISIBILITY_FLAG) $(AM_CFLAGS) -xineplug_inp_vcdo_la_LDFLAGS = -avoid-version -module xineplug_inp_stdin_fifo_la_SOURCES = input_stdin_fifo.c net_buf_ctrl.c xineplug_inp_stdin_fifo_la_LIBADD = $(XINE_LIB) $(PTHREAD_LIBS) -xineplug_inp_stdin_fifo_la_CFLAGS = $(VISIBILITY_FLAG) $(AM_CFLAGS) -xineplug_inp_stdin_fifo_la_LDFLAGS = -avoid-version -module xineplug_inp_rtp_la_SOURCES = input_rtp.c net_buf_ctrl.c xineplug_inp_rtp_la_LIBADD = $(XINE_LIB) $(NET_LIBS) $(PTHREAD_LIBS) -xineplug_inp_rtp_la_CFLAGS = $(VISIBILITY_FLAG) $(AM_CFLAGS) -xineplug_inp_rtp_la_LDFLAGS = -avoid-version -module xineplug_inp_http_la_SOURCES = input_http.c net_buf_ctrl.c http_helper.c xineplug_inp_http_la_LIBADD = $(XINE_LIB) $(NET_LIBS) $(PTHREAD_LIBS) -xineplug_inp_http_la_CFLAGS = $(VISIBILITY_FLAG) $(AM_CFLAGS) -xineplug_inp_http_la_LDFLAGS = -avoid-version -module xineplug_inp_pnm_la_SOURCES = input_pnm.c net_buf_ctrl.c pnm.c xineplug_inp_pnm_la_LIBADD = $(XINE_LIB) $(PTHREAD_LIBS) -xineplug_inp_pnm_la_CFLAGS = $(VISIBILITY_FLAG) $(AM_CFLAGS) -xineplug_inp_pnm_la_LDFLAGS = -avoid-version -module xineplug_inp_dvb_la_SOURCES = input_dvb.c net_buf_ctrl.c xineplug_inp_dvb_la_DEPS = $(XDG_BASEDIR_DEPS) xineplug_inp_dvb_la_LIBADD = $(XINE_LIB) $(PTHREAD_LIBS) $(XDG_BASEDIR_LIBS) -xineplug_inp_dvb_la_CFLAGS = $(VISIBILITY_FLAG) $(AM_CFLAGS) $(XDG_BASEDIR_CFLAGS) -xineplug_inp_dvb_la_LDFLAGS = -avoid-version -module +xineplug_inp_dvb_la_CFLAGS = $(AM_CFLAGS) $(XDG_BASEDIR_CFLAGS) xineplug_inp_rtsp_la_SOURCES = input_rtsp.c net_buf_ctrl.c xineplug_inp_rtsp_la_LIBADD = $(XINE_LIB) $(PTHREAD_LIBS) libreal/libreal.la librtsp/librtsp.la -xineplug_inp_rtsp_la_CFLAGS = $(VISIBILITY_FLAG) $(AM_CFLAGS) -xineplug_inp_rtsp_la_LDFLAGS = -avoid-version -module xineplug_inp_cdda_la_SOURCES = input_cdda.c media_helper.c sha1.c sha1.h base64.c base64.h xineplug_inp_cdda_la_DEPS = $(XDG_BASEDIR_DEPS) xineplug_inp_cdda_la_LIBADD = $(XINE_LIB) $(XDG_BASEDIR_LIBS) -xineplug_inp_cdda_la_CFLAGS = $(VISIBILITY_FLAG) $(AM_CFLAGS) $(XDG_BASEDIR_CFLAGS) -xineplug_inp_cdda_la_LDFLAGS = -avoid-version -module +xineplug_inp_cdda_la_CFLAGS = $(AM_CFLAGS) $(XDG_BASEDIR_CFLAGS) xineplug_inp_v4l_la_SOURCES = input_v4l.c xineplug_inp_v4l_la_LIBADD = $(ALSA_LIBS) $(XINE_LIB) -xineplug_inp_v4l_la_CFLAGS = $(VISIBILITY_FLAG) $(AM_CFLAGS) -xineplug_inp_v4l_la_LDFLAGS = -avoid-version -module xineplug_inp_gnome_vfs_la_SOURCES = input_gnome_vfs.c net_buf_ctrl.c xineplug_inp_gnome_vfs_la_LIBADD = $(GNOME_VFS_LIBS) $(XINE_LIB) $(PTHREAD_LIBS) -xineplug_inp_gnome_la_CFLAGS = $(VISIBILITY_FLAG) $(AM_CFLAGS) -xineplug_inp_gnome_vfs_la_LDFLAGS = -avoid-version -module xineplug_inp_smb_la_SOURCES = input_smb.c xineplug_inp_smb_la_LIBADD = $(LIBSMBCLIENT_LIBS) $(XINE_LIB) -xineplug_inp_smb_la_CFLAGS = $(VISIBILITY_FLAG) $(AM_CFLAGS) -xineplug_inp_smb_la_LDFLAGS = -avoid-version -module xineplug_inp_pvr_la_SOURCES = input_pvr.c xineplug_inp_pvr_la_LIBADD = $(XINE_LIB) $(PTHREAD_LIBS) -xineplug_inp_pvr_la_CFLAGS = $(VISIBILITY_FLAG) $(AM_CFLAGS) -xineplug_inp_pvr_la_LDFLAGS = -avoid-version -module xineinclude_HEADERS = input_plugin.h noinst_HEADERS = net_buf_ctrl.h mms.h mmsh.h pnm.h media_helper.h videodev2.h http_helper.h diff --git a/src/input/libdvdnav/Makefile.am b/src/input/libdvdnav/Makefile.am index 412828261..b7e313a38 100644 --- a/src/input/libdvdnav/Makefile.am +++ b/src/input/libdvdnav/Makefile.am @@ -1,6 +1,8 @@ include $(top_srcdir)/misc/Makefile.common +AM_CFLAGS = $(DEFAULT_OCFLAGS) $(VISIBILITY_FLAG) AM_CPPFLAGS = -D_LARGEFILE64_SOURCE -DDVDNAV_COMPILE -DHAVE_DLFCN_H +AM_LDFLAGS = $(xineplug_ldflags) noinst_LTLIBRARIES = libdvdnav.la @@ -23,8 +25,6 @@ libdvdnav_la_SOURCES = \ dvd_input.c \ dvd_udf.c libdvdnav_la_LIBADD = $(PTHREAD_LIBS) -libdvdnav_la_CFLAGS = $(VISIBILITY_FLAG) -libdvdnav_la_LDFLAGS = -avoid-version -module noinst_HEADERS = \ decoder.h \ diff --git a/src/input/libreal/Makefile.am b/src/input/libreal/Makefile.am index 5b10d1bca..500dfb910 100644 --- a/src/input/libreal/Makefile.am +++ b/src/input/libreal/Makefile.am @@ -1,5 +1,6 @@ include $(top_srcdir)/misc/Makefile.common +AM_CFLAGS = $(DEFAULT_OCFLAGS) $(VISIBILITY_FLAG) AM_CPPFLAGS = -D_LARGEFILE64_SOURCE -I$(srcdir)/../librtsp noinst_LTLIBRARIES = libreal.la @@ -10,8 +11,6 @@ libreal_la_SOURCES = \ rmff.c \ sdpplin.c -libreal_la_CFLAGS = $(VISIBILITY_FLAG) - noinst_HEADERS = \ real.h \ asmrp.h \ diff --git a/src/input/librtsp/Makefile.am b/src/input/librtsp/Makefile.am index bb85f9cf4..9027ab260 100644 --- a/src/input/librtsp/Makefile.am +++ b/src/input/librtsp/Makefile.am @@ -1,6 +1,8 @@ include $(top_srcdir)/misc/Makefile.common +AM_CFLAGS = $(DEFAULT_OCFLAGS) $(VISIBILITY_FLAG) AM_CPPFLAGS = -D_LARGEFILE64_SOURCE -I$(srcdir)/../libreal +AM_LDFLAGS = $(xineplug_ldflags) noinst_LTLIBRARIES = librtsp.la @@ -8,9 +10,6 @@ librtsp_la_SOURCES = \ rtsp.c \ rtsp_session.c -librtsp_la_CFLAGS = $(VISIBILITY_FLAG) -librtsp_la_LDFLAGS = -avoid-version -module - noinst_HEADERS = \ rtsp.h \ rtsp_session.h diff --git a/src/input/vcd/Makefile.am b/src/input/vcd/Makefile.am index 16eece779..014d28679 100644 --- a/src/input/vcd/Makefile.am +++ b/src/input/vcd/Makefile.am @@ -1,5 +1,8 @@ include $(top_srcdir)/misc/Makefile.common +AM_CFLAGS = $(DEFAULT_OCFLAGS) $(LIBCDIO_CFLAGS) +AM_LDFLAGS = $(xineplug_ldflags) + SUBDIRS = libcdio libvcd vcd_SRCS = xineplug_inp_vcd.c vcdplayer.c vcdio.c xine-extra.c @@ -9,10 +12,9 @@ EXTRA_DIST = $(vcd_SRCS) if ENABLE_VCD xineplug_LTLIBRARIES = xineplug_inp_vcd.la -AM_CFLAGS = $(LIBCDIO_CFLAGS) $(LIBVCD_CFLAGS) +AM_CFLAGS += $(LIBCDIO_CFLAGS) $(LIBVCD_CFLAGS) xineplug_inp_vcd_la_SOURCES = $(vcd_SRCS) -xineplug_inp_vcd_la_LDFLAGS = -avoid-version -module if HAVE_VCDNAV xineplug_inp_vcd_la_LIBADD = $(XINE_LIB) $(LIBVCDINFO_LIBS) else diff --git a/src/input/vcd/libcdio/Makefile.am b/src/input/vcd/libcdio/Makefile.am index c7415e787..0c6b26dac 100644 --- a/src/input/vcd/libcdio/Makefile.am +++ b/src/input/vcd/libcdio/Makefile.am @@ -1,5 +1,8 @@ include $(top_srcdir)/misc/Makefile.common +AM_CFLAGS = $(DEFAULT_OCFLAGS) +AM_LDFLAGS = $(xineplug_ldflags) + SUBDIRS = cdio MSWindows image INCLUDES = $(LIBCDIO_CFLAGS) -I$(top_srcdir)/include -I$(top_srcdir)/lib -I$(top_builddir)/lib @@ -54,9 +57,7 @@ if HAVE_VCDNAV else noinst_LTLIBRARIES = libcdio.la libiso9660.la libcdio_la_SOURCES = $(libcdio_SRCS) -libcdio_la_LDFLAGS = -avoid-version -module libiso9660_la_SOURCES = $(libiso9660_SRCS) -libiso9660_la_LDFLAGS = -avoid-version -module endif endif diff --git a/src/input/vcd/libvcd/Makefile.am b/src/input/vcd/libvcd/Makefile.am index 01b100aa4..cba784d26 100644 --- a/src/input/vcd/libvcd/Makefile.am +++ b/src/input/vcd/libvcd/Makefile.am @@ -1,5 +1,8 @@ include $(top_srcdir)/misc/Makefile.common +AM_CFLAGS = $(DEFAULT_OCFLAGS) +AM_LDFLAGS = $(xineplug_ldflags) + SUBDIRS = libvcd INCLUDES = $(LIBCDIO_CFLAGS) -I$(top_srcdir)/include -I$(top_srcdir)/lib @@ -36,10 +39,8 @@ if HAVE_VCDNAV else noinst_LTLIBRARIES = libvcd.la libvcdinfo.la libvcd_la_SOURCES = $(libvcd_SRCS) -libvcd_la_LDFLAGS = -avoid-version -module libvcd_la_LIBADD = $(LIBCDIO_LIBS) $(LIBISO9660_LIBS) libvcdinfo_la_SOURCES = $(libvcdinfo_SRCS) -libvcdinfo_la_LDFLAGS = -avoid-version -module endif endif diff --git a/src/liba52/Makefile.am b/src/liba52/Makefile.am index 6a0aebe62..948a7ab28 100644 --- a/src/liba52/Makefile.am +++ b/src/liba52/Makefile.am @@ -1,5 +1,8 @@ include $(top_srcdir)/misc/Makefile.common +AM_CFLAGS = $(DEFAULT_OCFLAGS) $(VISIBILITY_FLAG) +AM_LDFLAGS = $(xineplug_ldflags) + if A52 a52_module = xineplug_decode_a52.la endif @@ -27,9 +30,6 @@ else xineplug_decode_a52_la_LIBADD = $(XINE_LIB) -lm endif -xineplug_decode_a52_la_CFLAGS = $(VISIBILITY_FLAG) -xineplug_decode_a52_la_LDFLAGS = $(xineplug_ldflags) - noinst_HEADERS = \ a52.h \ a52_internal.h \ diff --git a/src/libfaad/Makefile.am b/src/libfaad/Makefile.am index d1a4ed865..c02810f00 100644 --- a/src/libfaad/Makefile.am +++ b/src/libfaad/Makefile.am @@ -1,5 +1,8 @@ include $(top_srcdir)/misc/Makefile.common +AM_CFLAGS = $(DEFAULT_OCFLAGS) $(VISIBILITY_FLAG) +AM_LDFLAGS = $(xineplug_ldflags) + SUBDIRS = codebook if BUILD_FAAD @@ -10,7 +13,7 @@ xineplug_LTLIBRARIES = $(faad_module) VPATH = @srcdir@:@srcdir@/codebook: -xineplug_decode_faad_la_CFLAGS = $(VISIBILITY_FLAG) $(AM_CFLAGS) -fno-strict-aliasing +xineplug_decode_faad_la_CFLAGS = $(AM_CFLAGS) -fno-strict-aliasing xineplug_decode_faad_la_SOURCES = \ bits.c \ cfft.c \ @@ -52,7 +55,6 @@ xineplug_decode_faad_la_SOURCES = \ tns.c \ xine_faad_decoder.c -xineplug_decode_faad_la_LDFLAGS = $(xineplug_ldflags) xineplug_decode_faad_la_LIBADD = -lm $(XINE_LIB) noinst_HEADERS = \ diff --git a/src/libffmpeg/Makefile.am b/src/libffmpeg/Makefile.am index 7b622cf74..b2571a4ea 100644 --- a/src/libffmpeg/Makefile.am +++ b/src/libffmpeg/Makefile.am @@ -1,7 +1,11 @@ include $(top_srcdir)/misc/Makefile.common +AM_CFLAGS = $(DEFAULT_OCFLAGS) $(VISIBILITY_FLAG) +AM_CPPFLAGS = $(ff_cppflags) $(ZLIB_CPPFLAGS) +AM_LDFLAGS = $(xineplug_ldflags) + if HAVE_FFMPEG -AM_CFLAGS = $(FFMPEG_CFLAGS) $(FFMPEG_POSTPROC_CFLAGS) +AM_CFLAGS += $(FFMPEG_CFLAGS) $(FFMPEG_POSTPROC_CFLAGS) link_ffmpeg = $(FFMPEG_LIBS) $(FFMPEG_POSTPROC_LIBS) else @@ -39,25 +43,21 @@ EXTRA_DIST = ffmpeg_encoder.c xineplug_LTLIBRARIES = xineplug_decode_ff.la xineplug_decode_dvaudio.la if HAVE_DXR3 -AM_CPPFLAGS = -I$(top_srcdir)/src/dxr3 $(X_CFLAGS) $(ff_cppflags) \ - $(ZLIB_CPPFLAGS) +AM_CPPFLAGS += -I$(top_srcdir)/src/dxr3 $(X_CFLAGS) xineplug_decode_ff_la_SOURCES = ffmpeg_decoder.c ff_audio_decoder.c ff_video_decoder.c \ ffmpeg_encoder.c ff_mpeg_parser.c ffmpeg_decoder.h \ ff_mpeg_parser.h else -AM_CPPFLAGS = $(ff_cppflags) $(ZLIB_CPPFLAGS) xineplug_decode_ff_la_SOURCES = ffmpeg_decoder.c ff_audio_decoder.c ff_video_decoder.c \ ff_mpeg_parser.c ffmpeg_decoder.h ff_mpeg_parser.h endif nodist_xineplug_decode_ff_la_SOURCES = ffmpeg_config.h -xineplug_decode_ff_la_CFLAGS = $(VISIBILITY_FLAG) $(AM_CFLAGS) -xineplug_decode_ff_la_LDFLAGS = $(xineplug_ldflags) $(IMPURE_TEXT_LDFLAGS) +xineplug_decode_ff_la_LDFLAGS = $(AM_LDFLAGS) $(IMPURE_TEXT_LDFLAGS) xineplug_decode_ff_la_LIBADD = $(MLIB_LIBS) $(XINE_LIB) -lm $(ZLIB_LIBS) \ $(link_ffmpeg) $(PTHREAD_LIBS) -xineplug_decode_dvaudio_la_CFLAGS = $(VISIBILITY_FLAG) $(AM_CFLAGS) -I $(top_srcdir)/contrib/ffmpeg/libavcodec -xineplug_decode_dvaudio_la_LDFLAGS = $(xineplug_ldflags) +xineplug_decode_dvaudio_la_CPPFLAGS = $(AM_CPPFLAGS) -I$(top_srcdir)/contrib/ffmpeg/libavcodec xineplug_decode_dvaudio_la_SOURCES = ff_dvaudio_decoder.c xineplug_decode_dvaudio_la_LIBADD = $(XINE_LIB) diff --git a/src/libmad/Makefile.am b/src/libmad/Makefile.am index c879645c5..7e8b617f4 100644 --- a/src/libmad/Makefile.am +++ b/src/libmad/Makefile.am @@ -1,6 +1,8 @@ include $(top_srcdir)/misc/Makefile.common -AM_CFLAGS = -DOPT_SPEED +AM_CFLAGS = $(DEFAULT_OCFLAGS) $(VISIBILITY_FLAG) +AM_CPPFLAGS = -DOPT_SPEED +AM_LDFLAGS = $(xineplug_ldflags) EXTRA_DIST = imdct_l_arm.S @@ -35,8 +37,7 @@ xineplug_decode_mad_la_LIBADD = $(XINE_LIB) $(LIBMAD_LIBS) else xineplug_decode_mad_la_LIBADD = $(XINE_LIB) endif -xineplug_decode_mad_la_CFLAGS = $(LIBMAD_CFLAGS) $(VISIBILITY_FLAG) -xineplug_decode_mad_la_LDFLAGS = $(xineplug_ldflags) +xineplug_decode_mad_la_CFLAGS = $(AM_CFLAGS) $(LIBMAD_CFLAGS) noinst_HEADERS = \ D.dat \ diff --git a/src/libmpeg2/Makefile.am b/src/libmpeg2/Makefile.am index 66fb39f13..6b194ebbb 100644 --- a/src/libmpeg2/Makefile.am +++ b/src/libmpeg2/Makefile.am @@ -1,5 +1,8 @@ include $(top_srcdir)/misc/Makefile.common +AM_CFLAGS = $(DEFAULT_OCFLAGS) $(VISIBILITY_FLAG) +AM_LDFLAGS = $(xineplug_ldflags) + xineplug_LTLIBRARIES = xineplug_decode_mpeg2.la xineplug_decode_mpeg2_la_SOURCES = \ @@ -23,8 +26,7 @@ xineplug_decode_mpeg2_la_SOURCES = \ libmpeg2_accel.c xineplug_decode_mpeg2_la_LIBADD = $(MLIB_LIBS) $(XINE_LIB) -lm -xineplug_decode_mpeg2_la_CFLAGS = $(VISIBILITY_FLAG) $(LIBMPEG2_CFLAGS) -xineplug_decode_mpeg2_la_LDFLAGS = $(xineplug_ldflags) +xineplug_decode_mpeg2_la_CFLAGS = $(AM_CFLAGS) $(LIBMPEG2_CFLAGS) noinst_HEADERS = vlc.h mpeg2.h xvmc.h xvmc_vld.h mpeg2_internal.h idct_mlib.h vis.h \ libmpeg2_accel.h diff --git a/src/libmpeg2new/Makefile.am b/src/libmpeg2new/Makefile.am index 49959da86..8f8f1c940 100644 --- a/src/libmpeg2new/Makefile.am +++ b/src/libmpeg2new/Makefile.am @@ -1,5 +1,8 @@ include $(top_srcdir)/misc/Makefile.common +AM_CFLAGS = $(DEFAULT_OCFLAGS) $(VISIBILITY_FLAG) +AM_LDFLAGS = $(xineplug_ldflags) + SUBDIRS = libmpeg2 xineplug_LTLIBRARIES = xineplug_decode_mpeg2.la @@ -7,7 +10,5 @@ xineplug_LTLIBRARIES = xineplug_decode_mpeg2.la xineplug_decode_mpeg2_la_SOURCES = \ xine_mpeg2_decoder.c -xineplug_decode_mpeg2_la_CFLAGS = $(VISIBILITY_FLAG) $(LIBMPEG2_CFLAGS) +xineplug_decode_mpeg2_la_CFLAGS = $(AM_CFLAGS) $(LIBMPEG2_CFLAGS) xineplug_decode_mpeg2_la_LIBADD = $(XINE_LIB) ./libmpeg2/libmpeg2.la -xineplug_decode_mpeg2_la_LDFLAGS = $(xineplug_ldflags) - diff --git a/src/libmpeg2new/libmpeg2/Makefile.am b/src/libmpeg2new/libmpeg2/Makefile.am index f99894f12..83ae1c32f 100644 --- a/src/libmpeg2new/libmpeg2/Makefile.am +++ b/src/libmpeg2new/libmpeg2/Makefile.am @@ -1,5 +1,7 @@ include $(top_srcdir)/misc/Makefile.common +AM_CFLAGS = $(DEFAULT_OCFLAGS) + noinst_LTLIBRARIES = libmpeg2.la libmpeg2arch.la libmpeg2_la_SOURCES = alloc.c header.c decode.c slice.c motion_comp.c idct.c diff --git a/src/libreal/Makefile.am b/src/libreal/Makefile.am index c9cf62984..28d85fe45 100644 --- a/src/libreal/Makefile.am +++ b/src/libreal/Makefile.am @@ -1,12 +1,13 @@ include $(top_srcdir)/misc/Makefile.common +AM_CFLAGS = $(DEFAULT_OCFLAGS) $(VISIBILITY_FLAG) +AM_LDFLAGS = $(xineplug_ldflags) + if ENABLE_REAL xineplug_LTLIBRARIES = xineplug_decode_real.la endif xineplug_decode_real_la_SOURCES = xine_real_video_decoder.c real_common.c xine_real_audio_decoder.c xineplug_decode_real_la_LIBADD = $(XINE_LIB) $(DYNAMIC_LD_LIBS) -xineplug_decode_real_la_CFLAGS = $(VISIBILITY_FLAG) -xineplug_decode_real_la_LDFLAGS = $(xineplug_ldflags) noinst_HEADERS = real_common.h diff --git a/src/libspucc/Makefile.am b/src/libspucc/Makefile.am index aefe4d7c1..c32e7a292 100644 --- a/src/libspucc/Makefile.am +++ b/src/libspucc/Makefile.am @@ -1,10 +1,12 @@ include $(top_srcdir)/misc/Makefile.common +AM_CFLAGS = $(DEFAULT_OCFLAGS) $(VISIBILITY_FLAG) +AM_LDFLAGS = $(xineplug_ldflags) + xineplug_LTLIBRARIES = xineplug_decode_spucc.la xineplug_decode_spucc_la_SOURCES = cc_decoder.c xine_cc_decoder.c -xineplug_decode_spucc_la_CFLAGS = $(VISIBILITY_FLAG) $(AM_CFLAGS) -fno-strict-aliasing +xineplug_decode_spucc_la_CFLAGS = $(AM_CFLAGS) -fno-strict-aliasing xineplug_decode_spucc_la_LIBADD = $(XINE_LIB) -xineplug_decode_spucc_la_LDFLAGS = -avoid-version -module noinst_HEADERS = cc_decoder.h diff --git a/src/libspucmml/Makefile.am b/src/libspucmml/Makefile.am index ac2970482..95b611008 100644 --- a/src/libspucmml/Makefile.am +++ b/src/libspucmml/Makefile.am @@ -1,8 +1,9 @@ include $(top_srcdir)/misc/Makefile.common +AM_CFLAGS = $(DEFAULT_OCFLAGS) $(VISIBILITY_FLAG) +AM_LDFLAGS = $(xineplug_ldflags) + xineplug_LTLIBRARIES = xineplug_decode_spucmml.la xineplug_decode_spucmml_la_SOURCES = xine_cmml_decoder.c xineplug_decode_spucmml_la_LIBADD = $(XINE_LIB) -xineplug_decode_spucmml_la_CFLAGS = $(VISIBILITY_FLAG) -xineplug_decode_spucmml_la_LDFLAGS = $(xineplug_ldflags) diff --git a/src/libspudec/Makefile.am b/src/libspudec/Makefile.am index 208d994f5..d159728fc 100644 --- a/src/libspudec/Makefile.am +++ b/src/libspudec/Makefile.am @@ -1,5 +1,9 @@ include $(top_srcdir)/misc/Makefile.common +AM_CFLAGS = $(DEFAULT_OCFLAGS) $(VISIBILITY_FLAG) +AM_CPPFLAGS = -I$(top_srcdir)/src/input/libdvdnav +AM_LDFLAGS = $(xineplug_ldflags) + xineplug_LTLIBRARIES = xineplug_decode_spu.la if HAVE_DVDNAV @@ -15,12 +19,10 @@ xineplug_decode_spu_la_SOURCES = \ nav_read.c \ spu.c \ xine_spu_decoder.c -AM_CPPFLAGS = -I$(top_srcdir)/src/input/libdvdnav xineplug_decode_spu_la_LIBADD = $(XINE_LIB) $(PTHREAD_LIBS) endif -xineplug_decode_spu_la_CFLAGS = $(DVDNAV_CFLAGS) $(VISIBILITY_FLAG) -xineplug_decode_spu_la_LDFLAGS = $(xineplug_ldflags) +xineplug_decode_spu_la_CFLAGS = $(AM_CFLAGS) $(DVDNAV_CFLAGS) noinst_HEADERS = spu.h diff --git a/src/libspudvb/Makefile.am b/src/libspudvb/Makefile.am index e385e5553..f4248909f 100644 --- a/src/libspudvb/Makefile.am +++ b/src/libspudvb/Makefile.am @@ -1,8 +1,9 @@ include $(top_srcdir)/misc/Makefile.common +AM_CFLAGS = $(DEFAULT_OCFLAGS) $(VISIBILITY_FLAG) +AM_LDFLAGS = $(xineplug_ldflags) + xineplug_LTLIBRARIES = xineplug_decode_spudvb.la xineplug_decode_spudvb_la_SOURCES = xine_spudvb_decoder.c xineplug_decode_spudvb_la_LIBADD = $(XINE_LIB) $(PTHREAD_LIBS) -xineplug_decode_spudvb_la_CFLAGS = $(VISIBILITY_FLAG) -xineplug_decode_spudvb_la_LDFLAGS = $(xineplug_ldflags) diff --git a/src/libsputext/Makefile.am b/src/libsputext/Makefile.am index 5e4ce59d0..71af2a1d3 100644 --- a/src/libsputext/Makefile.am +++ b/src/libsputext/Makefile.am @@ -1,13 +1,12 @@ include $(top_srcdir)/misc/Makefile.common +AM_CFLAGS = $(DEFAULT_OCFLAGS) $(VISIBILITY_FLAG) AM_LDFLAGS = $(xineplug_ldflags) xineplug_LTLIBRARIES = xineplug_decode_sputext.la xineplug_dmx_sputext.la xineplug_dmx_sputext_la_SOURCES = demux_sputext.c xineplug_dmx_sputext_la_LIBADD = $(XINE_LIB) -xineplug_dmx_sputext_la_CFLAGS = $(VISIBILITY_FLAG) xineplug_decode_sputext_la_SOURCES = xine_sputext_decoder.c xineplug_decode_sputext_la_LIBADD = $(XINE_LIB) -xineplug_decode_sputext_la_CFLAGS = $(VISIBILITY_FLAG) diff --git a/src/libw32dll/Makefile.am b/src/libw32dll/Makefile.am index 367dc3bda..774cc8705 100644 --- a/src/libw32dll/Makefile.am +++ b/src/libw32dll/Makefile.am @@ -1,6 +1,8 @@ include $(top_srcdir)/misc/Makefile.common -AM_CFLAGS = -I$(srcdir)/wine -DWIN32_PATH=\"@w32_path@\" $(VISIBILITY_FLAG) +AM_CFLAGS = $(DEFAULT_OCFLAGS) $(VISIBILITY_FLAG) +AM_CPPFLAGS = -I$(srcdir)/wine -DWIN32_PATH=\"@w32_path@\" +AM_LDFLAGS = $(xineplug_ldflags) SUBDIRS = wine DirectShow dmo qtx @@ -15,7 +17,6 @@ EXTRA_DIST = common.c xineplug_decode_w32dll_la_SOURCES = w32codec.c xineplug_decode_w32dll_la_CFLAGS = $(AM_CFLAGS) $(XDG_BASEDIR_CFLAGS) -xineplug_decode_w32dll_la_LDFLAGS = -avoid-version -module xineplug_decode_w32dll_la_DEPS = $(XDG_BASEDIR_DEPS) xineplug_decode_w32dll_la_LIBADD = \ $(top_builddir)/src/libw32dll/wine/libwine.la \ @@ -28,7 +29,6 @@ xineplug_decode_w32dll_la_LIBADD = \ $(XDG_BASEDIR_LIBS) xineplug_decode_qt_la_SOURCES = qt_decoder.c -xineplug_decode_qt_la_LDFLAGS = -avoid-version -module xineplug_decode_qt_la_LIBADD = \ $(top_builddir)/src/libw32dll/wine/libwine.la \ $(XINE_LIB) \ diff --git a/src/libw32dll/wine/Makefile.am b/src/libw32dll/wine/Makefile.am index b53d2c078..1fd132dca 100644 --- a/src/libw32dll/wine/Makefile.am +++ b/src/libw32dll/wine/Makefile.am @@ -1,20 +1,16 @@ include $(top_srcdir)/misc/Makefile.common -LIBTOOL = $(SHELL) $(top_builddir)/libtool - EXTRA_DIST = stubs.s wrapper.S noinst_LTLIBRARIES = $(wine_lib) -AM_CFLAGS = $(X_CFLAGS) @W32_NO_OPTIMIZE@ \ - -Wmissing-prototypes -Wimplicit-function-declaration \ - -DWIN32_PATH=\"@w32_path@\" -I$(srcdir)/.. -D__WINE__ \ +# disable -fomit-frame-pointer, -finline-functions, and -frename-registers +# because they cause bad behavior of wine +AM_CFLAGS = $(DEFAULT_OCFLAGS) $(X_CFLAGS) @W32_NO_OPTIMIZE@ \ + -fno-omit-frame-pointer -fno-inline-functions -fno-rename-registers +AM_CPPFLAGS = -DWIN32_PATH=\"@w32_path@\" -I$(srcdir)/.. -D__WINE__ \ -Ddbg_printf=__vprintf -DTRACE=__vprintf -# CFLAGS is here to filter out -fomit-frame-pointer, -# -finline-functions and -frename-registers because they cause bad -# behavior of wine -CFLAGS = `echo @CFLAGS@ | sed -e 's/-fomit-frame-pointer//g;s/-finline-functions//g;s/-frename-registers//g'` if HAVE_W32DLL wine_lib = libwine.la diff --git a/src/libxineadec/Makefile.am b/src/libxineadec/Makefile.am index 08d1df3dc..0d209be43 100644 --- a/src/libxineadec/Makefile.am +++ b/src/libxineadec/Makefile.am @@ -4,6 +4,7 @@ EXTRA_DIST = fooaudio.c SUBDIRS = gsm610 nosefart +AM_CFLAGS = $(DEFAULT_OCFLAGS) $(VISIBILITY_FLAG) AM_LDFLAGS = $(xineplug_ldflags) if HAVE_VORBIS @@ -38,31 +39,30 @@ xineplug_LTLIBRARIES = \ $(dts_module) xineplug_decode_gsm610_la_SOURCES = gsm610.c -xineplug_decode_gsm610_la_CFLAGS = $(VISIBILITY_FLAG) xineplug_decode_gsm610_la_LIBADD = $(XINE_LIB) gsm610/libgsm610.la xineplug_decode_nsf_la_SOURCES = nsf.c -xineplug_decode_nsf_la_CFLAGS = $(VISIBILITY_FLAG) -DNSF_PLAYER -fno-strict-aliasing +xineplug_decode_nsf_la_CFLAGS = $(AM_CFLAGS) -fno-strict-aliasing +xineplug_decode_nsf_la_CPPFLAGS = -DNSF_PLAYER xineplug_decode_nsf_la_LIBADD = $(XINE_LIB) -lm nosefart/libnosefart.la xineplug_decode_lpcm_la_SOURCES = xine_lpcm_decoder.c -xineplug_decode_lpcm_la_CFLAGS = $(VISIBILITY_FLAG) xineplug_decode_lpcm_la_LIBADD = $(XINE_LIB) xineplug_decode_vorbis_la_SOURCES = xine_vorbis_decoder.c xineplug_decode_vorbis_la_LIBADD = $(XINE_LIB) $(VORBIS_LIBS) $(OGG_LIBS) -xineplug_decode_vorbis_la_CFLAGS = $(VISIBILITY_FLAG) $(VORBIS_CFLAGS) +xineplug_decode_vorbis_la_CFLAGS = $(AM_CFLAGS) $(VORBIS_CFLAGS) xineplug_decode_speex_la_SOURCES = xine_speex_decoder.c xineplug_decode_speex_la_LIBADD = $(XINE_LIB) $(SPEEX_LIBS) -xineplug_decode_speex_la_CFLAGS = $(VISIBILITY_FLAGS) $(SPEEX_CFLAGS) +xineplug_decode_speex_la_CFLAGS = $(AM_CFLAGS) $(SPEEX_CFLAGS) xineplug_decode_mpc_la_SOURCES = xine_musepack_decoder.c -xineplug_decode_mpc_la_CFLAGS = $(VISIBILITY_FLAG) $(MPCDEC_CFLAGS) +xineplug_decode_mpc_la_CFLAGS = $(AM_CFLAGS) $(MPCDEC_CFLAGS) xineplug_decode_mpc_la_DEPENDENCIES = $(MPCDEC_DEPS) xineplug_decode_mpc_la_LIBADD = $(XINE_LIB) $(MPCDEC_LIBS) xineplug_decode_dts_la_SOURCES = xine_dts_decoder.c -xineplug_decode_dts_la_CFLAGS = $(LIBDTS_CFLAGS) $(VISIBILITY_FLAG) +xineplug_decode_dts_la_CFLAGS = $(AM_CFLAGS) $(LIBDTS_CFLAGS) xineplug_decode_dts_la_DEPENDENCIES = $(LIBDTS_DEPS) xineplug_decode_dts_la_LIBADD = $(XINE_LIB) $(LIBDTS_LIBS) diff --git a/src/libxineadec/gsm610/Makefile.am b/src/libxineadec/gsm610/Makefile.am index fe25ad9c3..f2011dfd4 100644 --- a/src/libxineadec/gsm610/Makefile.am +++ b/src/libxineadec/gsm610/Makefile.am @@ -1,5 +1,8 @@ include $(top_srcdir)/misc/Makefile.common +AM_CFLAGS = $(DEFAULT_OCFLAGS) $(VISIBILITY_FLAG) +AM_LDFLAGS = $(xineplug_ldflags) + noinst_LTLIBRARIES = libgsm610.la libgsm610_la_SOURCES = \ @@ -14,8 +17,6 @@ libgsm610_la_SOURCES = \ short_term.c \ table.c -libgsm610_la_CFLAGS = $(VISIBILITY_FLAG) -libgsm610_la_LDFLAGS = -avoid-version -module noinst_HEADERS = \ gsm_config.h \ diff --git a/src/libxineadec/nosefart/Makefile.am b/src/libxineadec/nosefart/Makefile.am index 51cc3f238..83c04a28d 100644 --- a/src/libxineadec/nosefart/Makefile.am +++ b/src/libxineadec/nosefart/Makefile.am @@ -1,5 +1,7 @@ include $(top_srcdir)/misc/Makefile.common +AM_CFLAGS = $(DEFAULT_OCFLAGS) $(VISIBILITY_FLAG) + noinst_LTLIBRARIES = libnosefart.la libnosefart_la_SOURCES = \ @@ -15,7 +17,8 @@ libnosefart_la_SOURCES = \ nsf.c \ vrcvisnd.c -libnosefart_la_CFLAGS = $(VISIBILITY_FLAG) -DNSF_PLAYER -fno-strict-aliasing +libnosefart_la_CFLAGS = $(AM_CFLAGS) -fno-strict-aliasing +libnosefart_la_CPPFLAGS = -DNSF_PLAYER noinst_HEADERS = \ dis6502.h \ diff --git a/src/libxinevdec/Makefile.am b/src/libxinevdec/Makefile.am index 87ee050e6..728991a96 100644 --- a/src/libxinevdec/Makefile.am +++ b/src/libxinevdec/Makefile.am @@ -1,6 +1,6 @@ include $(top_srcdir)/misc/Makefile.common -AM_CFLAGS = $(VISIBILITY_FLAG) +AM_CFLAGS = $(DEFAULT_OCFLAGS) $(VISIBILITY_FLAG) AM_LDFLAGS = $(xineplug_ldflags) EXTRA_DIST = foovideo.c diff --git a/src/post/audio/Makefile.am b/src/post/audio/Makefile.am index f4018a780..3fae4f92c 100644 --- a/src/post/audio/Makefile.am +++ b/src/post/audio/Makefile.am @@ -1,5 +1,8 @@ include $(top_srcdir)/misc/Makefile.common +AM_CFLAGS = $(DEFAULT_OCFLAGS) $(VISIBILITY_FLAG) +AM_LDFLAGS = $(xineplug_ldflags) + noinst_HEADERS = dsp.h filter.h window.h audio_filters.h xinepost_LTLIBRARIES = xineplug_post_audio_filters.la @@ -7,6 +10,4 @@ xinepost_LTLIBRARIES = xineplug_post_audio_filters.la xineplug_post_audio_filters_la_SOURCES = \ upmix.c upmix_mono.c filter.c window.c stretch.c volnorm.c audio_filters.c xineplug_post_audio_filters_la_LIBADD = $(XINE_LIB) $(PTHREAD_LIBS) -lm -xineplug_post_audio_filters_la_CFLAGS = $(VISIBILITY_FLAG) -xineplug_post_audio_filters_la_LDFLAGS = -avoid-version -module diff --git a/src/post/deinterlace/Makefile.am b/src/post/deinterlace/Makefile.am index d2d1d5c10..4296b637c 100644 --- a/src/post/deinterlace/Makefile.am +++ b/src/post/deinterlace/Makefile.am @@ -1,5 +1,8 @@ include $(top_srcdir)/misc/Makefile.common +AM_CFLAGS = $(DEFAULT_OCFLAGS) $(VISIBILITY_FLAG) +AM_LDFLAGS = $(xineplug_ldflags) $(IMPURE_TEXT_LDFLAGS) + SUBDIRS = plugins EXTRA_DIST = @@ -11,8 +14,4 @@ xineplug_post_tvtime_la_SOURCES = xine_plugin.c \ xineplug_post_tvtime_la_LIBADD = $(XINE_LIB) \ $(top_builddir)/src/post/deinterlace/plugins/libdeinterlaceplugins.la -xineplug_post_tvtime_la_CFLAGS = $(VISIBILITY_FLAG) -xineplug_post_tvtime_la_LDFLAGS = -avoid-version -module \ - @IMPURE_TEXT_LDFLAGS@ - noinst_HEADERS = deinterlace.h pulldown.h speedtools.h speedy.h tvtime.h diff --git a/src/post/deinterlace/plugins/Makefile.am b/src/post/deinterlace/plugins/Makefile.am index dcfa60180..33cff9d7f 100644 --- a/src/post/deinterlace/plugins/Makefile.am +++ b/src/post/deinterlace/plugins/Makefile.am @@ -29,10 +29,17 @@ EXTRA_DIST = greedy2frame_template.c greedyh.asm \ tomsmocomp/tomsmocompmacros.h x86-64_macros.inc # libpostproc is here so we can use their nice mangle.h -AM_CFLAGS = -I$(top_srcdir)/src/post/deinterlace \ +AM_CFLAGS = $(VISIBILITY_FLAG) +AM_CPPFLAGS = -I$(top_srcdir)/src/post/deinterlace \ -I$(top_srcdir)/contrib/ffmpeg/libpostproc -noinst_LTLIBRARIES = libdeinterlaceplugins.la +# per-object CFLAGS -- drop optimization on kdetv_greedyh.c so that gcc +# doesn't run out of general registers trying to compile it. + +noinst_LTLIBRARIES = libdeinterlacepluginsO1.la libdeinterlaceplugins.la + +libdeinterlacepluginsO1_la_SOURCES = kdetv_greedyh.c +libdeinterlacepluginsO1_la_CFLAGS = $(AM_CFLAGS) $(O1_CFLAGS) libdeinterlaceplugins_la_SOURCES = \ double.c \ @@ -43,10 +50,9 @@ libdeinterlaceplugins_la_SOURCES = \ weave.c \ greedy2frame.c \ scalerbob.c \ - kdetv_greedyh.c \ kdetv_tomsmocomp.c -libdeinterlaceplugins_la_LIBADD = $(XINE_LIB) -libdeinterlaceplugins_la_CFLAGS = $(VISIBILITY_FLAG) $(AM_CFLAGS) -libdeinterlaceplugins_la_LDFLAGS = -avoid-version -module +libdeinterlaceplugins_la_LIBADD = libdeinterlacepluginsO1.la $(XINE_LIB) +libdeinterlaceplugins_la_CFLAGS = $(AM_CFLAGS) $(DEFAULT_OCFLAGS) +libdeinterlaceplugins_la_LDFLAGS = $(xineplug_ldflags) noinst_HEADERS = plugins.h greedyhmacros.h diff --git a/src/post/goom/Makefile.am b/src/post/goom/Makefile.am index 481b66b41..a8dc13ab0 100644 --- a/src/post/goom/Makefile.am +++ b/src/post/goom/Makefile.am @@ -1,15 +1,18 @@ include $(top_srcdir)/misc/Makefile.common +AM_CFLAGS = $(DEFAULT_OCFLAGS) $(VISIBILITY_FLAG) +AM_LDFLAGS = $(xineplug_ldflags) + EXTRA_DIST = mmx.c xmmx.c ppc_drawings.s ppc_zoom_ultimate.s diff_against_release.patch \ gfontrle.c mathtools.c ## -fomit-frame-pointer segfaults here ## Use -O2 if -Os is stripped or x86 does not build #CFLAGS = `echo @CFLAGS@ | sed -e 's/-fomit-frame-pointer//g;s/-Os/-O2/g'` -CFLAGS = `echo @CFLAGS@ | sed -e 's/-Os/-O2/g'` +#CFLAGS = `echo @CFLAGS@ | sed -e 's/-Os/-O2/g'` # Avoid errors with -O0 -xineplug_post_goom_la-xmmx.o xineplug_post_goom_la-xmmx.lo: CFLAGS=`echo @CFLAGS@ | sed -e 's/-O0\?\s/-Os /g'` +#xineplug_post_goom_la-xmmx.o xineplug_post_goom_la-xmmx.lo: CFLAGS=`echo @CFLAGS@ | sed -e 's/-O0\?\s/-Os /g'` xinepost_LTLIBRARIES = xineplug_post_goom.la @@ -19,18 +22,12 @@ xinepost_LTLIBRARIES = xineplug_post_goom.la #AM_CPPFLAGS = -DCPU_POWERPC #endif -#if HAVE_MMX -extra_files = mmx.c xmmx.c -#endif - -xineplug_post_goom_la_SOURCES = $(extra_files) xine_goom.c \ +xineplug_post_goom_la_SOURCES = mmx.c xmmx.c xine_goom.c \ config_param.c convolve_fx.c cpu_info.c drawmethods.c filters.c flying_stars_fx.c \ gfontlib.c goom_core.c goom_tools.c goomsl.c goomsl_hash.c goomsl_heap.c \ goomsl_lex.c goomsl_yacc.c graphic.c ifs.c lines.c \ plugin_info.c sound_tester.c surf3d.c tentacle3d.c v3d.c xineplug_post_goom_la_LIBADD = $(XINE_LIB) $(GOOM_LIBS) $(PTHREAD_LIBS) -lm -xineplug_post_goom_la_CFLAGS = $(VISIBILITY_FLAG) -xineplug_post_goom_la_LDFLAGS = -avoid-version -module noinst_HEADERS = cpu_info.h default_scripts.h drawmethods.h gfontlib.h goom.h \ goom_config.h goom_config_param.h goom_filters.h goom_fx.h goom_graphic.h \ diff --git a/src/post/mosaico/Makefile.am b/src/post/mosaico/Makefile.am index c18b4e19c..2fa3fc7a5 100644 --- a/src/post/mosaico/Makefile.am +++ b/src/post/mosaico/Makefile.am @@ -1,13 +1,12 @@ include $(top_srcdir)/misc/Makefile.common +AM_CFLAGS = $(DEFAULT_OCFLAGS) $(VISIBILITY_FLAG) +AM_LDFLAGS = $(xineplug_ldflags) + xinepost_LTLIBRARIES = xineplug_post_mosaico.la xineplug_post_switch.la xineplug_post_mosaico_la_SOURCES = mosaico.c xineplug_post_mosaico_la_LIBADD = $(XINE_LIB) $(PTHREAD_LIBS) -xineplug_post_mosaico_la_CFLAGS = $(VISIBILITY_FLAG) -xineplug_post_mosaico_la_LDFLAGS = -avoid-version -module xineplug_post_switch_la_SOURCES = switch.c xineplug_post_switch_la_LIBADD = $(XINE_LIB) $(PTHREAD_LIBS) -xineplug_post_switch_la_CFLAGS = $(VISIBILITY_FLAG) -xineplug_post_switch_la_LDFLAGS = -avoid-version -module diff --git a/src/post/planar/Makefile.am b/src/post/planar/Makefile.am index 4461f8314..a051ea14f 100644 --- a/src/post/planar/Makefile.am +++ b/src/post/planar/Makefile.am @@ -17,21 +17,19 @@ endif # -fomit-frame-pointer is always needed. it might cause debug to not # work, but at least it compiles. -AM_CFLAGS = $(ff_cflags) -fomit-frame-pointer +AM_CFLAGS = $(DEFAULT_OCFLAGS) $(VISIBILITY_FLAG) $(ff_cflags) -fomit-frame-pointer +AM_LDFLAGS = $(xineplug_ldflags) $(IMPURE_TEXT_LDFLAGS) # Avoid errors with -O0 -xineplug_post_planar_la-eq.o xineplug_post_planar_la-eq.lo: CFLAGS=`echo @CFLAGS@ | sed -e 's/-O0\?\s/-Os /g'` -xineplug_post_planar_la-eq2.o xineplug_post_planar_la-eq2.lo: CFLAGS=`echo @CFLAGS@ | sed -e 's/-O0\?\s/-Os /g'` -xineplug_post_planar_la-noise.o xineplug_post_planar_la-noise.lo: CFLAGS=`echo @CFLAGS@ | sed -e 's/-O0\?\s/-Os /g'` +#xineplug_post_planar_la-eq.o xineplug_post_planar_la-eq.lo: CFLAGS=`echo @CFLAGS@ | sed -e 's/-O0\?\s/-Os /g'` +#xineplug_post_planar_la-eq2.o xineplug_post_planar_la-eq2.lo: CFLAGS=`echo @CFLAGS@ | sed -e 's/-O0\?\s/-Os /g'` +#xineplug_post_planar_la-noise.o xineplug_post_planar_la-noise.lo: CFLAGS=`echo @CFLAGS@ | sed -e 's/-O0\?\s/-Os /g'` xinepost_LTLIBRARIES = xineplug_post_planar.la xineplug_post_planar_la_SOURCES = planar.c invert.c expand.c fill.c boxblur.c \ denoise3d.c eq.c eq2.c unsharp.c pp.c noise.c xineplug_post_planar_la_LIBADD = $(XINE_LIB) $(postproc_lib) -lm $(PTHREAD_LIBS) -xineplug_post_planar_la_LDFLAGS = -avoid-version -module \ - @IMPURE_TEXT_LDFLAGS@ -xineplug_post_planar_la_CFLAGS = $(VISIBILITY_FLAG) $(AM_CFLAGS) $(POSTPROC_INT_LIB): cd $(top_builddir)/src/libffmpeg/libavcodec/libpostproc && $(MAKE) libpostprocess.la diff --git a/src/post/visualizations/Makefile.am b/src/post/visualizations/Makefile.am index f42598d9c..a02a74f77 100644 --- a/src/post/visualizations/Makefile.am +++ b/src/post/visualizations/Makefile.am @@ -1,5 +1,8 @@ include $(top_srcdir)/misc/Makefile.common +AM_CFLAGS = $(DEFAULT_OCFLAGS) $(VISIBILITY_FLAG) +AM_LDFLAGS = $(xineplug_ldflags) + EXTRA_DIST = fooviz.c xinepost_LTLIBRARIES = xineplug_post_visualizations.la @@ -7,7 +10,5 @@ xinepost_LTLIBRARIES = xineplug_post_visualizations.la xineplug_post_visualizations_la_SOURCES = \ visualizations.c fft.c fftscope.c oscope.c fftgraph.c xineplug_post_visualizations_la_LIBADD = $(XINE_LIB) $(PTHREAD_LIBS) -lm -xineplug_post_visualizations_la_CFLAGS = $(VISIBILITY_FLAG) -xineplug_post_visualizations_la_LDFLAGS = -avoid-version -module noinst_HEADERS = fft.h visualizations.h diff --git a/src/video_out/Makefile.am b/src/video_out/Makefile.am index 148eda84c..acab646c8 100644 --- a/src/video_out/Makefile.am +++ b/src/video_out/Makefile.am @@ -1,13 +1,14 @@ include $(top_srcdir)/misc/Makefile.common -AM_CPPFLAGS = -DXINE_COMPILE +AM_CFLAGS = $(DEFAULT_OCFLAGS) $(VISIBILITY_FLAG) AM_LDFLAGS = $(xineplug_ldflags) +AM_OBJCFLAGS = $(DEFAULT_OCFLAGS) $(VISIBILITY_FLAG) SUBDIRS = libdha vidix macosx EXTRA_DIST = video_out_directfb.c video_out_directfb_fb.c video_out_directfb_x.c video_out_directx.c video_out_macosx.m -VIDIX_CFLAGS = -I$(top_builddir)/src/video_out/vidix \ +VIDIX_CPPFLAGS = -I$(top_builddir)/src/video_out/vidix \ -I$(top_srcdir)/src/video_out/vidix if HAVE_X11 @@ -104,101 +105,93 @@ xineplug_LTLIBRARIES = $(xshm_module) $(xv_module) $(xvmc_module) \ xineplug_vo_out_xcbshm_la_SOURCES = yuv2rgb.c yuv2rgb_mmx.c yuv2rgb_mlib.c video_out_xcbshm.c $(XCBOSD) xineplug_vo_out_xcbshm_la_LIBADD = $(MLIB_LIBS) $(XINE_LIB) $(PTHREAD_LIBS) $(XCB_LIBS) $(XCBSHM_LIBS) -xineplug_vo_out_xcbshm_la_CFLAGS = $(VISIBILITY_FLAG) $(MLIB_CFLAGS) $(XCB_CFLAGS) $(XCBSHM_CFLAGS) +xineplug_vo_out_xcbshm_la_CFLAGS = $(AM_CFLAGS) $(MLIB_CFLAGS) $(XCB_CFLAGS) $(XCBSHM_CFLAGS) xineplug_vo_out_xcbxv_la_SOURCES = deinterlace.c video_out_xcbxv.c $(XCBOSD) xineplug_vo_out_xcbxv_la_LIBADD = $(XINE_LIB) $(PTHREAD_LIBS) $(XCBXV_LIBS) $(XCB_LIBS) -xineplug_vo_out_xcbxv_la_CFLAGS = $(VISIBILITY_FLAG) $(XCB_CFLAGS) $(XCBXV_CFLAGS) +xineplug_vo_out_xcbxv_la_CFLAGS = $(AM_CFLAGS) $(XCB_CFLAGS) $(XCBXV_CFLAGS) xineplug_vo_out_xshm_la_SOURCES = yuv2rgb.c yuv2rgb_mmx.c yuv2rgb_mlib.c \ video_out_xshm.c $(X11OSD) xineplug_vo_out_xshm_la_LIBADD = $(MLIB_LIBS) $(X_LIBS) $(XINE_LIB) $(PTHREAD_LIBS) -xineplug_vo_out_xshm_la_CFLAGS = $(VISIBILITY_FLAG) $(X_CFLAGS) $(MLIB_CFLAGS) -fno-strict-aliasing +xineplug_vo_out_xshm_la_CFLAGS = $(AM_CFLAGS) $(X_CFLAGS) $(MLIB_CFLAGS) -fno-strict-aliasing xineplug_vo_out_xv_la_SOURCES = $(X11OSD) deinterlace.c video_out_xv.c xineplug_vo_out_xv_la_LIBADD = $(XV_LIBS) $(X_LIBS) $(XINE_LIB) $(PTHREAD_LIBS) -xineplug_vo_out_xv_la_CFLAGS = $(VISIBILITY_FLAG) $(X_CFLAGS) $(XV_CFLAGS) -fno-strict-aliasing +xineplug_vo_out_xv_la_CFLAGS = $(AM_CFLAGS) $(X_CFLAGS) $(XV_CFLAGS) -fno-strict-aliasing xineplug_vo_out_xvmc_la_SOURCES = deinterlace.c video_out_xvmc.c xineplug_vo_out_xvmc_la_LIBADD = $(XVMC_LIBS) $(XV_LIBS) $(X_LIBS) $(XINE_LIB) $(PTHREAD_LIBS) -xineplug_vo_out_xvmc_la_CFLAGS = $(VISIBILITY_FLAG) $(X_CFLAGS) $(XV_CFLAGS) +xineplug_vo_out_xvmc_la_CFLAGS = $(AM_CFLAGS) $(X_CFLAGS) $(XV_CFLAGS) xineplug_vo_out_xxmc_la_SOURCES = $(X11OSD) deinterlace.c video_out_xxmc.c\ xvmc_mocomp.c xvmc_vld.c xxmc.h xineplug_vo_out_xxmc_la_LIBADD = $(XXMC_LIBS) $(XV_LIBS) $(X_LIBS) $(XINE_LIB) $(PTHREAD_LIBS) -xineplug_vo_out_xxmc_la_CFLAGS = $(VISIBILITY_FLAG) $(X_CFLAGS) $(XV_CFLAGS) -fno-strict-aliasing +xineplug_vo_out_xxmc_la_CFLAGS = $(AM_CFLAGS) $(X_CFLAGS) $(XV_CFLAGS) -fno-strict-aliasing xineplug_vo_out_opengl_la_SOURCES = yuv2rgb.c yuv2rgb_mmx.c yuv2rgb_mlib.c \ video_out_opengl.c myglext.h $(X11OSD) xineplug_vo_out_opengl_la_LIBADD = $(MLIB_LIBS) $(OPENGL_LIBS) $(GLUT_LIBS) \ $(GLU_LIBS) $(X_LIBS) $(XINE_LIB) $(PTHREAD_LIBS) $(DYNAMIC_LD_LIBS) -xineplug_vo_out_opengl_la_CFLAGS = $(VISIBILITY_FLAG) $(X_CFLAGS) $(MLIB_CFLAGS) -fno-strict-aliasing +xineplug_vo_out_opengl_la_CFLAGS = $(AM_CFLAGS) $(X_CFLAGS) $(MLIB_CFLAGS) -fno-strict-aliasing xineplug_vo_out_syncfb_la_SOURCES = video_out_syncfb.c xineplug_vo_out_syncfb_la_LIBADD = $(X_LIBS) $(XINE_LIB) $(PTHREAD_LIBS) -xineplug_vo_out_syncfb_la_CFLAGS = $(VISIBILITY_FLAG) xineplug_vo_out_pgx64_la_SOURCES = video_out_pgx64.c xineplug_vo_out_pgx64_la_LIBADD = $(XINE_LIB) $(X_LIBS) $(SUNDGA_LIBS) $(PTHREAD_LIBS) -xineplug_vo_out_pgx64_la_CFLAGS = $(VISIBILITY_FLAG) $(X_CFLAGS) +xineplug_vo_out_pgx64_la_CFLAGS = $(AM_CFLAGS) $(X_CFLAGS) xineplug_vo_out_pgx32_la_SOURCES = video_out_pgx32.c xineplug_vo_out_pgx32_la_LIBADD = $(XINE_LIB) $(X_LIBS) $(SUNDGA_LIBS) $(PTHREAD_LIBS) -xineplug_vo_out_pgx32_la_CFLAGS = $(VISIBILITY_FLAG) $(X_CFLAGS) +xineplug_vo_out_pgx32_la_CFLAGS = $(AM_CFLAGS) $(X_CFLAGS) xineplug_vo_out_vidix_la_SOURCES = video_out_vidix.c $(X11OSD) xineplug_vo_out_vidix_la_LIBADD = $(XINE_LIB) $(X_LIBS) \ $(top_builddir)/src/video_out/vidix/libvidix.la $(PTHREAD_LIBS) -xineplug_vo_out_vidix_la_CFLAGS = $(VISIBILITY_FLAG) $(VIDIX_CFLAGS) $(X_CFLAGS) -fno-strict-aliasing +xineplug_vo_out_vidix_la_CFLAGS = $(AM_CFLAGS) $(X_CFLAGS) -fno-strict-aliasing +xineplug_vo_out_vidix_la_CPPFLAGS = $(VIDIX_CPPFLAGS) xineplug_vo_out_aa_la_SOURCES = video_out_aa.c xineplug_vo_out_aa_la_LIBADD = $(AALIB_LIBS) $(XINE_LIB) $(PTHREAD_LIBS) -xineplug_vo_out_aa_la_CFLAGS = $(VISIBILITY_FLAG) $(AALIB_CFLAGS) +xineplug_vo_out_aa_la_CFLAGS = $(AM_CFLAGS) $(AALIB_CFLAGS) xineplug_vo_out_caca_la_SOURCES = yuv2rgb.c yuv2rgb_mmx.c yuv2rgb_mlib.c \ video_out_caca.c xineplug_vo_out_caca_la_LIBADD = $(CACA_LIBS) $(XINE_LIB) $(PTHREAD_LIBS) -xineplug_vo_out_caca_la_CFLAGS = $(VISIBILITY_FLAG) $(CACA_CFLAGS) +xineplug_vo_out_caca_la_CFLAGS = $(AM_CFLAGS) $(CACA_CFLAGS) xineplug_vo_out_fb_la_SOURCES = yuv2rgb.c yuv2rgb_mmx.c yuv2rgb_mlib.c \ video_out_fb.c xineplug_vo_out_fb_la_LIBADD = $(MLIB_LIBS) $(XINE_LIB) $(PTHREAD_LIBS) -xineplug_vo_out_fb_la_CFLAGS = $(VISIBILITY_FLAG) $(MLIB_CFLAGS) +xineplug_vo_out_fb_la_CFLAGS = $(AM_CFLAGS) $(MLIB_CFLAGS) xineplug_vo_out_directfb_la_SOURCES = video_out_directfb_fb.c xineplug_vo_out_directfb_la_LIBADD = $(XINE_LIB) $(DIRECTFB_LIBS) $(PTHREAD_LIBS) -xineplug_vo_out_directfb_la_CFLAGS = $(VISIBILITY_FLAG) $(DIRECTFB_CFLAGS) -fno-strict-aliasing +xineplug_vo_out_directfb_la_CFLAGS = $(AM_CFLAGS) $(DIRECTFB_CFLAGS) -fno-strict-aliasing xineplug_vo_out_xdirectfb_la_SOURCES = video_out_directfb_x.c $(X11OSD) xineplug_vo_out_xdirectfb_la_LIBADD = $(XINE_LIB) $(DIRECTFB_LIBS) $(X_LIBS) $(PTHREAD_LIBS) -xineplug_vo_out_xdirectfb_la_CFLAGS = $(VISIBILITY_FLAG) $(DIRECTFB_CFLAGS) -fno-strict-aliasing +xineplug_vo_out_xdirectfb_la_CFLAGS = $(AM_CFLAGS) $(DIRECTFB_CFLAGS) -fno-strict-aliasing xineplug_vo_out_sdl_la_SOURCES = video_out_sdl.c xineplug_vo_out_sdl_la_LIBADD = $(SDL_LIBS) $(X_LIBS) $(XINE_LIB) $(PTHREAD_LIBS) -xineplug_vo_out_sdl_la_CFLAGS = $(VISIBILITY_FLAG) $(X_CFLAGS) $(SDL_CFLAGS) +xineplug_vo_out_sdl_la_CFLAGS = $(AM_CFLAGS) $(X_CFLAGS) $(SDL_CFLAGS) xineplug_vo_out_stk_la_SOURCES = video_out_stk.c xineplug_vo_out_stk_la_LIBADD = $(XINE_LIB) $(LIBSTK_LIBS) $(PTHREAD_LIBS) -xineplug_vo_out_stk_la_CFLAGS = $(VISIBILITY_FLAG) $(LIBSTK_CFLAGS) +xineplug_vo_out_stk_la_CFLAGS = $(AM_CFLAGS) $(LIBSTK_CFLAGS) xineplug_vo_out_directx_la_SOURCES = yuv2rgb.c yuv2rgb_mmx.c video_out_directx.c -xineplug_vo_out_directx_la_CPPFLAGS = $(AM_CPPFLAGS) $(DIRECTX_CPPFLAGS) +xineplug_vo_out_directx_la_CPPFLAGS = $(DIRECTX_CPPFLAGS) xineplug_vo_out_directx_la_LIBADD = $(DIRECTX_VIDEO_LIBS) $(XINE_LIB) $(PTHREAD_LIBS) -xineplug_vo_out_directx_la_CFLAGS = $(VISIBILITY_FLAG) xineplug_vo_out_none_la_SOURCES = video_out_none.c xineplug_vo_out_none_la_LIBADD = $(XINE_LIB) $(PTHREAD_LIBS) -xineplug_vo_out_none_la_CFLAGS = $(VISIBILITY_FLAG) xineplug_vo_out_macosx_la_SOURCES = video_out_macosx.m -xineplug_vo_out_macosx_la_CPPFLAGS = $(AM_CPPFLAGS) $(X_CFLAGS) $(MLIB_CFLAGS) -xineplug_vo_out_macosx_la_OBJCFLAGS = $(VISIBILITY_FLAG) -xineplug_vo_out_macosx_la_LIBADD = $(MLIB_LIBS) $(OPENGL_LIBS) $(GLUT_LIBS) \ - $(GLU_LIBS) $(X_LIBS) $(XINE_LIB) $(PTHREAD_LIBS) -# The "-Wl,-framework -Wl,Cocoa" is needed for libtool versions before -# 1.5.x (1.257): the default version that ships with Mac OS X is 1.5 (1.1220) -xineplug_vo_out_macosx_la_LDFLAGS = $(AM_LDFLAGS) \ - -Wl,-framework -Wl,Cocoa -framework Cocoa -framework OpenGL +xineplug_vo_out_macosx_la_LIBADD = $(XINE_LIB) $(PTHREAD_LIBS) +xineplug_vo_out_macosx_la_LDFLAGS = $(AM_LDFLAGS) -framework Cocoa -framework OpenGL noinst_HEADERS = deinterlace.h video_out_syncfb.h \ yuv2rgb.h x11osd.h xcbosd.h diff --git a/src/video_out/libdha/Makefile.am b/src/video_out/libdha/Makefile.am index 8d94347d1..553907fc9 100644 --- a/src/video_out/libdha/Makefile.am +++ b/src/video_out/libdha/Makefile.am @@ -4,7 +4,7 @@ EXTRA_DIST = README pci_db2c.awk SUBDIRS = bin kernelhelper oth sysdep -AM_CFLAGS = @STATIC@ +AM_CFLAGS = $(DEFAULT_OCFLAGS) $(STATIC) if HAVE_VIDIX dha_lib = libdha.la diff --git a/src/video_out/macosx/Makefile.am b/src/video_out/macosx/Makefile.am index a69f30dc5..d649dfe1d 100644 --- a/src/video_out/macosx/Makefile.am +++ b/src/video_out/macosx/Makefile.am @@ -1,6 +1,6 @@ include $(top_srcdir)/misc/Makefile.common -AM_CPPFLAGS = -DXINE_COMPILE +AM_OBJCFLAGS = $(DEFAULT_OCFLAGS) $(VISIBILITY_FLAG) EXTRA_DIST = \ video_window.h \ @@ -14,12 +14,8 @@ if HAVE_MACOSX_VIDEO lib_LTLIBRARIES = libxineMacOSXVideo.la libxineMacOSXVideo_la_SOURCES = XineOpenGLView.m XineVideoWindow.m -# The "-Wl,-framework -Wl,..." is needed for libtool versions before -# 1.5.x (1.257): the default version that ships with Mac OS X is 1.5 (1.1220) -libxineMacOSXVideo_la_LDFLAGS = -version-info \ - $(XINE_LT_CURRENT):$(XINE_LT_REVISION):$(XINE_LT_AGE) \ - -Wl,-framework -Wl,Cocoa -framework Cocoa \ - -Wl,-framework -Wl,OpenGL -framework OpenGL +libxineMacOSXVideo_la_LDFLAGS = -framework Cocoa -framework OpenGL \ + -version-info $(XINE_LT_CURRENT):$(XINE_LT_REVISION):$(XINE_LT_AGE) xineinclude_HEADERS = video_window.h XineOpenGLView.h XineVideoWindow.h diff --git a/src/video_out/vidix/Makefile.am b/src/video_out/vidix/Makefile.am index 2ca8f168a..e002c56f0 100644 --- a/src/video_out/vidix/Makefile.am +++ b/src/video_out/vidix/Makefile.am @@ -4,7 +4,9 @@ EXTRA_DIST = README vidix.txt SUBDIRS = drivers -AM_CFLAGS = @STATIC@ +AM_CFLAGS = $(STATIC) +AM_CPPFLAGS = -I$(top_srcdir)/src/video_out/vidix \ + -I$(top_builddir)/src/video_out/libdha if HAVE_VIDIX vidix_lib = libvidix.la @@ -17,5 +19,3 @@ libvidix_la_LIBADD = $(DYNAMIC_LD_LIBS) $(top_builddir)/src/video_out/libdha/lib noinst_HEADERS = fourcc.h vidix.h vidixlib.h -AM_CPPFLAGS = -I$(top_srcdir)/src/video_out/vidix \ - -I$(top_builddir)/src/video_out/libdha diff --git a/src/video_out/vidix/drivers/Makefile.am b/src/video_out/vidix/drivers/Makefile.am index f438dde36..23272e4c9 100644 --- a/src/video_out/vidix/drivers/Makefile.am +++ b/src/video_out/vidix/drivers/Makefile.am @@ -1,5 +1,11 @@ include $(top_srcdir)/misc/Makefile.common +AM_CFLAGS = $(DEFAULT_OCFLAGS) +AM_CPPFLAGS = -I$(top_srcdir)/src/video_out/vidix \ + -I$(top_srcdir)/src/video_out/libdha \ + -I$(top_builddir)/src/video_out/libdha +AM_LDFLAGS = $(xineplug_ldflags) + EXTRA_DIST = genfb_vid.c if HAVE_VIDIX @@ -21,46 +27,36 @@ endif vidix_LTLIBRARIES = $(vidix_drivers) radeon_vid_la_SOURCES = radeon_vid.c -radeon_vid_la_LDFLAGS = -avoid-version -module -lm +radeon_vid_la_LIBADD = -lm rage128_vid_la_SOURCES = radeon_vid.c -rage128_vid_la_LDFLAGS = -avoid-version -module -lm -rage128_vid_la_CFLAGS = -DRAGE128 $(AM_CFLAGS) +rage128_vid_la_LIBADD = -lm +rage128_vid_la_CPPFLAGS = $(AM_CPPFLAGS) -DRAGE128 pm2_vid_la_SOURCES = pm2_vid.c -pm2_vid_la_LDFLAGS = -avoid-version -module pm3_vid_la_SOURCES = pm3_vid.c -pm3_vid_la_LDFLAGS = -avoid-version -module mach64_vid_la_SOURCES = mach64_vid.c -mach64_vid_la_LDFLAGS = -avoid-version -module mga_vid_la_SOURCES = mga_vid.c -mga_vid_la_LDFLAGS = -avoid-version -module -lm +mga_vid_la_LIBADD = -lm mga_crtc2_vid_la_SOURCES = mga_vid.c -mga_crtc2_vid_la_LDFLAGS = -avoid-version -module -lm -mga_crtc2_vid_la_CFLAGS = -DCRTC2 $(AM_CFLAGS) +mga_crtc2_vid_la_LIBADD = -lm +mga_crtc2_vid_la_CPPFLAGS = $(AM_CPPFLAGS) -DCRTC2 cyberblade_vid_la_SOURCES = cyberblade_vid.c -cyberblade_vid_la_LDFLAGS = -avoid-version -module unichrome_vid_la_SOURCES = unichrome_vid.c -unichrome_vid_la_LDFLAGS = -avoid-version -module nvidia_vid_la_SOURCES = nvidia_vid.c -nvidia_vid_la_LDFLAGS = -avoid-version -module sis_vid_la_SOURCES = sis_vid.c sis_bridge.c -sis_vid_la_LDFLAGS = -avoid-version -module savage_vid_la_SOURCES = savage_vid.c -savage_vid_la_LDFLAGS = -avoid-version -module -lm +savage_vid_la_LIBADD = -lm noinst_HEADERS = mach64.h glint_regs.h pm3_regs.h radeon.h savage_regs.h \ cyberblade_regs.h unichrome_regs.h sis_defs.h sis_regs.h -AM_CPPFLAGS = -I$(top_srcdir)/src/video_out/vidix \ - -I$(top_srcdir)/src/video_out/libdha \ - -I$(top_builddir)/src/video_out/libdha diff --git a/src/xine-engine/Makefile.am b/src/xine-engine/Makefile.am index aeb142708..f64dacba1 100644 --- a/src/xine-engine/Makefile.am +++ b/src/xine-engine/Makefile.am @@ -1,10 +1,9 @@ include $(top_srcdir)/misc/Makefile.common include $(top_srcdir)/lib/Makefile.common -AM_CFLAGS = $(X_CFLAGS) $(FT2_CFLAGS) $(FONTCONFIG_CFLAGS) $(XDG_BASEDIR_CFLAGS) $(VISIBILITY_FLAG) +AM_CFLAGS = $(DEFAULT_OCFLAGS) $(X_CFLAGS) $(FT2_CFLAGS) $(FONTCONFIG_CFLAGS) $(XDG_BASEDIR_CFLAGS) $(VISIBILITY_FLAG) AM_CPPFLAGS = $(ZLIB_CPPFLAGS) -DXINE_LIBRARY_COMPILE -LIBTOOL = $(SHELL) $(top_builddir)/libtool lib_LTLIBRARIES = libxine.la XINEUTILS_LIB = $(top_builddir)/src/xine-utils/libxineutils.la diff --git a/src/xine-utils/Makefile.am b/src/xine-utils/Makefile.am index 95de06b9e..1e58d9fc1 100644 --- a/src/xine-utils/Makefile.am +++ b/src/xine-utils/Makefile.am @@ -1,6 +1,5 @@ include $(top_srcdir)/misc/Makefile.common -LIBTOOL = $(SHELL) $(top_builddir)/libtool noinst_LTLIBRARIES = libxineutils.la EXTRA_DIST = ppcasm_string.S ppc_asm.tmpl @@ -11,7 +10,7 @@ pppc_files = ppcasm_string.S endif endif -AM_CFLAGS = $(X_CFLAGS) $(VISIBILITY_FLAG) +AM_CFLAGS = $(DEFAULT_OCFLAGS) $(X_CFLAGS) $(VISIBILITY_FLAG) AM_CPPFLAGS=-DXINE_LIBRARY_COMPILE libxineutils_la_SOURCES = $(pppc_files) \ diff --git a/version.sh b/version.sh new file mode 100755 index 000000000..2d9438379 --- /dev/null +++ b/version.sh @@ -0,0 +1,50 @@ +#!/bin/sh + +# Making releases: +# 1. Increment XINE_VERSION_SUB +# 2. Remove .cvsversion before running make dist +# 3. Adjust the values of XINE_LT_CURRENT, XINE_LT_REVISION, and XINE_LT_AGE +# according to the following rules: +# +# If the interface is totally unchanged from the previous release, +# increment XINE_LT_REVISION by one. Otherwise: +# 1. XINE_LT_REVISION=0 +# 2. Increment XINE_LT_CURRENT by one. +# 3. If any interfaces have been ADDED since the last release, +# increment XINE_LT_AGE by one. If any interfaces have been +# REMOVED or incompatibly changed, XINE_LT_AGE=0 +# +# Regarding libtool versioning, here are some details, but see the info page for +# libtool for the whole story. The most important thing to keep in mind is that +# the libtool version numbers DO NOT MATCH the xine-lib version numbers, and you +# should NEVER try to make them match. +# +# XINE_LT_CURRENT the current API version +# XINE_LT_REVISION an internal revision number that is increased when the +# API does not change in any way +# XINE_LT_AGE the number of previous API versions still supported by +# this version + +XINE_VERSION_MAJOR=1 +XINE_VERSION_MINOR=1 +XINE_VERSION_SUB=90 + +XINE_LT_CURRENT=19 +XINE_LT_REVISION=0 +XINE_LT_AGE=17 + +test -f "`dirname $0`/.cvsversion" && XINE_VERSION_SUFFIX="hg" +XINE_VERSION_SPEC="${XINE_VERSION_MAJOR}.${XINE_VERSION_MINOR}.${XINE_VERSION_SUB}${XINE_VERSION_SUFFIX}" + +#### +#### You should not need to touch anything beyond this point +#### + +echo "m4_define([XINE_VERSION_MAJOR], [${XINE_VERSION_MAJOR}])dnl" +echo "m4_define([XINE_VERSION_MINOR], [${XINE_VERSION_MINOR}])dnl" +echo "m4_define([XINE_VERSION_SUB], [${XINE_VERSION_SUB}])dnl" +echo "m4_define([XINE_VERSION_SUFFIX], [${XINE_VERSION_SUFFIX}])dnl" +echo "m4_define([XINE_VERSION_SPEC], [${XINE_VERSION_SPEC}])dnl" +echo "m4_define([__XINE_LT_CURRENT], [${XINE_LT_CURRENT}])dnl" +echo "m4_define([__XINE_LT_REVISION], [${XINE_LT_REVISION}])dnl" +echo "m4_define([__XINE_LT_AGE], [${XINE_LT_AGE}])dnl" |