⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 aclocal.m4

📁 minicom的源码,linux下常用的串口程序.
💻 M4
📖 第 1 页 / 共 5 页
字号:
dnl gives unlimited permission to copy and/or distribute it,dnl with or without modifications, as long as this notice is preserved.dnl Subroutines of libtool.m4,dnl with replacements s/AC_/AC_LIB/ and s/lt_cv/acl_cv/ to avoid collisiondnl with libtool.m4.dnl From libtool-1.4. Sets the variable with_gnu_ld to yes or no.AC_DEFUN([AC_LIB_PROG_LD_GNU],[AC_CACHE_CHECK([if the linker ($LD) is GNU ld], acl_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'*)  acl_cv_prog_gnu_ld=yes ;;*)  acl_cv_prog_gnu_ld=no ;;esac])with_gnu_ld=$acl_cv_prog_gnu_ld])dnl From libtool-1.4. Sets the variable LD.AC_DEFUN([AC_LIB_PROG_LD],[AC_ARG_WITH(gnu-ld,[  --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([AC_PROG_CC])dnlAC_REQUIRE([AC_CANONICAL_HOST])dnl# Prepare PATH_SEPARATOR.# The user is always right.if test "${PATH_SEPARATOR+set}" != set; then  echo "#! /bin/sh" >conf$$.sh  echo  "exit 0"   >>conf$$.sh  chmod +x conf$$.sh  if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then    PATH_SEPARATOR=';'  else    PATH_SEPARATOR=:  fi  rm -f conf$$.shfiac_prog=ldif test "$GCC" = yes; then  # Check if gcc -print-prog-name=ld gives a path.  AC_MSG_CHECKING([for ld used by GCC])  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.    [[\\/]* | [A-Za-z]:[\\/]*)]      [re_direlt='/[^/][^/]*/\.\./']      # Canonicalize the path 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    ;;  esacelif test "$with_gnu_ld" = yes; then  AC_MSG_CHECKING([for GNU ld])else  AC_MSG_CHECKING([for non-GNU ld])fiAC_CACHE_VAL(acl_cv_path_LD,[if test -z "$LD"; then  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}"  for ac_dir in $PATH; do    test -z "$ac_dir" && ac_dir=.    if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then      acl_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 `"$acl_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="$ac_save_ifs"else  acl_cv_path_LD="$LD" # Let the user override the test with a path.fi])LD="$acl_cv_path_LD"if test -n "$LD"; then  AC_MSG_RESULT($LD)else  AC_MSG_RESULT(no)fitest -z "$LD" && AC_MSG_ERROR([no acceptable ld found in \$PATH])AC_LIB_PROG_LD_GNU])# lib-link.m4 serial 6 (gettext-0.14.3)dnl Copyright (C) 2001-2005 Free Software Foundation, Inc.dnl This file is free software; the Free Software Foundationdnl gives unlimited permission to copy and/or distribute it,dnl with or without modifications, as long as this notice is preserved.dnl From Bruno Haible.AC_PREREQ(2.50)dnl AC_LIB_LINKFLAGS(name [, dependencies]) searches for libname anddnl the libraries corresponding to explicit and implicit dependencies.dnl Sets and AC_SUBSTs the LIB${NAME} and LTLIB${NAME} variables anddnl augments the CPPFLAGS variable.AC_DEFUN([AC_LIB_LINKFLAGS],[  AC_REQUIRE([AC_LIB_PREPARE_PREFIX])  AC_REQUIRE([AC_LIB_RPATH])  define([Name],[translit([$1],[./-], [___])])  define([NAME],[translit([$1],[abcdefghijklmnopqrstuvwxyz./-],                               [ABCDEFGHIJKLMNOPQRSTUVWXYZ___])])  AC_CACHE_CHECK([how to link with lib[]$1], [ac_cv_lib[]Name[]_libs], [    AC_LIB_LINKFLAGS_BODY([$1], [$2])    ac_cv_lib[]Name[]_libs="$LIB[]NAME"    ac_cv_lib[]Name[]_ltlibs="$LTLIB[]NAME"    ac_cv_lib[]Name[]_cppflags="$INC[]NAME"  ])  LIB[]NAME="$ac_cv_lib[]Name[]_libs"  LTLIB[]NAME="$ac_cv_lib[]Name[]_ltlibs"  INC[]NAME="$ac_cv_lib[]Name[]_cppflags"  AC_LIB_APPENDTOVAR([CPPFLAGS], [$INC]NAME)  AC_SUBST([LIB]NAME)  AC_SUBST([LTLIB]NAME)  dnl Also set HAVE_LIB[]NAME so that AC_LIB_HAVE_LINKFLAGS can reuse the  dnl results of this search when this library appears as a dependency.  HAVE_LIB[]NAME=yes  undefine([Name])  undefine([NAME])])dnl AC_LIB_HAVE_LINKFLAGS(name, dependencies, includes, testcode)dnl searches for libname and the libraries corresponding to explicit anddnl implicit dependencies, together with the specified include files anddnl the ability to compile and link the specified testcode. If found, itdnl sets and AC_SUBSTs HAVE_LIB${NAME}=yes and the LIB${NAME} anddnl LTLIB${NAME} variables and augments the CPPFLAGS variable, anddnl #defines HAVE_LIB${NAME} to 1. Otherwise, it sets and AC_SUBSTsdnl HAVE_LIB${NAME}=no and LIB${NAME} and LTLIB${NAME} to empty.AC_DEFUN([AC_LIB_HAVE_LINKFLAGS],[  AC_REQUIRE([AC_LIB_PREPARE_PREFIX])  AC_REQUIRE([AC_LIB_RPATH])  define([Name],[translit([$1],[./-], [___])])  define([NAME],[translit([$1],[abcdefghijklmnopqrstuvwxyz./-],                               [ABCDEFGHIJKLMNOPQRSTUVWXYZ___])])  dnl Search for lib[]Name and define LIB[]NAME, LTLIB[]NAME and INC[]NAME  dnl accordingly.  AC_LIB_LINKFLAGS_BODY([$1], [$2])  dnl Add $INC[]NAME to CPPFLAGS before performing the following checks,  dnl because if the user has installed lib[]Name and not disabled its use  dnl via --without-lib[]Name-prefix, he wants to use it.  ac_save_CPPFLAGS="$CPPFLAGS"  AC_LIB_APPENDTOVAR([CPPFLAGS], [$INC]NAME)  AC_CACHE_CHECK([for lib[]$1], [ac_cv_lib[]Name], [    ac_save_LIBS="$LIBS"    LIBS="$LIBS $LIB[]NAME"    AC_TRY_LINK([$3], [$4], [ac_cv_lib[]Name=yes], [ac_cv_lib[]Name=no])    LIBS="$ac_save_LIBS"  ])  if test "$ac_cv_lib[]Name" = yes; then    HAVE_LIB[]NAME=yes    AC_DEFINE([HAVE_LIB]NAME, 1, [Define if you have the $1 library.])    AC_MSG_CHECKING([how to link with lib[]$1])    AC_MSG_RESULT([$LIB[]NAME])  else    HAVE_LIB[]NAME=no    dnl If $LIB[]NAME didn't lead to a usable library, we don't need    dnl $INC[]NAME either.    CPPFLAGS="$ac_save_CPPFLAGS"    LIB[]NAME=    LTLIB[]NAME=  fi  AC_SUBST([HAVE_LIB]NAME)  AC_SUBST([LIB]NAME)  AC_SUBST([LTLIB]NAME)  undefine([Name])  undefine([NAME])])dnl Determine the platform dependent parameters needed to use rpath:dnl libext, shlibext, hardcode_libdir_flag_spec, hardcode_libdir_separator,dnl hardcode_direct, hardcode_minus_L.AC_DEFUN([AC_LIB_RPATH],[  dnl Tell automake >= 1.10 to complain if config.rpath is missing.  m4_ifdef([AC_REQUIRE_AUX_FILE], [AC_REQUIRE_AUX_FILE([config.rpath])])  AC_REQUIRE([AC_PROG_CC])                dnl we use $CC, $GCC, $LDFLAGS  AC_REQUIRE([AC_LIB_PROG_LD])            dnl we use $LD, $with_gnu_ld  AC_REQUIRE([AC_CANONICAL_HOST])         dnl we use $host  AC_REQUIRE([AC_CONFIG_AUX_DIR_DEFAULT]) dnl we use $ac_aux_dir  AC_CACHE_CHECK([for shared library run path origin], acl_cv_rpath, [    CC="$CC" GCC="$GCC" LDFLAGS="$LDFLAGS" LD="$LD" with_gnu_ld="$with_gnu_ld" \    ${CONFIG_SHELL-/bin/sh} "$ac_aux_dir/config.rpath" "$host" > conftest.sh    . ./conftest.sh    rm -f ./conftest.sh    acl_cv_rpath=done  ])  wl="$acl_cv_wl"  libext="$acl_cv_libext"  shlibext="$acl_cv_shlibext"  hardcode_libdir_flag_spec="$acl_cv_hardcode_libdir_flag_spec"  hardcode_libdir_separator="$acl_cv_hardcode_libdir_separator"  hardcode_direct="$acl_cv_hardcode_direct"  hardcode_minus_L="$acl_cv_hardcode_minus_L"  dnl Determine whether the user wants rpath handling at all.  AC_ARG_ENABLE(rpath,    [  --disable-rpath         do not hardcode runtime library paths],    :, enable_rpath=yes)])dnl AC_LIB_LINKFLAGS_BODY(name [, dependencies]) searches for libname anddnl the libraries corresponding to explicit and implicit dependencies.dnl Sets the LIB${NAME}, LTLIB${NAME} and INC${NAME} variables.AC_DEFUN([AC_LIB_LINKFLAGS_BODY],[  define([NAME],[translit([$1],[abcdefghijklmnopqrstuvwxyz./-],                               [ABCDEFGHIJKLMNOPQRSTUVWXYZ___])])  dnl By default, look in $includedir and $libdir.  use_additional=yes  AC_LIB_WITH_FINAL_PREFIX([    eval additional_includedir=\"$includedir\"    eval additional_libdir=\"$libdir\"  ])  AC_LIB_ARG_WITH([lib$1-prefix],[  --with-lib$1-prefix[=DIR]  search for lib$1 in DIR/include and DIR/lib  --without-lib$1-prefix     don't search for lib$1 in includedir and libdir],[    if test "X$withval" = "Xno"; then      use_additional=no    else      if test "X$withval" = "X"; then        AC_LIB_WITH_FINAL_PREFIX([          eval additional_includedir=\"$includedir\"          eval additional_libdir=\"$libdir\"        ])      else        additional_includedir="$withval/include"        additional_libdir="$withval/lib"      fi    fi])  dnl Search the library and its dependencies in $additional_libdir and  dnl $LDFLAGS. Using breadth-first-seach.  LIB[]NAME=  LTLIB[]NAME=  INC[]NAME=  rpathdirs=  ltrpathdirs=  names_already_handled=  names_next_round='$1 $2'  while test -n "$names_next_round"; do    names_this_round="$names_next_round"    names_next_round=    for name in $names_this_round; do      already_handled=      for n in $names_already_handled; do        if test "$n" = "$name"; then          already_handled=yes          break        fi      done      if test -z "$already_handled"; then        names_already_handled="$names_already_handled $name"        dnl See if it was already located by an earlier AC_LIB_LINKFLAGS        dnl or AC_LIB_HAVE_LINKFLAGS call.        uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'`        eval value=\"\$HAVE_LIB$uppername\"        if test -n "$value"; then          if test "$value" = yes; then            eval value=\"\$LIB$uppername\"            test -z "$value" || LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$value"            eval value=\"\$LTLIB$uppername\"            test -z "$value" || LTLIB[]NAME="${LTLIB[]NAME}${LTLIB[]NAME:+ }$value"          else            dnl An earlier call to AC_LIB_HAVE_LINKFLAGS has determined            dnl that this library doesn't exist. So just drop it.            :          fi        else          dnl Search the library lib$name in $additional_libdir and $LDFLAGS          dnl and the already constructed $LIBNAME/$LTLIBNAME.          found_dir=          found_la=          found_so=          found_a=          if test $use_additional = yes; then            if test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext"; then              found_dir="$additional_libdir"              found_so="$additional_libdir/lib$name.$shlibext"              if test -f "$additional_libdir/lib$name.la"; then                found_la="$additional_libdir/lib$name.la"              fi            else              if test -f "$additional_libdir/lib$name.$libext"; then                found_dir="$additional_libdir"                found_a="$additional_libdir/lib$name.$libext"                if test -f "$additional_libdir/lib$name.la"; then                  found_la="$additional_libdir/lib$name.la"                fi              fi            fi          fi          if test "X$found_dir" = "X"; then            for x in $LDFLAGS $LTLIB[]NAME; do              AC_LIB_WITH_FINAL_PREFIX([eval x=\"$x\"])              case "$x" in                -L*)                  dir=`echo "X$x" | sed -e 's/^X-L//'`                  if test -n "$shlibext" && test -f "$dir/lib$name.$shlibext"; then                    found_dir="$dir"                    found_so="$dir/lib$name.$shlibext"                    if test -f "$dir/lib$name.la"; then                      found_la="$dir/lib$name.la"

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -