Portage Errors: touch: No such file or directory

After updating coreutils you may encounter a problem using touch. This problem often manifests itself as a loop while trying to update other packages:

 *   Touching gcc/cstamp-h.in
 *   touch: setting times of `gcc/cstamp-h.in': No such file or directory
 *   make: *** [gcc/cstamp-h.in] Error 1
 *   Touching gcc/cstamp-h.in
 *   touch: setting times of `gcc/cstamp-h.in': No such file or directory
 *   make: *** [gcc/cstamp-h.in] Error 1
...

or a one-off event that breaks the merge:

touch: setting times of `config.h.in': No such file or directory
make: *** [config.h.in] Error 1
emake failed
 * ERROR: sys-process/psmisc-22.12 failed (compile phase):
 *   (no error message)
 * 
 * Call stack:
 *     ebuild.sh, line  56:  Called src_compile
 *   environment, line 2663:  Called die
 * The specific snippet of code:
 *       emake || die
 * 
 * If you need support, post the output of 'emerge --info =sys-process/psmisc-22.12',
 * the complete build log and the output of 'emerge -pqv =sys-process/psmisc-22.12'.
 * The complete build log is located at '/var/tmp/portage/sys-process/psmisc-22.12/temp/build.log'.
 * The ebuild environment file is located at '/var/tmp/portage/sys-process/psmisc-22.12/temp/environment'.
 * S: '/var/tmp/portage/sys-process/psmisc-22.12/work/psmisc-22.12'

>>> Failed to emerge sys-process/psmisc-22.12,

This problem occurs on systems running kernels older than 2.6.22, where futimesat was introduced. This pops up a lot on my older Gentoo VMs for obvious reasons (wouldn’t it be nice if we could have an up-to-date stable xen-sources package one day?).

You have four options:

Upgrade your kernel – this is the ideal solution but in an ideal world we all live forever and make too much money.

Disable sandbox – sandbox is intended to soften poorly written scripts. simply add -sandbox to your FEATURES variable. Not a big fan of this solution.

Replace touch with busybox’s implementation – this is a neat trick but I have encountered problems using bb’s touch in place of coreutils and the next time you update the symlink may get wiped out.

# rm /bin/touch && ln -s /bin/bb /bin/touch

Mask versions of coreutils newer than 8.5 – this is the ideologically correct way to take care of things if upgrading the kernel is not in your cards today.

# echo ">=sys-apps/coreutils-8.6" >> /etc/portage/package.mask

It’s important that you remember to remove the mask once you do. Funnily enough, if you have already installed coreutils-8.6+ emerging 8.5 will fail due to the broken touch, in this case you may wish to temporarily use one of the other solutions to get it installed:

checking for struct utmpx.ut_exit.e_termination... yes
checking for struct utmp.ut_exit.e_termination... yes
checking for stdlib.h... (cached) yes
checking for GNU libc compatible realloc... yes
checking for working re_compile_pattern... yes
checking whether rename honors trailing slash on destination... touch: setting times of `conftest.f': No such file or directory
configure: error: cannot create temporary files

!!! Please attach the following file when seeking support:
!!! /var/tmp/portage/sys-apps/coreutils-8.5/work/coreutils-8.5/config.log
 * ERROR: sys-apps/coreutils-8.5 failed (compile phase):
 *   econf failed
 * 
 * Call stack:
 *     ebuild.sh, line   56:  Called src_compile
 *   environment, line 2495:  Called econf '--with-packager=Gentoo' '--with-packager-version=8.5 (p1)' '--with-packager-bug-reports=http://bugs.gentoo.org/' '--enable-install-program=arch' '--enable-no-install-program=groups,hostname,kill,su,uptime' '--enable-largefile' '--disable-libcap' '--enable-nls' '--enable-acl' '--disable-xattr' '--without-gmp'
 *     ebuild.sh, line  557:  Called die
 * The specific snippet of code:
 *                      die "econf failed"
 * 
 * If you need support, post the output of 'emerge --info =sys-apps/coreutils-8.5',
 * the complete build log and the output of 'emerge -pqv =sys-apps/coreutils-8.5'.
 * The complete build log is located at '/var/tmp/portage/sys-apps/coreutils-8.5/temp/build.log'.
 * The ebuild environment file is located at '/var/tmp/portage/sys-apps/coreutils-8.5/temp/environment'.
 * S: '/var/tmp/portage/sys-apps/coreutils-8.5/work/coreutils-8.5'

