Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 420581 - check-reqs.eclass should not check requirements for binpkg installation
Summary: check-reqs.eclass should not check requirements for binpkg installation
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Gentoo Quality Assurance Team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-06-10 20:36 UTC by August Hörandl
Modified: 2015-12-27 09:27 UTC (History)
4 users (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 August Hörandl 2012-06-10 20:36:40 UTC
I have a machine (laptop) with 2GB memory. Bulding pypy requires 4GB.

So i build on the desktop and use a binary package, but the ebuild tells me that i need 4GB to install the binary package.

Reproducible: Always

Steps to Reproduce:
1. emerge --usepkg y -v pypy
2. emerge fails

Actual Results:  
# emerge --usepkg y -v pypy

These are the packages that would be merged, in order:

Calculating dependencies... done!
[binary  N     ] dev-python/pypy-1.9  USE="bzip2 doc examples jit ncurses sqlite ssl xml -sandbox -shadowstack" 0 kB                                                                                          

Total: 1 package (1 new, 1 binary), Size of downloads: 0 kB

>>> Running pre-merge checks for dev-python/pypy-1.9
 * pypy-1.9.tbz2 size ;-) ...                                            [ ok ]
 * Checking for at least 4 gibibytes RAM ...                                                    [ !! ]
 * There is NOT at least 4 gibibytes RAM
 * 
 * Space constrains set in the ebuild were not met!
 * The build will most probably fail, you should enhance the space
 * as per failed tests.
 * 
 * ERROR: dev-python/pypy-1.9 failed (pretend phase):
 *   Build requirements not met!
 * 
 * Call stack:
 *     ebuild.sh, line   85:  Called pkg_pretend
 *   environment, line 2744:  Called check-reqs_pkg_pretend
 *   environment, line 1113:  Called check-reqs_pkg_setup
 *   environment, line 1120:  Called check-reqs_output
 *   environment, line 1107:  Called die
 * The specific snippet of code:
 *           [[ ${EBUILD_PHASE} == "pretend" && -z ${I_KNOW_WHAT_I_AM_DOING} ]] && die "Build requirements not met!";
 * 
 * If you need support, post the output of `emerge --info '=dev-python/pypy-1.9'`,
 * the complete build log and the output of `emerge -pqv '=dev-python/pypy-1.9'`.
 * The complete build log is located at '/mnt/data/portage/portage/dev-python/pypy-1.9/temp/build.log'.
 * The ebuild environment file is located at '/mnt/data/portage/portage/dev-python/pypy-1.9/temp/environment'.
 * Working directory: '/mnt/data/portage/portage/dev-python/pypy-1.9'
 * S: '/mnt/data/portage/portage/dev-python/pypy-1.9/work/pypy-1.9'


Expected Results:  
A build requirement of 4GB RAM shouldn't be checked when building from binary.

# emerge --info '=dev-python/pypy-1.9'
Portage 2.1.10.65 (default/linux/amd64/10.0/desktop/kde, gcc-4.6.3, glibc-2.15-r2, 3.4.0-gentoo x86_64)
=================================================================
                        System Settings
