Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 474536 - Bootstrap failure on Open Indiana 151a7: __redirect_alloc_fd in portage's helper-functions.sh fails
Summary: Bootstrap failure on Open Indiana 151a7: __redirect_alloc_fd in portage's hel...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo/Alt
Classification: Unclassified
Component: Prefix Support (show other bugs)
Hardware: All Solaris
: Normal normal (vote)
Assignee: Gentoo Prefix
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: 478446
  Show dependency tree
 
Reported: 2013-06-23 21:29 UTC by Richard Yao (RETIRED)
Modified: 2013-07-28 20:44 UTC (History)
1 user (show)

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


Attachments
log from sed that shows __redirect_alloc_fd failure (build.log,46.22 KB, text/x-log)
2013-06-23 21:29 UTC, Richard Yao (RETIRED)
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Richard Yao (RETIRED) gentoo-dev 2013-06-23 21:29:41 UTC
Created attachment 351772 [details]
log from sed that shows __redirect_alloc_fd failure

If file descriptor 1023 is open on SVR4, then /dev/fd/{0..1023} will exist, regardless of whether or not any other file descriptors are open. The fallback in __redirect_alloc_fd assumes that the existence of /dev/fd/* implies an open file descriptor. This causes a build failure on Open Indiana 151a7 because it ships with bash 4.0.28, file descriptor 1023 is somehow opened during the bootstrap and __redirect_alloc_fd cannot find a free file descriptor. Oracle's documentation suggests that you should check for free file descriptors by opening them and checking for an error:

http://docs.oracle.com/cd/E26502_01/html/E29042/fd-4.html

Unfortunately, I cannot figure out how to do this from the shell.
Comment 3 Fabian Groffen gentoo-dev 2013-06-29 05:51:58 UTC
this is in 2.2.01.22097, thanks!