aboutsummaryrefslogtreecommitdiff
path: root/configure
diff options
context:
space:
mode:
authorSebastian Pop <sebastian.pop@amd.com>2011-03-02 03:48:44 +0000
committerSebastian Pop <spop@gcc.gnu.org>2011-03-02 03:48:44 +0000
commit7d32a44014d3681d969c257f60d5d7f554fc165c (patch)
tree8d7d40603030f117b9ae8a5796f3eca2770d9c73 /configure
parent3d2bc11b8d07d7efec102710437ff4c159f0bff8 (diff)
downloadgcc-7d32a44014d3681d969c257f60d5d7f554fc165c.zip
gcc-7d32a44014d3681d969c257f60d5d7f554fc165c.tar.gz
gcc-7d32a44014d3681d969c257f60d5d7f554fc165c.tar.bz2
Add -lpwl to ppllibs.
2011-03-02 Sebastian Pop <sebastian.pop@amd.com> * configure.ac: Add -lpwl to ppllibs. * configure: Regenerated. From-SVN: r170610
Diffstat (limited to 'configure')
-rwxr-xr-xconfigure108
1 files changed, 84 insertions, 24 deletions
diff --git a/configure b/configure
index ac7db39..997282f 100755
--- a/configure
+++ b/configure
@@ -5660,8 +5660,9 @@ fi
# Check for PPL
-ppllibs=" -lppl_c -lppl -lgmpxx"
+ppllibs=
pplinc=
+pwllib=
# Check whether --with-ppl was given.
@@ -5682,52 +5683,110 @@ if test "${with_ppl_lib+set}" = set; then :
fi
+# Check whether --enable-ppl-version-check was given.
+if test "${enable_ppl_version_check+set}" = set; then :
+ enableval=$enable_ppl_version_check;
+fi
+
+
case $with_ppl in
- no)
- ppllibs=
- ;;
- "" | yes)
+ yes | no | "")
;;
*)
- ppllibs="-L$with_ppl/lib -lppl_c -lppl -lgmpxx"
+ ppllibs="-L$with_ppl/lib"
pplinc="-I$with_ppl/include $pplinc"
+ if test -d "$with_ppl/lib" && test -d "$with_ppl/include"; then
+ with_ppl=yes
+ else
+ as_fn_error "cannot find directories \"$with_ppl/lib\" or \"$with_ppl/include\"" "$LINENO" 5
+ fi
;;
esac
-if test "x$with_ppl_include" != x; then
+
+if test x"$with_ppl_include" != x; then
pplinc="-I$with_ppl_include $pplinc"
+ with_ppl=yes
fi
+
if test "x$with_ppl_lib" != x; then
- ppllibs="-L$with_ppl_lib -lppl_c -lppl -lgmpxx"
+ ppllibs="-L$with_ppl_lib"
+ with_ppl=yes
fi
-if test "x$with_ppl$with_ppl_include$with_ppl_lib" = x && test -d ${srcdir}/ppl; then
- ppllibs='-L$$r/$(HOST_SUBDIR)/ppl/interfaces/C/'"$lt_cv_objdir"' -L$$r/$(HOST_SUBDIR)/ppl/src/'"$lt_cv_objdir"' -lppl_c -lppl -lgmpxx '
+
+if test x"$with_ppl$with_ppl_include$with_ppl_lib" = x && test -d ${srcdir}/ppl; then
+ if test x"$enable_watchdog" = xyes; then
+ pwllib="-lpwl"
+ fi
+ ppllibs='-L$$r/$(HOST_SUBDIR)/ppl/interfaces/C/'"$lt_cv_objdir"' -L$$r/$(HOST_SUBDIR)/ppl/src/'"$lt_cv_objdir"
pplinc='-I$$r/$(HOST_SUBDIR)/ppl/src -I$$r/$(HOST_SUBDIR)/ppl/interfaces/C '
enable_ppl_version_check=no
+ with_ppl=yes
fi
-# Check whether --enable-ppl-version-check was given.
-if test "${enable_ppl_version_check+set}" = set; then :
- enableval=$enable_ppl_version_check; ENABLE_PPL_CHECK=$enableval
+if test "x$with_ppl" = xyes; then
+ if test "x$pwllib" = x; then
+ saved_LDFLAGS="$LDFLAGS"
+ LDFLAGS="$LDFLAGS $ppllibs"
+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PWL_handle_timeout in -lpwl" >&5
+$as_echo_n "checking for PWL_handle_timeout in -lpwl... " >&6; }
+if test "${ac_cv_lib_pwl_PWL_handle_timeout+set}" = set; then :
+ $as_echo_n "(cached) " >&6
+else
+ ac_check_lib_save_LIBS=$LIBS
+LIBS="-lpwl $LIBS"
+cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h. */
+
+/* Override any GCC internal prototype to avoid an error.
+ Use char because int might match the return type of a GCC
+ builtin and then its argument prototype would still apply. */
+#ifdef __cplusplus
+extern "C"
+#endif
+char PWL_handle_timeout ();
+int
+main ()
+{
+return PWL_handle_timeout ();
+ ;
+ return 0;
+}
+_ACEOF
+if ac_fn_c_try_link "$LINENO"; then :
+ ac_cv_lib_pwl_PWL_handle_timeout=yes
else
- ENABLE_PPL_CHECK=yes
+ ac_cv_lib_pwl_PWL_handle_timeout=no
+fi
+rm -f core conftest.err conftest.$ac_objext \
+ conftest$ac_exeext conftest.$ac_ext
+LIBS=$ac_check_lib_save_LIBS
+fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pwl_PWL_handle_timeout" >&5
+$as_echo "$ac_cv_lib_pwl_PWL_handle_timeout" >&6; }
+if test "x$ac_cv_lib_pwl_PWL_handle_timeout" = x""yes; then :
+ pwllib="-lpwl"
fi
+ LDFLAGS="$saved_LDFLAGS"
+ fi
-if test "x$with_ppl" != "xno" -a "${ENABLE_PPL_CHECK}" = "yes"; then
- saved_CFLAGS="$CFLAGS"
- CFLAGS="$CFLAGS $pplinc $gmpinc"
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for version 0.11 (or later revision) of PPL" >&5
-$as_echo_n "checking for version 0.11 (or later revision) of PPL... " >&6; }
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+ ppllibs="$ppllibs -lppl_c -lppl $pwllib -lgmpxx"
+
+ if test "$enable_ppl_version_check" != no; then
+ saved_CFLAGS="$CFLAGS"
+ CFLAGS="$CFLAGS $pplinc $gmpinc"
+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for version 0.11 (revision 0 or later) of PPL" >&5
+$as_echo_n "checking for version 0.11 (revision 0 or later) of PPL... " >&6; }
+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
#include "ppl_c.h"
int
main ()
{
- #if PPL_VERSION_MAJOR != 0 || PPL_VERSION_MINOR < 11
- choke me
- #endif
+ #if PPL_VERSION_MAJOR != 0 || PPL_VERSION_MINOR < 11
+ choke me
+ #endif
;
return 0;
@@ -5741,7 +5800,8 @@ else
$as_echo "no" >&6; }; ppllibs= ; pplinc= ; with_ppl=no
fi
rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- CFLAGS="$saved_CFLAGS"
+ CFLAGS="$saved_CFLAGS"
+ fi
fi
# Flags needed for PPL