acinclude.m4
来自「基于4个mips核的noc设计」· M4 代码 · 共 1,996 行 · 第 1/5 页
M4
1,996 行
for i in `ls -dr $tixpath/tix* 2>/dev/null ` ; do if test -f $i/generic/tix.h ; then ac_cv_c_tixh=`(cd $i/generic; pwd)` break fi donefidnl see if one is installedif test x"${ac_cv_c_tixh}" = x ; then AC_MSG_RESULT(none) dnl Get the path to the compiler dnl Get the path to the compiler. We do it this way instead of using dnl AC_CHECK_HEADER, cause this doesn't depend in having X configured. ccpath=`which ${CC} | sed -e 's:/bin/.*::'`/include if test -f $ccpath/tix.h; then ac_cv_c_tixh=installed fielse AC_MSG_RESULT(${ac_cv_c_tixh})fi])if test x"${ac_cv_c_tixh}" = x ; then AC_MSG_ERROR([Can't find any Tix headers])fiif test x"${ac_cv_c_tixh}" != x ; then no_tix="" AC_MSG_RESULT(${ac_cv_c_tixh}) if test x"${ac_cv_c_tixh}" != x"installed" ; then TIXHDIR="-I${ac_cv_c_tixh}" fifiAC_SUBST(TIXHDIR)])AC_DEFUN(CYG_AC_PATH_TIXCONFIG, [## Ok, lets find the tix configuration# First, look for one uninstalled. # the alternative search directory is invoked by --with-tixconfig#if test x"${no_tix}" = x ; then # we reset no_tix in case something fails here no_tix=true AC_ARG_WITH(tixconfig, [ --with-tixconfig directory containing tix configuration (tixConfig.sh)], with_tixconfig=${withval}) AC_MSG_CHECKING([for Tix configuration]) AC_CACHE_VAL(ac_cv_c_tixconfig,[ # First check to see if --with-tixconfig was specified. if test x"${with_tixconfig}" != x ; then if test -f "${with_tixconfig}/tixConfig.sh" ; then ac_cv_c_tixconfig=`(cd ${with_tixconfig}; pwd)` else AC_MSG_ERROR([${with_tixconfig} directory doesn't contain tixConfig.sh]) fi fi # then check for a private Tix library if test x"${ac_cv_c_tixconfig}" = x ; then for i in \ ../tix \ `ls -dr ../tix[[4]]* 2>/dev/null` \ ../../tix \ `ls -dr ../../tix[[4]]* 2>/dev/null` \ ../../../tix \ `ls -dr ../../../tix[[4]]* 2>/dev/null` ; do if test -f "$i/tixConfig.sh" ; then ac_cv_c_tixconfig=`(cd $i; pwd)` break fi done fi # check in a few common install locations if test x"${ac_cv_c_tixconfig}" = x ; then for i in `ls -d ${prefix}/lib /usr/local/lib 2>/dev/null` ; do if test -f "$i/tixConfig.sh" ; then ac_cv_c_tkconfig=`(cd $i; pwd)` break fi done fi # check in a few other private locations if test x"${ac_cv_c_tixconfig}" = x ; then for i in \ ${srcdir}/../tix \ `ls -dr ${srcdir}/../tix[[4-9]]* 2>/dev/null` ; do if test -f "$i/tixConfig.sh" ; then ac_cv_c_tixconfig=`(cd $i; pwd)` break fi done fi ]) if test x"${ac_cv_c_tixconfig}" = x ; then TIXCONFIG="# no Tix configs found" AC_MSG_WARN(Can't find Tix configuration definitions) else no_tix= TIXCONFIG=${ac_cv_c_tixconfig}/tixConfig.sh AC_MSG_RESULT(found $TIXCONFIG) fifi])# Defined as a separate macro so we don't have to cache the values# from PATH_TIXCONFIG (because this can also be cached).AC_DEFUN(CYG_AC_LOAD_TIXCONFIG, [ if test -f "$TIXCONFIG" ; then . $TIXCONFIG fi AC_SUBST(TIX_BUILD_LIB_SPEC) AC_SUBST(TIX_LIB_FULL_PATH)])AC_DEFUN(CYG_AC_PATH_ITCLCONFIG, [## Ok, lets find the itcl configuration# First, look for one uninstalled. # the alternative search directory is invoked by --with-itclconfig#if test x"${no_itcl}" = x ; then # we reset no_itcl in case something fails here no_itcl=true AC_ARG_WITH(itclconfig, [ --with-itclconfig directory containing itcl configuration (itclConfig.sh)], with_itclconfig=${withval}) AC_MSG_CHECKING([for Itcl configuration]) AC_CACHE_VAL(ac_cv_c_itclconfig,[ # First check to see if --with-itclconfig was specified. if test x"${with_itclconfig}" != x ; then if test -f "${with_itclconfig}/itclConfig.sh" ; then ac_cv_c_itclconfig=`(cd ${with_itclconfig}; pwd)` else AC_MSG_ERROR([${with_itclconfig} directory doesn't contain itclConfig.sh]) fi fi # then check for a private itcl library if test x"${ac_cv_c_itclconfig}" = x ; then for i in \ ../itcl/itcl \ `ls -dr ../itcl/itcl[[3]]* 2>/dev/null` \ ../../itcl/itcl \ `ls -dr ../../itcl/itcl[[3]]* 2>/dev/null` \ ../../../itcl/itcl \ `ls -dr ../../../itcl/itcl[[3]]* 2>/dev/null` ; do if test -f "$i/itclConfig.sh" ; then ac_cv_c_itclconfig=`(cd $i; pwd)` break fi done fi # check in a few common install locations if test x"${ac_cv_c_itclconfig}" = x ; then for i in `ls -d ${prefix}/lib /usr/local/lib 2>/dev/null` ; do if test -f "$i/itclConfig.sh" ; then ac_cv_c_itclconfig=`(cd $i; pwd)` break fi done fi # check in a few other private locations if test x"${ac_cv_c_itclconfig}" = x ; then for i in \ ${srcdir}/../itcl/itcl \ `ls -dr ${srcdir}/../itcl/itcl[[3]]* 2>/dev/null` ; do if test -f "$i/itcl/itclConfig.sh" ; then ac_cv_c_itclconfig=`(cd $i; pwd)` break fi done fi ]) if test x"${ac_cv_c_itclconfig}" = x ; then ITCLCONFIG="# no itcl configs found" AC_MSG_WARN(Can't find itcl configuration definitions) else no_itcl= ITCLCONFIG=${ac_cv_c_itclconfig}/itclConfig.sh AC_MSG_RESULT(found $ITCLCONFIG) fifi])# Defined as a separate macro so we don't have to cache the values# from PATH_ITCLCONFIG (because this can also be cached).AC_DEFUN(CYG_AC_LOAD_ITCLCONFIG, [ if test -f "$ITCLCONFIG" ; then . $ITCLCONFIG fi AC_SUBST(ITCL_BUILD_LIB_SPEC) AC_SUBST(ITCL_SH) AC_SUBST(ITCL_LIB_FILE) AC_SUBST(ITCL_LIB_FULL_PATH)])AC_DEFUN(CYG_AC_PATH_ITKCONFIG, [## Ok, lets find the itk configuration# First, look for one uninstalled. # the alternative search directory is invoked by --with-itkconfig#if test x"${no_itk}" = x ; then # we reset no_itk in case something fails here no_itk=true AC_ARG_WITH(itkconfig, [ --with-itkconfig directory containing itk configuration (itkConfig.sh)], with_itkconfig=${withval}) AC_MSG_CHECKING([for Itk configuration]) AC_CACHE_VAL(ac_cv_c_itkconfig,[ # First check to see if --with-itkconfig was specified. if test x"${with_itkconfig}" != x ; then if test -f "${with_itkconfig}/itkConfig.sh" ; then ac_cv_c_itkconfig=`(cd ${with_itkconfig}; pwd)` else AC_MSG_ERROR([${with_itkconfig} directory doesn't contain itkConfig.sh]) fi fi # then check for a private itk library if test x"${ac_cv_c_itkconfig}" = x ; then for i in \ ../itcl/itk \ `ls -dr ../itcl/itk[[3]]* 2>/dev/null` \ ../../itcl/itk \ `ls -dr ../../itcl/itk[[3]]* 2>/dev/null` \ ../../../itcl/itk \ `ls -dr ../../../itcl/itk[[3]]* 2>/dev/null` ; do if test -f "$i/itkConfig.sh" ; then ac_cv_c_itkconfig=`(cd $i; pwd)` break fi done fi # check in a few common install locations if test x"${ac_cv_c_itkconfig}" = x ; then for i in `ls -d ${prefix}/lib /usr/local/lib 2>/dev/null` ; do if test -f "$i/itcl/itkConfig.sh" ; then ac_cv_c_itkconfig=`(cd $i; pwd)` break fi done fi # check in a few other private locations if test x"${ac_cv_c_itkconfig}" = x ; then for i in \ ${srcdir}/../itcl/itk \ `ls -dr ${srcdir}/../itcl/itk[[3]]* 2>/dev/null` ; do if test -f "$i/itkConfig.sh" ; then ac_cv_c_itkconfig=`(cd $i; pwd)` break fi done fi ]) if test x"${ac_cv_c_itkconfig}" = x ; then ITCLCONFIG="# no itk configs found" AC_MSG_WARN(Can't find itk configuration definitions) else no_itk= ITKCONFIG=${ac_cv_c_itkconfig}/itkConfig.sh AC_MSG_RESULT(found $ITKCONFIG) fifi])# Defined as a separate macro so we don't have to cache the values# from PATH_ITKCONFIG (because this can also be cached).AC_DEFUN(CYG_AC_LOAD_ITKCONFIG, [ if test -f "$ITKCONFIG" ; then . $ITKCONFIG fi AC_SUBST(ITK_BUILD_LIB_SPEC) AC_SUBST(ITK_LIB_FILE) AC_SUBST(ITK_LIB_FULL_PATH)])dnl ====================================================================dnl Ok, lets find the libgui source trees so we can use the headersdnl the alternative search directory is involked by --with-libguiincludeAC_DEFUN(CYG_AC_PATH_LIBGUI, [ CYG_AC_PATH_LIBGUIH CYG_AC_PATH_LIBGUILIB])AC_DEFUN(CYG_AC_PATH_LIBGUIH, [dirlist=".. ../../ ../../../ ../../../../ ../../../../../ ../../../../../../ ../../../../../../.. ../../../../../../../.. ../../../../../../../../.. ../../../../../../../../../..../../../../../../../../../../.."no_libgui=trueAC_MSG_CHECKING(for Libgui headers in the source tree)AC_ARG_WITH(libguiinclude, [ --with-libguiinclude directory where libgui headers are], with_libguiinclude=${withval})AC_CACHE_VAL(ac_cv_c_libguih,[dnl first check to see if --with-libguiinclude was specifiedif test x"${with_libguiinclude}" != x ; then if test -f ${with_libguiinclude}/guitcl.h ; then ac_cv_c_libguih=`(cd ${with_libguiinclude}; pwd)` elif test -f ${with_libguiinclude}/src/guitcl.h ; then ac_cv_c_libguih=`(cd ${with_libguiinclude}/src; pwd)` else AC_MSG_ERROR([${with_libguiinclude} directory doesn't contain headers]) fifidnl next check if it came with Libgui configuration fileif test x"${ac_cv_c_libguiconfig}" != x ; then for i in $dirlist; do if test -f $ac_cv_c_libguiconfig/$i/src/guitcl.h ; then ac_cv_c_libguih=`(cd $ac_cv_c_libguiconfig/$i/src; pwd)` break fi donefidnl next check in private source directorydnl since ls returns lowest version numbers first, reverse its outputif test x"${ac_cv_c_libguih}" = x ; then dnl find the top level Libgui source directory for i in $dirlist; do if test -n "`ls -dr $srcdir/$i/libgui* 2>/dev/null`" ; then libguipath=$srcdir/$i break fi done dnl find the exact Libgui source dir. We do it this way, cause there dnl might be multiple version of Libgui, and we want the most recent one. for i in `ls -dr $libguipath/libgui* 2>/dev/null ` ; do if test -f $i/src/guitcl.h ; then ac_cv_c_libguih=`(cd $i/src; pwd)` break fi donefidnl see if one is installedif test x"${ac_cv_c_libguih}" = x ; then AC_MSG_RESULT(none) AC_CHECK_HEADER(guitcl.h, ac_cv_c_libguih=installed, ac_cv_c_libguih="")fi])LIBGUIHDIR=""if test x"${ac_cv_c_libguih}" = x ; then AC_MSG_WARN([Can't find any Libgui headers])fiif test x"${ac_cv_c_libguih}" != x ; then no_libgui="" if test x"${ac_cv_c_libguih}" != x"installed" ; then LIBGUIHDIR="-I${ac_cv_c_libguih}" fifiAC_MSG_RESULT(${ac_cv_c_libguih})AC_SUBST(LIBGUIHDIR)])dnl ====================================================================dnl find the GUI libraryAC_DEFUN(CYG_AC_PATH_LIBGUILIB, [AC_MSG_CHECKING(for GUI library in the build tree)dirlist=".. ../../ ../../../ ../../../../ ../../../../../ ../../../../../../ ../../../../../../.. ../../../../../../../.. ../../../../../../../../.. ../../../../../../../../../.."dnl look for the libraryAC_MSG_CHECKING(for GUI library)AC_CACHE_VAL(ac_cv_c_libguilib,[if test x"${ac_cv_c_libguilib}" = x ; then for i in $dirlist; do if test -f "$i/libgui/src/Makefile" ; then ac_cv_c_libguilib=`(cd $i/libgui/src; pwd)` break fi donefi]) if test x"${ac_cv_c_libguilib}" != x ; then GUILIB="${GUILIB} -L${ac_cv_c_libguilib}" LIBGUILIB="-lgui" AC_MSG_RESULT(${ac_cv_c_libguilib})else AC_MSG_RESULT(none)fiAC_SUBST(GUILIB)AC_SUBST(LIBGUILIB)])
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?