Using this ebuild gives wrong results: KEYWORDS=~x86 src_install() { touch ${D}file1 touch /file2 } >>> Emerging (1 of 1) test/test-1.0 to / * checking ebuild checksums ;-) ... [ ok ] * checking auxfile checksums ;-) ... [ ok ] * checking miscfile checksums ;-) ... [ ok ] >>> Unpacking source... >>> Source unpacked. >>> Compiling source in /var/tmp/portage/test-1.0 ... >>> Source compiled. >>> Test phase [none]: test/test-1.0 >>> Install test-1.0 into /var/tmp/portage/test-1.0/image/ category test ACCESS DENIED open_wr: /file2 touch: cannot touch `/file2': Permission denied >>> Completed installing test-1.0 into /var/tmp/portage/test-1.0/ima ge/ man: * checking 1 files for package collisions * spent 0.000995874404907 seconds checking for file collisions >>> Merging test/test-1.0 to / >>> /file1 >>> Safely unmerging already-installed instance... --- !mtime obj /file1 >>> Regenerating /etc/ld.so.cache... >>> Original instance of package unmerged safely. >>> Regenerating /etc/ld.so.cache... >>> test/test-1.0 merged. >>> No packages selected for removal by clean. >>> Auto-cleaning packages... >>> No outdated packages were found on your system. * GNU info directory index is up-to-date. Portage 2.1.2_pre1 (default-linux/x86/2006.0, gcc-4.1.1/vanilla, glibc-2.4-r3, 2.6.17.11 i686) ================================================================= System uname: 2.6.17.11 i686 AMD Duron(tm) Processor Gentoo Base System version 1.12.5 Last Sync: Unknown app-admin/eselect-compiler: 2.0.0_rc2-r1 dev-java/java-config: [Not Present] dev-lang/python: 2.5-r1 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.17 sys-devel/gcc-config: [Not Present] sys-devel/libtool: 1.5.22 virtual/os-headers: 2.6.17-r1 ACCEPT_KEYWORDS="x86 ~x86" AUTOCLEAN="yes" CBUILD="i686-pc-linux-gnu" CFLAGS="-march=athlon-tbird -O2 -pipe -fomit-frame-pointer -Wimplicit-function-declaration" CHOST="i686-pc-linux-gnu" CONFIG_PROTECT="/etc /lib/rcscripts/addons /usr/kde/3.5/env /usr/kde/3.5/share/config /usr/kde/3.5/shutdown /usr/share/X11/xkb" CONFIG_PROTECT_MASK="/etc/env.d /etc/eselect/compiler /etc/gconf /etc/init.d /etc/revdep-rebuild /etc/terminfo /etc/texmf/web2c" CXXFLAGS="-march=athlon-tbird -O2 -pipe -fomit-frame-pointer" DISTDIR="/var/dist" FEATURES="assume-digests autoconfig autopatch collision-protect cvs distlocks metadata-transfer notitles parallel-fetch sandbox sfperms sign strict stricter test userpriv usersandbox" GENTOO_MIRRORS="http://ftp.easynet.nl/mirror/gentoo" LANG="en_GB.UTF-8" LDFLAGS="-Xlinker --as-needed" LINGUAS="en_GB en" PKGDIR="/var/pkg" 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/cvs/gentoo-x86" PORTDIR_OVERLAY="/etc/portage/overlay /etc/portage/overlay/enlightenment" SYNC="rsync://rsync.nl.gentoo.org/gentoo-portage" USE="x86 3dnow 3dnowext X alsa bindist cairo cdparanoia cjk crypt cups debugger divx dri dvd dvdr dvdread elibc_glibc flac ftp gcc-libffi gif gmedia gpgme graphviz gtk iconv idn immqt input_devices_keyboard input_devices_mouse ipv6 ithreads jpeg kde kdeenablefinal kdehiddenvisibility kdrive kernel_linux linguas_en linguas_en_GB lynxkeymap mbox mmx mmxext mozdevelop mudflap ncurses nethack nls no-old-linux noamazon nocxx nptl nptlonly nsplugin offensive ogg opengl pango paste64 pcre pdf perl png ppds qt3 quicktime readline real reiser4 rtc ssl svg tcl test theora truetype ucs2 unicode userland_GNU video_cards_radeon vim-pager vorbis wmp xim xine xorg" Unset: CTARGET, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LC_ALL, MAKEOPTS, PORTAGE_RSYNC_EXTRA_OPTS
The sandbox program is supposed to print the "ACCESS VIOLATION SUMMARY" and exit with nonzero status when a sandbox violation occurs. I have sandbox-1.2.18.1 and it works for me.
fails for me as well ...
(and by fails i mean sandbox/emerge behaves correctly)
I tried to rebuild sandbox a couple of times, but oddly, I can't get it to fail for me anymore, even when rebuilding with the exact same settings I originally used. Maybe it was a bug in gcc that's fixed now? Otherwise, I have no idea...