>>> Failed to emerge sys-apps/coreutils-8.5

Portage Errors: app-emulation/xen-tools NOT merged due to file collisions

If you are updating your Xen installation from 3.x to 4.x you may encounter something like this:

>>> Installing (1 of 3) app-emulation/xen-tools-4.1.0-r1
 * This package will overwrite one or more files that may belong to other
 * packages (see list below). You can use a command such as `portageq
 * owners / ` to identify the installed package that owns a
 * file. If portageq reports that only one package owns a file then do
 * NOT file a bug report. A bug report is only useful if it identifies at
 * least two or more packages that are known to install the same file(s).
 * If a collision occurs and you can not explain where the file came from
 * then you should simply ignore the collision since there is not enough
 * information to determine if a real problem exists. Please do NOT file
 * a bug report at http://bugs.gentoo.org unless you report exactly which
 * two packages install the same file(s). Once again, please do NOT file
 * a bug report unless you have completely understood the above message.
 * 
 * Detected file collision(s):
 * 
 *      /usr/include/xen/COPYING
 *      /usr/include/xen/arch-ia64.h
 *      /usr/include/xen/arch-x86_32.h
 *      /usr/include/xen/arch-x86_64.h
 *      /usr/include/xen/callback.h
 *      /usr/include/xen/dom0_ops.h
 *      /usr/include/xen/domctl.h
 *      /usr/include/xen/elfnote.h
 *      /usr/include/xen/event_channel.h
 *      /usr/include/xen/features.h
 *      /usr/include/xen/grant_table.h
 *      /usr/include/xen/kexec.h
 *      /usr/include/xen/memory.h
 *      /usr/include/xen/nmi.h
 *      /usr/include/xen/physdev.h
 *      /usr/include/xen/platform.h
 *      /usr/include/xen/sched.h
 *      /usr/include/xen/sysctl.h
 *      /usr/include/xen/trace.h
 *      /usr/include/xen/vcpu.h
 *      /usr/include/xen/version.h
 *      /usr/include/xen/xen-compat.h
 *      /usr/include/xen/xen.h
 *      /usr/include/xen/xencomm.h
 *      /usr/include/xen/xenoprof.h
 *      /usr/include/xen/arch-x86/xen-x86_32.h
 *      /usr/include/xen/arch-x86/xen-x86_64.h
 *      /usr/include/xen/arch-x86/xen.h
 *      /usr/include/xen/foreign/ia64.h
 *      /usr/include/xen/foreign/x86_32.h
 *      /usr/include/xen/foreign/x86_64.h
 *      /usr/include/xen/hvm/e820.h
 *      /usr/include/xen/hvm/hvm_info_table.h
 *      /usr/include/xen/hvm/hvm_op.h
 *      /usr/include/xen/hvm/ioreq.h
 *      /usr/include/xen/hvm/params.h
 *      /usr/include/xen/hvm/save.h
 *      /usr/include/xen/io/blkif.h
 *      /usr/include/xen/io/console.h
 *      /usr/include/xen/io/fbif.h
 *      /usr/include/xen/io/kbdif.h
 *      /usr/include/xen/io/netif.h
 *      /usr/include/xen/io/pciif.h
 *      /usr/include/xen/io/protocols.h
 *      /usr/include/xen/io/ring.h
 *      /usr/include/xen/io/tpmif.h
 *      /usr/include/xen/io/xenbus.h
 *      /usr/include/xen/io/xs_wire.h
 *      /usr/include/xen/xsm/acm.h
 *      /usr/include/xen/xsm/acm_ops.h
 *      /usr/include/xen/xsm/flask_op.h
 * 
 * Searching all installed packages for file collisions...
 * 
 * Press Ctrl-C to Stop
 * 
 * app-emulation/xen-3.2.1
 *      /usr/include/xen/COPYING
 *      /usr/include/xen/arch-ia64.h
 *      /usr/include/xen/arch-x86_32.h
 *      /usr/include/xen/arch-x86_64.h
 *      /usr/include/xen/callback.h
 *      /usr/include/xen/dom0_ops.h
 *      /usr/include/xen/domctl.h
 *      /usr/include/xen/elfnote.h
 *      /usr/include/xen/event_channel.h
 *      /usr/include/xen/features.h
 *      /usr/include/xen/grant_table.h
 *      /usr/include/xen/kexec.h
 *      /usr/include/xen/memory.h
 *      /usr/include/xen/nmi.h
 *      /usr/include/xen/physdev.h
 *      /usr/include/xen/platform.h
 *      /usr/include/xen/sched.h
 *      /usr/include/xen/sysctl.h
 *      /usr/include/xen/trace.h
 *      /usr/include/xen/vcpu.h
 * 
 * Package 'app-emulation/xen-tools-4.1.0-r1' NOT merged due to file
 * collisions. If necessary, refer to your elog messages for the whole
 * content of the above message.

