Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 568640 - dev-qt/qt-creator-3.6.0: estack_push: command not found
Summary: dev-qt/qt-creator-3.6.0: estack_push: command not found
Status: RESOLVED INVALID
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Unspecified (show other bugs)
Hardware: AMD64 Linux
: Normal normal with 2 votes (vote)
Assignee: Davide Pesavento
URL:
Whiteboard:
Keywords:
: 571164 571320 (view as bug list)
Depends on:
Blocks:
 
Reported: 2015-12-18 14:50 UTC by Stefan Böhmann
Modified: 2016-02-26 21:13 UTC (History)
5 users (show)

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


Attachments
qt-creator ebuild environment file (environment,83.17 KB, text/plain)
2015-12-21 18:55 UTC, Dmitry Nikulin
Details
environment file (environment,83.35 KB, text/plain)
2015-12-21 23:32 UTC, Stefan Böhmann
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Stefan Böhmann 2015-12-18 14:50:15 UTC
dev-qt/qt-creator-3.6.0 compiles fine but could not be installed:
install -m 644 -p /var/tmp/portage/dev-qt/qt-creator-3.6.0/work/qt-creator-opensource-src-3.6.0/share/qtcreator/cplusplus/wrappedQtHeaders/QtCore/qobjectdefs.h /var/tmp/portage/dev-qt/qt-creator-3.6.0/image/usr/share/qtcreator/cplusplus/wrappedQtHeaders/QtCore/
make[2]: Leaving directory '/var/tmp/portage/dev-qt/qt-creator-3.6.0/work/qt-creator-opensource-src-3.6.0/share/qtcreator'
make[1]: Leaving directory '/var/tmp/portage/dev-qt/qt-creator-3.6.0/work/qt-creator-opensource-src-3.6.0/share'
/var/tmp/portage/dev-qt/qt-creator-3.6.0/temp/environment: line 839: estack_push: command not found
/var/tmp/portage/dev-qt/qt-creator-3.6.0/temp/environment: line 828: estack_pop: command not found
 * ERROR: dev-qt/qt-creator-3.6.0::gentoo failed (install phase):
 *   eshopts_pop: unbalanced push
 * 
 * Call stack:
 *     ebuild.sh, line  133:  Called src_install
 *   environment, line 2051:  Called make_desktop_entry 'qtcreator' 'Qt Creator' 'QtProject-qtcreator' 'Qt;Development;IDE'
 *   environment, line 1525:  Called eshopts_pop
 *   environment, line  828:  Called die
 * The specific snippet of code:
 *       estack_pop eshopts s || die "${FUNCNAME}: unbalanced push";
 * 
 * If you need support, post the output of `emerge --info '=dev-qt/qt-creator-3.6.0::gentoo'`,
 * the complete build log and the output of `emerge -pqv '=dev-qt/qt-creator-3.6.0::gentoo'`.
 * The complete build log is located at '/var/tmp/portage/dev-qt/qt-creator-3.6.0/temp/build.log'.
 * The ebuild environment file is located at '/var/tmp/portage/dev-qt/qt-creator-3.6.0/temp/environment'.
 * Working directory: '/var/tmp/portage/dev-qt/qt-creator-3.6.0/work/qt-creator-opensource-src-3.6.0'
 * S: '/var/tmp/portage/dev-qt/qt-creator-3.6.0/work/qt-creator-opensource-src-3.6.0'
 * QA Notice: command not found:
 * 
 *      /var/tmp/portage/dev-qt/qt-creator-3.6.0/temp/environment: line 839: estack_push: command not found
 *      /var/tmp/portage/dev-qt/qt-creator-3.6.0/temp/environment: line 828: estack_pop: command not found



Reproducible: Always
Comment 1 Davide Pesavento gentoo-dev 2015-12-18 16:03:25 UTC
The real errors are

/var/tmp/portage/dev-qt/qt-creator-3.6.0/temp/environment: line 839: estack_push: command not found
/var/tmp/portage/dev-qt/qt-creator-3.6.0/temp/environment: line 828: estack_pop: command not found

However this is very weird.
make_desktop_entry() calls those functions, and they are defined in the same eclass... I'm confused.
Comment 2 Davide Pesavento gentoo-dev 2015-12-19 14:28:04 UTC
Attach your environment file please.
Comment 3 Dmitry Nikulin 2015-12-21 18:55:47 UTC
Created attachment 420060 [details]
qt-creator ebuild environment file
Comment 4 Stefan Böhmann 2015-12-21 23:32:45 UTC
Created attachment 420110 [details]
environment file

This is my environment file from /var/tmp/portage/dev-qt/qt-creator-3.6.0/temp/environment
Comment 5 Dmitry Nikulin 2015-12-26 16:04:15 UTC
Strange, but when I change EAPI=6 to EAPI=5 in ebuild, it works.
Comment 6 Davide Pesavento gentoo-dev 2016-01-07 23:25:55 UTC
Your env file contains the following function:

pre_src_prepare () 
{ 
    if ! type epatch_user > /dev/null 2>&1; then
        local names="epatch_user epatch evar_push evar_push_set evar_pop estack_push estack_pop";
        source <(awk "/^# @FUNCTION: / { p = 0 } /^# @FUNCTION: (${names// /|})\$/ { p = 1; } p { print  }" /usr/portage/eclass/eutils.eclass);
    fi;
    epatch_user;
    for name in $names;
    do
        unset $name;
    done
}

