Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 926868 - postgres-multi.eclass calls eapply_user after ebuild src_prepare possibly runs autoconf; doesn't handle PATCHES
Summary: postgres-multi.eclass calls eapply_user after ebuild src_prepare possibly run...
Status: CONFIRMED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Eclasses (show other bugs)
Hardware: All Linux
: Normal normal
Assignee: PgSQL Bugs
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2024-03-13 02:00 UTC by Eli Schwartz
Modified: 2024-08-11 21:24 UTC (History)
1 user (show)

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


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Eli Schwartz gentoo-dev 2024-03-13 02:00:54 UTC
postgres-multi_src_prepare() {

        [sanity checks]

        eapply_user

        multibuild_copy_sources
}

Its job is, largely, to copy sources. Individual ebuilds *may* override src_prepare, in which case they finish it off by calling postgres-multi_src_prepare to get the sources copied.

An individual ebuild src_prepare can do *anything*, including things that have to happen after a user patch is applied. Also, eapply_user was likely wrong all along, because it should have used "default" to also apply PATCHES=().

Due to the ordering requirements, namely that individual ebuilds have to be able to apply logic in between PATCHES/eapply_user and the final source copying, this problem is, I believe, unfixable given the current design.

It should be replaced with a new ability for ebuilds to define a postgres_prepare_all function which will be called by ${ECLASS}_src_prepare.

This would then be used as a hook by ebuilds that want to interject additional logic after patches have been handled.