Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 670558 - portageq eclass_path fails with eroot parameter
Summary: portageq eclass_path fails with eroot parameter
Alias: None
Product: Portage Development
Classification: Unclassified
Component: Core (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Portage team
Depends on:
Reported: 2018-11-06 20:48 UTC by Bruce Schultz
Modified: 2018-11-07 00:39 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---

demonstrates a number of test case (,4.26 KB, application/x-shellscript)
2018-11-06 20:51 UTC, Bruce Schultz

Note You need to log in before you can comment on or make changes to this bug.
Description Bruce Schultz 2018-11-06 20:48:09 UTC
portageq eclass_path always searches in the host repo, even when the eroot parameter is provided.

In this case, it is not as simple as overriding the configroot for the eclass_path command. Although that then does map to the correct repo, portage fails to find the eclass within that repo unless the repo path provided in the eroot is relative to the host's root.

Reproducible: Always

Steps to Reproduce:
The following script demonstrates the problem:
mkdir -p /tmp/portageq/etc/portage
cat > /tmp/portageq/etc/portage/repos.conf <<EOF
location = /var/blah/gentoo
mkdir -p /tmp/portageq/var/blah/gentoo/eclass
touch /tmp/portageq/var/blah/gentoo/eclass/user.eclass
portageq --version
portageq eclass_path /tmp/portageq gentoo user

A more comprehensive test script will be attached

Actual Results:  
Portage 2.3.49

It always locates an eclass within the host's repos.

However, when portageq is modified with @uses_configroot for eclass_path, the output is blank.

Expected Results:  
Should always be able to find the eclass within the eroot repo.

I expect the example above should output:
Comment 1 Bruce Schultz 2018-11-06 20:51:54 UTC
Created attachment 554322 [details]
demonstrates a number of test case

To use the system installed portageq, run the test as:


To run with a modified portageq, define a portageq variable pointing to that instance; eg:

portageq=./portageq ./