Summary: | app-admin/eselect-1.0.11-r1 portageq portdir called from inside profile.eselect returns nothing | ||
---|---|---|---|
Product: | Gentoo Linux | Reporter: | Steen Eugen "Miravlix" Poulsen <sep> |
Component: | Current packages | Assignee: | Portage team <dev-portage> |
Status: | RESOLVED INVALID | ||
Severity: | normal | CC: | timmy |
Priority: | High | ||
Version: | unspecified | ||
Hardware: | x86 | ||
OS: | Linux | ||
Whiteboard: | |||
Package list: | Runtime testing required: | --- |
Description
Steen Eugen "Miravlix" Poulsen
2008-09-21 12:01:12 UTC
This is really starting to bug me, I have several machines that gets nothing when they call portageq. Latest example. icecream calls gcc-config when it's setting up, but if python -V &>/dev/null ; then export REAL_CHOST=$(env -i portageq envvar CHOST 2>/dev/null) fi This code fails from inside the script. env -i portageq envvar CHOST returns nothing, but works fine on the command line. I keep having to add stupid work arounds like, like here where I instead of an else, made another if checking if REAL_CHOST actually got populated with the above code. if [[ -z ${REAL_CHOST} ]] ; then ewarn "Python seems to be broken, attempting to locate CHOST ourselves ..." export REAL_CHOST=$(try_real_hard_to_find_CHOST) fi This latest failure is a freshly 100% handbook 64 bit Gentoo, I just created in a virtual machine and I can't for the life of me explain why portageq doesn't work from scripts. I can't reproduce this, must have been an improperly assigned portage bug. %% cat tmp/test.sh if python -V &>/dev/null ; then echo $(env -i portageq envvar CHOST 2>/dev/null) fi %% bash !$ bash tmp/test.sh x86_64-pc-linux-gnu |