>>> Failed to install app-emulation/xen-tools-4.1.0-r1

This problem arises because the new version of xen-tools takes over installing some of the files the old version of xen used to:

# portageq owners / /usr/include/xen/COPYING
app-emulation/xen-3.2.1
        /usr/include/xen/COPYING

To fix, unmerge the old version of xen then emerge –update xen to install the new versions of the xen-tools and xen packages:

# emerge --unmerge xen
# emerge --update --deep --newuse xen

Portage Errors: app-emulation/xen-tools check_python FAILED

You may run into something like this while updating or installing your Xen platform:

>>> Emerging (1 of 3) app-emulation/xen-tools-4.1.0-r1
* xen-4.1.0.tar.gz RMD160 SHA1 SHA256 size ;-) ...                                   [ ok ]
* Package:    app-emulation/xen-tools-4.1.0-r1
* Repository: gentoo
* Maintainer: xen@gentoo.org
* USE:        acm elibc_glibc flask kernel_linux pygrub userland_GNU x86
* FEATURES:   sandbox
>>> Unpacking source...
>>> Unpacking xen-4.1.0.tar.gz to /var/tmp/portage/app-emulation/xen-tools-4.1.0-r1/work
>>> Source unpacked in /var/tmp/portage/app-emulation/xen-tools-4.1.0-r1/work
>>> Preparing source in /var/tmp/portage/app-emulation/xen-tools-4.1.0-r1/work/xen-4.1.0 ...
* Applying xen-tools-3.4.0-network-bridge-broadcast.patch ...                        [ ok ]
* Applying xen-tools-3.3.0-nostrip.patch ...                                         [ ok ]
>>> Source prepared.
>>> Configuring source in /var/tmp/portage/app-emulation/xen-tools-4.1.0-r1/work/xen-4.1.0 ...
>>> Source configured.
>>> Compiling source in /var/tmp/portage/app-emulation/xen-tools-4.1.0-r1/work/xen-4.1.0 ...
make -j2 -C tools
make: Entering directory `/var/tmp/portage/app-emulation/xen-tools-4.1.0-r1/work/xen-4.1.0/tools'
make[1]: Entering directory `/var/tmp/portage/app-emulation/xen-tools-4.1.0-r1/work/xen-4.1.0/tools'
make -C check all
make[2]: Entering directory `/var/tmp/portage/app-emulation/xen-tools-4.1.0-r1/work/xen-4.1.0/tools/check'
PYTHON=python LIBXENAPI_BINDINGS=n ACM_SECURITY=y ./chk build
Xen CHECK-BUILD  Mon Apr 11 16:19:03 EDT 2011
Checking check_crypto_lib: OK
Checking check_curl: unused, OK
Checking check_openssl_devel: OK
Checking check_python:
*** check_python FAILED: need python version >= 2.2
Checking check_python_devel: OK
Checking check_uuid_devel: OK
Checking check_xgettext: OK
Checking check_xml2: OK
Checking check_zlib_devel: OK
Checking check_zlib_lib: OK
make[2]: *** [check-build] Error 1
make[2]: Leaving directory `/var/tmp/portage/app-emulation/xen-tools-4.1.0-r1/work/xen-4.1.0/tools/check'
make[1]: *** [subdir-all-check] Error 2
make[1]: Leaving directory `/var/tmp/portage/app-emulation/xen-tools-4.1.0-r1/work/xen-4.1.0/tools'
make: *** [subdirs-all] Error 2
make: Leaving directory `/var/tmp/portage/app-emulation/xen-tools-4.1.0-r1/work/xen-4.1.0/tools'
emake failed
* ERROR: app-emulation/xen-tools-4.1.0-r1 failed (compile phase):
*   compile failed
*
* Call stack:
*     ebuild.sh, line  56:  Called src_compile
*   environment, line 4879:  Called die
* The specific snippet of code:
*       emake -C tools ${myopt} || die "compile failed";
*
* If you need support, post the output of 'emerge --info =app-emulation/xen-tools-4.1.0-r1',
* the complete build log and the output of 'emerge -pqv =app-emulation/xen-tools-4.1.0-r1'.
* The complete build log is located at '/var/tmp/portage/app-emulation/xen-tools-4.1.0-r1/temp/build.log'.
* The ebuild environment file is located at '/var/tmp/portage/app-emulation/xen-tools-4.1.0-r1/temp/environment'.
* S: '/var/tmp/portage/app-emulation/xen-tools-4.1.0-r1/work/xen-4.1.0'
 
