VirtualBox packages are fetched correctly, but somehow wget gets lost following the download URL and aborts, so emerge does. (this was originally reported as a comment for bug 296369). As a workaround the file, already downloaded in the right directory has to be renamed by hand. So this problem isn't blocking. The same thing goes with all the packages from VitualBox, here's an example: [root@aemaeth:/usr/portage/distfiles]$ emerge -f virtualbox-bin Calculating dependencies * waiting for lock on /var/db/.pkg.portage_lockfile ... [ ok ] ... done! >>> Fetching (1 of 1) app-emulation/virtualbox-bin-3.1.2 * VirtualBox-3.1.2-56127-Linux_amd64.run RMD160 SHA1 SHA256 size ;-) ... [ ok ] >>> Downloading 'http://download.virtualbox.org/virtualbox/3.1.2/VirtualBoxSDK-3.1.2-56127.zip' --2010-01-30 10:08:28-- http://download.virtualbox.org/virtualbox/3.1.2/VirtualBoxSDK-3.1.2-56127.zip Resolving download.virtualbox.org... 72.5.124.114 Connecting to download.virtualbox.org|72.5.124.114|:80... connected. HTTP request sent, awaiting response... 302 Moved Temporarily Location: http://dlc-cdn.sun.com/virtualbox/3.1.2/VirtualBoxSDK-3.1.2-56127.zip [following] --2010-01-30 10:08:29-- http://dlc-cdn.sun.com/virtualbox/3.1.2/VirtualBoxSDK-3.1.2-56127.zip Resolving dlc-cdn.sun.com... 87.248.195.134 Connecting to dlc-cdn.sun.com|87.248.195.134|:80... connected. HTTP request sent, awaiting response... 302 Found Location: http://dlc-cdn-rd.sun.com/c1/virtualbox/3.1.2/VirtualBoxSDK-3.1.2-56127.zip?e=1264842809&h=b02aa98c306ae8c89c4af9ca0f3485ac [following] --2010-01-30 10:08:29-- http://dlc-cdn-rd.sun.com/c1/virtualbox/3.1.2/VirtualBoxSDK-3.1.2-56127.zip?e=1264842809&h=b02aa98c306ae8c89c4af9ca0f3485ac Resolving dlc-cdn-rd.sun.com... 87.248.218.147, 87.248.218.119 Connecting to dlc-cdn-rd.sun.com|87.248.218.147|:80... connected. HTTP request sent, awaiting response... 200 OK Length: 8240501 (7.9M) [application/zip] Saving to: “/usr/portage/distfiles/VirtualBoxSDK-3.1.2-56127.zip?e=1264842809&h=b02aa98c306ae8c89c4af9ca0f3485ac” 100%[======================================================================================================================================================================================================================================>] 8,240,501 839K/s in 9.6s 2010-01-30 10:08:38 (841 KB/s) - “/usr/portage/distfiles/VirtualBoxSDK-3.1.2-56127.zip?e=1264842809&h=b02aa98c306ae8c89c4af9ca0f3485ac” saved [8240501/8240501] --2010-01-30 10:08:38-- http://virtualboxsdk-3.1.2-56127.zip/ Resolving virtualboxsdk-3.1.2-56127.zip... failed: Unknown host. wget: unable to resolve host address “virtualboxsdk-3.1.2-56127.zip” FINISHED --2010-01-30 10:08:38-- Downloaded: 1 files, 7.9M in 9.6s (841 KB/s) !!! Couldn't download 'VirtualBoxSDK-3.1.2-56127.zip'. Aborting. * Fetch failed for 'app-emulation/virtualbox-bin-3.1.2' >>> Failed to emerge app-emulation/virtualbox-bin-3.1.2 [10:08] [root@aemaeth:/usr/portage/distfiles]$ ll VirtualBoxSDK-3.1.2* -rw-rw-r-- 1 portage portage 8240501 17 dic 14:48 VirtualBoxSDK-3.1.2-56127.zip?e=1264842809&h=b02aa98c306ae8c89c4af9ca0f3485ac [10:09] [root@aemaeth:/usr/portage/distfiles]$ emerge --version Portage 2.2_rc62 (default/linux/amd64/10.0/desktop, gcc-4.4.1, glibc-2.10.1-r1, 2.6.32-gentoo-r2 x86_64) [10:10] [root@aemaeth:/usr/portage/distfiles]$ mv 'VirtualBoxSDK-3.1.2-56127.zip?e=1264842809&h=b02aa98c306ae8c89c4af9ca0f3485ac' VirtualBoxSDK-3.1.2-56127.zip [10:10] [root@aemaeth:/usr/portage/distfiles]$ emerge -f virtualbox-bin Calculating dependencies ... done! >>> Fetching (1 of 1) app-emulation/virtualbox-bin-3.1.2 * VirtualBox-3.1.2-56127-Linux_amd64.run RMD160 SHA1 SHA256 size ;-) ... [ ok ] * VirtualBoxSDK-3.1.2-56127.zip RMD160 SHA1 SHA256 size ;-) ... [ ok ] * checking ebuild checksums ;-) ... [ ok ] * checking auxfile checksums ;-) ... [ ok ] * checking miscfile checksums ;-) ... Reproducible: Always Steps to Reproduce: 1.fetch VirtualBox packages via emerge 2. 3. Actual Results: emerge aborts Expected Results: emerge should find its file where it belongs to
It seems like a bug in wget, since the portage FETCHCOMMAND calls wget -O "${DISTDIR}/${FILE}" and therefore the saved filename should always be correct.
Actually, I just tested and the file name came out correctly: wget -O VirtualBoxSDK-3.1.2-56127.zip http://download.virtualbox.org/virtualbox/3.1.2/VirtualBoxSDK-3.1.2-56127.zip I think you need to update FETCHCOMMAND to use the wget -O option. See /usr/share/portage/config/make.conf.example for FETCHCOMMAND setting.
You are right, I modified FETCHCOMMAND and RESUMECOMMAND it probably was a leftover... #FETCHCOMMAND="/usr/bin/wget -t 1 -T 4 --passive-ftp \${URI} -P \${DISTDIR} \${FILE}" FETCHCOMMAND="/usr/bin/wget -t 1 -T 4 --passive-ftp -O \"\${DISTDIR}/\${FILE}\" \"\${URI}\"" #RESUMECOMMAND="/usr/bin/wget -c -t 1 --passive-ftp --limit-rate=200k \${URI} -P \${DISTDIR} \${FILE}" RESUMECOMMAND="/usr/bin/wget -c -t 1 --passive-ftp --limit-rate=200k -O \"\${DISTDIR}/\${FILE}\" \"\${URI}\"" "bug" fixed. Many thanks