提交 c833c6c5 编写于 作者: T Tom Lane

Hack to work around broken linker on older NetBSD/OpenBSD/Irix assumed

that readline must depend on libcurses, but it seems more recent ones
use libtermcap instead.  Allow that case.
上级 d7658911
# $PostgreSQL: pgsql/config/programs.m4,v 1.17 2004/11/30 06:13:02 tgl Exp $ # $PostgreSQL: pgsql/config/programs.m4,v 1.18 2004/12/02 20:04:19 tgl Exp $
# PGAC_PATH_FLEX # PGAC_PATH_FLEX
...@@ -87,13 +87,14 @@ for pgac_rllib in -lreadline -ledit ; do ...@@ -87,13 +87,14 @@ for pgac_rllib in -lreadline -ledit ; do
for pgac_lib in "" " -ltermcap" " -lncurses" " -lcurses" ; do for pgac_lib in "" " -ltermcap" " -lncurses" " -lcurses" ; do
LIBS="${pgac_rllib}${pgac_lib} $pgac_save_LIBS" LIBS="${pgac_rllib}${pgac_lib} $pgac_save_LIBS"
AC_TRY_LINK_FUNC([readline], [[ AC_TRY_LINK_FUNC([readline], [[
# NetBSD, OpenBSD, and Irix have a broken linker that does not # Older NetBSD, OpenBSD, and Irix have a broken linker that does not
# recognize dependent libraries # recognize dependent libraries; assume curses is needed if we didn't
case $host_os in netbsd* | openbsd* | irix*) # find any dependency.
case $pgac_lib in case $host_os in
*curses*) ;; netbsd* | openbsd* | irix*)
*) pgac_lib=" -lcurses" ;; if test x"$pgac_lib" = x"" ; then
esac pgac_lib=" -lcurses"
fi ;;
esac esac
pgac_cv_check_readline="${pgac_rllib}${pgac_lib}" pgac_cv_check_readline="${pgac_rllib}${pgac_lib}"
......
...@@ -5996,13 +5996,14 @@ if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 ...@@ -5996,13 +5996,14 @@ if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
echo "$as_me:$LINENO: \$? = $ac_status" >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then (exit $ac_status); }; }; then
# NetBSD, OpenBSD, and Irix have a broken linker that does not # Older NetBSD, OpenBSD, and Irix have a broken linker that does not
# recognize dependent libraries # recognize dependent libraries; assume curses is needed if we didn't
case $host_os in netbsd* | openbsd* | irix*) # find any dependency.
case $pgac_lib in case $host_os in
*curses*) ;; netbsd* | openbsd* | irix*)
*) pgac_lib=" -lcurses" ;; if test x"$pgac_lib" = x"" ; then
esac pgac_lib=" -lcurses"
fi ;;
esac esac
pgac_cv_check_readline="${pgac_rllib}${pgac_lib}" pgac_cv_check_readline="${pgac_rllib}${pgac_lib}"
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册