Package portage
[hide private]

Package portage

source code

Submodules [hide private]

Classes [hide private]
  FetchlistDict
This provide a mapping interface to retrieve fetch lists.
  MtimeDB
  _LegacyGlobalProxy
Instances of these serve as proxies to global variables that are initialized on demand.
  _MtimedbProxy
The mtimedb is independent from the portdb and other globals.
  _PortdbProxy
The portdb is initialized separately from the rest of the variables, since sometimes the other variables are needed while the portdb is not.
  config
This class encompasses the main portage configuration.
  digraph
Functions [hide private]
 
ExtractKernelVersion(base_dir)
Try to figure out what kernel version we are running @param base_dir: Path to sources (usually /usr/src/linux) @type base_dir: string @rtype: tuple( version[string], error[string]) @returns: 1.
source code
 
_adjust_perms_msg(settings, msg) source code
 
_check_build_log(mysettings, out=None)
Search the content of $PORTAGE_LOG_FILE if it exists and generate the following QA Notices when appropriate:
source code
 
_check_digests(filename, digests, show_errors=1)
Check digests and display a message if an error occurs.
source code
 
_check_distfile(filename, digests, eout, show_errors=1)
@return a tuple of (match, stat_obj) where match is True if filename matches all given digests (if any) and stat_obj is a stat result, or None if the file does not exist.
source code
 
_checksum_failure_temp_file(distdir, basename)
First try to find a duplicate temp file with the same checksum and return that filename if available.
source code
 
_chflags(path, flags, opts="") source code
tuple
_create_pty_or_pipe(copy_term_size=None)
Try to create a pty and if then fails then create a normal pipe instead.
source code
 
_disable_legacy_globals()
This deletes the ObjectProxy instances that are used for lazy initialization of legacy global variables.
source code
 
_doebuild_exit_status_check(mydo, settings)
Returns an error string if the shell appeared to exit unsuccessfully, None otherwise.
source code
 
_doebuild_exit_status_check_and_log(settings, mydo, retval) source code
 
_doebuild_exit_status_unlink(exit_status_file)
Double check to make sure it really doesn't exist and raise an OSError if it still does (it shouldn't).
source code
 
_expand_new_virtuals(mysplit, edebug, mydbapi, mysettings, myroot='/', trees=None, **kwargs)
Recursively expand new-style virtuals so as to collapse one or more levels of indirection.
source code
None or List
_global_updates(trees, prev_mtimes)
Perform new global updates if they exist in $PORTDIR/profiles/updates/.
source code
 
_lchflags(path, flags) source code
 
_movefile(src, dest, **kwargs)
Calls movefile and raises a PortageException if an error occurs.
source code
 
_post_phase_userpriv_perms(mysettings) source code
 
_post_pkg_postinst_cmd(mysettings)
Post phase logic and tasks that have been factored out of build.sh.
source code
 
_post_pkg_preinst_cmd(mysettings)
Post phase logic and tasks that have been factored out of ebuild.sh.
source code
 
_post_src_install_checks(mysettings) source code
 
_post_src_install_uid_fix(mysettings)
Files in $D with user and group bits that match the "portage" user or group are automatically mapped to PORTAGE_INST_UID and PORTAGE_INST_GID if necessary.
source code
 
_prepare_features_dirs(mysettings) source code
 
_prepare_workdir(mysettings) source code
 
_shell_quote(s)
Quote a string in double-quotes and use backslashes to escape any backslashes, double-quotes, dollar signs, or backquotes in the string.
source code
 
_spawn_fetch(settings, args, **kwargs)
Spawn a process with appropriate settings for fetching, including userfetch and selinux support.
source code
int
_spawn_misc_sh(mysettings, commands, **kwargs)
Returns: the return value from the spawn() call
source code
 
_userpriv_test_write_file(settings, file_path)
Drop privileges and try to open a file for writing.
source code
 
abssymlink(symlink)
This reads symlinks, resolving the relative symlinks, and returning the absolute.
source code
string
autouse(myvartree, use_cache=1, mysettings=None)
autuse returns a list of USE variables auto-enabled to packages being installed
source code
 
best_from_dict(key, top_dict, key_order, EmptyOnError=1, FullCopy=1, AllowEmpty=1) source code
 
