📄 acinclude.m4
字号:
# libtool.m4 - Configure libtool for the host system. -*-Shell-script-*-## Copyright 1996, 1997, 1998, 1999, 2000, 2001## Free Software Foundation, Inc.## 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., 59 Temple Place - Suite 330, Boston, MA 02111-1307, 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.## ------------------------------------------------------------------------## Find a file (or one of more files in a list of dirs)## ------------------------------------------------------------------------##AC_DEFUN(AC_FIND_FILE,[$3=NOfor i in $2;do for j in $1; do if test -r "$i/$j"; then $3=$i break 2 fi donedone])## ------------------------------------------------------------------------## Find qt lib## ------------------------------------------------------------------------##AC_DEFUN(AC_PATH_QT_LIB,[ AC_REQUIRE_CPP() AC_REQUIRE([AC_PATH_X]) AC_MSG_CHECKING(for QT 3.x libraries) ac_qt_libraries="no" AC_ARG_WITH(qt-libraries, [ --with-qt-libraries where the QT libraries are located. ], [ ac_qt_libraries="$withval" ]) AC_CACHE_VAL(ac_cv_lib_qtlib, [ dnl Did the user give --with-qt-libraries? if test "$ac_qt_libraries" = no; then dnl No they didn't, so lets look for them... dnl If you need to add extra directories to check, add them here. qt_library_dirs="\ /usr/lib \ /usr/local/lib \ /usr/X11/lib \ /usr/X11R6/lib" if test "x$QTDIR" != x; then qt_library_dirs="$QTDIR/lib $qt_library_dirs" fi if test "x$QTLIB" != x; then qt_library_dirs="$QTLIB $qt_library_dirs" fi for qt_temp in $qt_library_dirs; do for qt_dir in $qt_temp $qt_temp/*/ $qt_temp/*/*/ $qt_temp/*/*/*/; do if test -r $qt_dir/libqt.so.3 && test -r $qt_dir/libqt.so; then ac_qt_libraries=$qt_dir ac_qt_lib=qt break 2 elif test -r $qt_dir/libqt-mt.so.3 && test -r $qt_dir/libqt-mt.so; then ac_qt_libraries=$qt_dir ac_qt_lib=qt-mt break 2 fi done done else dnl yes they did, so lets look for qt or qt-mt... qt_lib_dir="$ac_qt_libraries" if test -r $qt_lib_dir/libqt.so.3 && test -r $qt_lib_dir/libqt.so; then ac_qt_lib=qt elif test -r $qt_lib_dir/libqt-mt.so.3 && test -r $qt_lib_dir/libqt-mt.so; then ac_qt_lib=qt-mt fi fi ac_cv_lib_qtlib=$ac_qt_libraries ]) dnl Define a shell variable for later checks if test "$ac_cv_lib_qtlib" = no; then have_qt_lib="no" else have_qt_lib="yes" fi AC_MSG_RESULT([$ac_cv_lib_qtlib]) QT_LDFLAGS="-L$ac_cv_lib_qtlib" QT_LIBDIR="$ac_cv_lib_qtlib" QT_LIB="-l$ac_qt_lib" AC_SUBST(QT_LDFLAGS) AC_SUBST(QT_LIBDIR) AC_SUBST(QT_LIB)])AC_DEFUN(AC_PATH_QT_INC,[ AC_REQUIRE_CPP() AC_REQUIRE([AC_PATH_X]) AC_MSG_CHECKING(for QT 3.x includes) ac_qt_includes="no" AC_ARG_WITH(qt-includes, [ --with-qt-includes where the QT headers are located. ], [ ac_qt_includes="$withval" ]) AC_CACHE_VAL(ac_cv_header_qtinc, [ dnl Did the user give --with-qt-includes? if test "$ac_qt_includes" = no; then dnl No they didn't, so lets look for them... dnl If you need to add extra directories to check, add them here. qt_include_dirs="\ /usr \ /usr/lib \ /usr/local/ \ /usr/X11/ \ /usr/X11R6/" if test "x$QTDIR" != x; then qt_include_dirs="$QTDIR/include $qt_include_dirs" fi if test "x$QTINC" != x; then qt_include_dirs="$QTINC $qt_include_dirs" fi for qt_temp in $qt_include_dirs; do for qt_dir in $qt_temp/include/ $qt_temp/qt*/include/ $qt_temp/include/qt*/ $qt_temp/include/*/qt*/; do if test -r "$qt_dir/qnamespace.h" && test -r "$qt_dir/qptrlist.h"; then ac_qt_includes=$qt_dir break 2 fi done done fi ac_cv_header_qtinc=$ac_qt_includes ]) if test "$ac_cv_header_qtinc" = no; then have_qt_inc="no" else have_qt_inc="yes" fi AC_MSG_RESULT([$ac_cv_header_qtinc]) QT_INCLUDES="-I$ac_cv_header_qtinc" QT_INCDIR="$ac_cv_header_qtinc" AC_SUBST(QT_INCLUDES) AC_SUBST(QT_INCDIR) QTDIR="$ac_cv_header_qtinc/.."])## ------------------------------------------------------------------------## Find qt meta object compile (moc)## ------------------------------------------------------------------------##AC_DEFUN(AC_PATH_QT_MOC,[ AC_PATH_PROG( MOC, moc, $QTDIR/bin/moc, $QTDIR/bin:/usr/bin:/usr/X11R6/bin:/usr/lib/qt/bin:/usr/local/qt/bin:$PATH) AC_SUBST(MOC)])## ------------------------------------------------------------------------## Find qt findtr ???## ------------------------------------------------------------------------####AC_DEFUN(AC_PATH_QT_FINDTR,##[## AC_PATH_PROG(## QT_FINDTR,## findtr,## $QTDIR/bin/findtr,## $QTDIR/bin:/usr/bin:/usr/X11R6/bin:/usr/lib/qt/bin:/usr/local/qt/bin:$PATH)##])## ------------------------------------------------------------------------## Find qt msgtoqm ???## ------------------------------------------------------------------------####AC_DEFUN(AC_PATH_QT_MSGTOQM,##[## AC_PATH_PROG(## QT_MSG2QM,## msg2qm,## $QTDIR/bin/msg2qm,## $QTDIR/bin:/usr/bin:/usr/X11R6/bin:/usr/lib/qt/bin:/usr/local/qt/bin:$PATH)##])## ------------------------------------------------------------------------## Find qt mergetr ???## ------------------------------------------------------------------------####AC_DEFUN(AC_PATH_QT_MERGETR,##[## AC_PATH_PROG(## QT_MERGETR,## mergetr,## $QTDIR/bin/mergetr,## $QTDIR/bin:/usr/bin:/usr/X11R6/bin:/usr/lib/qt/bin:/usr/local/qt/bin:$PATH)##])## ------------------------------------------------------------------------## Find OpenHBCI dir## ------------------------------------------------------------------------##AC_DEFUN(AC_PATH_OHBCI_DIR,[ AC_REQUIRE_CPP() AC_REQUIRE([AC_PATH_X]) AC_MSG_CHECKING(for OpenHBCI libraries and includes) ac_ohbci_directory="no" AC_ARG_WITH(ohbci-libraries, [ --with-ohbci-libraries where the OHBCI libraries are located. ], [ ac_ohbci_directory="$withval" ]) AC_CACHE_VAL(ac_cv_lib_ohbcilib, [ dnl Did the user give --with-ohbci-libraries? if test "$ac_ohbci_directory" = no; then dnl No they didn't, so lets look for them... dnl If you need to add extra directories to check, add them here. ohbci_library_dirs="/usr/local/openhbci \ /usr/local \ /usr/openhbci \ /usr \ /" if test "x$OHBCIDIR" != x; then ohbci_library_dirs="$OHBCIDIR/lib $ohbci_library_dirs" fi if test "x$OHBCILIB" != x; then ohbci_library_dirs="$OHBCILIB $ohbci_library_dirs" fi for ohbci_dir in $ohbci_library_dirs; do if test -x "$ohbci_dir/bin/openhbci-config"; then ac_ohbci_directory=$ohbci_dir break fi done fi ]) dnl Define a shell variable for later checks if test "$ac_ohbci_directory" = no; then have_ohbci_lib="no" else have_ohbci_lib="yes" all_libraries="$all_libraries `$ac_ohbci_directory/bin/openhbci-config --libraries`" all_includes="$all_includes `$ac_ohbci_directory/bin/openhbci-config --includes`" fi AC_MSG_RESULT([$ac_ohbci_directory]) AC_SUBST(all_includes) AC_SUBST(all_libraries)])## ------------------------------------------------------------------------## Find ktoblzcheck lib## ------------------------------------------------------------------------##AC_DEFUN(AC_PATH_KTOBLZCHECK_LIB,[ AC_REQUIRE_CPP() AC_REQUIRE([AC_PATH_X]) AC_MSG_CHECKING(for ktoblzcheck libraries) ac_ktoblzcheck_libraries="no" AC_ARG_WITH(ktoblzcheck-libraries, [ --with-ktoblzcheck-libraries where the ktoblzcheck libraries are located. ], [ ac_ktoblzcheck_libraries="$withval" ]) AC_CACHE_VAL(ac_cv_lib_ktoblzchecklib, [ dnl Did the user give --with-ktoblzcheck-libraries? if test "$ac_ktoblzcheck_libraries" = no; then dnl No they didn't, so lets look for them... dnl If you need to add extra directories to check, add them here. ktoblzcheck_library_dirs="\ /usr/lib \ /usr/local/lib \ /usr \ /" if test "x$KTOBLZCHECKDIR" != x; then ktoblzcheck_library_dirs="$KTOBLZCHECKDIR/lib $ktoblzcheck_library_dirs" fi if test "x$KTOBLZCHECKLIB" != x; then ktoblzcheck_library_dirs="$KTOBLZCHECKLIB $ktoblzcheck_library_dirs" fi for ktoblzcheck_temp in $ktoblzcheck_library_dirs; do for ktoblzcheck_dir in $ktoblzcheck_temp $ktoblzcheck_temp/*/ $ktoblzcheck_temp/*/*/ $ktoblzcheck_temp/*/*/*/; do if test -r $ktoblzcheck_dir/libktoblzcheck.so; then ac_ktoblzcheck_libraries=$ktoblzcheck_dir ac_ktoblzcheck_lib=ktoblzcheck break 2 fi done done else dnl yes they did ac_ktoblzcheck_lib=ktoblzcheck fi ac_cv_lib_ktoblzchecklib=$ac_ktoblzcheck_libraries ]) dnl Define a shell variable for later checks if test "$ac_cv_lib_ktoblzchecklib" = no; then have_ktoblzcheck_lib="no" else have_ktoblzcheck_lib="yes" fi AC_MSG_RESULT([$ac_cv_lib_ktoblzchecklib]) KTOBLZCHECK_LDFLAGS="-L$ac_cv_lib_ktoblzchecklib" KTOBLZCHECK_LIBDIR="$ac_cv_lib_ktoblzchecklib" KTOBLZCHECK_LIB="-l$ac_ktoblzcheck_lib" AC_SUBST(KTOBLZCHECK_LDFLAGS) AC_SUBST(KTOBLZCHECK_LIBDIR) AC_SUBST(KTOBLZCHECK_LIB)])## ------------------------------------------------------------------------## Find ktoblzcheck inc## ------------------------------------------------------------------------##AC_DEFUN(AC_PATH_KTOBLZCHECK_INC,[ AC_REQUIRE_CPP() AC_REQUIRE([AC_PATH_X]) AC_MSG_CHECKING(for ktoblzcheck includes) ac_ktoblzcheck_includes="no" AC_ARG_WITH(ktoblzcheck-includes, [ --with-ktoblzcheck-includes where the ktoblzcheck headers are located. ], [ ac_ktoblzcheck_includes="$withval" ]) AC_CACHE_VAL(ac_cv_header_ktoblzcheckinc, [ dnl Did the user give --with-ktoblzcheck-includes? if test "$ac_ktoblzcheck_includes" = no; then dnl No they didn't, so lets look for them... dnl If you need to add extra directories to check, add them here. ktoblzcheck_include_dirs="\ /usr \ /usr/local \ /usr \ /" if test "x$KTOBLZCHECKDIR" != x; then ktoblzcheck_include_dirs="$KTOBLZCHECKDIR/include $ktoblzcheck_include_dirs" fi if test "x$KTOBLZCHECKINC" != x; then ktoblzcheck_include_dirs="$KTOBLZCHECKINC $ktoblzcheck_include_dirs" fi for ktoblzcheck_temp in $ktoblzcheck_include_dirs; do for ktoblzcheck_dir in $ktoblzcheck_temp/include/ $ktoblzcheck_temp/ktoblzcheck*/include/ $ktoblzcheck_temp/include/ktoblzcheck*/ $ktoblzcheck_temp/include/*/ktoblzcheck*/; do if test -r "$ktoblzcheck_dir/ktoblzcheck.hh"; then ac_ktoblzcheck_includes=$ktoblzcheck_dir break 2 fi done done fi ac_cv_header_ktoblzcheckinc=$ac_ktoblzcheck_includes ]) if test "$ac_cv_header_ktoblzcheckinc" = no; then have_ktoblzcheck_inc="no" else have_ktoblzcheck_inc="yes" fi AC_MSG_RESULT([$ac_cv_header_ktoblzcheckinc]) KTOBLZCHECK_INCLUDES="-I$ac_cv_header_ktoblzcheckinc" KTOBLZCHECK_INCDIR="$ac_cv_header_ktoblzcheckinc" AC_SUBST(KTOBLZCHECK_INCLUDES) AC_SUBST(KTOBLZCHECK_INCDIR) KTOBLZCHECKDIR="$ac_cv_header_ktoblzcheckinc/.."])
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -