Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 692024 - portage-2.3.71: econf should die on error in EAPIs 0 to 3
Summary: portage-2.3.71: econf should die on error in EAPIs 0 to 3
Status: RESOLVED FIXED
Alias: None
Product: Portage Development
Classification: Unclassified
Component: Core - Ebuild Support (show other bugs)
Hardware: All Linux
: Normal normal
Assignee: Portage team
URL:
Whiteboard:
Keywords: InVCS
Depends on:
Blocks: 563798 691278
  Show dependency tree
 
Reported: 2019-08-12 20:46 UTC by Ulrich Müller
Modified: 2022-04-14 03:15 UTC (History)
0 users

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


Attachments
econf: Unconditionally die on error in EAPIs 0 to 3. (0001-econf-Unconditionally-die-on-error-in-EAPIs-0-to-3.patch,1.14 KB, patch)
2019-08-12 21:00 UTC, Ulrich Müller
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Ulrich Müller gentoo-dev 2019-08-12 20:46:29 UTC
PMS says in https://projects.gentoo.org/pms/7/pms.html#x1-12800012.3.8:
"econf [...] Should any portion of it fail, it must abort the build using die, unless run using nonfatal, in which case it must return non-zero exit status."

So:
- In EAPIs without nonfatal (i.e. 0 to 3), econf must die on error.
- In EAPIs with nonfatal (i.e. 4 to 7), econf must die on error, unless called with nonfatal.

Current behaviour is correct in EAPIs 4 to 7, but not in EAPIs 0 to 3. Especially, this means that there is no error checking at all in default src_configure or src_compile.

(For the non-believers: PMS from 2009, i.e. EAPI 2, said: "Should any portion of it fail, it must abort the build using die." https://projects.gentoo.org/pms/2/pms.pdf)
Comment 1 Ulrich Müller gentoo-dev 2019-08-12 21:00:24 UTC
Created attachment 586694 [details, diff]
econf: Unconditionally die on error in EAPIs 0 to 3.
Comment 2 Larry the Git Cow gentoo-dev 2019-08-14 02:19:03 UTC
The bug has been referenced in the following commit(s):

https://gitweb.gentoo.org/proj/portage.git/commit/?id=06756a72592e621c8f071e5d17c5c79136e31155

commit 06756a72592e621c8f071e5d17c5c79136e31155
Author:     Ulrich Müller <ulm@gentoo.org>
AuthorDate: 2019-08-12 20:58:17 +0000
Commit:     Zac Medico <zmedico@gentoo.org>
CommitDate: 2019-08-14 02:10:13 +0000

    econf: Unconditionally die on error in EAPIs 0 to 3.
    
    As specified by PMS: "econf [...] Should any portion of it fail, it
    must abort the build using die, unless run using nonfatal, in which
    case it must return non-zero exit status."
    https://projects.gentoo.org/pms/7/pms.html#x1-12800012.3.8
    
    Bug: https://bugs.gentoo.org/692024
    Signed-off-by: Ulrich Müller <ulm@gentoo.org>
    Signed-off-by: Zac Medico <zmedico@gentoo.org>

 bin/phase-helpers.sh | 2 ++
 1 file changed, 2 insertions(+)
Comment 3 Zac Medico gentoo-dev 2019-08-14 02:19:41 UTC
Thanks!
Comment 4 Larry the Git Cow gentoo-dev 2019-08-19 05:06:55 UTC
The bug has been referenced in the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=08557524dc6c8eec3a366e43ab2587d2cdd8f133

commit 08557524dc6c8eec3a366e43ab2587d2cdd8f133
Author:     Zac Medico <zmedico@gentoo.org>
AuthorDate: 2019-08-19 04:24:07 +0000
Commit:     Zac Medico <zmedico@gentoo.org>
CommitDate: 2019-08-19 05:06:15 +0000

    sys-apps/portage: Bump to version 2.3.72
    
     #463952 glsa-check: install in /usr/bin
     #646090 preserve-libs: get dep graph from EROOT
     #690484 detect internal collisions for /usr merge
     #690786 repoman: support metadata/layout.conf restrict-allowed
     #691776 unpack: Unconditionally die if an unpacker returns an error
     #691638 Show get/setfattr stderr
     #692024 econf: Unconditionally die on error in EAPIs 0 to 3
     #692262 QA Notice: EXPORT_FUNCTIONS is called before inherit in
             kernel-2.eclass
     #692412 emerge IndexError for ambiguous package atom with pypy
    
    Bug: https://bugs.gentoo.org/691278
    Bug: https://bugs.gentoo.org/463952
    Bug: https://bugs.gentoo.org/646090
    Bug: https://bugs.gentoo.org/690484
    Bug: https://bugs.gentoo.org/690786
    Bug: https://bugs.gentoo.org/691776
    Bug: https://bugs.gentoo.org/691638
    Bug: https://bugs.gentoo.org/692024
    Bug: https://bugs.gentoo.org/692262
    Bug: https://bugs.gentoo.org/692412
    Package-Manager: Portage-2.3.71, Repoman-2.3.17
    Signed-off-by: Zac Medico <zmedico@gentoo.org>

 sys-apps/portage/Manifest              |   1 +
 sys-apps/portage/portage-2.3.72.ebuild | 264 +++++++++++++++++++++++++++++++++
 2 files changed, 265 insertions(+)