Zac Medico [Sat, 21 Aug 2010 13:38:59 +0000 (06:38 -0700)]
Add a deprecation warning for the unused justmanifest parameter of
digestcheck().
Zac Medico [Sat, 21 Aug 2010 13:31:18 +0000 (06:31 -0700)]
Quote arrays in QA_PREBUILT handling.
Zac Medico [Sat, 21 Aug 2010 13:24:50 +0000 (06:24 -0700)]
Add support for a QA_PREBUILT variable should contain a list of
pre-built binaries. Paths listed here will be appended to each of
the other QA_* variables. Thanks to Diego Pettenò <flameeyes@g.o>
for the suggestion.
Zac Medico [Sat, 21 Aug 2010 11:30:29 +0000 (04:30 -0700)]
Add upstream.workaround warning for addpredict calls. Thanks to
Diego Pettenò <flameeyes@g.o> for the suggestion.
Zac Medico [Sat, 21 Aug 2010 11:20:22 +0000 (04:20 -0700)]
Fix broken reference to portage._validate_cache_for_unsupported_eapis.
Zac Medico [Sat, 21 Aug 2010 11:13:09 +0000 (04:13 -0700)]
Add a wrapper around config.features that provides the following
enhancements:
* The FEATURES variable is automatically synchronized upon modification.
* Modifications result in a permanent override that will cause the change
to propagate to the incremental stacking mechanism in config.regenerate().
This eliminates the need to call config.backup_changes() when FEATURES
is modified, since any overrides are guaranteed to persist despite calls
to config.reset().
This allows cleanup of all code that overrides FEATURES, and also allows
config.regenerate() to stack FEATURES such that special cases are not
needed for package.env handling inside config.setcpv().
Zac Medico [Sat, 21 Aug 2010 09:24:47 +0000 (02:24 -0700)]
When stacking incrementals in config.regenerate(), use a set to avoid
relatively inefficient __contains__ and remove operations on a list.
Zac Medico [Sat, 21 Aug 2010 01:21:00 +0000 (18:21 -0700)]
Fix config.setcpv() so it only calls _grab_pkg_env when there are
relevant package.env settings.
Zac Medico [Sat, 21 Aug 2010 00:44:56 +0000 (17:44 -0700)]
Remove duplicate realpath call for PORTAGE_TMPDIR.
Zac Medico [Sat, 21 Aug 2010 00:31:08 +0000 (17:31 -0700)]
At some point we may want to stop exporting FEATURES to the ebuild
environment, in order to prevent ebuilds from abusing it. In
preparation for that, export it as PORTAGE_FEATURES so that bashrc
users will be able to migrate any FEATURES conditional code to
use this alternative variable.
Zac Medico [Sat, 21 Aug 2010 00:11:38 +0000 (17:11 -0700)]
Bug #44796 - Add support for /etc/portage/package.env. As documented in
man/portage.5:
Per-package environment variable settings. Entries refer to environment
files that are placed in the /etc/portage/env/ directory and have the
same format as make.conf(5).
Format:
- comment lines begin with # (no inline comments)
- one DEPEND atom per line followed by name(s) of environment file(s)
Example:
sys-libs/glibc glibc.conf
Zac Medico [Fri, 20 Aug 2010 22:32:13 +0000 (15:32 -0700)]
Make varexpand() create a new empty dict for variable expansions in
case one is not passed in. This will prevent some potentially
confusing behavior.
Zac Medico [Fri, 20 Aug 2010 18:23:24 +0000 (11:23 -0700)]
Split out a _ordered_by_atom_specificity() in order to eliminate
duplicate code from the package.* config file handling.
Zac Medico [Fri, 20 Aug 2010 17:20:59 +0000 (10:20 -0700)]
Make DEPCACHE_PATH relative to EPREFIX, and comment about similarity
to make.globals handling.
Zac Medico [Fri, 20 Aug 2010 16:41:21 +0000 (09:41 -0700)]
* Make dblink._linkmap_rebuild() return early if preserve-libs is disabled
and the preserve-libs registry is empty.
* Make dblink._find_unused_preserved_libs() return early if the
preserve-libs registry is empty.
Zac Medico [Fri, 20 Aug 2010 16:09:39 +0000 (09:09 -0700)]
Stop using the myroot arguments to the dblink constructor, merge(),
and unmerge(). Use settings['ROOT'] instead. This helps avoid confusion
given support for EROOT.
Zac Medico [Fri, 20 Aug 2010 15:21:16 +0000 (08:21 -0700)]
* Fix EROOT handling in various places in vartree.py. It should be
all fixed now, but needs testing.
* Remove unused root parameter in calls to dblink.isowner() and
_match_contents().
* Make doebuild_environment() and prepare_build_dirs() take keyword
arguments, and ignore unused parameters. Especially don't use
myroot parameters since they are confusing given EROOT support.
Zac Medico [Fri, 20 Aug 2010 14:04:13 +0000 (07:04 -0700)]
Fix LinkageMap to use vardbapi._eroot instead of _root.
Zac Medico [Fri, 20 Aug 2010 14:02:32 +0000 (07:02 -0700)]
Don't pass the myroot parameter to *counter_tick* methods since it's
ignored anyway.
Zac Medico [Fri, 20 Aug 2010 13:43:16 +0000 (06:43 -0700)]
Make the portagetree.root attribute a property that generates a
DeprecationWarning on access.
Zac Medico [Fri, 20 Aug 2010 13:22:42 +0000 (06:22 -0700)]
Remove unused clone paramter from vartree constructor (support and
deprecation warning were already removed in commit
c0ee69585bf87e09c237668531127e79e0cd1c46).
Zac Medico [Fri, 20 Aug 2010 12:50:45 +0000 (05:50 -0700)]
Fix typo in comment.
Sebastian Luther [Fri, 20 Aug 2010 10:54:05 +0000 (12:54 +0200)]
--autounmask: If we can't do a change because of REQUIRED_USE, give at least a good error message
Sebastian Luther [Fri, 20 Aug 2010 10:17:19 +0000 (12:17 +0200)]
--autounmask: Don't do use changes if they violate REQUIRED_USE
This also fixes some pkg.use.enabled / _pkg_use_enabled(pkg) bugs
Sebastian Luther [Fri, 20 Aug 2010 08:34:05 +0000 (10:34 +0200)]
slot collision handler: Drop solutions that violate REQUIRED_USE
Sebastian Luther [Fri, 20 Aug 2010 07:54:19 +0000 (09:54 +0200)]
slot collision handler: Work correctly with --autounmask
Sebastian Luther [Fri, 20 Aug 2010 07:24:46 +0000 (09:24 +0200)]
circular dependency handler: Add support for REQUIRED_USE
Sebastian Luther [Fri, 20 Aug 2010 07:19:17 +0000 (09:19 +0200)]
Add portage.dep.get_required_use_flags to extract the use flags used in a REQUIRED_USE string
Sebastian Luther [Fri, 20 Aug 2010 06:24:05 +0000 (08:24 +0200)]
circular dependency handler: Small code clean ups
Zac Medico [Fri, 20 Aug 2010 05:56:26 +0000 (22:56 -0700)]
Make the make.globals path relative to EPREFIX, and add comments possible
alternative behavior for target systems.
Zac Medico [Fri, 20 Aug 2010 04:52:58 +0000 (21:52 -0700)]
Fix BinTestCase instances to stop leaving orphan temp dirs.
Zac Medico [Fri, 20 Aug 2010 04:28:10 +0000 (21:28 -0700)]
Add experimental EPREFIX/EROOT support to the config and vartree
classes, and use it in ResolverPlayground to emulate a prefix-like
environment. This fixes ResolverPlayground so that it doesn't have
to abuse the --root and --root-deps options in order to create a
testing environment. Instead it simply creates a temporary EPREFIX.
WARNING: EPREFIX/EROOT support is experimental and may be incomplete
for cases in which EPREFIX is non-empty.
Zac Medico [Fri, 20 Aug 2010 01:46:12 +0000 (18:46 -0700)]
Stop trying to read /etc/make.globals because it's been a symlink to
/usr/share/portage/config/make.globals since portage-2.1.6.
Zac Medico [Fri, 20 Aug 2010 01:42:24 +0000 (18:42 -0700)]
Update docs, comments, and messages to refer to make.globals in
/usr/share/portage/config/ instead of /etc/make.globals.
Zac Medico [Fri, 20 Aug 2010 00:05:53 +0000 (17:05 -0700)]
Rename the bdeps_root variable to depend_root, since it's used to control
DEPEND and in the future we may have separate build-time dep types for
host and target.
Zac Medico [Fri, 20 Aug 2010 00:01:16 +0000 (17:01 -0700)]
Eliminate the bdeps_optional variables inside depgraph._add_pkg_deps(),
and use the pkg.built attribute instead.
Sebastian Luther [Thu, 19 Aug 2010 22:56:27 +0000 (00:56 +0200)]
Tests: Properly test the circular dep handler
Sebastian Luther [Thu, 19 Aug 2010 22:55:46 +0000 (00:55 +0200)]
Tests: ResolverPlayground: Support checking the suggestions given by the circular dep handler.
Sebastian Luther [Thu, 19 Aug 2010 22:54:34 +0000 (00:54 +0200)]
Move the clever parts of depgraph._show_circular_deps into its own module.
This also fixes some bugs related to autounmask.
Sebastian Luther [Thu, 19 Aug 2010 13:10:40 +0000 (15:10 +0200)]
cycle-finder: Don't try to change flags that are in use.{make,focrce}
Zac Medico [Thu, 19 Aug 2010 08:58:27 +0000 (01:58 -0700)]
Move code from EbuildProcess to EbuildPhase.
Zac Medico [Thu, 19 Aug 2010 08:54:16 +0000 (01:54 -0700)]
Raise ValueError if fromlist contains an extra comma.
Zac Medico [Thu, 19 Aug 2010 07:34:36 +0000 (00:34 -0700)]
Remove duplicate attributes from __slots__.
Zac Medico [Thu, 19 Aug 2010 06:31:49 +0000 (23:31 -0700)]
* In helpers_die arguments, display ${0##*/} instead of $0 since $0
is needlessly long.
* When calling helpers_die from a function, use ${FUNCNAME[0]} in
arguments instead of $0.
Zac Medico [Thu, 19 Aug 2010 00:52:10 +0000 (17:52 -0700)]
Use doebuild_environment() to ensure proper environment initialization
for clean/cleanrm phases, and use the simpler _spawn_phase() function
instead of doebuild to spawn the phases.
Zac Medico [Thu, 19 Aug 2010 00:26:23 +0000 (17:26 -0700)]
Use simpler _spawn_phase() instead of doebuild() since
doebuild_environment() already done the env setup.
Zac Medico [Thu, 19 Aug 2010 00:08:59 +0000 (17:08 -0700)]
Move the code from _prepare_env_file() to a new BinpkgEnvExtractor
class.
Zac Medico [Wed, 18 Aug 2010 22:42:58 +0000 (15:42 -0700)]
Remove unnecessary call to _prepare_env_file(), since it only makes
sense for binary or installed packages.
Zac Medico [Wed, 18 Aug 2010 22:31:29 +0000 (15:31 -0700)]
Move environment sanity check to the Scheduler and do it if there
are any source packages in the merge list.
Zac Medico [Wed, 18 Aug 2010 21:53:44 +0000 (14:53 -0700)]
When suggesting solutions inside _show_circular_deps(), ignore solutions
that involve changes to use.mask or use.force settings.
Zac Medico [Wed, 18 Aug 2010 20:49:52 +0000 (13:49 -0700)]
Fix get_cycles() to handle None return value from shortest_path().
Zac Medico [Wed, 18 Aug 2010 20:45:19 +0000 (13:45 -0700)]
Fix deprecation warnings from paren_reduce.
Sebastian Luther [Wed, 18 Aug 2010 20:08:58 +0000 (22:08 +0200)]
Fix small bug in _show_circular_deps and add some tests
Sebastian Luther [Wed, 18 Aug 2010 19:40:26 +0000 (21:40 +0200)]
portage.util.digraph: Raise KeyError in newly added functions. Add tests.
Sebastian Luther [Wed, 18 Aug 2010 17:42:11 +0000 (19:42 +0200)]
extract_affecting_use: Fix the same bug as in use_reduce
Sebastian Luther [Mon, 14 Jun 2010 12:37:59 +0000 (14:37 +0200)]
_show_circular_deps: Ignore solution that violate use dpendencies specified by parents. Warn the user if there are many cycles.
Sebastian Luther [Mon, 14 Jun 2010 09:53:38 +0000 (11:53 +0200)]
_show_circular_deps: Stop prunning the graph to show (other) parents of the involved packages in the merge list
Sebastian Luther [Mon, 14 Jun 2010 09:51:44 +0000 (11:51 +0200)]
_show_circular_deps: Fix handling of 'None' returned by extract_affecting_use and remove debug output
Sebastian Luther [Fri, 11 Jun 2010 09:26:43 +0000 (11:26 +0200)]
_emerge.depgraph._show_circular_deps(): Find suggestions if an atom occures more than once in a dep string
Sebastian Luther [Tue, 8 Jun 2010 18:29:15 +0000 (20:29 +0200)]
Print suggestions for circular dependencies
Sebastian Luther [Tue, 8 Jun 2010 12:00:38 +0000 (14:00 +0200)]
_emerge.depgraph._show_circular_deps(): Display only the smallest cycle
Sebastian Luther [Tue, 8 Jun 2010 11:59:41 +0000 (13:59 +0200)]
portage.util.digraph: Add get_cycles() and its helpers shortest_path() and bfs()
Sebastian Luther [Wed, 18 Aug 2010 16:44:08 +0000 (18:44 +0200)]
Tests: Make sure the ResolverPlayground doesn't ignore DEPEND
Sebastian Luther [Wed, 18 Aug 2010 16:43:20 +0000 (18:43 +0200)]
Tests: ResolverPlaygound: change --root-deps parameter to include build time deps
Zac Medico [Wed, 18 Aug 2010 20:01:54 +0000 (13:01 -0700)]
Use _prepare_env_file() to extract the binary package environment.bz2
prior to the pkg_setup phase. This fixes a regression since EbuildPhase
no longer calls doebuild(), and therefore _prepare_env_file() needs
to be called now.
Zac Medico [Wed, 18 Aug 2010 19:26:19 +0000 (12:26 -0700)]
Use _prepare_env_file() to extract environment.bz2 prior to the
pkg_prerm phase. This fixes a regression since EbuildPhase no
longer calls doebuild(), and therefore _prepare_env_file() needs
to be called now.
Zac Medico [Wed, 18 Aug 2010 14:37:28 +0000 (07:37 -0700)]
Bug #324075 - If the vcs doesn't preserve mtimes then disable the
copyright date check unless the ebuild has just been added or
modified.
Sebastian Luther [Wed, 18 Aug 2010 13:50:53 +0000 (15:50 +0200)]
check_required_use: Fix the same bug as in use_reduce
Sebastian Luther [Wed, 18 Aug 2010 13:33:55 +0000 (15:33 +0200)]
paren_reduce: Fix the same bug as in use_reduce
Sebastian Luther [Wed, 18 Aug 2010 13:19:24 +0000 (15:19 +0200)]
Revert "Tests: Remove paren_reduce tests"
This reverts commit
67f3bef9efeff7061765edc9515a97143c2f2e55.
Zac Medico [Wed, 18 Aug 2010 13:36:21 +0000 (06:36 -0700)]
* Replace config._iuse_implicit_re with a callable _iuse_implicit_match
object that simply returns boolean, and update consumers.
* Make check_required_use() take a callable for the iuse parameter,
and pass in Package.use.is_valid_flag or iuse.__contains__ as
appropriate.
Sebastian Luther [Wed, 18 Aug 2010 12:58:19 +0000 (14:58 +0200)]
use_reduce: code cleanup
Zac Medico [Wed, 18 Aug 2010 12:21:28 +0000 (05:21 -0700)]
Bug #312085 - Make config.setcpv() treat USE_EXPAND_HIDDEN flags as if
they are in IUSE. This helps for the embedded profile which does not have
typical use.force/use.mask settings. The flags are matched with a regular
expression and match results are memoized in order to optimize performance.
Zac Medico [Wed, 18 Aug 2010 12:07:12 +0000 (05:07 -0700)]
Bug #308933 - Export os.path.realpath(PORTAGE_TMPDIR), to make sandbox
happy.
Zac Medico [Wed, 18 Aug 2010 11:24:01 +0000 (04:24 -0700)]
Remove unused iuse_implicit attribute.
Zac Medico [Wed, 18 Aug 2010 10:48:06 +0000 (03:48 -0700)]
Add opconvert test for "|| ( ( A B ) C )".
Zac Medico [Wed, 18 Aug 2010 10:24:13 +0000 (03:24 -0700)]
Fix use_reduce() to correctly handle "|| ( ( A B ) C )", and also
fix some test cases that had erroneous expected_result values.
Zac Medico [Wed, 18 Aug 2010 07:29:05 +0000 (00:29 -0700)]
Add commented test case for a known regression.
Zac Medico [Tue, 17 Aug 2010 20:22:35 +0000 (13:22 -0700)]
Temporarily disable portage.dep deprecation warnings for external api
consumers. Once the relevant api changes are in a portage release with
stable keywords, make these warnings unconditional.
Zac Medico [Tue, 17 Aug 2010 18:55:13 +0000 (11:55 -0700)]
Use binarytree._ensure_dir() to create the binpkg parent dir.
Zac Medico [Tue, 17 Aug 2010 18:41:34 +0000 (11:41 -0700)]
Use binarytree._ensure_dir() to create the binpkg parent dir.
Zac Medico [Tue, 17 Aug 2010 18:24:15 +0000 (11:24 -0700)]
Fix breakage in REPLACING_VERSIONS support for emerge.
Zac Medico [Tue, 17 Aug 2010 18:00:15 +0000 (11:00 -0700)]
Add pretend to actionmap_deps.
Zac Medico [Tue, 17 Aug 2010 17:55:21 +0000 (10:55 -0700)]
Fix the REPLACING_VERSIONS code to work in cases when the pretend/setup
phases are pulled in as dependencies of other phases.
Zac Medico [Tue, 17 Aug 2010 17:30:12 +0000 (10:30 -0700)]
Discard REPLACING_VERSIONS and REPLACED_BY_VERSION when they are no
longer needed.
Zac Medico [Tue, 17 Aug 2010 16:42:20 +0000 (09:42 -0700)]
Use EbuildPhase instead of EbuildProcess, for things like die_hooks
support.
Zac Medico [Tue, 17 Aug 2010 16:35:41 +0000 (09:35 -0700)]
Make EbuildBinpkg inherit from CompositeTask since the EbuildPhase
class is capable of executing the 'package' phase.
Arfrever Frehtes Taifersar Arahesis [Tue, 17 Aug 2010 15:50:56 +0000 (17:50 +0200)]
Remove no longer needed code.
Zac Medico [Tue, 17 Aug 2010 14:38:13 +0000 (07:38 -0700)]
Tweak the EbuildSpawnProcess test and add comments.
Zac Medico [Tue, 17 Aug 2010 14:18:30 +0000 (07:18 -0700)]
Make EbuildBinpkg inherit from EbuildProcess since the 'package'
phase is already a member of actionmap.
Zac Medico [Tue, 17 Aug 2010 14:03:23 +0000 (07:03 -0700)]
Pass actionmap keyword argument as keyword, rather than positional.
Zac Medico [Tue, 17 Aug 2010 13:54:42 +0000 (06:54 -0700)]
Write compiled bytecodes to /dev/null, rather than write and unlink
them.
Zac Medico [Tue, 17 Aug 2010 13:43:31 +0000 (06:43 -0700)]
Fix _spawn_phase() to pass actionmap to EbuildPhase.
Zac Medico [Tue, 17 Aug 2010 13:39:17 +0000 (06:39 -0700)]
Unify ebuild spawing some more. All proper ebuild phases which execute
ebuild.sh are spawned via _doebuild_spawn() now. No exceptions.
Zac Medico [Tue, 17 Aug 2010 08:22:58 +0000 (01:22 -0700)]
Fix _spawn_phase() to spawn phases without sandbox when necessary.
Zac Medico [Tue, 17 Aug 2010 07:58:44 +0000 (00:58 -0700)]
Source isolated-functions.sh for helpers_die function.
Zac Medico [Tue, 17 Aug 2010 07:48:23 +0000 (00:48 -0700)]
Make doebuild() use EbuildPhase to execute all phase (unless returnpid
is True, which is only for the "depend" phase now).
Zac Medico [Tue, 17 Aug 2010 07:23:36 +0000 (00:23 -0700)]
Make sure doebuild() doesn't erroneously unlink a logfile when returnpid
is True.
Zac Medico [Tue, 17 Aug 2010 05:38:49 +0000 (22:38 -0700)]
Make EbuildBuild check the manifest before beginning, since with
--keep-going mode it's currently possible to get this far with a
broken manifest.
Zac Medico [Tue, 17 Aug 2010 04:52:31 +0000 (21:52 -0700)]
For ebuilds from $ROOT/var/db/pkg, don't give /var/db/pkg with the
"Appending /var/db/pkg to PORTDIR_OVERLAY..." treatment.