From e7b5a35e5caa784200da32b6c6b457e20a67fd2a Mon Sep 17 00:00:00 2001 From: Matthias Schiffer Date: Fri, 25 Apr 2025 12:35:23 +0200 Subject: [PATCH] perl: drop 110-always_use_miniperl.patch The patch was introduced in commit 4c57844f0f04 ("lang/perl: Add hack to make perl always use miniperl during build"), but it is not actually necessary. By setting $perl to a non-empty value (using 'perl' as is common on desktop distros), the logic works as intended and selects the correct perl binary for host and target builds. As miniperl just symlinks to host perl for target builds, the main effect of this change is not unconditionally passing `-Ilib -I.` anymore. This seems like a good thing; host libraries should be used with host perl by default. Signed-off-by: Matthias Schiffer --- lang/perl/files/base.config | 2 +- .../patches/110-always_use_miniperl.patch | 27 ------------- lang/perl/patches/900-use-rm-force.patch | 38 +++++++++---------- ...06-adjust-dependency-paths-on-instal.patch | 8 ++-- 4 files changed, 24 insertions(+), 51 deletions(-) delete mode 100644 lang/perl/patches/110-always_use_miniperl.patch diff --git a/lang/perl/files/base.config b/lang/perl/files/base.config index 67232b6d8..7d8b88b20 100644 --- a/lang/perl/files/base.config +++ b/lang/perl/files/base.config @@ -864,7 +864,7 @@ package='perl5' pager='/usr/bin/less' passcat='cat /etc/passwd' path_sep=':' -perl='' +perl='perl' perl5='' perl_patchlevel='' perl_static_inline='static __inline__' diff --git a/lang/perl/patches/110-always_use_miniperl.patch b/lang/perl/patches/110-always_use_miniperl.patch deleted file mode 100644 index 806a31256..000000000 --- a/lang/perl/patches/110-always_use_miniperl.patch +++ /dev/null @@ -1,27 +0,0 @@ ---- a/Makefile.SH -+++ b/Makefile.SH -@@ -360,22 +360,11 @@ PERL_EXE_LDFLAGS=$exeldflags - ;; - esac - --case "$usecrosscompile$perl" in --define?*) -- $spitshell >>$Makefile <>$Makefile <>$Makefile <>$Makefile <>$Makefile <<'!NO!SUBS!' $(DTRACE_MINI_O): perldtrace.d $(miniperl_objs_nodt) @@ -48,7 +48,7 @@ !NO!SUBS! ;; -@@ -926,13 +927,13 @@ $(LIBPERL): $& $(perllib_dep) $(DYNALOAD +@@ -937,13 +938,13 @@ $(LIBPERL): $& $(perllib_dep) $(DYNALOAD case "$useshrplib" in true) $spitshell >>$Makefile <<'!NO!SUBS!' @@ -64,7 +64,7 @@ mv $@ libperl$(OBJ_EXT) $(AR) qv $(LIBPERL) libperl$(OBJ_EXT) !NO!SUBS! -@@ -941,7 +942,7 @@ $(LIBPERL): $& $(perllib_dep) $(DYNALOAD +@@ -952,7 +953,7 @@ $(LIBPERL): $& $(perllib_dep) $(DYNALOAD ;; *) $spitshell >>$Makefile <<'!NO!SUBS!' @@ -73,7 +73,7 @@ $(AR) rc $(LIBPERL) $(perllib_objs) $(DYNALOADER) @$(ranlib) $(LIBPERL) !NO!SUBS! -@@ -975,7 +976,7 @@ $(MINIPERL_EXE): lib/buildcustomize.pl +@@ -986,7 +987,7 @@ $(MINIPERL_EXE): lib/buildcustomize.pl amigaos*) $spitshell >>$Makefile <<'!NO!SUBS!' lib/buildcustomize.pl: $& $(miniperl_objs) write_buildcustomize.pl @@ -82,7 +82,7 @@ $(CC) $(CLDFLAGS) -o $(MINIPERL_EXE) \ $(miniperl_objs) $(libs) # $(LDLIBPTH) ./miniperl$(HOST_EXE_EXT) -w -Ilib -Idist/Exporter/lib -MExporter -e '' || sh -c 'echo >&2 Failed to build miniperl. Please run make minitest; exit 1' -@@ -997,7 +998,7 @@ NAMESPACEFLAGS = -force_flat_namespace +@@ -1008,7 +1009,7 @@ NAMESPACEFLAGS = -force_flat_namespace esac $spitshell >>$Makefile <<'!NO!SUBS!' lib/buildcustomize.pl: $& $(miniperl_objs) write_buildcustomize.pl @@ -91,7 +91,7 @@ $(CC) $(CLDFLAGS) $(NAMESPACEFLAGS) -o $(MINIPERL_EXE) \ $(miniperl_objs) $(libs) $(LDLIBPTH) ./miniperl$(HOST_EXE_EXT) -w -Ilib -Idist/Exporter/lib -MExporter -e '' || sh -c 'echo >&2 Failed to build miniperl. Please run make minitest; exit 1' -@@ -1008,8 +1009,8 @@ lib/buildcustomize.pl: $& $(miniperl_obj +@@ -1019,8 +1020,8 @@ lib/buildcustomize.pl: $& $(miniperl_obj if test "X$hostperl" != X; then $spitshell >>$Makefile <' || sh -c 'echo >&2 Failed to build miniperl. Please run make minitest; exit 1' \$(MINIPERL) -f write_buildcustomize.pl 'osname' "$osname" -@@ -1017,7 +1018,7 @@ lib/buildcustomize.pl: \$& \$(miniperl_d +@@ -1028,7 +1029,7 @@ lib/buildcustomize.pl: \$& \$(miniperl_d else $spitshell >>$Makefile <<'!NO!SUBS!' lib/buildcustomize.pl: $& $(miniperl_dep) write_buildcustomize.pl @@ -111,7 +111,7 @@ $(CC) $(CLDFLAGS) -o $(MINIPERL_EXE) \ $(miniperl_objs) $(libs) $(LDLIBPTH) ./miniperl$(HOST_EXE_EXT) -w -Ilib -Idist/Exporter/lib -MExporter -e '' || sh -c 'echo >&2 Failed to build miniperl. Please run make minitest; exit 1' -@@ -1030,7 +1031,7 @@ lib/buildcustomize.pl: $& $(miniperl_dep +@@ -1041,7 +1042,7 @@ lib/buildcustomize.pl: $& $(miniperl_dep $spitshell >>$Makefile <<'!NO!SUBS!' $(PERL_EXE): $& $(perlmain_dep) $(LIBPERL) $(static_ext) ext.libs $(PERLEXPORT) write_buildcustomize.pl @@ -120,7 +120,7 @@ !NO!SUBS! case "$osname" in -@@ -1130,8 +1131,8 @@ pod/perl5400delta.pod: pod/perldelta.pod +@@ -1141,8 +1142,8 @@ pod/perl5400delta.pod: pod/perldelta.pod $(LNS) perldelta.pod pod/perl5400delta.pod extra.pods: $(MINIPERL_EXE) @@ -131,7 +131,7 @@ -@for x in `grep -l '^=[a-z]' README.* | grep -v README.vms` ; do \ nx=`echo $$x | sed -e "s/README\.//"`; \ $(LNS) ../$$x "pod/perl"$$nx".pod" ; \ -@@ -1330,11 +1331,11 @@ realclean: _realcleaner _mopup +@@ -1341,11 +1342,11 @@ realclean: _realcleaner _mopup @echo "Note that '$(MAKE) realclean' does not delete config.sh or Policy.sh" _clobber: @@ -148,7 +148,7 @@ clobber: _realcleaner _mopup _clobber -@@ -1342,24 +1343,24 @@ distclean: clobber +@@ -1353,24 +1354,24 @@ distclean: clobber # Like distclean but also removes emacs backups and *.orig. veryclean: _verycleaner _mopup _clobber @@ -184,7 +184,7 @@ -cd pod; $(LDLIBPTH) $(MAKE) $(CLEAN) -cd utils; $(LDLIBPTH) $(MAKE) $(CLEAN) -@if test -f $(MINIPERL_EXE) ; then \ -@@ -1369,8 +1370,8 @@ _cleaner1: +@@ -1380,8 +1381,8 @@ _cleaner1: else \ sh $(CLEAN).sh ; \ fi @@ -195,7 +195,7 @@ # Dear POSIX, thanks for making the default to xargs to be # run once if nothing is passed in. It is such a great help. -@@ -1385,24 +1386,24 @@ _cleaner1: +@@ -1396,24 +1397,24 @@ _cleaner1: # Add new rules before that line - the next line (rm -f so_locations ...) is # used as a placeholder by a regen script. _cleaner2: @@ -237,7 +237,7 @@ -rmdir lib/version lib/threads lib/inc/ExtUtils lib/inc lib/encoding -rmdir lib/autodie/exception lib/autodie/Scope lib/autodie lib/XS -rmdir lib/Win32API lib/VMS lib/Unicode/Collate/Locale -@@ -1459,11 +1460,11 @@ _realcleaner: +@@ -1470,11 +1471,11 @@ _realcleaner: _verycleaner: @$(LDLIBPTH) $(MAKE) _cleaner1 CLEAN=veryclean @$(LDLIBPTH) $(MAKE) _cleaner2 @@ -251,7 +251,7 @@ lint $(lintflags) -DPERL_CORE -D_REENTRANT -DDEBUGGING -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 $(c) cscopeflags = -Rb # Recursive, build-only. -@@ -1524,7 +1525,7 @@ case "$targethost" in +@@ -1535,7 +1536,7 @@ case "$targethost" in '') $spitshell >>$Makefile <<'!NO!SUBS!' test_prep test-prep: test_prep_pre $(MINIPERL_EXE) $(unidatafiles) $(PERL_EXE) \ $(dynamic_ext) $(TEST_PERL_DLL) runtests $(generated_pods) common_build @@ -260,7 +260,7 @@ !NO!SUBS! ;; -@@ -1574,7 +1575,7 @@ test_prep test-prep: test_prep_pre \$(MI +@@ -1585,7 +1586,7 @@ test_prep test-prep: test_prep_pre \$(MI $to config.sh # --- For lib/diagnostics.t with -Duseshrplib $to \$(PERL_EXE) @@ -269,7 +269,7 @@ $to t/\$(PERL_EXE) !GROK!THIS! -@@ -1592,7 +1593,7 @@ else +@@ -1603,7 +1604,7 @@ else $spitshell >>$Makefile <<'!NO!SUBS!' test_prep_reonly: $(MINIPERL_EXE) $(PERL_EXE) $(dynamic_ext_re) $(TEST_PERL_DLL) $(MINIPERL) make_ext.pl $(dynamic_ext_re) MAKE="$(MAKE)" LIBPERL_A=$(LIBPERL) LINKTYPE=dynamic @@ -278,7 +278,7 @@ !NO!SUBS! fi -@@ -1648,7 +1649,7 @@ minitest_prep: $(MINIPERL_EXE) +@@ -1659,7 +1660,7 @@ minitest_prep: $(MINIPERL_EXE) @echo "You may see some irrelevant test failures if you have been unable" @echo "to build lib/Config.pm, or the Unicode data files." @echo " " diff --git a/lang/perl/patches/920-Revert-perl-127606-adjust-dependency-paths-on-instal.patch b/lang/perl/patches/920-Revert-perl-127606-adjust-dependency-paths-on-instal.patch index e9e5688e4..6436a8ea0 100644 --- a/lang/perl/patches/920-Revert-perl-127606-adjust-dependency-paths-on-instal.patch +++ b/lang/perl/patches/920-Revert-perl-127606-adjust-dependency-paths-on-instal.patch @@ -42,10 +42,10 @@ Signed-off-by: Georgi Valkov - ;; -esac - - $spitshell >>$Makefile <>$Makefile <