>>> Failed to emerge app-emulation/xen-tools-4.1.0-r1, Log file:
 
>>>  '/var/tmp/portage/app-emulation/xen-tools-4.1.0-r1/temp/build.log'
 
* Messages for package app-emulation/xen-tools-4.1.0-r1:
 
* ERROR: app-emulation/xen-tools-4.1.0-r1 failed (compile phase):
*   compile failed
*
* Call stack:
*     ebuild.sh, line  56:  Called src_compile
*   environment, line 4879:  Called die
* The specific snippet of code:
*       emake -C tools ${myopt} || die "compile failed";
*
* If you need support, post the output of 'emerge --info =app-emulation/xen-tools-4.1.0-r1',
* the complete build log and the output of 'emerge -pqv =app-emulation/xen-tools-4.1.0-r1'.
* The complete build log is located at '/var/tmp/portage/app-emulation/xen-tools-4.1.0-r1/temp/build.log'.
* The ebuild environment file is located at '/var/tmp/portage/app-emulation/xen-tools-4.1.0-r1/temp/environment'.
* S: '/var/tmp/portage/app-emulation/xen-tools-4.1.0-r1/work/xen-4.1.0'

The problem is due to Xen’s check-build not recognizing your Python 3x installation as “greater than or equal to 2.2.” You can resolve this by temporarily switching your Python profile:

# eselect python list
Available Python interpreters:
  [1]   python2.4
  [2]   python2.5
  [3]   python2.6
  [4]   python3.1 *
# eselect python set 3

It might be advisable to run python-updater and any other updates you have before compiling xen-tools with python2x; once you switch back to the latest version of python xen-tools will be picked up by python-updater and fail to compile.

For more information please see my bug report at http://bugs.gentoo.org/show_bug.cgi?id=363299

Return top
foxpa.ws
Online Marketing Toplist
Internet
Technology Blogs - Blog Rankings

Internet Blogs - BlogCatalog Blog Directory

Bad Karma Networks

Please Donate!


Made in Canada  •  There's a fox in the Gibson!  •  2010-12