Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 347321 - python-2.7.1 fails to install (cp: not writing through dangling symlink)
Summary: python-2.7.1 fails to install (cp: not writing through dangling symlink)
Status: RESOLVED FIXED
Alias: None
Product: Gentoo/Alt
Classification: Unclassified
Component: Prefix Support (show other bugs)
Hardware: All Linux
: High normal (vote)
Assignee: Gentoo Prefix
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-11-30 18:06 UTC by Sven Schwyn (svoop)
Modified: 2010-12-04 18:20 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 Sven Schwyn (svoop) 2010-11-30 18:06:43 UTC
make DESTDIR=/Gentoo/var/tmp/portage/dev-lang/python-2.7.1/image/ maninstall 
/Gentoo/usr/bin/install -c -m 644 ./Misc/python.man \
	/Gentoo/var/tmp/portage/dev-lang/python-2.7.1/image//Gentoo/usr/lib/Python.framework/Versions/2.7/share/man/man1/python2.7.1
cp: not writing through dangling symlink `./2to3'
 * ERROR: dev-lang/python-2.7.1 failed:
 *   (no error message)
 * 
 * Call stack:
 *     ebuild.sh, line  62:  Called src_install
 *   environment, line 5561:  Called die
 * The specific snippet of code:
 *               cp "${D}${fwdir}"/Versions/${SLOT}/bin/${f} . || die;


Reproducible: Always




Portage 2.2.01.17168-prefix (prefix/darwin/macos/10.5/x86, gcc-4.2.1, unavailable, 10.5.0 i386)
=================================================================
                        System Settings
=================================================================
System uname: Darwin-10.5.0-i386-32bit
Timestamp of tree: Tue, 30 Nov 2010 13:42:55 +0000
distcc 3.1-toolwhip.1 i386-apple-darwin10.0 [disabled]
app-shells/bash:     4.1_p7
dev-lang/python:     2.6.5-r2
dev-util/cmake:      2.8.1
sys-devel/autoconf:  2.68
sys-devel/automake:  1.10.3, 1.11.1
sys-devel/gcc-config: 1.4.1-r00.2
sys-devel/libtool:   2.4
sys-devel/make:      3.82
Repositories: gentoo_prefix bitcetera-prefix local
ACCEPT_KEYWORDS="~x86-macos"
ACCEPT_LICENSE="* -@EULA"
CBUILD="i686-apple-darwin9"
CFLAGS="-O2 -pipe -march=nocona"
CHOST="i686-apple-darwin9"
CONFIG_PROTECT="/etc"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/env.d /etc/eselect/postgresql /etc/gconf /etc/portage /etc/revdep-rebuild /etc/terminfo"
CXXFLAGS="-O2 -pipe -march=nocona"
DISTDIR="/Gentoo/usr/portage/distfiles"
FEATURES="assume-digests binpkg-logs collision-protect distlocks fixlafiles fixpackages news nostrip parallel-fetch preserve-libs protect-owned sfperms strict unknown-features-warn unmerge-logs unmerge-orphans userfetch"
GENTOO_MIRRORS="http://distfiles.gentoo.org"
LDFLAGS="-Wl,-dead_strip_dylibs"
PKGDIR="/Gentoo/usr/portage/packages"
PORTAGE_CONFIGROOT="/Gentoo/"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --stats --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages"
PORTAGE_TMPDIR="/Gentoo/var/tmp"
PORTDIR="/Gentoo/usr/portage"
PORTDIR_OVERLAY="/Gentoo/var/lib/layman/bitcetera-prefix /Gentoo/usr/local/portage/local"
SYNC="rsync://rsync.prefix.freens.org/gentoo-portage-prefix"
USE="aqua coreaudio cracklib cxx mmx mmxext modules ncurses nls objc objc++ prefix readline sse sse2 ssl unicode x86-macos zlib" APACHE2_MODULES="actions alias auth_basic authn_alias authn_anon authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache cgi cgid dav dav_fs dav_lock deflate dir disk_cache env expires ext_filter file_cache filter headers include info log_config logio mem_cache mime mime_magic negotiation rewrite setenvif speling status unique_id userdir usertrack vhost_alias" COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog" ELIBC="Darwin" GPSD_PROTOCOLS="ashtech aivdm earthmate evermore fv18 garmin garmintxt gpsclock itrax mtk3301 nmea ntrip navcom oceanserver oldstyle oncore rtcm104v2 rtcm104v3 sirf superstar2 timing tsip tripmate tnt ubx" INPUT_DEVICES="keyboard mouse" KERNEL="Darwin" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" PHP_TARGETS="php5-2" RUBY_TARGETS="ruby19" USERLAND="GNU" XTABLES_ADDONS="quota2 psd pknock lscan length2 ipv4options ipset ipp2p iface geoip fuzzy condition tee tarpit sysrq steal rawnat logmark ipmark dhcpmac delude chaos account" 
Unset:  CPPFLAGS, CTARGET, EMERGE_DEFAULT_OPTS, FFLAGS, INSTALL_MASK, LANG, LC_ALL, LINGUAS, MAKEOPTS, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS
Comment 1 Fabian Groffen gentoo-dev 2010-12-01 18:44:00 UTC
can you show me

 ls -la "/Gentoo/var/tmp/portage/dev-lang/python-2.7.1/image//Gentoo/usr/lib/Python.framework"/Versions/2.7/bin/2to3
Comment 2 Sven Schwyn (svoop) 2010-12-02 08:24:42 UTC
$ "/Gentoo/var/tmp/portage/dev-lang/python-2.7.1/image//Gentoo/usr/lib/Python.framework"/Versions/2.7/bin/2to3
bash: /Gentoo/var/tmp/portage/dev-lang/python-2.7.1/image//Gentoo/usr/lib/Python.framework/Versions/2.7/bin/2to3: /Gentoo/usr/lib/Python.framework/Versions/2.7/bin/python2.7: bad interpreter: No such file or directory

$ cat "/Gentoo/var/tmp/portage/dev-lang/python-2.7.1/image//Gentoo/usr/lib/Python.framework"/Versions/2.7/bin/2to3
#!/Gentoo/usr/lib/Python.framework/Versions/2.7/bin/python2.7
import sys
from lib2to3.main import main

sys.exit(main("lib2to3.fixes"))

$ ls /Gentoo/usr/bin/python*
/Gentoo/usr/bin/python             /Gentoo/usr/bin/python2
/Gentoo/usr/bin/python-config      /Gentoo/usr/bin/python2.6
/Gentoo/usr/bin/python-config-2.6  /Gentoo/usr/bin/pythonw
/Gentoo/usr/bin/python-wrapper     /Gentoo/usr/bin/pythonw2.6

$ eselect python list
Available Python interpreters:
  [1]   python2.6 *
Comment 3 Fabian Groffen gentoo-dev 2010-12-02 09:17:57 UTC
hmmm, this suggests that it's not a dangling symlink at all... ¿???
Comment 4 Fabian Groffen gentoo-dev 2010-12-03 13:19:11 UTC
I cannot reproduce this on powerpc-apple-darwin8 and powerpc-apple-darwin9
Comment 5 Sven Schwyn (svoop) 2010-12-03 20:55:45 UTC
I've tried again after cleaning /var/tmp/portage and the distfiles - same issue. Can somebody on i386-apple-darwin10.0 confirm it?
Comment 6 MATSUI Tetsushi 2010-12-04 02:22:10 UTC
I also have the same problem on x86-macos.
Comment 7 MATSUI Tetsushi 2010-12-04 04:18:22 UTC
By 'ls -l' in /Users/tetsushi/Gentoo/var/tmp/portage/dev-lang/python-2.7.1/image/Users/tetsushi/Gentoo/usr/bin, I get after the error:

lrwxr-xr-x 1 tetsushi staff   69 12  4 12:55 2to3 -> /Users/tetsushi/Gentoo/usr/lib/Python.framework/Versions/2.7/bin/2to3
lrwxr-xr-x 1 tetsushi staff   73 12  4 12:55 2to3-2.7 -> /Users/tetsushi/Gentoo/usr/lib/Python.framework/Versions/2.7/bin/2to3-2.7
-rwxr-xr-x 1 tetsushi staff 8852 12  4 12:55 python2.7
lrwxr-xr-x 1 tetsushi staff   51 12  4 12:55 pythonw2.7 -> ../lib/Python.framework/Versions/2.7/bin/pythonw2.7
lrwxr-xr-x 1 tetsushi staff   73 12  4 12:55 smtpd.py -> /Users/tetsushi/Gentoo/usr/lib/Python.framework/Versions/2.7/bin/smtpd.py

These point outside the image. We have to remove them before attempting cp, or stop creating them.
Comment 8 Fabian Groffen gentoo-dev 2010-12-04 11:12:22 UTC
Thanks MATSUI Tetsushi!

I went for removing whatever's already there, since our own copies are safer, since we modify them afterwards.

This also explains why on some machines I saw the shebang actually having a framework path.
Comment 9 Sven Schwyn (svoop) 2010-12-04 18:20:32 UTC
Thanks for the fix, guys!