summaryrefslogtreecommitdiffstats
path: root/pym/_emerge/AbstractEbuildProcess.py
Commit message (Collapse)AuthorAgeFilesLines
* Remove unneeded _unicode_decode for io.StringIO.Zac Medico2011-07-121-4/+1
| | | | | | | Since StringIO.StringIO fallback was removed in commit 5df96179611ce0e98727945b1800b43daccedfc2, we can rely on io.StringIO.getoutput() to return unicode, so there's no need to call _unicode_decode on the result.
* Remove python-2.6 StringIO.StringIO fallback.Zac Medico2011-07-121-3/+2
| | | | | | | | Since the io module in python-2.6 was broken when threading was disabled, we needed to fall back from io.StringIO to StringIO.StringIO in this case (typically just for Gentoo's stage1 and stage2 tarballs). Now that python-2.7 is stable in stages and we rely on io.open() being available, we can also rely on io.StringIO being available.
* SubProcess: fix status for _set_returncode callerZac Medico2011-06-091-1/+1
| | | | | | These callers don't intend to make WIFSIGNALED return True, so they need to shift their codes 8 bits to the left. This ensures that commit 88f5bf84e2fd23125910b2ecaffc035971445696 behaves as intended.
* AbstractEbuildProcess: handle kill by signalZac Medico2011-06-091-5/+19
| | | | This will fix bug #368817.
* MergeProcess: Fix PORTAGE_BACKGROUND/LOG_FILE useZac Medico2011-03-241-2/+4
| | | | | | | | In this subprocess we don't want PORTAGE_BACKGROUND to suppress stdout/stderr output since they are pipes. We also don't want to open PORTAGE_LOG_FILE, since it will already be opened by the parent process, so we set the PORTAGE_BACKGROUND="subprocess" value for use in conditional logging code involving PORTAGE_LOG_FILE.
* AbstractPollTask: log exceptional eventsZac Medico2011-03-091-0/+5
| | | | | | | | | | | | | | | | Previously, when AbstractPollTask receives a POLLERR or POLLNVAL event, it would silently cancel the task. Now it will generate a message like this: !!! SpawnProcess received strange poll event: 8 The message is displayed via a new _log_poll_exception method, which is overridden by AbstractEbuildProcess to log the message via elog. This might help diagnose reported cases of SIGTERM signals killing ebuild processes for no apparent reason: http://code.google.com/p/chromium-os/issues/detail?id=12968
* Add PollScheduler.terminate() for interruption.Zac Medico2011-01-151-3/+4
| | | | | This allows PollScheduler instances to do basic cleanup and terminate gracefully when SIGINT or SIGTERM signals are received.
* Copy term size to pty only if foreground.Zac Medico2010-10-231-1/+3
|
* has/best_version: eqawarn if EAPI wrong for atomZac Medico2010-10-111-1/+1
| | | | | Instead of calling die as in bug #340387, just call eqawarn for the time being.
* Bug #337465 - Enable EbuildIpcDaemon on Darwin and FreeBSD sinceZac Medico2010-09-251-8/+0
| | | | | | it seems fixed now. This reverts commit 0906fee12ffe0ebd07e8952316f03927962af29b.
* Bug #337465 - Disable EbuildIpcDaemon on Darwin and FreeBSD sinceZac Medico2010-09-211-0/+8
| | | | | | it reportedly triggers a tight loop in emerge. This reverts commit 6085103bdd7623d941e3c6ae5905e66658c49fd7.
* Bug #337465 - Enable EbuildIpcDaemon on Darwin and FreeBSD since itZac Medico2010-09-191-8/+0
| | | | seems fixed since commit 81fc303212b8379219cf5d463c8717359b972dba.
* Disable EbuildIpcDaemon for Darwin (similar issues to FreeBSD).Zac Medico2010-09-181-1/+2
|
* Bug #337465 - Disable EbuildIpcDaemon on FreeBSD since it doesn'tv2.2_rc83Zac Medico2010-09-151-0/+8
| | | | work yet.
* Make EbuildBuildDir use the PORTAGE_BUILDDIR variable instead of theZac Medico2010-09-141-1/+0
| | | | dir_path attribute.
* Make AbstractEbuildProcess lock PORTAGE_BUILDIR if it's not alreadyZac Medico2010-09-131-1/+10
| | | | locked.
* Move the stale elog cleanup code from AbstractEbuildProcess toZac Medico2010-09-071-14/+0
| | | | EbuildPhase.
* Move the stale elog cleanup code from _doebuild_spawn() toZac Medico2010-09-071-1/+17
| | | | | | | AbstractEbuildProcess._start() since that's a better place if we decide to use phase_completed_file skip the spawning of bash (dyn_unpack automatic clean/re-unpack logic could be migrated here too).
* Add a more generic AbstractEbuildProcess._elog() method to replaceZac Medico2010-09-051-3/+13
| | | | the existing _eerror() method.
* In AbstractEbuildProcess._start(), verify that PORTAGE_BUILDIRZac Medico2010-09-041-0/+13
| | | | exists and bail out if necessary.
* Add a TODO note to AbstractEbuildProcess._can_log() about adding supportZac Medico2010-08-301-0/+3
| | | | for logging via named pipe (fifo) for sesandbox.
* Remove unused imports found by pylint.Arfrever Frehtes Taifersar Arahesis2010-08-291-3/+1
|
* Allow more time for natural exit of the ebuild process after it hasZac Medico2010-08-221-4/+9
| | | | called the exit command via IPC.
* Bug #324191 - Add support for FEATURES=compress-build-logs. The causesZac Medico2010-08-211-12/+2
| | | | | | | all build logs to be compressed while they are being written. Log file names have an extension that is appropriate for the compression type. Currently, only gzip(1) compression is supported, so build logs will have a '.gz' extension when this feature is enabled.
* Move the fakeroot_state attribute back to EbuildSpawnProcess fromZac Medico2010-08-161-3/+1
| | | | AbstractEbuildProcess (only EbuildSpawnProcess uses it).
* Move fakeroot_state attribute from EbuildSpawnProcess toZac Medico2010-08-161-1/+3
| | | | AbstractEbuildProcess.
* Enable EbuildIpcDaemon support by default.Zac Medico2010-08-151-4/+5
|
* Remove redundant os.path.join() call in _init_ipc_fifos().Zac Medico2010-08-151-3/+1
|
* Disable EbuildIpcDaemon for now, since it seems to be triggeringZac Medico2010-08-141-20/+81
| | | | | intermittent build failures in my stage builds. For testing purposes set PORTAGE_IPC_DAEMON_ENABLE=1 to enable EbuildIpcDaemon.
* When in background mode, set NOCOLOR=true in order to prevent colorZac Medico2010-08-141-0/+5
| | | | | codes from showing up in logs, since we're not displaying to a terminal anyway. Thanks to Brian Harring for the suggestion.
* Move 'phase' attribute to AbstractEbuildProcess from subclasses, soZac Medico2010-08-141-9/+9
| | | | the _get_phase() method isn't needed.
* Add a QueryCommand.settings attribute and use it so that $USEZac Medico2010-08-141-1/+1
| | | | | doesn't have to be passed to the daemon in has_version and best_version calls.
* Fix EbuildSpawnProcess to use self.settings.environ() for the spawnZac Medico2010-08-141-7/+2
| | | | | environment, so all AbstractEbuildProcess subclasses are consistent in this way.
* Make sure PORTAGE_IPC_DAEMON is only in the environment forZac Medico2010-08-141-3/+6
| | | | | appropriate phases (it was leaking into clean/cleanrm from previous phases.
* Bug #315615 - Use EbuildIpcDaemon to implement has_version and best_version.Zac Medico2010-08-131-1/+7
| | | | | This provides performance benefits and also avoids permissions issues with FEATURES=userpriv.
* Rename SubProcess._zombie() to _orphan_process_warn() and clarifyZac Medico2010-08-131-4/+4
| | | | the eerror message.
* Write eerror messages to the log file, and only to stdout whenZac Medico2010-08-131-5/+30
| | | | appropriate.
* Bug #278895 - After EbuildIpcDaemon identifies an ebuild process thatZac Medico2010-08-131-0/+10
| | | | | has left an orphan child process running in the background, generate an eerror message about a 'zombie' process and note the pid.
* Use EbuildIpcDaemon to replace the functionality ofZac Medico2010-08-131-11/+86
| | | | EBUILD_EXIT_STATUS_FILE.
* Factor EBUILD_EXIT_STATUS_FILE code out of AbstractEbuildProcessZac Medico2010-08-121-0/+13
| | | | subclasses and into AbstractEbuildProcess itself.
* Relocate attributes from AbstractEbuildProcess to subclasses that useZac Medico2010-08-091-1/+1
| | | | them, since EbuildSpawnProcess doesn't use the attributes.
* Remove all svn $Id keywords.Zac Medico2010-03-241-1/+0
|
* Move _pty module to portage.util._pty.Zac Medico2010-03-021-1/+1
| | | | svn path=/main/trunk/; revision=15515
* Split doebuild and related code to the portage.package.ebuild module.Zac Medico2010-02-251-1/+2
| | | | svn path=/main/trunk/; revision=15448
* Add a AbstractEbuildProcess class for MiscFunctionsProcess to inherit theZac Medico2009-12-061-0/+24
_pipe and _can_log methods that used to be in the EbuildProcess class. svn path=/main/trunk/; revision=14933