summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* autotools.eclass: simplify WANT_AUTOCONF logicMike Gilbert5 days1-17/+4
| | | | | | | | Update WANT_AUTOMAKE atoms to match. Drop 2.71 from _LATEST_AUTOCONF since 2.72 is stable. Closes: https://bugs.gentoo.org/948125 Signed-off-by: Mike Gilbert <floppym@gentoo.org>
* autotools.eclass: drop support for EAPI 6David Seifert2024-10-081-57/+14
| | | | Signed-off-by: David Seifert <soap@gentoo.org>
* autotools.eclass: Run eautoheader with --forceYiFei Zhu2024-09-241-1/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | To quote Eli [1] (I can't explain it better than this): autotools.eclass runs autoheader without options (and in particular without --force). This will only remake config.h.in if there are actual changes to the content, which in turn means that it will be out of date compared to aclocal.m4 (which we very much expect to have changes). So `make` sees that the header is out of date, and runs autoheader yet again, this time updating the timestamp for `make` purposes. This causes QA warning that "maintainer mode" is detected. autoheader and autoconf added --force option at the same time [2], so no reason only autoconf has that option in the eclass and not autoheader. Like, autoconf, a check on WANT_AUTOCONF != 2.1 is added because the feature was added in autoconf 2.52. [1] https://bugs.gentoo.org/939468#c6 [2] https://git.savannah.gnu.org/gitweb/?p=autoconf.git;a=commitdiff;h=dbf7fc61 Closes: https://bugs.gentoo.org/939468 Closes: https://bugs.gentoo.org/939535 Signed-off-by: YiFei Zhu <zhuyifei1999@gmail.com> Closes: https://github.com/gentoo/gentoo/pull/38588 Signed-off-by: Sam James <sam@gentoo.org>
* autotools.eclass: add global-scope ewarn for deprecated < EAPI 7Sam James2024-09-081-5/+9
| | | | Signed-off-by: Sam James <sam@gentoo.org>
* autotools.eclass: crank _LATEST_AUTOMAKE to get fixed 1.17-r1Sam James2024-07-121-1/+1
| | | | Signed-off-by: Sam James <sam@gentoo.org>
* autotools.eclass: add 1.17 to _LATEST_AUTOMAKESam James2024-07-121-1/+1
| | | | Signed-off-by: Sam James <sam@gentoo.org>
* autotools.eclass: conditionalize gnuconfig dependencySam James2024-05-031-2/+6
| | | | | | | Use newly-added GNUCONFIG_DEPEND so that AUTOTOOLS_AUTO_DEPEND=no doesn't result in a useless dependency on gnuconfig. Signed-off-by: Sam James <sam@gentoo.org>
* autotools.eclass: require >=dev-build/libtool-2.4.7-r3Sam James2024-03-241-1/+1
| | | | | | | | Needed for c7012f128a3c04053924fa1e96ed48a1c758fc65 wrt upgrade ordering. Bug: https://bugs.gentoo.org/927650 Bug: https://bugs.gentoo.org/927662 Signed-off-by: Sam James <sam@gentoo.org>
* Move {sys-devel → dev-build}/libtoolMichał Górny2024-01-151-1/+1
| | | | | | Signed-off-by: Michał Górny <mgorny@gentoo.org> Closes: https://github.com/gentoo/gentoo/pull/34807 Signed-off-by: Michał Górny <mgorny@gentoo.org>
* Move {sys-devel → dev-build}/automakeMichał Górny2024-01-151-4/+4
| | | | Signed-off-by: Michał Górny <mgorny@gentoo.org>
* Move {sys-devel → dev-build}/autoconfMichał Górny2024-01-151-8/+8
| | | | Signed-off-by: Michał Górny <mgorny@gentoo.org>
* autotools.eclass: drop 2.13/2.69 from _WANT_AUTOCONFSam James2023-12-271-1/+1
| | | | | | | | | | If people want/need these, they should explicitly state it in the ebuild (although please port to a newer version!) Otherwise, we're going to be saying that autoconf-2.13 and such could satisfy all ebuilds unless they explicitly say something else which is rather unlikely. Signed-off-by: Sam James <sam@gentoo.org>
* autotools.eclass: treat 2.5 as 2.71 for nowSam James2023-12-271-1/+9
| | | | | | | | | | | Having an unbound dependency (no slot) causes all sorts of problems. Add cases for each slot. I think we should really have the slots aligned to PV and slotmove as required but let's handle that another time. This would've hidden the original bug at least. Bug: https://bugs.gentoo.org/920822 Signed-off-by: Sam James <sam@gentoo.org>
* autotools.eclass: optimize dependency generation (elide subshells)Sam James2023-12-271-2/+6
| | | | Signed-off-by: Sam James <sam@gentoo.org>
* autotools.eclass: avoid deprecated backticksSam James2023-12-271-6/+11
| | | | Signed-off-by: Sam James <sam@gentoo.org>
* autotools.eclass: rework WANT_AUTOCONF handlingSam James2023-12-271-6/+67
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | For automake, we enumerate each of the automake slots in _WANT_AUTOMAKE and use this to handle setting WANT_AUTOMAKE accordingly if the ebuild (or user, I suppose) haven't set WANT_AUTOMAKE themselves. This means that we can easily rollover to the latest installed on a system (and we also pull it in via _WANT_AUTOMAKE which is used for dependencies) because WANT_AUTOMAKE is based on the slots in _WANT_AUTOMAKE intersected with whatever is installed on the system. For autoconf, we weren't doing any of that, and were just hardcoding whatever the latest slot is! That's error prone on bumps but it also wasn't really possible to get right as-is without marking a new slot stable because of the entanglement between the dependencies, WANT_AUTOCONF, and no intersection being done (WANT_AUTOCONF wasn't dynamic at all). We now implement a similar scheme for autoconf as we already had for automake. This fixes the case where WANT_AUTOCONF="latest" in an ebuild (the default), autoconf:2.71 isn't installed, but autoconf:2.72 is. This sometimes worked before if the latest dep was slotted rather than unslotted like it is now (see below for why that's not easy to just fix) because the new slot would never get pulled in and hence the older slot which aligned with WANT_AUTOCONF's hardcoded value would be available. (I still think we should consider slotmoving older autoconfs but that's something to discuss and possibly do another time. See TODO.) Bug: https://bugs.gentoo.org/827852 Bug: https://bugs.gentoo.org/893434 Closes: https://bugs.gentoo.org/920822 Signed-off-by: Sam James <sam@gentoo.org>
* autotools.eclass: WhitespaceUlrich Müller2023-05-291-1/+0
| | | | Signed-off-by: Ulrich Müller <ulm@gentoo.org>
* autotools.eclass: Allow running the tools only in src_prepareUlrich Müller2023-05-291-1/+1
| | | | | | | | Running them in src_unpack made sense only in EAPIs 0 and 1. Fixes: 18fda95cea306efe8009d1100195225acd8f8756 Reviewed-by: Sam James <sam@gentoo.org> Signed-off-by: Ulrich Müller <ulm@gentoo.org>
* autotools.eclass: Downgrade eqawarn for renaming configure.inUlrich Müller2023-05-291-1/+1
| | | | | | | | | | | | | | | At this point, almost all upstreams will have switched to configure.ac. Therefore, configure.in is most likely an indication of an inactive upstream, and there is no reasonable way for the ebuild maintainer to silence the warning (other than the ebuild renaming the file). Keep the message as einfo, so there is still an indication that the file was renamed. Bug: https://bugs.gentoo.org/426262 Reviewed-by: Sam James <sam@gentoo.org> Reviewed-by: Pacho Ramos <pacho@gentoo.org> Signed-off-by: Ulrich Müller <ulm@gentoo.org>
* autotools.eclass: fix spellingSam James2023-03-261-1/+1
| | | | | | | Thanks to codespell. Signed-off-by: Sam James <sam@gentoo.org> Signed-off-by: Ulrich Müller <ulm@gentoo.org>
* autotools.eclass: Quote argument of ":" commandUlrich Müller2023-03-261-10/+10
| | | | | | This avoids globbing, see: https://www.shellcheck.net/wiki/SC2223 Signed-off-by: Ulrich Müller <ulm@gentoo.org>
* eclass: standardize prologue/epilogueDavid Seifert2023-03-171-9/+7
| | | | | Closes: https://github.com/gentoo/gentoo/pull/30061 Signed-off-by: David Seifert <soap@gentoo.org>
* autotools.eclass: fix autoconf 2.13 minimum boundSam James2022-11-231-1/+1
| | | | | Fixes: cece5b154234aa8c9982feae05f67df8db39e270 Signed-off-by: Sam James <sam@gentoo.org>
* autotools.eclass: depend on modern libtoolSam James2022-11-231-1/+1
| | | | | | | 2.4.7 has been stable for a while, and for older versions, we can't be sure that our elibtoolize (elt-patches) bits will work anyway. Signed-off-by: Sam James <sam@gentoo.org>
* autotools.eclass: crank up autoconf minimum versionsSam James2022-11-231-2/+2
| | | | | | | | This ensures we have versions which have Clang 16 / GCC 14 / stricter compiler fixes, so 'eautoreconf' will Do The Right Thing. Closes: https://bugs.gentoo.org/870412 Signed-off-by: Sam James <sam@gentoo.org>
* autotools.eclass: Drop support for EAPI 5Ulrich Müller2022-07-181-7/+7
| | | | Signed-off-by: Ulrich Müller <ulm@gentoo.org>
* autotools.eclass: import ::prefix automake has_version edgecase logicSam James2022-06-291-2/+12
| | | | | | | | | | | | | During bootstrapping, an automake may not exist yet (which is sometimes fine if an ebuild doesn't actually need it). Make the check non-fatal for prefix where automake doesn't yet exist inside BROOT. We could probably do a bit better here and inspect PATH but this is the logic which has been used in ::prefix for a looong time, and it's currently breaking bootstraps, so let's get it fixed. Signed-off-by: Sam James <sam@gentoo.org>
* autotools.eclass: egrep -> grep -ESam James2022-05-161-1/+1
| | | | | | Deprecated for a while but newer grep emits deprecation warnings. Signed-off-by: Sam James <sam@gentoo.org>
* autotools.eclass: drop ROOT=/ in has_version callSam James2022-04-301-1/+1
| | | | | | | | | | | | | | | | | | | Noticed when doing a read-through of the eclass (which is how I noticed c8e74a7dfe477dea008548553141f083c5d03782 too). Forcing ROOT=/ is, at best, going to confuse matters, and at worst, do entirely the wrong thing. In EAPI 5 and 6, we had --host-root (which we use in the eclass), and in EAPI 7+, we have -b/-d (which we use in the eclass too). The ROOT= setting was there for pre-EAPI 5 times. The aforementioned toggles (--host-root and then later on, -b/-d) are the correct methods to specify (B)ROOT for has_version. Using one of those with ROOT= have undefined behaviour, so drop it. Bug: https://bugs.gentoo.org/312687 Thanks-to: James Le Cuirot <chewi@gentoo.org> Thanks-to: Ulrich Müller <ulm@gentoo.org> Signed-off-by: Sam James <sam@gentoo.org>
* autotools.eclass: fix EAPI 8 conditional; simplifySam James2022-04-281-3/+3
| | | | Signed-off-by: Sam James <sam@gentoo.org>
* autotools.eclass: update automake 1.16 stable versionSam James2022-04-161-1/+1
| | | | | Closes: https://bugs.gentoo.org/833654 Signed-off-by: Sam James <sam@gentoo.org>
* autotools.eclass: don't use reserved variable (__)Sam James2022-04-121-4/+4
| | | | | Closes: https://bugs.gentoo.org/806368 Signed-off-by: Sam James <sam@gentoo.org>
* *.eclass: @ECLASS-VARIABLE renamed to @ECLASS_VARIABLEUlrich Müller2022-03-241-12/+12
| | | | | Bug: https://bugs.gentoo.org/835396 Signed-off-by: Ulrich Müller <ulm@gentoo.org>
* autotools.eclass: update for autoconf 2.71Sam James2022-01-221-2/+2
| | | | | Closes: https://bugs.gentoo.org/827852 Signed-off-by: Sam James <sam@gentoo.org>
* autotools.eclass: update for latest automake 1.16.4Sam James2022-01-221-1/+1
| | | | Signed-off-by: Sam James <sam@gentoo.org>
* autotools.eclass: use --system-acdir for aclocalSam James2022-01-221-1/+19
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | We need to instruct aclocal that it might find macros in both ${BROOT} _and_ ${SYSROOT}. - A classic example within BROOT is autoconf-archive. - A classic example within SYSROOT is, say, libogg. A fair amount of codec software installs its own macro to help locating it (but this is in no ways limited to that genre/area). The correct position for a dependency like libogg is DEPEND, and yet the status quo doesn't mean that aclocal is obligated to check in ${ESYSROOT} which is where DEPEND-class dependencies are guaranteed to be installed. We can't rely on these being in BDEPEND -- in fact, most of the time, they won't be. If we wanted to rely on macros always being provided by BDEPEND, we'd have to duplicate a considerable number of dependencies in both BDEPEND + DEPEND, with the unnecessary cross-compilation that would entail too: it makes far more sense to just tell aclocal to look in the right place (an extra location). Bug: https://bugs.gentoo.org/710792 Closes: https://bugs.gentoo.org/677002 Closes: https://bugs.gentoo.org/738918 Thanks-to: David Michael <fedora.dm0@gmail.com> (for the suggestion) Thanks-to: James Le Cuirot <chewi@gentoo.org> (rubberducking & sounding board) Signed-off-by: Sam James <sam@gentoo.org>
* autotools.eclass: don't inject -I${SYSROOT} to aclocalSam James2022-01-221-7/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When -I${SYSROOT} is injected, it'll override the default of -Im4, which results in trying to install macros to ${SYSROOT} (a sandbox violation) when they can't be found. From aclocal(1): ``` -I DIR add directory to search list for .m4 files --install copy third-party files to the first -I directory ``` The first directory is normally -Im4 if anything, whereas when injected (when ${SYSROOT} is defined), it ends up being ${SYSROOT}, not m4 (so we try to copy macros to somewhere outside of the build directory). [We could drop this just for > EAPI 7, but I'm not sure there's much point there either. As Chewi observed in bug 677002, you can't assume they'll be present in ${SYSROOT} anyway, and frankly, the cross-compilation (and --root, --sysroot, and so on) situation is rather bleak for earlier EAPIs, which is why we did all that work for 7.] Bug: https://bugs.gentoo.org/710792 Closes: https://bugs.gentoo.org/677002 Closes: https://bugs.gentoo.org/738918 Thanks-to: James Le Cuirot <chewi@gentoo.org> Signed-off-by: Sam James <sam@gentoo.org>
* autotools.eclass: mark AUTOTOOLS_DEPEND as an output variableMike Gilbert2021-10-011-1/+1
| | | | | | This variable is used in several ebuilds for optional dependencies. Signed-off-by: Mike Gilbert <floppym@gentoo.org>
* autotools.eclass: fix EAPI 8 supportSam James2021-08-151-1/+1
| | | | | | Fixes: 0d6f1fbaa1198c04f6efb5bb8be505b4394c3541 Reported-by: Joonas Niilola <juippis@gentoo.org> Signed-off-by: Sam James <sam@gentoo.org>
* autotools.eclass: add EAPI 8 supportSam James2021-07-101-2/+2
| | | | | | Signed-off-by: Sam James <sam@gentoo.org> Closes: https://github.com/gentoo/gentoo/pull/21584 Signed-off-by: Lars Wendler <polynomial-c@gentoo.org>
* autotools.eclass: rename configure.in to configure.ac on new EAPIsSam James2021-07-101-3/+14
| | | | | | | | | | | | | | | automake is "eventually" going to fail when it detects configure.in. Don't do this immediately - instead only on new EAPIs to avoid breaking existing ebuilds. We give an eqawarn (which is triggered by e.g. PORTAGE_ELOG_CLASSES="qa" and is opt-in) for maintainers to upstream these where possible, but this isn't always the case for software ehich otherwise works but is unmaintained upstream. Bug: https://bugs.gentoo.org/426262 Signed-off-by: Sam James <sam@gentoo.org> Signed-off-by: Lars Wendler <polynomial-c@gentoo.org>
* Revert "autotools.eclass: add explicit GNU awk dependency"Lars Wendler2021-04-121-3/+1
| | | | | | | This reverts commit 307c855dc6d7842098fae8738a7a5228670a71f6. Change was done without maintainer consent Signed-off-by: Lars Wendler <polynomial-c@gentoo.org>
* Revert "autotools.eclass: rename configure.in to configure.ac on new EAPIs"Lars Wendler2021-04-121-13/+3
| | | | | | | This reverts commit fe3f65790fabb6e98d0b851d3013714c7706eccc. Change was done without maintainer consent Signed-off-by: Lars Wendler <polynomial-c@gentoo.org>
* Revert "autotools.eclass: more case-style changes for consistency"Lars Wendler2021-04-121-3/+3
| | | | | | | This reverts commit 45afdd17d7eecc191399315c88bc4b67aa796d32. Change was done without maintainer consent Signed-off-by: Lars Wendler <polynomial-c@gentoo.org>
* autotools.eclass: more case-style changes for consistencySam James2021-04-111-3/+3
| | | | Signed-off-by: Sam James <sam@gentoo.org>
* autotools.eclass: drop obsolete EAPI 0 compatibility codeSam James2021-04-111-16/+9
| | | | Signed-off-by: Sam James <sam@gentoo.org>
* autotools.eclass: fix EAPI support logic in config_rpath_updateSam James2021-04-111-1/+1
| | | | | | ${EPREFIX} doesn't exist pre-EAPI 3, so let's make that clear. Signed-off-by: Sam James <sam@gentoo.org>
* autotools.eclass: use gnuconfig.eclass for finding latest config.{guess, sub}Sam James2021-04-111-10/+2
| | | | | | No need to duplicate logic. Signed-off-by: Sam James <sam@gentoo.org>
* autotools.eclass: rename configure.in to configure.ac on new EAPIsSam James2021-04-111-3/+13
| | | | | | | | | | automake is eventually going to fail when it detects configure.in. Don't do this immediately - instead only on new EAPIs to avoid breaking existing ebuilds. Bug: https://bugs.gentoo.org/426262 Signed-off-by: Sam James <sam@gentoo.org>
* autotools.eclass: add explicit GNU awk dependencySam James2021-04-111-1/+3
| | | | | | | | autotools_check_macro_val specifically requires GNU awk (sys-apps/gawk) rather than any awk (virtual/awk). Closes: https://bugs.gentoo.org/584254 Signed-off-by: Sam James <sam@gentoo.org>