Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 64928 - gftp configure doesn't detect and use -lutil correctly
Summary: gftp configure doesn't detect and use -lutil correctly
Status: RESOLVED NEEDINFO
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: x86 Linux
: Low normal (vote)
Assignee: Gentoo Linux Gnome Desktop Team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2004-09-21 21:28 UTC by Stephen Rust
Modified: 2005-05-03 18:42 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Stephen Rust 2004-09-21 21:28:58 UTC
When I try to emerge gftp (for several versions, including the latest 2.0.17), I get the following compile error:

../../lib/libgftp.a(pty.o)(.text+0x2d6): In function `gftp_exec_with_new_pty':
: undefined reference to `openpty'
../../lib/libgftp.a(pty.o)(.text+0x353): In function `gftp_exec_with_new_pty':
: undefined reference to `login_tty'

This happens for several of the directories.

Doing a 'man openpty' I found out this is included in the libutil library (-lutil).

Checking the configure.in in /var/tmp/portage/gftp-2.0.17/work/gftp-2.0.17, I notice that indeed HAVE_OPENPTY is one of the checks that are done, and indeed this should be including -lutil on the EXTRA_LIBS section, especially as the config.h lists HAVE_OPENPTY=1 set in the file.

Yet the -lutil is clearly not in the link line during compilation.  I added the line manually in the LDADD section of the Makefile simply to get it to compile, and that did fix the problem.  But this should be fixed more correctly through the automake/autoconf setup.

Note: configure.in lists above the OPENPTY check that this is needed for FreeBSD.  Apparently this is also needed for linux ;)  (or at least my linux)

Reproducible: Always
Steps to Reproduce:
1. emerge gftp
2.
3.

Actual Results:  
./../lib/libgftp.a(pty.o)(.text+0x2d6): In function `gftp_exec_with_new_pty':
: undefined reference to `openpty'
../../lib/libgftp.a(pty.o)(.text+0x353): In function `gftp_exec_with_new_pty':
: undefined reference to `login_tty'

Expected Results:  
Added -lutil to the EXTRA_LIBS line as part of HAVE_OPENPTY and compiled cleanly.

Portage 2.0.51_rc1 (default-x86-2004.0, gcc-3.4.1, glibc-2.3.4.20040808-r0,
2.6.7-gentoo-r9 i686)
=================================================================
System uname: 2.6.7-gentoo-r9 i686 Intel(R) Pentium(R) M processor 1300MHz
Gentoo Base System version 1.5.3
ccache version 2.3 [enabled]
Autoconf: sys-devel/autoconf-2.59-r4
Automake: sys-devel/automake-1.8.5-r1
Binutils: sys-devel/binutils-2.15.90.0.1.1-r3
Headers:  sys-kernel/linux26-headers-2.6.8.1
Libtools: sys-devel/libtool-1.5.2-r5
ACCEPT_KEYWORDS="x86 ~x86"
AUTOCLEAN="yes"
CFLAGS="-O2 -march=i686 -fomit-frame-pointer"
CHOST="i686-pc-linux-gnu"
COMPILER=""
CONFIG_PROTECT="/etc /usr/X11R6/lib/X11/xkb /usr/kde/2/share/config
/usr/kde/3.2/share/config
/usr/kde/3.3/share/config:/usr/kde/3.3/env:/usr/kde/3.3/shutdown
/usr/kde/3/share/config /usr/lib/mozilla/defaults/pref /usr/share/config
/var/qmail/control"
CONFIG_PROTECT_MASK="/etc/gconf /etc/terminfo /etc/env.d"
CXXFLAGS="-O2 -march=i686 -fomit-frame-pointer"
DISTDIR="/usr/portage/distfiles"
FEATURES="autoaddcvs ccache sandbox"
GENTOO_MIRRORS="http://gentoo.osuosl.org/
ftp://distro.ibiblio.org/pub/Linux/distributions/gentoo/
ftp://ftp.gtlib.cc.gatech.edu/pub/gentoo ftp://gentoo.mirrors.pair.com/
ftp://ftp-mirror.internap.com/pub/gentoo/"
MAKEOPTS="-j2"
PKGDIR="/usr/portage/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY=""
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="X alsa apm arts avi berkdb bitmap-fonts cdr crypt cups dvd encode esd
foomaticdb gdbm gif gnome gpm gstreamer gtk gtk2 imlib java jpeg libg++ libwww
mad mikmod motif mozilla mpeg ncurses nls nptl oggvorbis opengl oss pam pda
pdflib perl png python quicktime readline sdl slang spell ssl svga tcpd truetype
x86 xml2 xmms xprint xv zlib"
Comment 1 foser (RETIRED) gentoo-dev 2004-10-16 04:11:04 UTC
maybe you could patch it ? This is _not_ a blocker.
Comment 2 John N. Laliberte (RETIRED) gentoo-dev 2005-04-09 08:29:31 UTC
does this still happen for you with 2.0.18-r1 ?
Comment 3 John N. Laliberte (RETIRED) gentoo-dev 2005-05-03 18:42:43 UTC
closing, no response from reporter.