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

📄 configure.in

📁 wu-ftpd类unix下的ftp服务器,可用于嵌入式系统
💻 IN
📖 第 1 页 / 共 2 页
字号:
if test $result = "no"; then  AC_TRY_RUN([#include <stdio.h>  int main(int argc, char **argv) {    if(printf("%qd",(long long) 1)==1)      return 0;    return 1;  }],[ result="qd" ],[ result="no" ], [ result="no"])  if test $result = "no"; then    AC_TRY_RUN([#include <stdio.h>    int main(int argc, char **argv) {      if(printf("Ld",(long long) 1)==1)        return 0;      return 1;    }],[ result="Ld" ],[ result="no" ], [ result="no" ])    if test $result = "no"; then      AC_TRY_RUN([#include <stdio.h>      int main(int argc, char **argv) {        if(printf("lld",(long long) 1)==1)          return 0;        return 1;      }],[ result="lld" ],[ result="no" ], [ result="no" ])      if test $result = "no"; then        AC_TRY_RUN([#include <stdio.h>        int main(int argc, char **argv) {          if(printf("ld",(long long) 1)==1)            return 0;          return 1;        }],[ result="ld" ],[ result="d" ], [ result="d" ])      fi    fi  fi  AC_DEFINE_UNQUOTED(PW_UID_FORMAT,"$result")  AC_MSG_RESULT(%$result)fiAC_MSG_CHECKING(how to printf an off_t)AC_TRY_RUN([#ifdef HAVE_STDLIB_H#include <stdlib.h>#endif#ifdef HAVE_UNISTD_H#include <unistd.h>#endif#include <sys/stat.h>int main(int argc, char **argv) {  if(sizeof(off_t)<=4)    return 0;  return 1;}],[ result="u"AC_DEFINE_UNQUOTED(L_FORMAT, "$result")AC_MSG_RESULT(off_t is just a long - using %u)],[ result="no" ], [ result="no" ])if test $result = "no"; then  AC_TRY_RUN([#include <stdio.h>  int main(int argc, char **argv) {    char tstr[8];    if(sprintf(tstr, "%qd",(long long) 1)==1)      return 0;    return 1;  }],[ result="qd" ],[ result="no" ], [ result="no"])  if test $result = "no"; then    AC_TRY_RUN([#include <stdio.h>    int main(int argc, char **argv) {      char tstr[8];      if(sprintf(tstr, "Ld",(long long) 1)==1)        return 0;      return 1;    }],[ result="Ld" ],[ result="no" ], [ result="no" ])    if test $result = "no"; then      AC_TRY_RUN([#include <stdio.h>      int main(int argc, char **argv) {        char tstr[8];        if(sprintf(tstr, "lld",(long long) 1)==1)          return 0;        return 1;      }],[ result="lld" ],[ result="no" ], [ result="no" ])      if test $result = "no"; then        AC_TRY_RUN([#include <stdio.h>        int main(int argc, char **argv) {          char tstr[8];          if(sprintf(tstr, "ld",(long long) 1)==1)            return 0;          return 1;        }],[ result="ld" ],[ result="d" ], [ result="d" ])      fi    fi  fi  AC_DEFINE_UNQUOTED(L_FORMAT,"$result")  AC_MSG_RESULT(using %$result)fiAC_MSG_CHECKING(how to printf a time_t)AC_TRY_RUN([#ifdef HAVE_STDLIB_H#include <stdlib.h>#endif#ifdef HAVE_UNISTD_H#include <unistd.h>#endif#ifdef TIME_WITH_SYS_TIME#include <sys/time.h>#include <time.h>#else#ifdef HAVE_SYS_TIME_H#include <sys/time.h>#else#include <time.h>#endif#endifint main(int argc, char **argv) {  if(sizeof(time_t)<=4)    return 0;  return 1;}],[ result="u"AC_DEFINE_UNQUOTED(T_FORMAT, "$result")AC_MSG_RESULT(time_t is just a long - using %u)],[ result="no" ], [ result="no" ])if test $result = "no"; then  AC_TRY_RUN([#include <stdio.h>  int main(int argc, char **argv) {    if(printf("%qd",(long long) 1)==1)      return 0;    return 1;  }],[ result="qd" ],[ result="no" ], [ result="no"])  if test $result = "no"; then    AC_TRY_RUN([#include <stdio.h>    int main(int argc, char **argv) {      if(printf("Ld",(long long) 1)==1)        return 0;      return 1;    }],[ result="Ld" ],[ result="no" ], [ result="no" ])    if test $result = "no"; then      AC_TRY_RUN([#include <stdio.h>      int main(int argc, char **argv) {        if(printf("lld",(long long) 1)==1)          return 0;        return 1;      }],[ result="lld" ],[ result="no" ], [ result="no" ])      if test $result = "no"; then        AC_TRY_RUN([#include <stdio.h>        int main(int argc, char **argv) {          if(printf("ld",(long long) 1)==1)            return 0;          return 1;        }],[ result="ld" ],[ result="d" ], [ result="d" ])      fi    fi  fi  AC_DEFINE_UNQUOTED(T_FORMAT,"$result")  AC_MSG_RESULT(%$result)fidnl ===========================================================================dnl Handle some of the input generated above...dnl ============================================================================if test $ac_cv_func_usercmp != yes; then	AUTHUSER=authuser.ofiif test $ac_cv_func_ftw != yes; then	FTW=ftw.ofiif test $ac_cv_func_getusershell != yes; then	GETUSERSHELL=getusershell.ofiif test $ac_cv_func_setuid != yes; then	SCO=sco.oelse	AC_DEFINE(HAVE_SETUID)fiif test $ac_cv_func_snprintf != yes; then	SNPRINTF=snprintf.ofiif test $ac_cv_func_strcasestr != yes; then	STRCASESTR=strcasestr.ofiif test $ac_cv_func_strdup != yes; then	STRDUP=strdup.ofiif test $ac_cv_func_strerror != yes; then	STRERROR=strerror.ofiif test $ac_cv_func_strsep != yes; then	STRSEP=strsep.ofiif test $ac_cv_func_strstr != yes; then	STRSTR=strstr.ofiif test $ac_cv_func_syslog != yes; then	SYSLOG=syslog.ofiif test $ac_cv_func_glob != yes; then	GLOB=glob.ofiif test $ac_cv_func_strcasecmp != yes; then	STRCASECMP=strcasecmp.ofiif test $ac_cv_func_strncasecmp != yes; then	STRNCASECMP=strncasecmp.ofiAC_SUBST(AUTHUSER)AC_SUBST(FTW)AC_SUBST(GETUSERSHELL)AC_SUBST(SCO)AC_SUBST(SNPRINTF)AC_SUBST(STRCASESTR)AC_SUBST(STRDUP)AC_SUBST(STRERROR)AC_SUBST(STRSEP)AC_SUBST(STRSTR)AC_SUBST(SYSLOG)AC_SUBST(GLOB)AC_SUBST(STRCASECMP)AC_SUBST(STRNCASECMP)dnl ===========================================================================dnl Get the --enable, --disable, --with, --without stuff into the config filesdnl fix it up when necessarydnl ============================================================================if test $upload = yes; then	AC_DEFINE(UPLOAD)fiif test $overwrite = yes; then	AC_DEFINE(OVERWRITE)fiif test $hostxs = yes; then	AC_DEFINE(HOST_ACCESS)fiif test $logfailed = yes; then	AC_DEFINE(LOG_FAILED)fiif test $logtoomany = yes; then	AC_DEFINE(LOG_TOOMANY)fiif test $private = no; then	AC_DEFINE(NO_PRIVATE)fiif test $dnsretry = yes; then	AC_DEFINE(DNS_TRYAGAIN)fiif test $anononly = yes; then	if test $anonymous = no; then		AC_MSG_ERROR(enable-anononly and disable-anonymous together don't make sense.)	fi	AC_DEFINE(ANON_ONLY)fiif test $paranoid = yes; then	AC_DEFINE(PARANOID)fiif test $quota != no; then	AC_CHECK_HEADERS(sys/quota.h sys/fs/ufs_quota.h ufs/quota.h jfs/quota.h ufs/ufs/quota.h linux/quota.h)	if test $ac_cv_header_sys_quota.h = yes -o $ac_cv_header_sys_fs_ufs_quota_h = yes -o $ac_cv_header_ufs_quota_h = yes -o $ac_cv_header_jfs_quota_h = yes -o $ac_cv_header_ufs_ufs_quota_h = yes -o $ac_cv_header_linux_quota_h = yes; then		quota=yes	else		if test $quota = yes; then			AC_MSG_WARN(QUOTA not supported by OS - disabled)		fi		quota=no	fi	AC_MSG_CHECKING(for quota support)	AC_MSG_RESULT($quota)fiif test $quota = yes; then	dnl FIXME!!	dnl I didn't find a way to reliably check for QUOTA_DEVICE...	dnl so we're guessing at the system type, actually... :/	if test $ac_cv_header_sys_quota_h = yes -o $ac_cv_header_sys_fs_ufs_quota_h = yes; then		AC_DEFINE(QUOTA_DEVICE)	fi	AC_MSG_CHECKING(whether quota support is file- or inode based)	AC_TRY_COMPILE([#include <unistd.h>#ifdef TIME_WITH_SYS_TIME#include <sys/time.h>#include <time.h>#else#ifdef HAVE_SYS_TIME_H#include <sys/time.h>#else#include <time.h>#endif#endif#ifdef HAVE_SYS_TYPES_H#include <sys/types.h>#endif#ifdef HAVE_SYS_QUOTA_H#include <sys/quota.h>#else#ifdef HAVE_LINUX_QUOTA_H#include <linux/quota.h>#endif#endif#ifdef HAVE_SYS_FS_UFS_QUOTA_H#include <sys/fs/ufs/quota.h>#endif#ifdef HAVE_UFS_QUOTA_H#include <ufs/quota.h>#endif#ifdef HAVE_JFS_QUOTA_H#include <jfs/quota.h>#endif#ifdef HAVE_UFS_UFS_QUOTA_H#include <ufs/ufs/quota.h>#endifstruct dqblk quota;],[ int f=quota.dqb_ihardlimit; ], [ result=inode ], [ result=file ])	AC_MSG_RESULT($result)	if test $result = inode; then		AC_DEFINE(QUOTA_INODE)	fi	AC_DEFINE(QUOTA)fiif test $ac_cv_header_security_pam_appl_h = no; then  if test $pam = yes; then    AC_MSG_WARN(You don\'t have PAM libraries, or you\'re using an incompatible PAM implementation. PAM support disabled.)    pam=no  fifiif test $pam = yes; then	AC_DEFINE(USE_PAM)	LIBS="$LIBS -lpam"	AC_CHECK_LIB(dl, dlopen, result=yes, result=no)	if test $result = yes; then		# Some PAM implementations require -ldl...		LIBS="$LIBS -ldl"	fifidnl ===========================================================================dnl See if we have shadow passwords...dnl ============================================================================AC_CHECK_LIB(shadow, setspent, result=yes, result=no)SHADOW_PASSWORD=0LIBSHADOW=0if test $result = yes; then	LIBS="$LIBS -lshadow"	SHADOW_PASSWORD=1	LIBSHADOW=1else	AC_CHECK_LIB(shadow, getspnam, result=yes, result=no)	if test $result = yes; then		LIBS="$LIBS -lshadow"		SHADOW_PASSWORD=1		LIBSHADOW=1	else		AC_CHECK_LIB(c, setspent, result=yes, result=no)		if test $result = yes; then			SHADOW_PASSWORD=1		fi	fifiif test $SHADOW_PASSWORD = 1; then	if test $ac_cv_func_fgetspent != yes; then		AC_CHECK_LIB(shadow, fgetspent, result=yes, result=no)		if test $result = yes; then			if test $LIBSHADOW != 1; then				LIBS="$LIBS -lshadow"			fi		fi	fi	AC_DEFINE(SHADOW_PASSWORD)fiif test $ac_cv_header_skey_h = no; then  if test $skey = yes; then    AC_MSG_WARN(You don\'t have S/Key libraries, or you\'re using an incompatible implementation. S/Key support disabled.)    skey=no  fifiif test $skey = yes; then	AC_DEFINE(SKEY)	LIBS="$LIBS -lskey"fiif test $ac_cv_header_opie_h = no; then  if test $opie = yes; then    AC_MSG_WARN(You don\'t have OPIE libraries, or you\'re using an incompatible implementation. OPIE support disabled.)    opie=no  fifiif test $opie = yes; then	AC_DEFINE(OPIE)	LIBS="$LIBS -lopie"fiif test $newcd = yes; then	AC_DEFINE(ALTERNATE_CD)fiif test $chmod = yes; then	AC_DEFINE(UNRESTRICTED_CHMOD)fiif test $rfc931 = yes; then	AC_DEFINE(USE_RFC931)fiif test "$ratio" = "yes"; then	AC_DEFINE(RATIO)fiif test "$passwd" = "yes"; then	AC_DEFINE(OTHER_PASSWD)fiif test $daemon = yes; then	AC_DEFINE(DAEMON)fiif test $mapchdir = yes; then	AC_DEFINE(MAPPING_CHDIR)fiif test $throughput = yes; then	AC_DEFINE(THROUGHPUT)fiif test $count = yes; then	AC_DEFINE(TRANSFER_COUNT)	AC_DEFINE(TRANSFER_LIMIT)fiif test $newlines = no; then	AC_DEFINE(NO_SUCKING_NEWLINES)fiif test $crackers = yes; then	AC_DEFINE(HELP_CRACKERS)fiif test $verbose = yes; then	AC_DEFINE(VERBOSE_ERROR_LOGING)fiif test $noop = no; then	AC_DEFINE(IGNORE_NOOP)fiif test $logrp = yes; then	AC_DEFINE(XFERLOG_REALPATH)fiif test $virtual = yes; then	AC_DEFINE(VIRTUAL)fiif test $closedvirt = yes; then	AC_DEFINE(CLOSED_VIRTUAL_SERVER)fiif test $dns = no; then	AC_DEFINE(NO_DNS)fiif test $port = no; then	if test $pasv = no; then		AC_MSG_ERROR(Need at least PORT or PASV mode. Don't disable both.)	fi	AC_DEFINE(DISABLE_PORT)fiif test $pasv = no; then	AC_DEFINE(DISABLE_PASV)fiif test $plsm = no; then	AC_DEFINE(NO_PID_SLEEP_MSGS)fiif test $pasvip = yes; then	AC_DEFINE(FIGHT_PASV_PORT_RACE)fiif test $anonymous = no; then	AC_DEFINE(NO_ANONYMOUS_ACCESS)fiif test $ls = yes; then	AC_DEFINE(INTERNAL_LS)fiif test $numericuid = yes; then	AC_DEFINE(LS_NUMERIC_UIDS)fiif test $hidesetuid = yes; then	AC_DEFINE(HIDE_SETUID)fiif test $mail = yes; then	AC_DEFINE(MAIL_ADMIN)fiif test $badclients = yes; then	AC_DEFINE(SUPPORT_BROKEN_CLIENTS)fiif test $nlstdirs = yes; then	AC_DEFINE(NLST_SHOWS_DIRS)fidnl TODO:is there a better check whether or not an argument is numeric???if test x`expr $bufsize + 1 - 1 2>/dev/null` = x$bufsize; then	AC_DEFINE_UNQUOTED(BUFFER_SIZE, $bufsize)fiif test x`expr $backlog + 1 - 1 2>/dev/null` = x$backlog; then	AC_DEFINE_UNQUOTED(MAX_BACKLOG, $backlog)else	AC_DEFINE_UNQUOTED(MAX_BACKLOG, 100)fiAC_DEFINE_UNQUOTED(SIGNAL_TYPE, void)LIBS="$LIBS -lsupport"AC_SUBST(LIBS)AC_DEFINE(USE_ETC)dnl ===========================================================================dnl Write results...dnl ============================================================================AC_OUTPUT(Makefile src/Makefile support/Makefile util/privatepw/Makefile src/pathnames.h)

⌨️ 快捷键说明

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