Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 153872 - chgrp from sys-apps/coreutils-6.4 fails symlink test
Summary: chgrp from sys-apps/coreutils-6.4 fails symlink test
Status: VERIFIED DUPLICATE of bug 147705
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Core system (show other bugs)
Hardware: All Linux
: High normal
Assignee: Gentoo's Team for Core System packages
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2006-11-02 15:43 UTC by Drake Wyrm
Modified: 2010-03-28 00:52 UTC (History)
0 users

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 Drake Wyrm 2006-11-02 15:43:47 UTC
It looks as though the updated chgrp fails to correctly handle symlinks when given the -h command-line option. Even if the symlink group cannot be changed, chgrp -h should _do_nothing_, rather than change the group of the target.

When compiled as:

[ebuild     U ] sys-apps/coreutils-6.4 [5.94-r1] USE="acl nls (-selinux) -static (-build%)" 0 kB 

the tests exit with the following error message:

    1848 make  check-TESTS
    1849 make[3]: Entering directory `/var/tmp/portage/coreutils-6.4/work/coreutils-6.4/tests/chgrp'
    1850 ./no-x: /var/tmp/portage/coreutils-6.4/work/coreutils-6.4/tests/chgrp: not writable by user `nobody'
    1851 ./no-x: skipping this test
    1852 SKIP: no-x
    1853 PASS: posix-H
    1854 FAIL: basic
    1855 ./deref: skipping this test; your system doesn't support changing
    1856 the owner or group of a symbolic link.
    1857 SKIP: deref
    1858 PASS: recurse
    1859 ======================================
    1860 1 of 3 tests failed
    1861 (2 tests were not run)
    1862 Please report to bug-coreutils@gnu.org
    1863 ======================================
    1864 make[3]: *** [check-TESTS] Error 1
    1865 make[3]: Leaving directory `/var/tmp/portage/coreutils-6.4/work/coreutils-6.4/tests/chgrp'
    1866 make[2]: *** [check-am] Error 2
    1867 make[2]: Leaving directory `/var/tmp/portage/coreutils-6.4/work/coreutils-6.4/tests/chgrp'
    1868 make[1]: *** [check-recursive] Error 1
    1869 make[1]: Leaving directory `/var/tmp/portage/coreutils-6.4/work/coreutils-6.4/tests'
    1870 make: *** [check-recursive] Error 1

Specifically, tests/chgrp/basic fails during the portion:

      78 
      79 # This should not change the group of f.
      80 chgrp -h $g2 symlink
      81 test `stat --printf=%g f` = $g1 || fail=1
      82 test `stat --printf=%g symlink` = $g2 || fail=1
      83 

as indicated by the logs:

    2167 + chgrp -h 1 symlink
    2168 ++ stat --printf=%g f
    2169 + test 1 = 0
    2170 + fail=1
    2171 ++ stat --printf=%g symlink
    2172 + test 0 = 1
    2173 + fail=1

produced by compiling with the following options:

# env VERBOSE=yes MAKEOPTS='-j1 -w' emerge -1v coreutils

For the sake of completeness, here's my emerge --info:

Gentoo Base System version 1.12.5
Portage 2.1.1-r1 (default-linux/x86/2006.0, gcc-4.1.1, glibc-2.4-r3, 2.6.17-gentoo-r4 i686)
=================================================================
System uname: 2.6.17-gentoo-r4 i686 AMD Athlon(tm) processor
Last Sync: Thu, 02 Nov 2006 10:50:01 +0000
app-admin/eselect-compiler: [Not Present]
dev-java/java-config: 1.3.7, 2.0.30
dev-lang/python:     2.4.3-r4
dev-python/pycrypto: 2.0.1-r5
dev-util/ccache:     [Not Present]
dev-util/confcache:  [Not Present]
sys-apps/sandbox:    1.2.18.1
sys-devel/autoconf:  2.13, 2.60
sys-devel/automake:  1.4_p6, 1.5, 1.6.3, 1.7.9-r1, 1.8.5-r3, 1.9.6-r2
sys-devel/binutils:  2.16.1-r3
sys-devel/gcc-config: 1.3.13-r4
sys-devel/libtool:   1.5.22
virtual/os-headers:  2.6.17-r1
ACCEPT_KEYWORDS="x86"
AUTOCLEAN="yes"
CBUILD="i686-pc-linux-gnu"
CFLAGS="-march=athlon-tbird -O3 -pipe"
CHOST="i686-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/share/X11/xkb /usr/share/texmf/dvipdfm/config/ /usr/share/texmf/dvips/config/ /usr/share/texmf/tex/generic/config/ /usr/share/texmf/tex/platex/config/ /usr/share/texmf/xdvi/ /var/bind"
CONFIG_PROTECT_MASK="/etc/env.d /etc/env.d/java/ /etc/gconf /etc/java-config/vms/ /etc/revdep-rebuild /etc/terminfo"
CXXFLAGS="-march=athlon-tbird -O3 -pipe"
DISTDIR="/var/cache/distfiles"
FEATURES="autoconfig distlocks metadata-transfer parallel-fetch sandbox sfperms strict test"
GENTOO_MIRRORS="http://ftp.ucsb.edu/pub/mirrors/linux/gentoo/ http://gentoo.arcticnetwork.ca/ http://gentoo.mirrors.tera-byte.com/ http://cudlug.cudenver.edu/gentoo/ http://gentoo.mirrors.easynews.com/linux/gentoo/"
LINGUAS="en en_US"
MAKEOPTS="-j2 -w"
PKGDIR="/usr/share/packages/portage"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --delete-after --stats --timeout=180 --exclude='/distfiles' --exclude='/local' --exclude='/packages'"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/var/cache/portage/gentoo"
PORTDIR_OVERLAY="/var/cache/portage/boxed-main /usr/local/portage"
SYNC="rsync://rsync.namerica.gentoo.org/gentoo-portage"
USE="x86 3dnow X aalib acl alsa bash-completion berkdb bzip2 cjk crypt dga directfb doc elibc_glibc esd fbcon flac gdbm gif gpm gtk gtk2 imagemagick input_devices_evdev input_devices_jamstudio input_devices_keyboard input_devices_mouse ipv6 java jpeg kernel_linux ldap linguas_en linguas_en_US mad mbox mmx mpeg mysql ncurses nls nptl nptlonly offensive ogg oggvorbis opengl oss pam perl png python readline sdl skey slang ssl svga tcl tcltk tcpd tetex tiff tk truetype unicode userland_GNU video_cards_fbdev video_cards_r128 video_cards_vesa xv zlib"
Unset:  CTARGET, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LANG, LC_ALL, LDFLAGS, PORTAGE_RSYNC_EXTRA_OPTS
Comment 1 SpanKY gentoo-dev 2006-11-10 23:36:42 UTC

*** This bug has been marked as a duplicate of 147705 ***