texlive[61891] Master/tlpkg/TeXLive/TLUtils.pm: try to fix curl

commits+preining at tug.org commits+preining at tug.org
Sat Feb 5 12:02:25 CET 2022


Revision: 61891
          http://tug.org/svn/texlive?view=revision&revision=61891
Author:   preining
Date:     2022-02-05 12:02:25 +0100 (Sat, 05 Feb 2022)
Log Message:
-----------
try to fix curl cacert on some macos

Modified Paths:
--------------
    trunk/Master/tlpkg/TeXLive/TLUtils.pm

Modified: trunk/Master/tlpkg/TeXLive/TLUtils.pm
===================================================================
--- trunk/Master/tlpkg/TeXLive/TLUtils.pm	2022-02-05 11:02:18 UTC (rev 61890)
+++ trunk/Master/tlpkg/TeXLive/TLUtils.pm	2022-02-05 11:02:25 UTC (rev 61891)
@@ -2625,17 +2625,15 @@
                  "$bindir/$dltype/$defprog.$platform", "--version", $tlfirst);
   }
   # check for curl special stuff on MacOS
-  if (member("curl", @working_downloaders) && platform() =~ m/^darwin/) {
-    #
-    my $use_our_cacert = 0;
-    # TODO
-    # check version of darwin and set $use_our_cacert = 1
-    #
-    if ($use_our_cacert == 1) {
+  if (member("curl", @working_downloaders) && platform() =~ m/darwin/) {
+    # copied from platform_name
+    chomp (my $sw_vers = `sw_vers -productVersion`);
+    my ($os_major,$os_minor) = split (/\./, $sw_vers);
+    if ($os_major == 10 && ($os_minor == 13 || $os_minor == 14)) {
       my @curlargs = @{$TeXLive::TLConfig::FallbackDownloaderArgs{'curl'}};
       # can't push new arg at end of list because builtin list ends with
       # -o to set the output file.
-      unshift (@curlargs, '--cacert', "SOME PATH WE NEED TO DECIDE TODO");
+      unshift (@curlargs, '--cacert', "$::installerdir/tlpkg/curl/curl-ca-bundle.crt");
       $TeXLive::TLConfig::FallbackDownloaderArgs{'curl'} = \@curlargs;
       debug("TLUtils::setup_programs: curl on old darwin, final curl args: @{$TeXLive::TLConfig::FallbackDownloaderArgs{'curl'}}\n");
     }



More information about the tex-live-commits mailing list.