📄 configure.ac
字号:
if test "x$local_os_type" = "xopenbsd"; then LIBS="$LIBS -liconv" fi fi if test "x$support_xft" = "xyes"; then AC_DEFINE(XFT_SUPPORT, [], [set XFT support]) else dnl Restore backup copy variables LIBS="$OLD_LIBS" CFLAGS="$OLD_CFLAGS" LDFLAGS="$OLD_LDFLAGS" fifiAM_CONDITIONAL(XFT_SUPPORT, test "x$support_xft" = "xyes")if test "x$support_cjk" = "xyes"; then AC_DEFINE(MULTICHAR_SET, [], [set CJK multichar set support]) AC_DEFINE_UNQUOTED(MULTICHAR_ENCODING, "$encoding_option", [default encoding])fiAC_HEADER_STDCAC_HEADER_SYS_WAITAC_CHECK_HEADERS([stdlib.h], [], [], [#include <stdio.h> ])AC_CHECK_HEADERS([sys/socket.h], [], [], [#include <stdio.h> #ifdef STDC_HEADERS # include <stdlib.h> # include <stddef.h> #else # ifdef HAVE_STDLIB_H # include <stdlib.h> # endif #endif ])AC_CHECK_HEADERS( \ arpa/inet.h \ assert.h \ fcntl.h \ iconv.h \ lastlog.h \ limits.h \ locale.h \ langinfo.h \ netinet/in.h \ pty.h \ sgtty.h \ stdarg.h \ stdlib.h \ string.h \ sys/byteorder.h \ sys/ioctl.h \ sys/select.h \ sys/sockio.h \ sys/stropts.h \ sys/strredir.h \ sys/stat.h \ sys/time.h \ sys/times.h \ sys/types.h \ sys/wait.h \ time.h \ termios.h \ unistd.h \ utmp.h \ utmpx.h \ wordexp.h \ wchar.h \)if test "x$support_sessionmgr" = "xyes"; then AC_CHECK_HEADERS(X11/SM/SMlib.h)fiAC_CHECK_HEADERS([net/if.h], [], [], [#include <stdio.h> #ifdef STDC_HEADERS # include <stdlib.h> # include <stddef.h> #else # ifdef HAVE_STDLIB_H # include <stdlib.h> # endif #endif #if HAVE_SYS_SOCKET_H # include <sys/socket.h> #endif ])AC_CHECK_HEADERS([net/if_arp.h], [], [], [#include <stdio.h> #ifdef STDC_HEADERS # include <stdlib.h> # include <stddef.h> #else # ifdef HAVE_STDLIB_H # include <stdlib.h> # endif #endif #if HAVE_SYS_SOCKET_H # include <sys/socket.h> #endif ])dnl Checks for typedefs, structures, and compiler characteristics.AC_C_CONSTAC_C_INLINEAC_HEADER_TIMEAC_STRUCT_TMAC_TYPE_MODE_TAC_TYPE_UID_TAC_TYPE_PID_TAC_TYPE_SIGNALAC_CACHE_CHECK(for working nl_langinfo, rxvt_cv_func_nl_langinfo,[AC_LINK_IFELSE([AC_LANG_PROGRAM([[#include <langinfo.h>]], [[nl_langinfo(CODESET);]])],[rxvt_cv_func_nl_langinfo=yes],[rxvt_cv_func_nl_langinfo=no])])if test "x$rxvt_cv_func_nl_langinfo" = "xyes"; then AC_DEFINE(HAVE_NL_LANGINFO, 1, Define if nl_langinfo(CODESET) works)fiAC_CACHE_CHECK([for XPointer], rxvt_cv_xpointer,[AC_TRY_COMPILE([#include <X11/Xlib.h>], [XPointer dummy;],rxvt_cv_xpointer=yes, rxvt_cv_xpointer=no)])if test "x$rxvt_cv_xpointer" = "xyes"; then AC_DEFINE(HAVE_XPOINTER, 1, Define if you have XPointer typedef)fiif test "x$support_utmp" = "xyes"; then AC_CACHE_CHECK([for struct utmp], rxvt_cv_struct_utmp, [AC_TRY_COMPILE([#include <sys/types.h> #include <utmp.h>], [struct utmp ut;], rxvt_cv_struct_utmp=yes, rxvt_cv_struct_utmp=no)]) if test "x$rxvt_cv_struct_utmp" = "xyes"; then AC_DEFINE(HAVE_STRUCT_UTMP, 1, Define if utmp.h has struct utmp) fi AC_CACHE_CHECK(for ut_host in utmp struct, rxvt_cv_struct_utmp_host, [AC_TRY_COMPILE([#include <sys/types.h> #include <utmp.h>], [struct utmp ut; ut.ut_host;], rxvt_cv_struct_utmp_host=yes, rxvt_cv_struct_utmp_host=no)]) if test "x$rxvt_cv_struct_utmp_host" = "xyes"; then AC_DEFINE(HAVE_UTMP_HOST, 1, Define if struct utmp contains ut_host) fi AC_CACHE_CHECK(for ut_pid in utmp struct, rxvt_cv_struct_utmp_pid, [AC_TRY_COMPILE([#include <sys/types.h> #include <utmp.h>], [struct utmp ut; ut.ut_pid;], rxvt_cv_struct_utmp_pid=yes, rxvt_cv_struct_utmp_pid=no)]) if test "x$rxvt_cv_struct_utmp_pid" = "xyes"; then AC_DEFINE(HAVE_UTMP_PID, 1, Define if struct utmp contains ut_pid) fi AC_CACHE_CHECK([for struct utmpx], rxvt_cv_struct_utmpx, [AC_TRY_COMPILE([#include <sys/types.h> #include <utmpx.h>], [struct utmpx ut;], rxvt_cv_struct_utmpx=yes, rxvt_cv_struct_utmpx=no)]) if test "x$rxvt_cv_struct_utmpx" = "xyes"; then AC_DEFINE(HAVE_STRUCT_UTMPX, 1, Define if utmpx.h has struct utmpx) fi AC_CACHE_CHECK(for ut_host in utmpx struct, rxvt_cv_struct_utmpx_host, [AC_TRY_COMPILE([#include <sys/types.h> #include <utmpx.h>], [struct utmpx utx; utx.ut_host;], rxvt_cv_struct_utmpx_host=yes, rxvt_cv_struct_utmpx_host=no)]) if test "x$rxvt_cv_struct_utmpx_host" = "xyes"; then AC_DEFINE(HAVE_UTMPX_HOST, 1, Define if struct utmpx contains ut_host) fi AC_CACHE_CHECK(for ut_session in utmpx struct, rxvt_cv_struct_utmpx_session, [AC_TRY_COMPILE([#include <sys/types.h> #include <utmpx.h>], [struct utmpx utx; utx.ut_session;], rxvt_cv_struct_utmpx_session=yes, rxvt_cv_struct_utmpx_session=no)]) if test "x$rxvt_cv_struct_utmpx_session" = "xyes"; then AC_DEFINE(HAVE_UTMPX_SESSION, 1, Define if struct utmpx contains ut_session) fifiif test "x$support_utmp x$support_lastlog" = "xyes xyes"; then AC_CACHE_CHECK(for struct lastlog, rxvt_cv_struct_lastlog, [AC_TRY_COMPILE([#include <sys/types.h> #include <utmp.h> #ifdef HAVE_LASTLOG_H #include <lastlog.h> #endif ], [struct lastlog ll;], rxvt_cv_struct_lastlog=yes, rxvt_cv_struct_lastlog=no)]) if test "x$rxvt_cv_struct_lastlog" = "xyes"; then AC_DEFINE(HAVE_STRUCT_LASTLOG, 1, Define if utmp.h or lastlog.h has struct lastlog) fifiAC_CHECK_SIZEOF(char, 1)AC_CHECK_SIZEOF(short, 2)AC_CHECK_SIZEOF(int, 4)AC_CHECK_SIZEOF(long, 4)AC_CHECK_SIZEOF(long long, 8)AC_CHECK_SIZEOF(int *, 4)if test $ac_cv_sizeof_char -ge 2; then RINT16T=char AC_DEFINE(RINT16T, char,[typedef]) AC_DEFINE(RUINT16T, unsigned char,[typedef])else if test $ac_cv_sizeof_short -ge 2; then RINT16T=short AC_DEFINE(RINT16T, short,[typedef]) AC_DEFINE(RUINT16T, unsigned short,[typedef]) else if test $ac_cv_sizeof_int -ge 2; then RINT16T=int AC_DEFINE(RINT16T, int,[typedef]) AC_DEFINE(RUINT16T, unsigned int,[typedef]) else dnl What a fantastic system ? RINT16T=long AC_DEFINE(RINT16T, long,[typedef]) AC_DEFINE(RUINT16T, unsigned long,[typedef]) fi fifiif test $ac_cv_sizeof_char -ge 4; then RINT32T=char AC_DEFINE(RINT32T, char,[typedef]) AC_DEFINE(RUINT32T, unsigned char,[typedef])else if test $ac_cv_sizeof_short -ge 4; then RINT32T=short AC_DEFINE(RINT32T, short,[typedef]) AC_DEFINE(RUINT32T, unsigned short,[typedef]) else if test $ac_cv_sizeof_int -ge 4; then RINT32T=int AC_DEFINE(RINT32T, int,[typedef]) AC_DEFINE(RUINT32T, unsigned int,[typedef]) else dnl What a fantastic system ? RINT32T=long AC_DEFINE(RINT32T, long,[typedef]) AC_DEFINE(RUINT32T, unsigned long,[typedef]) fi fifiif test $ac_cv_sizeof_char -eq $ac_cv_sizeof_int_p; then RINTPT=char AC_DEFINE(RINTPT, char,[typedef]) AC_DEFINE(RUINTPT, unsigned char,[typedef])else if test $ac_cv_sizeof_short -eq $ac_cv_sizeof_int_p; then RINTPT=short AC_DEFINE(RINTPT, short,[typedef]) AC_DEFINE(RUINTPT, unsigned short,[typedef]) else if test $ac_cv_sizeof_int -eq $ac_cv_sizeof_int_p; then RINTPT=int AC_DEFINE(RINTPT, int,[typedef]) AC_DEFINE(RUINTPT, unsigned int,[typedef]) else dnl what next? long long? quad? RINTPT=long AC_DEFINE(RINTPT, long,[typedef]) AC_DEFINE(RUINTPT, unsigned long,[typedef]) fi fifidnl Checks for library functions.AC_FUNC_CHOWNAC_FUNC_FORKAC_PROG_GCC_TRADITIONALAC_FUNC_LSTATdnl AC_FUNC_MALLOCAC_FUNC_SETPGRPAC_FUNC_VPRINTFdnl Now to check functionsAC_CHECK_FUNCS( getcwd \ getpt \ _getpty \ getpwuid \ grantpt \ isastream \ nanosleep \ openpty \ putenv \ revoke \ select \ setlocale \ seteuid \ setpgrp \ setpgid \ setreuid \ setsid \ setutent \ socket \ strcasestr \ strchr \ strdup \ strndup \ strrchr \ ttyslot \ unlockpt \ unsetenv \ updwtmp \ updwtmpx \ xsetlocale \)dnl Now to set tty optionsdnl echo "*** ac_cv_func_getpt = $ac_cv_func_getpt"dnl Check PTY/TTY typesif test "x$ac_cv_func_openpty" = "xyes"; then rxvt_cv_ptys=OPENPTYelse if test "x$ac_cv_func__getpty" = "xyes"; then rxvt_cv_ptys=SGI4else if test -c /dev/ttyp20; then rxvt_cv_ptys=SCOelse if test -c /dev/ptym/clone; then rxvt_cv_ptys=HPUXelse if test "x$ac_cv_func_getpt" = "xyes"; then rxvt_cv_ptys=GLIBCelse if test -c /dev/ptc -a -c /dev/pts; then rxvt_cv_ptys=PTCelse if test -c /dev/ptc -a -d /dev/pts; then rxvt_cv_ptys=PTCelse if test -c /dev/ptmx -a -c /dev/pts/0; then rxvt_cv_ptys=STREAMSelse if test "x$ac_cv_func_grantpt x$ac_cv_func_unlockpt" = "xyes xyes"; then rxvt_cv_ptys=STREAMSelse rxvt_cv_ptys=BSDfififififififififidnl echo "*** rxvt_cv_ptys = $rxvt_cv_ptys"if test "x$rxvt_cv_ptys" = "xOPENPTY"; then AC_DEFINE(PTYS_ARE_OPENPTY, 1, Define for this pty type)fiif test "x$rxvt_cv_ptys" = "xSCO"; then AC_DEFINE(PTYS_ARE_NUMERIC, 1, Define for this pty type)fiif test "x$rxvt_cv_ptys" = "xSTREAMS"; then AC_DEFINE(PTYS_ARE_PTMX, 1, Define for this pty type)fiif test "x$rxvt_cv_ptys" = "xPTC"; then AC_DEFINE(PTYS_ARE_PTC, 1, Define for this pty type)fiif test "x$rxvt_cv_ptys" = "xSGI4"; then AC_DEFINE(PTYS_ARE__GETPTY, 1, Define for this pty type)fiif test "x$rxvt_cv_ptys" = "xCONVEX"; then AC_DEFINE(PTYS_ARE_GETPTY, 1, Define for this pty type)fiif test "x$rxvt_cv_ptys" = "xGLIBC"; then AC_DEFINE(PTYS_ARE_GETPT, 1, Define for this pty type)fiif test "x$rxvt_cv_ptys" = "xHPUX"; then AC_DEFINE(PTYS_ARE_CLONE, 1, Define for this pty type)fiif test "x$rxvt_cv_ptys" = "xBSD" -o "x$rxvt_cv_ptys" = "xHPUX" -o "x$rxvt_cv_ptys" = "xGLIBC"; then AC_DEFINE(PTYS_ARE_SEARCHED, 1, Define for this pty type)fiAC_CHECKING(for pty ranges)ptys=`echo /dev/pty??`pch1=`echo $ptys | tr ' ' '\012' | sed -e 's/^.*\(.\).$/\1/g' | sort -u | tr -d '\012'`pch2=`echo $ptys | tr ' ' '\012' | sed -e 's/^.*\(.\)$/\1/g' | sort -u | tr -d '\012'`if test x$pch1 != x; then AC_DEFINE_UNQUOTED(PTYCHAR1, "$pch1", Define for first char in devptyXX)fiif test x$pch2 != x; then AC_DEFINE_UNQUOTED(PTYCHAR2, "$pch2", Define for second char in devptyXX)fidnl Now to generate MakefilesAC_SUBST(CC)AC_SUBST(CFLAGS)AC_SUBST(LDFLAGS)AC_SUBST(LIBS)AC_CONFIG_FILES([Makefile doc/Makefile src/Makefile share/Makefile])AC_OUTPUTdnl Now to dump configuration optionsdnl echo "CFLAGS: $CFLAGS"dnl echo "LDFLAGS: $LDFLAGS"dnl echo "LIBS: $LIBS"echoechoecho "Configurations:"echoechoecho "Maintenance:"echo "Debug mode : $support_debug"echo "Private string functions : $support_ourstrings"echo "Rarely used features : $support_frills"echo echo "Scroll features:"echo "Keep scroll : $support_keepscrolling"echo "Scroll on selection : $support_selectionscrolling"echo "Mouse wheel scroll : $support_mousewheel"if test "x$support_mousewheel" = "xyes"; then echo "Slip mouse wheel scroll : $support_mouseslipwheel"fiif test "x$support_scroll" = "xyes"; then echo "RXVT style scrollbar : $support_scroll_rxvt" echo "NeXT style scrollbar : $support_scroll_next" echo "Xterm style scrollbar : $support_scroll_xterm" echo "Plain style scrollbar : $support_scroll_plain" echo "SGI IRIX style scrollbar : $support_scroll_sgi" if test "x$support_scroll_rxvt" = "xyes"; then echo "Half shadow scrollbar : $support_half_shadow" fifiechoecho "Logging features:"echo "Support utmp records : $support_utmp"echo "Support wtmp records : $support_wtmp"echo "Support lastlog records : $support_lastlog"echo "Support X session manager : $support_sessionmgr"echo "Use utempter library : $support_utempter"echoecho "Visual features:"echo "Support line space : $support_linespace"echo "24 bits color mode : $support_24bits"echo "256 color mode : $support_256colors"echo "Blink cursor : $support_cursor_blink"echo "Blank pointer : $support_pointer_blank"echo "Color text shadow : $support_text_shadow"echo "Smart resize : $support_smart_resize"echo "Menu bar : $support_menubar"echoecho "Background features:"echo "Background image : $support_background_image"echo "XPM background image : $support_xpm"echo "JPEG background image : $support_jpeg"echo "PNG background image : $support_png"echo "Transparent background : $support_transparency"dnl: echo "Off focus fading : $support_fading"if test "x$support_tinting" = "xno"; then echo "Background tinting : $support_tinting"else if test "x$support_xrender" = "xyes"; then echo "Background tinting : $support_tinting (XRender)" else echo "Background tinting : $support_tinting (Fast)" fifiechoecho "Multi-language and font features:"echo "Freetype Font : $support_xft"echo "X Input Method : $support_xim"echo "Greek keyboard : $support_greek"echo "CJK multichar language : $support_cjk"if test "x$support_cjk" = "xyes"; then echo "Default encoding method : $encoding_option"fiechoecho "System features:"echo "TTY/PTY type : $rxvt_cv_ptys"echo "TTY gid : $support_ttygid"echo "Backspace key : $support_backspace_key"echo "Delete key : $support_delete_key"echo "Use fifo : $use_fifo"echo "X resources : $support_resources"echo "X default resources : $support_xgetdefault"echo "Swap screen : $support_swapscreen"echo "Old selection : $support_old_selection"echoecho "Options:"echo "Terminal name : $term_name_option"echo "Maximal profiles : $max_prof_option"echo "Maximal tabs : $max_term_option"echo "Extra height% of active tab : $atab_extra_option"echo "Radius% of tab corners : $tab_radius_option"if test "x$support_linespace" = "xyes"; then echo "Line space : $line_space_option"fiif test "x$support_frills" = "xyes"; then echo "Internal border width : $int_border_option" echo "External border width : $ext_border_option"fiif test "x$support_scroll" = "xyes"; then echo "Saved lines in scroll : $save_lines_option"fiecho
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -