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

📄 aclocal.m4

📁 ncurses 库 可能有用酒用 没用就算了 我觉得还可以用
💻 M4
📖 第 1 页 / 共 5 页
字号:
make an error#endif],	[cf_cv_gnu_source=no],	[cf_cv_gnu_source=yes])	CPPFLAGS="$cf_save"	])])test "$cf_cv_gnu_source" = yes && CPPFLAGS="$CPPFLAGS -D_GNU_SOURCE"])dnldnl ---------------------------------------------------------------------------dnl CF_GPP_LIBRARY version: 8 updated: 2003/02/02 01:41:46dnl --------------dnl If we're trying to use g++, test if libg++ is installed (a rather commondnl problem :-).  If we have the compiler but no library, we'll be able todnl configure, but won't be able to build the c++ demo program.AC_DEFUN([CF_GPP_LIBRARY],[cf_cxx_library=unknowncase $cf_cv_system_name in #(vios2*) #(vi	cf_gpp_libname=gpp	;;*)	cf_gpp_libname=g++	;;esacif test "$GXX" = yes; then	AC_MSG_CHECKING([for lib$cf_gpp_libname])	cf_save="$LIBS"	LIBS="$LIBS -l$cf_gpp_libname"	AC_TRY_LINK([#include <$cf_gpp_libname/builtin.h>	],	[two_arg_error_handler_t foo2 = lib_error_handler],	[cf_cxx_library=yes	 CXXLIBS="$CXXLIBS -l$cf_gpp_libname"	 if test "$cf_gpp_libname" = cpp ; then	    AC_DEFINE(HAVE_GPP_BUILTIN_H)	 else	    AC_DEFINE(HAVE_GXX_BUILTIN_H)	 fi],	[AC_TRY_LINK([#include <builtin.h>	],	[two_arg_error_handler_t foo2 = lib_error_handler],	[cf_cxx_library=yes	 CXXLIBS="$CXXLIBS -l$cf_gpp_libname"	 AC_DEFINE(HAVE_BUILTIN_H)],	[cf_cxx_library=no])])	LIBS="$cf_save"	AC_MSG_RESULT($cf_cxx_library)fi])dnldnl ---------------------------------------------------------------------------dnl CF_GXX_VERSION version: 5 updated: 2005/08/27 09:53:42dnl --------------dnl Check for version of g++AC_DEFUN([CF_GXX_VERSION],[AC_REQUIRE([AC_PROG_CPP])GXX_VERSION=noneif test "$GXX" = yes; then	AC_MSG_CHECKING(version of g++)	GXX_VERSION="`${CXX-g++} --version| sed -e '2,$d' -e 's/^.*(GCC) //' -e 's/^[[^0-9.]]*//' -e 's/[[^0-9.]].*//'`"	test -z "$GXX_VERSION" && GXX_VERSION=unknown	AC_MSG_RESULT($GXX_VERSION)fi])dnldnl ---------------------------------------------------------------------------dnl CF_GXX_WARNINGS version: 5 updated: 2005/08/13 14:54:38dnl ---------------dnl Check if the compiler supports useful warning options.dnldnl Most of gcc's options apply to g++, except:dnl	-Wbad-function-castdnl	-Wmissing-declarationsdnl	-Wnested-externsdnldnl Omit a few (for now):dnl	-Winlinednldnl Parameter:dnl	$1 is an optional list of g++ warning flags that a particulardnl		application might want to use, e.g., "no-unused" fordnl		-Wno-unuseddnl Special:dnl	If $with_ext_const is "yes", add a check for -Wwrite-stringsdnlAC_DEFUN([CF_GXX_WARNINGS],[CF_INTEL_COMPILER(GXX,INTEL_CPLUSPLUS,CXXFLAGS)AC_REQUIRE([CF_GXX_VERSION])AC_LANG_SAVEAC_LANG_CPLUSPLUScat > conftest.$ac_ext <<EOF#line __oline__ "configure"int main(int argc, char *argv[[]]) { return (argv[[argc-1]] == 0) ; }EOFif test "$INTEL_CPLUSPLUS" = yesthen# The "-wdXXX" options suppress warnings:# remark #1419: external declaration in primary source file# remark #1682: implicit conversion of a 64-bit integral type to a smaller integral type (potential portability problem)# remark #1683: explicit conversion of a 64-bit integral type to a smaller integral type (potential portability problem)# remark #1684: conversion from pointer to same-sized integral type (potential portability problem)# remark #193: zero used for undefined preprocessing identifier# remark #593: variable "curs_sb_left_arrow" was set but never used# remark #810: conversion from "int" to "Dimension={unsigned short}" may lose significant bits# remark #869: parameter "tw" was never referenced# remark #981: operands are evaluated in unspecified order# warning #269: invalid format string conversion	AC_CHECKING([for $CC warning options])	cf_save_CXXFLAGS="$CXXFLAGS"	EXTRA_CXXFLAGS="-Wall"	for cf_opt in \		wd1419 \		wd1682 \		wd1683 \		wd1684 \		wd193 \		wd279 \		wd593 \		wd810 \		wd869 \		wd981	do		CXXFLAGS="$cf_save_CXXFLAGS $EXTRA_CXXFLAGS -$cf_opt"		if AC_TRY_EVAL(ac_compile); then			test -n "$verbose" && AC_MSG_RESULT(... -$cf_opt)			EXTRA_CXXFLAGS="$EXTRA_CXXFLAGS -$cf_opt"		fi	done	CXXFLAGS="$cf_save_CXXFLAGS"elif test "$GXX" = yesthen	AC_CHECKING([for $CXX warning options])	cf_save_CXXFLAGS="$CXXFLAGS"	EXTRA_CXXFLAGS="-W -Wall"	cf_gxx_extra_warnings=""	test "$with_ext_const" = yes && cf_gxx_extra_warnings="Wwrite-strings"	case "$GCC_VERSION" in	[[1-2]].*)		;;	*)		cf_gxx_extra_warnings="$cf_gxx_extra_warnings Weffc++"		;;	esac	for cf_opt in \		Wabi \		fabi-version=0 \		Woverloaded-virtual \		Wsign-promo \		Wsynth \		Wold-style-cast \		Wcast-align \		Wcast-qual \		Wmissing-prototypes \		Wpointer-arith \		Wshadow \		Wstrict-prototypes \		Wundef $cf_gxx_extra_warnings $1	do		CXXFLAGS="$cf_save_CXXFLAGS $EXTRA_CXXFLAGS -Werror -$cf_opt"		if AC_TRY_EVAL(ac_compile); then			test -n "$verbose" && AC_MSG_RESULT(... -$cf_opt)			EXTRA_CXXFLAGS="$EXTRA_CXXFLAGS -$cf_opt"		else			test -n "$verbose" && AC_MSG_RESULT(... no -$cf_opt)		fi	done	CXXFLAGS="$cf_save_CXXFLAGS"firm -f conftest*AC_LANG_RESTOREAC_SUBST(EXTRA_CXXFLAGS)])dnldnl ---------------------------------------------------------------------------dnl CF_HELP_MESSAGE version: 3 updated: 1998/01/14 10:56:23dnl ---------------dnl Insert text into the help-message, for readability, from AC_ARG_WITH.AC_DEFUN([CF_HELP_MESSAGE],[AC_DIVERT_HELP([$1])dnl])dnldnl ---------------------------------------------------------------------------dnl CF_INCLUDE_DIRS version: 4 updated: 2002/12/01 00:12:15dnl ---------------dnl Construct the list of include-options according to whether we're buildingdnl in the source directory or using '--srcdir=DIR' option.  If we're buildingdnl with gcc, don't append the includedir if it happens to be /usr/include,dnl since that usually breaks gcc's shadow-includes.AC_DEFUN([CF_INCLUDE_DIRS],[CPPFLAGS="-I. -I../include $CPPFLAGS"if test "$srcdir" != "."; then	CPPFLAGS="-I\$(srcdir)/../include $CPPFLAGS"fiif test "$GCC" != yes; then	CPPFLAGS="$CPPFLAGS -I\$(includedir)"elif test "$includedir" != "/usr/include"; then	if test "$includedir" = '${prefix}/include' ; then		if test $prefix != /usr ; then			CPPFLAGS="$CPPFLAGS -I\$(includedir)"		fi	else		CPPFLAGS="$CPPFLAGS -I\$(includedir)"	fifiAC_SUBST(CPPFLAGS)])dnldnl ---------------------------------------------------------------------------dnl CF_INTEL_COMPILER version: 3 updated: 2005/08/06 18:37:29dnl -----------------dnl Check if the given compiler is really the Intel compiler for Linux.  Itdnl tries to imitate gcc, but does not return an error when it finds a mismatchdnl between prototypes, e.g., as exercised by CF_MISSING_CHECK.dnldnl This macro should be run "soon" after AC_PROG_CC or AC_PROG_CPLUSPLUS, todnl ensure that it is not mistaken for gcc/g++.  It is normally invoked fromdnl the wrappers for gcc and g++ warnings.dnldnl $1 = GCC (default) or GXXdnl $2 = INTEL_COMPILER (default) or INTEL_CPLUSPLUSdnl $3 = CFLAGS (default) or CXXFLAGSAC_DEFUN([CF_INTEL_COMPILER],[ifelse($2,,INTEL_COMPILER,[$2])=noif test "$ifelse($1,,[$1],GCC)" = yes ; then	case $host_os in	linux*|gnu*)		AC_MSG_CHECKING(if this is really Intel ifelse($1,GXX,C++,C) compiler)		cf_save_CFLAGS="$ifelse($3,,CFLAGS,[$3])"		ifelse($3,,CFLAGS,[$3])="$ifelse($3,,CFLAGS,[$3]) -no-gcc"		AC_TRY_COMPILE([],[#ifdef __INTEL_COMPILER#elsemake an error#endif],[ifelse($2,,INTEL_COMPILER,[$2])=yescf_save_CFLAGS="$cf_save_CFLAGS -we147 -no-gcc"],[])		ifelse($3,,CFLAGS,[$3])="$cf_save_CFLAGS"		AC_MSG_RESULT($ifelse($2,,INTEL_COMPILER,[$2]))		;;	esacfi])dnldnl ---------------------------------------------------------------------------dnl CF_ISASCII version: 3 updated: 2000/08/12 23:18:52dnl ----------dnl Check if we have either a function or macro for 'isascii()'.AC_DEFUN([CF_ISASCII],[AC_MSG_CHECKING(for isascii)AC_CACHE_VAL(cf_cv_have_isascii,[	AC_TRY_LINK([#include <ctype.h>],[int x = isascii(' ')],	[cf_cv_have_isascii=yes],	[cf_cv_have_isascii=no])])dnlAC_MSG_RESULT($cf_cv_have_isascii)test "$cf_cv_have_isascii" = yes && AC_DEFINE(HAVE_ISASCII)])dnldnl ---------------------------------------------------------------------------dnl CF_LARGEFILE version: 5 updated: 2005/07/17 11:03:36dnl ------------dnl Add checks for large file support.AC_DEFUN([CF_LARGEFILE],[ifdef([AC_FUNC_FSEEKO],[	AC_FUNC_FSEEKO	AC_SYS_LARGEFILE	# Normally we would collect these definitions in the config.h,	# but (like _XOPEN_SOURCE), some environments rely on having these	# defined before any of the system headers are included.  Another	# case comes up with C++, e.g., on AIX the compiler compiles the	# header files by themselves before looking at the body files it is	# told to compile.  For ncurses, those header files do not include	# the config.h	test "$ac_cv_sys_large_files"      != no && CPPFLAGS="$CPPFLAGS -D_LARGE_FILES "	test "$ac_cv_sys_largefile_source" != no && CPPFLAGS="$CPPFLAGS -D_LARGEFILE_SOURCE "	AC_CACHE_CHECK(whether to use struct dirent64, cf_cv_struct_dirent64,[		AC_TRY_COMPILE([#include <sys/types.h>#include <dirent.h>		],[		/* if transitional largefile support is setup, this is true */		extern struct dirent64 * readdir(DIR *);		struct dirent64 *x = readdir((DIR *)0);		struct dirent *y = readdir((DIR *)0);		int z = x - y;		],		[cf_cv_struct_dirent64=yes],		[cf_cv_struct_dirent64=no])	])	test "$cf_cv_struct_dirent64" = yes && AC_DEFINE(HAVE_STRUCT_DIRENT64)])])dnl ---------------------------------------------------------------------------dnl CF_LIBUTF8 version: 2 updated: 2002/01/19 22:51:32dnl ----------dnl Check for libutf8AC_DEFUN([CF_LIBUTF8],[AC_CACHE_CHECK(for putwc in libutf8,cf_cv_libutf8,[	cf_save_LIBS="$LIBS"	LIBS="-lutf8 $LIBS"AC_TRY_LINK([#include <libutf8.h>],[putwc(0,0);],	[cf_cv_libutf8=yes],	[cf_cv_libutf8=no])	LIBS="$cf_save_LIBS"])if test "$cf_cv_libutf8" = yes ; then	AC_DEFINE(HAVE_LIBUTF8_H)	LIBS="-lutf8 $LIBS"fi])dnldnl ---------------------------------------------------------------------------dnl CF_LIB_PREFIX version: 7 updated: 2001/01/12 01:23:48dnl -------------dnl Compute the library-prefix for the given host systemdnl $1 = variable to setAC_DEFUN([CF_LIB_PREFIX],[	case $cf_cv_system_name in	OS/2*)	LIB_PREFIX=''     ;;	os2*)	LIB_PREFIX=''     ;;	*)	LIB_PREFIX='lib'  ;;	esacifelse($1,,,[$1=$LIB_PREFIX])	AC_SUBST(LIB_PREFIX)])dnldnl ---------------------------------------------------------------------------dnl CF_LIB_RULES version: 36 updated: 2005/05/28 13:16:28dnl ------------dnl Append definitions and rules for the given models to the subdirectorydnl Makefiles, and the recursion rule for the top-level Makefile.  If thednl subdirectory is a library-source directory, modify the LIBRARIES list indnl the corresponding makefile to list the models that we'll generate.dnldnl For shared libraries, make a list of symbolic links to construct whendnl generating each library.  The convention used for Linux is the simplestdnl one:dnl	lib<name>.so	->dnl	lib<name>.so.<major>	->dnl	lib<name>.so.<maj>.<minor>AC_DEFUN([CF_LIB_RULES],[CF_LIB_PREFIX(cf_prefix)AC_REQUIRE([CF_SUBST_NCURSES_VERSION])for cf_dir in $SRC_SUBDIRSdo	if test -f $srcdir/$cf_dir/modules; then		IMPORT_LIB=		SHARED_LIB=		LIBS_TO_MAKE=		for cf_item in $CF_LIST_MODELS		do			CF_LIB_SUFFIX($cf_item,cf_suffix)			if test $cf_item = shared ; then			if test "$cf_cv_do_symlinks" = yes ; then				case "$cf_cv_shlib_version" in #(vi				rel) #(vi					case "$cf_cv_system_name" in #(vi					darwin*)					case .${LIB_SUFFIX} in					.w*)						cf_suffix=`echo $cf_suffix | sed 's/^w//'`						cf_suffix=w'.$(REL_VERSION)'"$cf_suffix"						;;					*)						cf_suffix='.$(REL_VERSION)'"$cf_suffix"						;;					esac					;; #(vi					*) cf_suffix="$cf_suffix"'.$(REL_VERSION)' ;;					esac					;;				abi)					case "$cf_cv_system_name" in #(vi					darwin*)					case .${LIB_SUFFIX} in					.w*)						cf_suffix=`echo $cf_suffix | sed 's/^w//'`						cf_suffix=w'.$(ABI_VERSION)'"$cf_suffix"						;;					*)						cf_suffix='.$(ABI_VERSION)'"$cf_suffix"						;;					esac					;; #(vi					*) cf_suffix="$cf_suffix"'.$(ABI_VERSION)' ;;					esac					;;				esac			fi			# cygwin needs import library, and has unique naming convention			# use autodetected ${cf_prefix} for import lib and static lib, but			# use 'cyg' prefix for shared lib.			if test $cf_cv_shlib_version = cygdll ; then				SHARED_LIB="../lib/cyg${cf_dir}\$(ABI_VERSION).dll"				IMPORT_LIB="../lib/${cf_prefix}${cf_dir}.dll.a"				LIBS_TO_MAKE="$LIBS_TO_MAKE \$(SHARED_LIB) \$(IMPORT_LIB)"				continue			fi			fi			LIBS_TO_MAKE="$LIBS_TO_MAKE ../lib/${cf_prefix}${cf_dir}${cf_suffix}"		done		if test $cf_dir = ncurses ; then			cf_subsets="$LIB_SUBSETS"			cf_termlib=`echo "$cf_subsets" |sed -e 's/ .*$//'`			if test "$cf_termlib" != "$cf_subsets" ; then				cf_item=`echo $LIBS_TO_MAKE |sed -e s%${LIB_NAME}${LIB_SUFFIX}%${TINFO_LIB_SUFFIX}%g`				LIBS_TO_MAKE="$cf_item $LIBS_TO_MAKE"			fi		else			cf_subsets=`echo "$LIB_SUBSETS" | sed -e 's/^termlib.* //'`		fi		sed -e "s%@LIBS_TO_MAKE@%$LIBS_TO_MAKE%" \		    -e "s%@IMPORT_LIB@%$IMPORT_LIB%" \		    -e "s%@SHARED_LIB@%$SHARED_LIB%" \			$cf_dir/Makefile >$cf_dir/Makefile.out		mv $cf_dir/Makefile.out $cf_dir/Makefile		$AWK -f $srcdir/mk-0th.awk \			libname="${cf_dir}${LIB_SUFFIX}" subsets="$LIB_SUBSETS" \			$srcdir/$cf_dir/modules >>$cf_dir/Makefile		for cf_subset in $cf_subsets		do			cf_subdirs=			for cf_item in $CF_LIST_MODELS			do			echo "Appending rules for ${cf_item} model (${cf_dir}: ${cf_subset})"			CF_UPPER(cf_ITEM,$cf_item)			CF_LIB_SUFFIX($cf_item,cf_suffix)			CF_OBJ_SUBDIR($cf_item,cf_subdir)			# Test for case where we build libtinfo with a different name.			cf_libname=$cf_dir

⌨️ 快捷键说明

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