diff options
| author | Kent Fredric <kentnl@gentoo.org> | 2020-06-21 01:04:43 +1200 |
|---|---|---|
| committer | Kent Fredric <kentnl@gentoo.org> | 2020-06-21 01:06:25 +1200 |
| commit | 80bf6a8420ffc005391f048f093679ac417bf5c5 (patch) | |
| tree | 6e2722fc2bd15601bb148dd8f9b7d9c1e570cb5b /dev-lang/perl/files | |
| parent | b736ece2eb5da75a4db21e9b5c364aea3557fc6f (diff) | |
| download | gentoo-80bf6a8420ffc005391f048f093679ac417bf5c5.tar.gz gentoo-80bf6a8420ffc005391f048f093679ac417bf5c5.tar.bz2 gentoo-80bf6a8420ffc005391f048f093679ac417bf5c5.zip | |
dev-lang/perl: Add unkeyworded -r2 version with WIP features
This is a work in-progress experiment, hence, it is unkeyworded until
I can get more eyes on the changes, and fully test the consequences at
scale.
Important Changes:
- Convert to EAPI7
- Remove inherit on eutils
- Replace calls to "epatch" to "eapply", but resulting in a loss of
nice output
- Add new hidden feature PERL_SINGLE_SLOT, which, when set, installs
perl into a directory named after SUBSLOT (eg: 5.30) as opposed to one
following the explicit name (eg: 5.30.2), which aims to pre-emptively
solve (in both direction) the problem faced by shipping binpkg's,
where the built perl has only one set of INC dirs (eg: 5.30.2), but a
binpkg was built with a different, but compatible perl (eg: 5.30.1),
and subsequently, installs to an @INC dir that is not visible to the
built perl. Instead, all perl's that are defined to be
inter-compatible share the same directory for both arch-dependent and
arch-independent code, so binpkg's only need to be regenerated when:
- Upgrading/downgrading between major revisions
- Flipping USE="debug" or USE="ithreads".
Under PERL_SINGLE_SLOT, directories that should be compatible, and are
available, but built under the previous scheme, are also inhaled into
@INC for ease of transition.
The name of this flag is subject to change, and may become a USE flag.
- Add a new hidden feature PERL_SUPPORT_SINGLE_SLOT, which builds perl
the same way as in previous versions, but also probes for version'd
directories generated by installing packages on perl's built with
PERL_SINGLE_SLOT, as a fallback mechaism for transitioning away from a
perl built with PERL_SINGLE_SLOT.
The name of this flag is subject to change, and may become a USE flag
- Add a patch to various parts of Configure, perl.c, and friends, to
facilitate the above, which exposes itself as -Dgentoolibdirs=, and
has the same syntax as -Dotherlibdirs, but doesn't pollute everything
by adding its own arch-dirs when they weren't asked for. This patch
may also later help facilitate building perl's without
PERL_SINGLE_SLOT, but with other @INC dirs forced into place, for the
same purpose, but implemented differently, as the previous mechanism,
-Dinc_version_list is limited in that it:
- Excludes internally directories that don't exist
- Mangles directories sometimes trashing @INC entirely, throwing
away litterally all the versions you passed.
- Fixed a very embarrasing typo in the einfo code, ${EROO%/T} ...
- Restructured the @INC discovery/cleanup logic into dedicated functions
- Add more error handling in the discovery path, especially adding loud
error output if directories that *need* to be traversed for compat
discovery cannot be traversed, due to misconfigured permissions.
- Fix an embarrasing bug in @INC list stripping, that due to inherently
being a *substring* match, not a *fullstring* match, could have
excluded 5.30.20 from the @INC path for 5.30.2, even though they're
intercompatible. This became more obvious, when one was trying to
strip '5.30' from a list that contained '5.30.1', '5.30.2', because it
just ate everything!
Questions:
- Why do we have bzip2 in RDEPEND? Surely, that should be BDEPEND-only
- Are we even using bzip2 anymore?
- Should we migrate the patch ball to being a more-common-these-days set
of numerically ordered patches, and potentially reduce the handling
complexity in the ebuild as a result?
Package-Manager: Portage-2.3.100, Repoman-2.3.22
Signed-off-by: Kent Fredric <kentnl@gentoo.org>
Diffstat (limited to 'dev-lang/perl/files')
| -rw-r--r-- | dev-lang/perl/files/perl-5.30.3-gentoo-libdirs.patch | 135 |
1 files changed, 135 insertions, 0 deletions
diff --git a/dev-lang/perl/files/perl-5.30.3-gentoo-libdirs.patch b/dev-lang/perl/files/perl-5.30.3-gentoo-libdirs.patch new file mode 100644 index 000000000000..b9e36223a941 --- /dev/null +++ b/dev-lang/perl/files/perl-5.30.3-gentoo-libdirs.patch @@ -0,0 +1,135 @@ +From 7572be1afb16621a537e9da02f96cf04cb10b655 Mon Sep 17 00:00:00 2001 +From: Kent Fredric <kentnl@gentoo.org> +Date: Sat, 20 Jun 2020 22:14:22 +1200 +Subject: Add support for -Dgentoolibdirs + +Which just adds the libdirs verbatim in the right place without +having perl molest it in the process. +--- + Configure | 26 ++++++++++++++++++++++++++ + config_h.SH | 5 +++++ + perl.c | 1 + + perl_inc_macro.h | 8 ++++++++ + uconfig.sh | 1 + + 5 files changed, 41 insertions(+) + +diff --git a/Configure b/Configure +index cef8c3c078..77258e8f43 100755 +--- a/Configure ++++ b/Configure +@@ -1181,6 +1181,8 @@ orderlib='' + ranlib='' + d_perl_otherlibdirs='' + otherlibdirs='' ++gentoolibdirs='' ++d_gentoolibdirs='' + package='' + spackage='' + pager='' +@@ -8101,6 +8103,28 @@ esac + set d_perl_otherlibdirs + eval $setvar + ++case "$gentoolibdirs" in ++''|' ') dflt='none' ;; ++*) dflt="$gentoolibdirs" ;; ++esac ++$cat <<EOM ++Enter a colon-seperated list of explicit gentoo paths to stuff in @INC ++unmolested, or enter 'none' for no extra paths ++ ++EOM ++rp='Colon-seperated list of gentoo-specific perl library search dirs?' ++. ./myread ++case "$ans" in ++' '|''|none) gentoolibdirs=' ';; ++*) gentoolibdirs="$ans" ;; ++esac ++case "$gentoolibdirs" in ++' ') val=$undef ;; ++*) val=$define ;; ++esac ++set d_gentoolibdirs ++eval $setvar ++ + : DTrace support + dflt_dtrace='/usr/sbin/dtrace' + $test -x /usr/bin/dtrace && dflt_dtrace='/usr/bin/dtrace' +@@ -24402,6 +24426,7 @@ d_openat='$d_openat' + d_pathconf='$d_pathconf' + d_pause='$d_pause' + d_perl_otherlibdirs='$d_perl_otherlibdirs' ++d_gentoolibdirs='$d_gentoolibdirs' + d_phostname='$d_phostname' + d_pipe2='$d_pipe2' + d_pipe='$d_pipe' +@@ -24937,6 +24962,7 @@ orderlib='$orderlib' + osname='$osname' + osvers='$osvers' + otherlibdirs='$otherlibdirs' ++gentoolibdirs='$gentoolibdirs' + package='$package' + pager='$pager' + passcat='$passcat' +diff --git a/config_h.SH b/config_h.SH +index 08c5923ef8..5563082969 100755 +--- a/config_h.SH ++++ b/config_h.SH +@@ -1308,6 +1308,11 @@ sed <<!GROK!THIS! >$CONFIG_H -e 's!^#undef\(.*/\)\*!/\*#define\1 \*!' -e 's!^#un + */ + #$d_perl_otherlibdirs PERL_OTHERLIBDIRS "$otherlibdirs" /**/ + ++/* GENTOO_LIBDIRS: ++ * Like PERL_OTHERLIBDIRS, but doesn't stuff ARCH dirs in when not wanted ++ */ ++#$d_gentoolibdirs GENTOO_LIBDIRS "$gentoolibdirs" /**/ ++ + /* PRIVLIB: + * This symbol contains the name of the private library for this package. + * The library is private in the sense that it needn't be in anyone's +diff --git a/perl.c b/perl.c +index 2013a76026..62e67cfaa2 100644 +--- a/perl.c ++++ b/perl.c +@@ -4750,6 +4750,7 @@ S_init_perllib(pTHX) + INCPUSH_ARCHLIB_EXP + INCPUSH_PRIVLIB_EXP + INCPUSH_PERL_OTHERLIBDIRS ++ INCPUSH_GENTOO_LIBDIRS + INCPUSH_PERL5LIB + INCPUSH_APPLLIB_OLD_EXP + INCPUSH_SITELIB_STEM +diff --git a/perl_inc_macro.h b/perl_inc_macro.h +index 5a2f20dfae..4b69b39199 100644 +--- a/perl_inc_macro.h ++++ b/perl_inc_macro.h +@@ -143,6 +143,14 @@ + INCPUSH_ADD_OLD_VERS|INCPUSH_CAN_RELOCATE); + #endif + ++#ifdef GENTOO_LIBDIRS ++# define INCPUSH_GENTOO_LIBDIRS S_incpush_use_sep(aTHX_ STR_WITH_LEN(GENTOO_LIBDIRS), \ ++ INCPUSH_ADD_OLD_VERS|INCPUSH_CAN_RELOCATE); ++#endif ++#ifndef INCPUSH_GENTOO_LIBDIRS ++# define INCPUSH_GENTOO_LIBDIRS ++#endif ++ + #ifdef PERL_OTHERLIBDIRS + # define INCPUSH_PERL_OTHERLIBDIRS_ARCHONLY S_incpush_use_sep(aTHX_ STR_WITH_LEN(PERL_OTHERLIBDIRS), \ + INCPUSH_ADD_OLD_VERS|INCPUSH_ADD_ARCHONLY_SUB_DIRS|INCPUSH_CAN_RELOCATE); +diff --git a/uconfig.sh b/uconfig.sh +index 1d4a0f4a57..fba825acad 100644 +--- a/uconfig.sh ++++ b/uconfig.sh +@@ -185,6 +185,7 @@ d_futimes='undef' + d_gai_strerror='undef' + d_gdbm_ndbm_h_uses_prototypes='undef' + d_gdbmndbm_h_uses_prototypes='undef' ++d_gentoolibdirs='undef' + d_getaddrinfo='undef' + d_getcwd='undef' + d_getespwnam='undef' +-- +2.27.0 + |