cacheddir(my_original_path, ignorecvs, ignorelist, EmptyOnError, followSymlinks=True) source code
 
check_config_instance(test) source code
 
commit_mtimedb(mydict=None, filename=None) source code
 
cpv_expand(mycpv, mydb=None, use_cache=1, settings=None)
Given a string (packagename or virtual) expand it into a valid cat/package string.
source code
 
cpv_getkey(mycpv) source code
 
create_trees(config_root=None, target_root=None, trees=None) source code
 
dep_check(depstring, mydbapi, mysettings, use='yes', mode=None, myuse=None, use_cache=1, use_binaries=0, myroot='/', trees=None)
Takes a depend string and parses the condition.
source code
 
dep_eval(deplist) source code
 
dep_expand(mydep, mydb=None, use_cache=1, settings=None) source code
 
dep_virtual(mysplit, mysettings)
Does virtual dependency conversion
source code
 
dep_wordreduce(mydeplist, mysettings, mydbapi, mode, use_cache=1)
Reduces the deplist to ones and zeros
source code
 
dep_zapdeps(unreduced, reduced, myroot, use_binaries=0, trees=None)
Takes an unreduced and reduced deplist and removes satisfied dependencies.
source code
 
deprecated_profile_check() source code
 
digestParseFile(myfilename, mysettings=None)
(filename) -- Parses a given file for entries matching: <checksumkey> <checksum_hex_string> <filename> <filesize> Ignores lines that don't start with a valid checksum identifier and returns a dict with the filenames as keys and {checksumkey:checksum} as the values.
source code
 
digestcheck(myfiles, mysettings, strict=0, justmanifest=0)
Verifies checksums.
source code
 
digestgen(myarchives, mysettings, overwrite=1, manifestonly=0, myportdb=None)
Generates a digest file if missing.
source code
 
doebuild(myebuild, mydo, myroot, mysettings, debug=0, listonly=0, fetchonly=0, cleanup=0, dbkey=None, use_cache=1, fetchall=0, tree=None, mydbapi=None, vartree=None, prev_mtimes=None, fd_pipes=None, returnpid=False)
Wrapper function that invokes specific ebuild phases through the spawning of ebuild.sh
source code
 
doebuild_environment(myebuild, mydo, myroot, mysettings, debug, use_cache, mydbapi) source code
 
eapi_is_supported(eapi) source code
 
env_update(makelinks=1, target_root=None, prev_mtimes=None, contents=None, env=None, writemsg_level=<function writemsg_level at 0x8a18e64>) source code
 
fetch(myuris, mysettings, listonly=0, fetchonly=0, locks_in_subdir='.locks', use_locks=1, try_mirrors=1)
fetch files.
source code
 
flatten(mytokens)
this function now turns a [1,[2,3]] list into a [1,2,3] list and returns it.
source code
 
flushmtimedb(record) source code
 
getCPFromCPV(mycpv)
Calls pkgsplit on a cpv and returns only the cp.
source code
 
getcwd()
this fixes situations where the current directory doesn't exist
source code
 
getmaskingreason(mycpv, metadata=None, settings=None, portdb=None, return_location=False) source code
 
getmaskingstatus(mycpv, settings=None, portdb=None) source code
 
getvirtuals(myroot) source code
 
init_legacy_globals() source code
 
key_expand(mykey, mydb=None, use_cache=1, settings=None) source code
List
listdir(mypath, recursive=False, filesonly=False, ignorecvs=False, ignorelist=[], followSymlinks=True, EmptyOnError=False, dirsonly=False)
Portage-specific implementation of os.listdir
source code
 
load_mod(name) source code
 
merge(mycat, mypkg, pkgloc, infloc, myroot, mysettings, myebuild=None, mytree=None, mydbapi=None, vartree=None, prev_mtimes=None, blockers=None, scheduler=None) source code
 
movefile(src, dest, newmtime=None, sstat=None, mysettings=None)
moves a file from src to dest, preserving all permissions and attributes; mtime will be preserved even when moving across filesystems.
source code
 