=================================================================
System uname: Linux-3.4.0-gentoo-x86_64-Mobile_AMD_Sempron-tm-_Processor_3800+-with-gentoo-2.1
Timestamp of tree: Fri, 08 Jun 2012 20:00:01 +0000
app-shells/bash:          4.2_p29
dev-java/java-config:     2.1.12
dev-lang/python:          2.7.3-r2, 3.2.3-r1
dev-util/cmake:           2.8.8-r2
dev-util/pkgconfig:       0.26
sys-apps/baselayout:      2.1-r1
sys-apps/openrc:          0.10.2
sys-apps/sandbox:         2.5
sys-devel/autoconf:       2.13, 2.69
sys-devel/automake:       1.6.3-r1, 1.9.6-r3, 1.10.3, 1.11.5, 1.12.1
sys-devel/binutils:       2.22-r1
sys-devel/gcc:            4.5.3-r2, 4.6.3
sys-devel/gcc-config:     1.7.2
sys-devel/libtool:        2.4.2
sys-devel/make:           3.82-r3
sys-kernel/linux-headers: 3.4 (virtual/os-headers)
sys-libs/glibc:           2.15-r2
Repositories: gentoo sunrise local_overlay
ACCEPT_KEYWORDS="amd64 ~amd64"
ACCEPT_LICENSE="* -@EULA PUEL dlj-1.1 IBM-J1.5 skype-eula cadsoft googleearth AdobeFlash-10.3 Broadcom Oracle-BCLA-JavaSE"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-march=k8 -msse3 -O2 -pipe -fomit-frame-pointer"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/share/config /usr/share/gnupg/qualified.txt"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/env.d /etc/env.d/java/ /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/php/apache2-php5.3/ext-active/ /etc/php/apache2-php5.4/ext-active/ /etc/php/cgi-php5.3/ext-active/ /etc/php/cgi-php5.4/ext-active/ /etc/php/cli-php5.3/ext-active/ /etc/php/cli-php5.4/ext-active/ /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo /etc/texmf/language.dat.d /etc/texmf/language.def.d /etc/texmf/updmap.d /etc/texmf/web2c"
CXXFLAGS="-march=k8 -msse3 -O2 -pipe -fomit-frame-pointer"
DISTDIR="/usr/portage/distfiles"
FEATURES="assume-digests binpkg-logs config-protect-if-modified distlocks ebuild-locks fixlafiles metadata-transfer news parallel-fetch parse-eapi-ebuild-head protect-owned sandbox sfperms splitdebug strict unknown-features-warn unmerge-logs unmerge-orphans userfetch"
FFLAGS=""
GENTOO_MIRRORS="http://gentoo.inode.at/ http://gd.tuwien.ac.at/opsys/linux/gentoo/ http://ftp.uni-erlangen.de/pub/mirrors/gentoo"
LANG="de_AT.UTF-8"
LDFLAGS="-Wl,-O1 -Wl,--as-needed"
LINGUAS="en de"
MAKEOPTS="-j1"
PKGDIR="/usr/portage/packages"
PORTAGE_CONFIGROOT="/"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --stats --human-readable --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages"
PORTAGE_TMPDIR="/mnt/data/portage/"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/var/lib/layman/sunrise /usr/local/portage"
SYNC="rsync://bach/gentoo-portage"
USE="3dnow 3dnowext X a52 aac aalib accessibility acl acpi addressbook akonadi alisp alsa amd64 apache2 apng arts asf assistant ati autoipd avahi avi bash-completion berkdb bindist bineditor binfilter bluetooth bookmarks branding bzip2 cairo calendar cdda cdio cdr cgi chm cli compat consolekit cracklib crypt cups curl cxx dbus de_tvtoday declarative desktopglobe dga dhclient dia divx divx4linux djvu dlloader dlna doc dri dts dv dvb dvd dvdr dvdread ebook emacs emacs-w3 embedded emboss emovix enblend enca encode examples exif expat expoblending extensions extra fam ffmpeg firefox flac fluidsynth fontconfig fortran freetype fts3 gd gdbm geolocation gif gimp gimpprint git glitz gnutls gocr gphoto2 gpssync graphics hddtemp htmlreport httpd iconv icu id3tag ieee1394 imagemagick injection inotify insecure-savers ipod iptv ipv6 jadetex jpeg jpeg2k kde kdeenablefinal kdehiddenvisibility kdexdelta kipi kpathsea kqemu lapack laptop latex lcms ldap libnotify librsync-bundled libwww live lm_sensors lua lyx lzma mad math mathml matplotlib matroska mbox melt metric mikmod minizip mjpeg mmx mmx2 mng modules mono mp140 mp3 mp4 mpeg mpi mplayer mtp mudflap multilib multimedia mysql nas ncurses network-cron nlpsolver nls nptlonly nsplugin nspluginwrapper numpy ocrad ogg oggvorbis okteta okular ole openexr opengl openmp pam pango panorama pch pcre pdf pdo phonon plasma pmu png policykit portaudio ppds pppd private-headers pstricks pyglet pylint python qalculate qimageblitz qscintilla qt qt3support qt4 qthelp qtscript qwt rdesktop readline redeyes reports romio rtsp samba scanner science scipy sdl secure-delete semantic-desktop session sift skins slang smbclient spell sql sqlite sqlite3 srt sse sse2 ssl startup-notification stream svg symlink tcl tcpd tesseract tetex tex tex4ht texmacs theora theorea threads tidy tiff tk transcode truetype twolame ubs udev udisks unicode upower usb userlocales utempter uudeview v4l v4l2 vcd vcdx vdr virt-network virtualbox vlm vnc vorbis webdav webkit webm wicd wifi wireshark wmf wxwidgets wxwindows x264 xanim xcb xcomposite xemacs xetex xext xine xinerama xml xmlwriter xmp xorg xosd xscreensaver xulrunner xv xvid zeroconf zip zlib zvbi" ALSA_CARDS="hda-intel" ALSA_PCM_PLUGINS="adpcm alaw asym copy dmix dshare dsnoop empty extplug file hooks iec958 ioplug ladspa lfloat linear meter mmap_emul mulaw multi null plug rate route share shm softvol" APACHE2_MODULES="actions alias auth_basic auth_digest authn_anon authn_dbd authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache dav dav_fs dav_lock dbd deflate dir disk_cache env expires ext_filter file_cache filter headers ident imagemap include info log_config logio mem_cache mime mime_magic negotiation proxy proxy_ajp proxy_balancer proxy_connect proxy_http rewrite setenvif so speling status unique_id userdir usertrack vhost_alias cgi" CALLIGRA_FEATURES="kexi words flow plan sheets stage tables krita karbon braindump" CAMERAS="ptp2 canon" COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog" ELIBC="glibc" 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="evdev keyboard mouse" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LIBREOFFICE_EXTENSIONS="presenter-console presenter-minimizer" LINGUAS="en de" PHP_TARGETS="php5-3" PYTHON_TARGETS="python3_2 python2_7" RUBY_TARGETS="ruby18 ruby19" USERLAND="GNU" VIDEO_CARDS="ati radeon vesa fbdev radeonhd r600 r300" 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, INSTALL_MASK, LC_ALL, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS, USE_PYTHON
Comment 1 Marien Zwart (RETIRED) gentoo-dev 2012-06-17 10:22:09 UTC
The pypy ebuild uses the check-reqs eclass to check for enough ram, and the check-reqs eclass calls "die" for us if it's used from pkg_pretend. I think check-reqs_pkg_pretend should be a noop if MERGE_TYPE is "binary". QA team, as you're the maintainer of this eclass: could you make this change, or let me make it? The alternative would be for pypy to conditionally call check-reqs_pkg_pretend, but as this eclass is meant to be used for "ebuilds which have very high *build* requirements" it probably makes more sense for the eclass to do it, or many check-reqs users will accidentally incorrectly fail with binpkgs the way pypy does.
Comment 2 Mike Gilbert gentoo-dev 2012-06-17 14:06:47 UTC
(In reply to comment #1)

Reminder: MERGE_TYPE was introduced in EAPI 4; its value is undefined in previous EAPI versions. So worst case, the improved logic works only in EAPI 4 or greater.
Comment 3 Marien Zwart (RETIRED) gentoo-dev 2012-06-17 16:04:51 UTC
That's why I mentioned checking for this in pkg_pretend, although I did not realize when I said that that the eclass uses *both* pkg_pretend and pkg_setup in EAPI 4. But yeah, I think this can only sensibly be fixed in EAPI 4.
Comment 4 Justin Lecher (RETIRED) gentoo-dev 2015-12-27 09:27:49 UTC
Meanwhile this bug was fixed by checking for MERGE_TYPE in pretend and setup