Where does it come from?
Comment 7 Jaak Ristioja 2016-01-08 00:01:35 UTC
(In reply to Davide Pesavento from comment #6)
> Where does it come from?

https://wiki.gentoo.org/wiki//etc/portage/patches
Comment 8 Igor Poboiko 2016-01-08 00:04:17 UTC
(In reply to Davide Pesavento from comment #6)
> Your env file contains the following function:
> 
> pre_src_prepare () 
> { 
>     if ! type epatch_user > /dev/null 2>&1; then
>         local names="epatch_user epatch evar_push evar_push_set evar_pop
> estack_push estack_pop";
>         source <(awk "/^# @FUNCTION: / { p = 0 } /^# @FUNCTION: (${names//
> /|})\$/ { p = 1; } p { print  }" /usr/portage/eclass/eutils.eclass);
>     fi;
>     epatch_user;
>     for name in $names;
>     do
>         unset $name;
>     done
> }
> 
> Where does it come from?

Actually, I have the same problem, and I also have the same code snippet in my /etc/portage/bashrc (also from https://wiki.gentoo.org/wiki//etc/portage/patches).
If it is related to this issue (I can't check it right now), then the article should either be changed (so method works again) or marked as outdated.
Comment 9 Davide Pesavento gentoo-dev 2016-01-08 01:09:04 UTC
That bashrc snippet is no longer needed (in fact it should be considered harmful) with EAPI=6 ebuilds. This bug is invalid.

Cc'ing portage team as they might want to know about this.
Comment 10 Davide Pesavento gentoo-dev 2016-01-08 01:10:43 UTC
*** Bug 571164 has been marked as a duplicate of this bug. ***
Comment 11 Pavel Šimerda 2016-01-08 09:37:46 UTC
(In reply to Davide Pesavento from comment #9)
> That bashrc snippet is no longer needed (in fact it should be considered
> harmful) with EAPI=6 ebuilds.

I will have to test as the scriptlet worked in the best phase for upstream patches. Could you please provide a link to docs for the new features so that one can see whether it is at least as useful as the scriptlet?

> This bug is invalid.

Non sequitur. You were talking about EAPI=6 but I seriously doubt all ebuilds are now using the new EAPI.

I would like to fix and comment the scriptlet accordingly but I unfortunately don't have the time for testing right now.
Comment 12 Pavel Šimerda 2016-01-08 11:56:08 UTC
I'm not getting the same errors. I'm using portage 2.2.26. Do I need to update anything else to see it?
Comment 13 Davide Pesavento gentoo-dev 2016-01-08 12:39:43 UTC
(In reply to Pavel Šimerda (pavlix) from comment #11)
> (In reply to Davide Pesavento from comment #9)
> > That bashrc snippet is no longer needed (in fact it should be considered
> > harmful) with EAPI=6 ebuilds.
> 
> I will have to test as the scriptlet worked in the best phase for upstream
> patches. Could you please provide a link to docs for the new features so
> that one can see whether it is at least as useful as the scriptlet?
> 

https://projects.gentoo.org/pms/6/pms.html#x1-13600011.3.3.7

In case people haven't noticed the problem yet, the scriptlet unsets random functions such as estack_push.

> > This bug is invalid.
> 
> Non sequitur. You were talking about EAPI=6 but I seriously doubt all
> ebuilds are now using the new EAPI.
> 

The bug happens only on EAPI=6 ebuilds. The number of ebuilds using EAPI 6 doesn't change the fact that it's invalid. The mere fact that the bug is triggered by a bashrc snippet makes it invalid.
Comment 14 George Diamantopoulos 2016-01-11 14:51:46 UTC
*** Bug 571320 has been marked as a duplicate of this bug. ***
Comment 15 Davide Pesavento gentoo-dev 2016-01-17 21:32:10 UTC
IIRC calling eapply_user is mandatory in EAPI 6, so the hack described in https://wiki.gentoo.org/wiki//etc/portage/patches is completely unnecessary for EAPI 6 ebuilds.

Assuming the $EAPI variable is available when portage bashrc is sourced (I would assume it is), the snippet can be "fixed" by adding the following line at the *beginning* of pre_src_prepare():

    [[ ${EAPI:-0} == [012345] ]] || return
Comment 16 selurvedu 2016-01-24 03:04:36 UTC
(In reply to Davide Pesavento from comment #15)
> 
>     [[ ${EAPI:-0} == [012345] ]] || return

Thanks, looks like this neutralizes the issue completely. Should this be present on the wiki page instead of a warning?
Comment 17 Michael Palimaka (kensington) gentoo-dev 2016-01-24 08:49:10 UTC
(In reply to selurvedu from comment #16)
> (In reply to Davide Pesavento from comment #15)
> > 
> >     [[ ${EAPI:-0} == [012345] ]] || return
> 
> Thanks, looks like this neutralizes the issue completely. Should this be
> present on the wiki page instead of a warning?

Sure. I've updated it for now, but please always feel free to edit the wiki.
Comment 18 Derk W te Bokkel 2016-02-26 21:13:49 UTC
bug #575074 also has same issue .. with .. the unset portion removed the script seems less toxic .. i.e. does not clobber existing eutil.eclass containing builds