pkgmerge(mytbz2, myroot, mysettings, mydbapi=None, vartree=None, prev_mtimes=None, blockers=None)
will merge a .tbz2 file, returning a list of runtime dependencies that must be satisfied, or None if there was a merge error.
source code
 
portageexit() source code
 
prepare_build_dirs(myroot, mysettings, cleanup) source code
 
spawn(mystring, mysettings, debug=0, free=0, droppriv=0, sesandbox=0, fakeroot=0, **keywords)
Spawn a subprocess with extra portage-specific options.
source code
 
spawnebuild(mydo, actionmap, mysettings, debug, alwaysdep=0, logfile=None, fd_pipes=None, returnpid=False) source code
 
unmerge(cat, pkg, myroot, mysettings, mytrimworld=1, vartree=None, ldpath_mtimes=None, scheduler=None) source code
Variables [hide private]
  VERSION = '2.2_rc8_p11503'
  _disable_openpty = False
  _doebuild_broken_ebuilds = set([])
  _doebuild_broken_manifests = set([])
  _doebuild_manifest_cache = None
  _doebuild_manifest_exempt_depend = 0
  _fetch_resume_size_re = re.compile(r'(^\d+)([KMGTPEZY]?$)')
  _globals_initialized = False
  _legacy_global_var_names = ('archlist', 'db', 'features', 'gro...
  _mtimedb_initialized = False
  _portdb_initialized = False
  _post_phase_cmds = {'install': ['install_qa_check', 'install_s...
  _size_suffix_map = {'': 0, 'E': 60, 'G': 30, 'K': 10, 'M': 20,...
  _userpriv_spawn_kwargs = (('uid', 250), ('gid', 250), ('groups...
  _userpriv_test_write_cmd_script = 'touch %(file_path)s 2>/dev/...
  _userpriv_test_write_file_cache = {}
  archlist = ['ppc', '~ppc', 's390', '~s390', 'amd64', '~amd64',...
  auxdbkeylen = 22
  auxdbkeys = ['DEPEND', 'RDEPEND', 'SLOT', 'SRC_URI', 'RESTRICT...
  bsd_chflags = None
  cacheHit = 0
  cacheMiss = 0
  cacheStale = 0
  db = {'/': {'virtuals': None, 'bintree': None, 'vartree': None...
  dircache = {}
  expandcache = {}
  features = ['assume-digests', 'collision-protect', 'distlocks'...
  groups = ['x86', '~x86']
  k = 'flushmtimedb'
  mtimedb = {'info': {'/usr/share/info': 1220735393L, '/usr/shar...
  mtimedbfile = '/var/cache/edb/mtimedb'
  pkglines = ['*virtual/dev-manager', '*virtual/gzip', '*app-she...
  portdb = _PortdbProxy()
  profiledir = '/etc/make.profile'
  root = '/'
  selinux_enabled = 0
  settings = <portage.config object at 0x84a114c>
  thirdpartymirrors = {'3dgamers': ['ftp://ftp.planetmirror.com/...
  usedefaults = {'aalib': ['media-libs/aalib'], 'acl': ['sys-app...

Imports: eclass_cache, BASH_BINARY, CACHE_PATH, CONFIG_MEMORY_FILE, CUSTOM_MIRRORS_FILE, CUSTOM_PROFILE_PATH, CacheError, DEPCACHE_PATH, DEPRECATED_PROFILE_FILE, EAPI, EBUILD_SH_BINARY, EBUILD_SH_ENV_FILE, INCREMENTALS, INVALID_ENV_FILE, LOCALE_DATA_PATH, MAKE_CONF_FILE, MAKE_DEFAULTS_FILE, MISC_SH_BINARY, MODULES_FILE_PATH, MOVE_BINARY, Manifest, PORTAGE_BASE_PATH, PORTAGE_BIN_PATH, PORTAGE_PYM_PATH, PRELINK_BINARY, PRIVATE_PATH, PROFILE_PATH, REPO_NAME_FILE, REPO_NAME_LOC, SANDBOX_BINARY, USER_CONFIG_PATH, USER_VIRTUALS_FILE, UserDict, VDB_PATH, WORLD_FILE, _, apply_recursive_permissions, apply_secpass_permissions, atexit_register, atomic_ofstream, best, best_match_to_list, binarytree, bindbapi, bold, cPickle, cache, catpkgsplit, catsplit, chain, checksum, close_portdbapi_caches, colorize, commands, const, copy, cvstree, data, dbapi, dblink, dep, dep_getcpv, dep_getkey, dep_transform, dump_traceback, elog, endversion, endversion_keys, errno, exception, fakedbapi, fixdbentries, get_operator, getbinpkg, getconfig, gpg, grab_updates, grabdict, grabdict_package, grabfile, grabfile_package, green, isjustname, isspecific, isvalidatom, izip, lchown, localization, lockdir, lockfile, locks, logging, mail, manifest, map_dictlist_vals, match_from_list, match_to_list, new_protect_filename, normalize_path, os, ostype, output, parse_updates, perform_checksum, perform_md5, pickle_read, pickle_write, pkgcmp, pkgsplit, platform, portage_gid, portage_uid, portagetree, portdbapi, prelink_capable, process, re, red, run_exitfuncs, secpass, selinux, shuffle, shutil, sleep, stack_dictlist, stack_dicts, stack_lists, stat, sys, time, uid, unique_array, unlockdir, unlockfile, update, update_config_files, update_dbentries, userland, userpriv_groups, util, vardbapi, varexpand, vartree, vercmp, versions, ververify, warnings, wheelgid, write_atomic, writedict, writemsg, writemsg_stdout, xpak, yellow


Function Details [hide private]

ExtractKernelVersion(base_dir)

source code 

Try to figure out what kernel version we are running
@param base_dir: Path to sources (usually /usr/src/linux)
@type base_dir: string
@rtype: tuple( version[string], error[string])
@returns:
1. tuple( version[string], error[string])
Either version or error is populated (but never both)

_check_build_log(mysettings, out=None)

source code 

Search the content of $PORTAGE_LOG_FILE if it exists
and generate the following QA Notices when appropriate:

  * Automake "maintainer mode"
  * command not found
  * Unrecognized configure options

_check_digests(filename, digests, show_errors=1)

source code 

Check digests and display a message if an error occurs. @return True if all digests match, False otherwise.

_checksum_failure_temp_file(distdir, basename)

source code 

First try to find a duplicate temp file with the same checksum and return that filename if available. Otherwise, use mkstemp to create a new unique filename._checksum_failure_.$RANDOM, rename the given file, and return the new filename. In any case, filename will be renamed or removed before this function returns a temp filename.

_create_pty_or_pipe(copy_term_size=None)

source code 

Try to create a pty and if then fails then create a normal pipe instead.

Parameters:
  • copy_term_size (int) - If a tty file descriptor is given then the term size will be copied to the pty.
Returns: tuple
A tuple of (is_pty, master_fd, slave_fd) where is_pty is True if a pty was successfully allocated, and False if a normal pipe was allocated.

_disable_legacy_globals()

source code 

This deletes the ObjectProxy instances that are used for lazy initialization of legacy global variables. The purpose of deleting them is to prevent new code from referencing these deprecated variables.

_doebuild_exit_status_unlink(exit_status_file)

source code 

Double check to make sure it really doesn't exist and raise an OSError if it still does (it shouldn't). OSError if necessary.

_expand_new_virtuals(mysplit, edebug, mydbapi, mysettings, myroot='/', trees=None, **kwargs)

source code 

Recursively expand new-style virtuals so as to collapse one or more levels of indirection. In dep_zapdeps, new-style virtuals will be assigned zero cost regardless of whether or not they are currently installed. Virtual blockers are supported but only when the virtual expands to a single atom because it wouldn't necessarily make sense to block all the components of a compound virtual. When more than one new-style virtual is matched, the matches are sorted from highest to lowest versions and the atom is expanded to || ( highest match ... lowest match ).

_global_updates(trees, prev_mtimes)

source code 

Perform new global updates if they exist in $PORTDIR/profiles/updates/.

Parameters:
  • trees (dict) - A dictionary containing portage trees.
  • prev_mtimes (dict) - A dictionary containing mtimes of files located in $PORTDIR/profiles/updates/.
Returns: None or List
None if no were no updates, otherwise a list of update commands that have been performed.

_post_pkg_preinst_cmd(mysettings)

source code 

Post phase logic and tasks that have been factored out of ebuild.sh. Call preinst_mask last so that INSTALL_MASK can can be used to wipe out any gmon.out files created during previous functions (in case any tools were built with -pg in CFLAGS).

_post_src_install_uid_fix(mysettings)

source code 

Files in $D with user and group bits that match the "portage" user or group are automatically mapped to PORTAGE_INST_UID and PORTAGE_INST_GID if necessary. The chown system call may clear S_ISUID and S_ISGID bits, so those bits are restored if necessary.

_spawn_misc_sh(mysettings, commands, **kwargs)

source code 
Parameters:
  • mysettings (config) - the ebuild config
  • commands (list) - a list of function names to call in misc-functions.sh
Returns: int
the return value from the spawn() call

_userpriv_test_write_file(settings, file_path)

source code 

Drop privileges and try to open a file for writing. The file may or may not exist, and the parent directory is assumed to exist. The file is removed before returning.

Parameters:
  • settings - A config instance which is passed to _spawn_fetch()
  • file_path - A file path to open and write.
Returns:
True if write succeeds, False otherwise.

autouse(myvartree, use_cache=1, mysettings=None)

source code 

autuse returns a list of USE variables auto-enabled to packages being installed

Parameters:
  • myvartree (vartree) - Instance of the vartree class (from /var/db/pkg...)
  • use_cache (Boolean) - read values from cache
  • mysettings (config) - Instance of config
Returns: string
A string containing a list of USE variables that are enabled via use.defaults

cpv_expand(mycpv, mydb=None, use_cache=1, settings=None)

source code 

Given a string (packagename or virtual) expand it into a valid cat/package string. Virtuals use the mydb to determine which provided virtual is a valid choice and defaults to the first element when there are no installed/available candidates.

dep_zapdeps(unreduced, reduced, myroot, use_binaries=0, trees=None)

source code 

Takes an unreduced and reduced deplist and removes satisfied dependencies. Returned deplist contains steps that must be taken to satisfy dependencies.

digestParseFile(myfilename, mysettings=None)

source code 
(filename) -- Parses a given file for entries matching:
<checksumkey> <checksum_hex_string> <filename> <filesize>
Ignores lines that don't start with a valid checksum identifier
and returns a dict with the filenames as keys and {checksumkey:checksum}
as the values.
DEPRECATED: this function is now only a compability wrapper for
            portage.manifest.Manifest().

digestcheck(myfiles, mysettings, strict=0, justmanifest=0)

source code 
Verifies checksums.  Assumes all files have been downloaded.
DEPRECATED: this is now only a compability wrapper for 
            portage.manifest.Manifest().

digestgen(myarchives, mysettings, overwrite=1, manifestonly=0, myportdb=None)

source code 

Generates a digest file if missing.  Assumes all files are available.
DEPRECATED: this now only is a compability wrapper for 
            portage.manifest.Manifest()
NOTE: manifestonly and overwrite are useless with manifest2 and
      are therefore ignored.

doebuild(myebuild, mydo, myroot, mysettings, debug=0, listonly=0, fetchonly=0, cleanup=0, dbkey=None, use_cache=1, fetchall=0, tree=None, mydbapi=None, vartree=None, prev_mtimes=None, fd_pipes=None, returnpid=False)

source code 

Wrapper function that invokes specific ebuild phases through the spawning
of ebuild.sh

@param myebuild: name of the ebuild to invoke the phase on (CPV)
@type myebuild: String
@param mydo: Phase to run
@type mydo: String
@param myroot: $ROOT (usually '/', see man make.conf)
@type myroot: String
@param mysettings: Portage Configuration
@type mysettings: instance of portage.config
@param debug: Turns on various debug information (eg, debug for spawn)
@type debug: Boolean
@param listonly: Used to wrap fetch(); passed such that fetch only lists files required.
@type listonly: Boolean
@param fetchonly: Used to wrap fetch(); passed such that files are only fetched (no other actions)
@type fetchonly: Boolean
@param cleanup: Passed to prepare_build_dirs (TODO: what does it do?)
@type cleanup: Boolean
@param dbkey: A dict (usually keys and values from the depend phase, such as KEYWORDS, USE, etc..)
@type dbkey: Dict or String
@param use_cache: Enables the cache
@type use_cache: Boolean
@param fetchall: Used to wrap fetch(), fetches all URI's (even ones invalid due to USE conditionals)
@type fetchall: Boolean
@param tree: Which tree to use ('vartree','porttree','bintree', etc..), defaults to 'porttree'
@type tree: String
@param mydbapi: a dbapi instance to pass to various functions; this should be a portdbapi instance.
@type mydbapi: portdbapi instance
@param vartree: A instance of vartree; used for aux_get calls, defaults to db[myroot]['vartree']
@type vartree: vartree instance
@param prev_mtimes: A dict of { filename:mtime } keys used by merge() to do config_protection
@type prev_mtimes: dictionary
@rtype: Boolean
@returns:
1. 0 for success
2. 1 for error

Most errors have an accompanying error message.

listonly and fetchonly are only really necessary for operations involving 'fetch'
prev_mtimes are only necessary for merge operations.
Other variables may not be strictly required, many have defaults that are set inside of doebuild.

fetch(myuris, mysettings, listonly=0, fetchonly=0, locks_in_subdir='.locks', use_locks=1, try_mirrors=1)

source code 

fetch files. Will use digest file if available.

listdir(mypath, recursive=False, filesonly=False, ignorecvs=False, ignorelist=[], followSymlinks=True, EmptyOnError=False, dirsonly=False)

source code 

Portage-specific implementation of os.listdir

Parameters:
  • mypath (String) - Path whose contents you wish to list
  • recursive (Boolean @param filesonly; Only return files, not more directories) - Recursively scan directories contained within mypath
  • ignorecvs (Boolean) - Ignore CVS directories ('CVS','.svn','SCCS')
  • ignorelist (List) - List of filenames/directories to exclude
  • followSymlinks (Boolean) - Follow Symlink'd files and directories
  • EmptyOnError (Boolean) - Return [] if an error occurs.
  • dirsonly (Boolean) - Only return directories.
  • filesonly (Boolean)
Returns: List
A list of files and directories (or just files or just directories) or an empty list.

movefile(src, dest, newmtime=None, sstat=None, mysettings=None)

source code 

moves a file from src to dest, preserving all permissions and attributes; mtime will be preserved even when moving across filesystems. Returns true on success and false on failure. Move is atomic.

pkgmerge(mytbz2, myroot, mysettings, mydbapi=None, vartree=None, prev_mtimes=None, blockers=None)

source code 

will merge a .tbz2 file, returning a list of runtime dependencies that must be satisfied, or None if there was a merge error. This code assumes the package exists.

spawn(mystring, mysettings, debug=0, free=0, droppriv=0, sesandbox=0, fakeroot=0, **keywords)

source code 

Spawn a subprocess with extra portage-specific options.
Optiosn include:

Sandbox: Sandbox means the spawned process will be limited in its ability t
read and write files (normally this means it is restricted to ${IMAGE}/)
SElinux Sandbox: Enables sandboxing on SElinux
Reduced Privileges: Drops privilages such that the process runs as portage:portage
instead of as root.

Notes: os.system cannot be used because it messes with signal handling.  Instead we
use the portage.process spawn* family of functions.

This function waits for the process to terminate.

@param mystring: Command to run
@type mystring: String
@param mysettings: Either a Dict of Key,Value pairs or an instance of portage.config
@type mysettings: Dictionary or config instance
@param debug: Ignored
@type debug: Boolean
@param free: Enable sandboxing for this process
@type free: Boolean
@param droppriv: Drop to portage:portage when running this command
@type droppriv: Boolean
@param sesandbox: Enable SELinux Sandboxing (toggles a context switch)
@type sesandbox: Boolean
@param fakeroot: Run this command with faked root privileges
@type fakeroot: Boolean
@param keywords: Extra options encoded as a dict, to be passed to spawn
@type keywords: Dictionary
@rtype: Integer
@returns:
1. The return code of the spawned process.


Variables Details [hide private]

_legacy_global_var_names

Value:
('archlist',
 'db',
 'features',
 'groups',
 'mtimedb',
 'mtimedbfile',
 'pkglines',
 'portdb',
...

_post_phase_cmds

Value:
{'install': ['install_qa_check', 'install_symlink_html_docs'],
 'postinst': ['postinst_bsdflags'],
 'preinst': ['preinst_bsdflags',
             'preinst_sfperms',
             'preinst_selinux_labels',
             'preinst_suid_scan',
             'preinst_mask']}

_size_suffix_map

Value:
{'': 0,
 'E': 60,
 'G': 30,
 'K': 10,
 'M': 20,
 'P': 50,
 'T': 40,
 'Y': 80,
...

_userpriv_spawn_kwargs

Value:
(('uid', 250), ('gid', 250), ('groups', [250]), ('umask', 2))

_userpriv_test_write_cmd_script

Value:
'touch %(file_path)s 2>/dev/null ; rval=$? ; rm -f  %(file_path)s ; ex\
it $rval'

archlist

Value:
['ppc', '~ppc', 's390', '~s390', 'amd64', '~amd64', 'x86', '~x86', 'pp\
c64', '~ppc64', 'x86-fbsd', '~x86-fbsd', 'm68k', '~m68k', 'arm', '~arm\
', 'sparc', '~sparc', 'sh', '~sh', 'mips', '~mips', 'ia64', '~ia64', '\
alpha', '~alpha', 'hppa', '~hppa', 'sparc-fbsd', '~sparc-fbsd']

auxdbkeys

Value:
['DEPEND',
 'RDEPEND',
 'SLOT',
 'SRC_URI',
 'RESTRICT',
 'HOMEPAGE',
 'LICENSE',
 'DESCRIPTION',
...

db

Value:
{'/': {'virtuals': None, 'bintree': None, 'vartree': None, 'porttree':\
 None}}

features

Value:
['assume-digests',
 'collision-protect',
 'distlocks',
 'fakeroot',
 'parallel-fetch',
 'preserve-libs',
 'protect-owned',
 'sandbox',
...

mtimedb

Value:
{'info': {'/usr/share/info': 1220735393L, '/usr/share/info/emacs-22': \
1211843387L, '/mnt/gentoo/3/usr/share/binutils-data/i586-pc-linux-gnu/\
2.18/info': 1214107128L, '/usr/share/gcc-data/i586-pc-linux-gnu/4.3.1/\
info': 1218264672L, '/mnt/gentoo/3/usr/share/gcc-data/i586-pc-linux-gn\
u/4.2.4/info': 1214107129L, '/usr/share/gcc-data/i586-pc-linux-gnu/4.2\
.4/info': 1217865588L, '/usr/share/binutils-data/i586-pc-linux-gnu/2.1\
8/info': 1216781092L, '/mnt/gentoo/3/usr/share/info': 1214107127L, '/m\
nt/gentoo/3/usr/share/info/emacs-22': 1214107132L}, 'resume_backup': {\
...

pkglines

Value:
['*virtual/dev-manager',
 '*virtual/gzip',
 '*app-shells/bash',
 '*sys-devel/libtool',
 '*sys-apps/texinfo',
 '*sys-apps/findutils',
 '*sys-devel/make',
 '>=sys-apps/baselayout-1.12.10-r5',
...

thirdpartymirrors

Value:
{'3dgamers': ['ftp://ftp.planetmirror.com/pub/3dgamers/games/'],
 'alsaproject': ['ftp://ftp.alsa-project.org/pub',
                 'ftp://ftp.silug.org/pub/alsa',
                 'ftp://ftp.task.gda.pl/pub/linux/misc/alsa',
                 'ftp://gd.tuwien.ac.at/opsys/linux/alsa',
                 'ftp://ftp.iasi.roedu.net/pub/mirrors/ftp.alsa-projec\
t.org',
                 'http://dl.ambiweb.de/mirrors/ftp.alsa-project.org',
...

usedefaults

Value:
{'aalib': ['media-libs/aalib'],
 'acl': ['sys-apps/acl'],
 'adns': ['net-libs/adns'],
 'afs': ['net-fs/openafs'],
 'alsa': ['media-libs/alsa-lib'],
 'arts': ['kde-base/arts'],
 'audiofile': ['media-libs/audiofile'],
 'bash-completion': ['app-shells/bash-completion'],
...