Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 289247 - sys-libs/ncurses-5.7 build fails on x86_64-apple-darwin9 while bootstrapping gentoo/prefix
Summary: sys-libs/ncurses-5.7 build fails on x86_64-apple-darwin9 while bootstrapping ...
Status: RESOLVED NEEDINFO
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Core system (show other bugs)
Hardware: x86 OS X
: High blocker (vote)
Assignee: Gentoo Prefix
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2009-10-15 20:53 UTC by Tim Spriggs
Modified: 2011-04-06 17:45 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 Tim Spriggs 2009-10-15 20:53:16 UTC
While bootstrapping prefix on OSX Leopard, bash requires ncurses and then the ncurses build fails. I noticed that the ncurses build is trying to link against libs in /usr/lib before libs in /prefix-path/usr/lib

If I modify the ebuild/do_compile() function to add LDFLAGS="-L${EPREFIX}/usr/$(get_libdir)" then the emerge of ncurses completes successfully.

Reproducible: Always

Steps to Reproduce:
1. Follow prefix installation guide for OSX on Leopard
2. while building bash, ncurses is pulled in as a dependency
3. watch the ebuild die a painful horrid death as it links to stuff in /usr/lib

Actual Results:  
gcc -m64 ../obj_s/tset.o -Wl,-search_paths_first -L/usr/lib -L/lib -Wl,-search_paths_first -I../progs -I/apps/dist/x86_64-apple-darwin9/var/tmp/portage/sys-libs/ncurses-5.7/work/ncurses-5.7/progs -DHAVE_CONFIG_H -I/apps/dist/x86_64-apple-darwin9/var/tmp/portage/sys-libs/ncurses-5.7/work/ncurses-5.7/progs/../include -I. -I../include -I/usr/include -U_XOPEN_SOURCE -D_XOPEN_SOURCE=500 -DSIGWINCH=28 -DXTSTRINGDEFINES -DNDEBUG -I/apps/dist/x86_64-apple-darwin9/usr/include -L/apps/dist/x86_64-apple-darwin9/usr/lib  --param max-inline-insns-single=1200  -W -Wall -Wbad-function-cast -Wcast-align -Wcast-qual -Wmissing-declarations -Wmissing-prototypes -Wnested-externs -Wpointer-arith -Wshadow -Wstrict-prototypes -Wundef -Wwrite-strings -Wdeclaration-after-statement -Wextra -Wno-unknown-pragmas -Wswitch-enum -dynamic  -L../lib -lncurses    -o tset
Undefined symbols:
  "__nc_is_abs_path", referenced from:
      _get_termcap_entry in tset.o
ld: symbol(s) not found
collect2: ld returned 1 exit status
make[2]: *** [tset] Error 1
make[2]: Leaving directory `/apps/dist/x86_64-apple-darwin9/var/tmp/portage/sys-libs/ncurses-5.7/work/narrowc/progs'
make[1]: *** [all] Error 2
make[1]: Leaving directory `/apps/dist/x86_64-apple-darwin9/var/tmp/portage/sys-libs/ncurses-5.7/work/narrowc'
 * ERROR: sys-libs/ncurses-5.7 failed:
 *   make failed
 *
 * Call stack:
 *               ebuild.sh:  51: <call src_compile>
 *             environment:2703: <call do_compile '--without-ada'>
 *             environment: 734:     emake || die "make failed"
 *
 * If you need support, post the topmost build error, and the call stack if relevant.

>>> Failed to emerge sys-libs/ncurses-5.7, Log file:

>>>  '/apps/dist/x86_64-apple-darwin9/var/tmp/portage/sys-libs/ncurses-5.7/temp/build.log'

 * Messages for package sys-libs/ncurses-5.7:

 * ERROR: sys-libs/ncurses-5.7 failed:
 *   make failed
 * 
 * Call stack:
 *               ebuild.sh:  51: <call src_compile>
 *             environment:2703: <call do_compile '--without-ada'>
 *             environment: 734:     emake || die "make failed"
 * 
 * If you need support, post the topmost build error, and the call stack if relevant.


Expected Results:  
a clean build against /prefix-path-to/usr/lib

would be happy to contribute extra info/test patches.
Comment 1 Fabian Groffen gentoo-dev 2009-10-29 21:19:41 UTC
This feels like an error somewhere, as -Wl,-search_paths_first should be followed by the offset libdirs, not the host libdirs.  Just like EPREFIX was unset at a given point during the bootstrap.
Comment 2 Michael Hammer (RETIRED) gentoo-dev 2010-01-16 20:53:03 UTC
I can confirm this bug. I did a fresh bootstrap on MacOS X. The next strange thing is, that sys-libs/ncurses-5.6-r2 compiles without problems.

g, mueli
Comment 3 Fabian Groffen gentoo-dev 2011-04-06 17:45:42 UTC
I can't reproduce this,  I need more info