📄 aclocal.m4
字号:
dnl #undef HAVE_PTHREAD_SETCANCELdnl END ACCONFIGdnl ACCONFIG BOTTOMdnl dnl #if defined(__SVR4) && defined(__sun)dnl #define _THR_SUNOS5dnl #elsednl #if defined(__SVR4__) && defined(__SUN__)dnl #define _THR_SUNOS5dnl #endifdnl #endifdnl #ifdef _THR_SUNOS5dnl #include "/usr/include/thread.h"dnl #endifdnl dnl #if defined(HAVE_PTHREAD_H) && defined(_THREAD_SAFE)dnl #ifndef __USE_UNIX98dnl #define __USE_UNIX98dnl #include <pthread.h>dnl #undef __USE_UNIX98dnl #elsednl #include <pthread.h>dnl #endifdnl #ifdef HAVE_PTHREAD_NP_Hdnl #include <pthread_np.h>dnl #endifdnl #ifdef HAVE_SEMAPHORE_Hdnl #include <semaphore.h>dnl #endifdnl #ifdef _POSIX_PRIORITY_SCHEDULINGdnl #ifdef HAVE_SCHED_Hdnl #include <sched.h>dnl #elsednl #ifdef HAVE_SYS_SCHED_Hdnl #include <sys/sched.h>dnl #endifdnl #endifdnl #endifdnl dnl #define __PTHREAD_H__dnl #ifndef PTHREAD_MUTEXTYPE_RECURSIVEdnl #ifdef MUTEX_TYPE_COUNTING_FASTdnl #define PTHREAD_MUTEXTYPE_RECURSIVE MUTEX_TYPE_COUNTING_FASTdnl #endifdnl #endifdnl #ifndef HAVE_PTHREAD_MUTEXATTR_SETTYPEdnl #if HAVE_PTHREAD_MUTEXATTR_SETKIND_NPdnl #ifndef PTHREAD_MUTEXTYPE_RECURSIVEdnl #define PTHREAD_MUTEXTYPE_RECURSIVE PTHREAD_MUTEX_RECURSIVE_NPdnl #endifdnl #define pthread_mutexattr_gettype(x, y) pthread_mutexattr_getkind_np(x, y)dnl #define pthread_mutexattr_settype(x, y) pthread_mutexattr_setkind_np(x, y)dnl #endif dnl #if HAVE_PTHREAD_MUTEXATTR_SETTYPE_NPdnl #ifndef PTHREAD_MUTEXTYPE_RECURSIVEdnl #define PTHREAD_MUTEXTYPE_RECURSIVE PTHREAD_MUTEXTYPE_RECURSIVE_NPdnl #endifdnl #define pthread_mutexattr_settype(x, y) pthread_mutexattr_settype_np(x, y)dnl #define pthread_mutexattr_gettype(x, y) pthread_mutexattr_gettype_np(x, y)dnl #endifdnl #endifdnl dnl #ifndef HAVE_PTHREAD_YIELDdnl #ifdef HAVE_PTHREAD_SCHED_YIELDdnl #define pthread_yield() sched_yield()dnl #define HAVE_PTHREAD_YIELDdnl #endifdnl #endifdnl dnl #ifndef HAVE_PTHREAD_DELAYdnl #ifdef HAVE_PTHREAD_DELAY_NPdnl #define HAVE_PTHREAD_DELAYdnl #define pthread_delay(x) pthread_delay_np(x)dnl #endifdnl #ifdef HAVE_PTHREAD_NANOSLEEPdnl #ifndef HAVE_PTHREAD_DELAYdnl #define HAVE_PTHREAD_DELAYdnl #define pthread_delay(x) nanosleep(x, NULL)dnl #endifdnl #endifdnl #endifdnl dnl #ifdef HAVE_PTHREAD_ATTR_SETSTACKdnl #ifndef PTHREAD_STACK_MINdnl #define PTHREAD_STACK_MIN 8192dnl #endifdnl #endifdnl dnl #ifndef HAVE_PTHREAD_CANCELdnl #ifdef SIGCANCELdnl #define _SIG_THREAD_CANCEL SIGCANCELdnl #elsednl #define _SIG_THREAD_CANCEL SIGQUITdnl #endifdnl #define pthread_cancel(x) pthread_kill(x, _SIG_THREAD_CANCEL)dnl #endifdnl dnl #ifndef HAVE_PTHREAD_SETCANCELTYPEdnl #ifdef HAVE_PTHREAD_SETCANCELdnl enumdnl { PTHREAD_CANCEL_ASYNCHRONOUS = CANCEL_ON,dnl PTHREAD_CANCEL_DEFERRED = CANCEL_OFF};dnl enumdnl { PTHREAD_CANCEL_ENABLE = CANCEL_ON,dnl PTHREAD_CANCEL_DISABLE = CANCEL_OFF};dnl #define pthread_setcancelstate(x, y) \dnl (y == NULL) ? pthread_setcancel(x) : *y = pthread_setcanceldnl #define pthread_setcanceltype(x, y) \dnl (y == NULL) ? pthread_setasynccancel(x) | *y = pthread_setasynccancel(x)dnl #elsednl #define pthread_setcanceltype(x, y)dnl #define pthread_setcancelstate(x, y)dnl #endifdnl #endifdnl dnl #endifdnl dnl END ACCONFIGdnl Copyright (C) 1999-2000 Open Source Telecom Corporation.dnl dnl This program is free software; you can redistribute it and/or modifydnl it under the terms of the GNU General Public License as published bydnl the Free Software Foundation; either version 2 of the License, ordnl (at your option) any later version.dnl dnl This program is distributed in the hope that it will be useful,dnl but WITHOUT ANY WARRANTY; without even the implied warranty ofdnl MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See thednl GNU General Public License for more details.dnl dnl You should have received a copy of the GNU General Public Licensednl along with this program; if not, write to the Free Software dnl Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.dnl dnl As a special exception to the GNU General Public License, if you dnl distribute this file as part of a program that contains a configuration dnl script generated by Autoconf, you may include it under the same dnl distribution terms that you use for the rest of that program.AC_DEFUN(OST_HEADER_SYSTIME,[ AC_HEADER_TIME AC_CHECK_HEADERS(sys/time.h)])dnl ACCONFIG TEMPLATEdnl #undef HAVE_SYS_TIME_Hdnl #undef TIME_WITH_SYS_TIMEdnl END ACCONFIGdnl ACCONFIG BOTTOMdnl dnl #if TIME_WITH_SYS_TIMEdnl #include <sys/time.h>dnl #include <time.h>dnl #elsednl #if HAVE_SYS_TIME_Hdnl #include <sys/time.h>dnl #elsednl #include <time.h>dnl #endifdnl #endifdnl dnl END ACCONFIGdnl Copyright (C) 1999-2000 Open Source Telecom Corporation.dnl dnl This program is free software; you can redistribute it and/or modifydnl it under the terms of the GNU General Public License as published bydnl the Free Software Foundation; either version 2 of the License, ordnl (at your option) any later version.dnl dnl This program is distributed in the hope that it will be useful,dnl but WITHOUT ANY WARRANTY; without even the implied warranty ofdnl MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See thednl GNU General Public License for more details.dnl dnl You should have received a copy of the GNU General Public Licensednl along with this program; if not, write to the Free Software dnl Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.dnl dnl As a special exception to the GNU General Public License, if you dnl distribute this file as part of a program that contains a configuration dnl script generated by Autoconf, you may include it under the same dnl distribution terms that you use for the rest of that program.AC_DEFUN(OST_LIB_SOCKET,[ AC_REQUIRE([OST_HEADER_SYSTIME]) ost_cv_inet_sockets=no ost_cv_unix_sockets=no ost_cv_lib_socket="c" AC_CHECK_HEADERS(sys/socket.h,[ AC_CHECK_HEADERS(select.h sys/select.h) AC_CHECK_HEADERS(arpa/inet.h, ost_cv_inet_sockets=yes) AC_CHECK_HEADERS(sys/un.h, ost_cv_unix_sockets=yes) ], AC_CHECK_HEADERS(winsock.h, ost_cv_inet_sockets=yes)) AC_CHECK_LIB(socket, socket, [ ost_cv_lib_socket="socket" LIBS="$LIBS -lsocket" ]) if test $ost_cv_inet_sockets = yes ; then AC_DEFINE(HAVE_INET_SOCKETS) AC_CHECK_LIB($ost_cv_lib_socket, inet_aton,[ AC_DEFINE(HAVE_INET_ATON)]) AC_CACHE_CHECK("for socklen_t defined", ost_cv_socklen_t, [ ost_cv_socklen_t='no' AC_EGREP_HEADER(socklen_t, sys/socket.h, ost_cv_socklen_t='yes') ]) if test $ost_cv_socklen_t = yes ; then AC_DEFINE(HAVE_SOCKLEN_T) fi fi if test $ost_cv_unix_sockets = yes ; then AC_DEFINE(HAVE_UNIX_SOCKETS) fi])dnl ACCONFIG TEMPLATEdnl #undef HAVE_SYS_SOCKET_Hdnl #undef HAVE_ARPA_INET_Hdnl #undef HAVE_SYS_UN_Hdnl #undef HAVE_SELECT_Hdnl #undef HAVE_SYS_SELECT_Hdnl #undef HAVE_INET_ATONdnl #undef HAVE_INET_SOCKETSdnl #undef HAVE_UNIX_SOCKETSdnl #undef HAVE_SOCKLEN_Tdnl END ACCONFIGdnl ACCONFIG BOTTOMdnl dnl #ifdef HAVE_WINSOCK_Hdnl #include <winsock.h>dnl #elsednl #ifdef HAVE_SYS_SOCKET_Hdnl #include <sys/socket.h>dnl #ifdef HAVE_SELECT_Hdnl #include <select.h>dnl #elsednl #ifdef HAVE_SYS_SELECT_Hdnl #include <sys/select.h>dnl #endifdnl #endifdnl #ifdef HAVE_ARPA_INET_Hdnl #include <netinet/in.h>dnl #include <arpa/inet.h>dnl #include <netdb.h>dnl #endifdnl #ifdef HAVE_SYS_UN_Hdnl #include <sys/un.h>dnl #endifdnl #endifdnl #endifdnl dnl #ifndef HAVE_INET_ATONdnl #define inet_aton(cp, addr) \dnl (((*(unsigned long int *)(addr)) = inet_addr(cp)) != -1)dnl #endifdnl dnl #ifndef SUN_LENdnl #ifdef SCM_RIGHTSdnl #define HAVE_UN_LENdnl #endifdnl #ifdef __linuxdnl #define HAVE_UN_LENdnl #endifdnl #ifdef HAVE_UN_LENdnl #define SUN_LEN(ptr) sizeof(sockaddr_un.sun_len) + \dnl sizeof(sockaddr_un.sun_family) + sizeof(sockaddr_un.sun_path) + 1dnl #elsednl #define SUN_LEN(ptr) ((size_t)((struct sockaddr_un *)0)->sun_path) \dnl + strlen((ptr)->sun_path))dnl #endifdnl #endifdnl dnl #ifndef HAVE_SOCKLEN_Tdnl typedef int socklen_t;dnl #endifdnl dnl END ACCONFIGdnl Copyright (C) 1999-2000 Open Source Telecom Corporation.dnl dnl This program is free software; you can redistribute it and/or modifydnl it under the terms of the GNU General Public License as published bydnl the Free Software Foundation; either version 2 of the License, ordnl (at your option) any later version.dnl dnl This program is distributed in the hope that it will be useful,dnl but WITHOUT ANY WARRANTY; without even the implied warranty ofdnl MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See thednl GNU General Public License for more details.dnl dnl You should have received a copy of the GNU General Public Licensednl along with this program; if not, write to the Free Software dnl Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.dnl dnl As a special exception to the GNU General Public License, if you dnl distribute this file as part of a program that contains a configuration dnl script generated by Autoconf, you may include it under the same dnl distribution terms that you use for the rest of that program.AC_DEFUN(OST_CC_DAEMON,[ AC_REQUIRE([OST_SYS_POSIX]) AC_REQUIRE([OST_CC_SIGNAL]) AC_REQUIRE([AC_TYPE_PID_T]) AC_CHECK_HEADERS(sys/resource.h sysexits.h) AC_CHECK_FUNCS(pdetach)])AC_DEFUN(OST_LIB_WRAPPER,[ AC_REQUIRE([OST_LIB_SOCKET]) AC_CHECK_HEADERS(tcpd.h) AC_CHECK_LIB(wrap, request_init, [ LIBS="-lwrap $LIBS"])])AC_DEFUN(OST_LIB_DYNAMIC,[ DYN_LOADER='' AC_REQUIRE([OST_SYS_POSIX]) AC_CHECK_HEADERS(dlfcn.h) AC_CHECK_LIB(dl, dlopen, [DYN_LOADER=-ldl]) if test ! -z "$DYN_LOADER" ; then AC_DEFINE(HAVE_MODULES) fi AC_SUBST(DYN_LOADER) ])dnl ACCONFIG TEMPLATEdnl #undef HAVE_SYS_RESOURCE_Hdnl #undef HAVE_PDETACHdnl #undef HAVE_SYSEXITS_Hdnl #undef HAVE_TCPD_Hdnl #undef HAVE_DLOPENdnl #undef HAVE_MODULESdnl END ACCONFIGdnl ACCONFIG BOTTOMdnl dnl #ifdef HAVE_SYS_RESOURCE_Hdnl #include <sys/resource.h>dnl #endifdnl dnl #ifdef HAVE_DLFCN_Hdnl #include <dlfcn.h>dnl #endifdnl dnl #ifdef HAVE_SYSEXITS_Hdnl #include <sysexits.h>dnl #endifdnl dnl #ifdef HAVE_TCPD_Hdnl #include <tcpd.h>dnl #endifdnl dnl #ifndef EX_OKdnl #define EX_OK 0dnl #endifdnl #ifndef EX_USAGEdnl #define EX_USAGE 64dnl #endifdnl #ifndef EX_DATAERRdnl #define EX_DATAERR 65dnl #endifdnl #ifndef EX_NOINPUTdnl #define EX_NOINPUT 66dnl #endifdnl #ifndef EX_NOUSERdnl #define EX_NOUSER 67dnl #endifdnl #ifndef EX_NOHOSTdnl #define EX_NOHOST 68dnl #endifdnl #ifndef EX_UNAVAILABLEdnl #define EX_UNAVAILABLE 69dnl #endifdnl #ifndef EX_SOFTWAREdnl #define EX_SOFTWARE 70dnl #endifdnl #ifndef EX_OSERRdnl #define EX_OSERR 71dnl #endifdnl #ifndef EX_OSFILEdnl #define EX_OSFILE 72dnl #endifdnl #ifndef EX_CANTCREATdnl #define EX_CANTCREAT 73dnl #endifdnl #ifndef EX_IOERRdnl #define EX_IOERR 74dnl #endifdnl #ifndef EX_TEMPFAILdnl #define EX_TEMPFAIL 75dnl #endifdnl #ifndef EX_PROTOCOLdnl #define EX_PROTOCOL 76dnl #endifdnl #ifndef EX_NOPERMdnl #define EX_NOPERM 77dnl #endifdnl #ifndef EX_CONFIGdnl #define EX_CONFIG 78dnl #endifdnl #ifndef EX__MAXdnl #define EX__MAX 78dnl #endifdnl dnl END ACCONFIG
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -