Index: src/gnuwin32/MkRules.local
===================================================================
--- src/gnuwin32/MkRules.local	(nonexistent)
+++ src/gnuwin32/MkRules.local	(working copy)
@@ -0,0 +1,13 @@
+LOCAL_SOFT = /c/Users/tomas/ucrt/x86_64-w64-mingw32.static.posix
+WIN = 64
+BINPREF64 = $(LOCAL_SOFT)/bin/
+USE_ICU = YES
+ICU_LIBS = -lsicuin -lsicuuc $(LOCAL_SOFT)/lib/sicudt.a -lstdc++
+USE_LIBCURL = YES
+CURL_LIBS = -lcurl -lrtmp -lssl -lssh2 -lgcrypt -lcrypto -lgdi32 -lz -lws2_32 -lgdi32 -lcrypt32 -lidn2 -lunistring -liconv -lgpg-error -lwldap32 -lwinmm
+USE_CAIRO = YES
+CAIRO_LIBS = "-lcairo -lfontconfig -lfreetype -lpng -lpixman-1 -lexpat -lharfbuzz -lbz2 -lintl -lz -liconv -lgdi32 -lmsimg32"
+CAIRO_CPPFLAGS = "-I$(LOCAL_SOFT)/include/cairo"
+TEXI2ANY = texi2any
+MAKEINFO = texi2any
+ISDIR = C:/Program Files (x86)/Inno Setup 6
Index: src/gnuwin32/fixed/etc/Makeconf
===================================================================
--- src/gnuwin32/fixed/etc/Makeconf	(revision 78739)
+++ src/gnuwin32/fixed/etc/Makeconf	(working copy)
@@ -52,7 +52,7 @@
 
 ## Things defined in Renviron on Unix
 SED = sed
-TAR = tar
+TAR = tar --force-local
 
 ## Things defined in MkRules
 CAT = cat
Index: src/gnuwin32/front-ends/RGui32.manifest
===================================================================
--- src/gnuwin32/front-ends/RGui32.manifest	(revision 78739)
+++ src/gnuwin32/front-ends/RGui32.manifest	(working copy)
@@ -6,6 +6,11 @@
     name="Rgui.exe"
     type="win32"
 />
+<application>
+  <windowsSettings>
+    <activeCodePage xmlns="http://schemas.microsoft.com/SMI/2019/WindowsSettings">UTF-8</activeCodePage>
+  </windowsSettings>
+</application>
 <description>RGui console</description>
 <dependency>
     <dependentAssembly>
Index: src/gnuwin32/front-ends/RGui64.manifest
===================================================================
--- src/gnuwin32/front-ends/RGui64.manifest	(revision 78739)
+++ src/gnuwin32/front-ends/RGui64.manifest	(working copy)
@@ -6,6 +6,11 @@
     name="Rgui.exe"
     type="win32"
 />
+<application>
+  <windowsSettings>
+    <activeCodePage xmlns="http://schemas.microsoft.com/SMI/2019/WindowsSettings">UTF-8</activeCodePage>
+  </windowsSettings>
+</application>
 <description>RGui console</description>
 <dependency>
     <dependentAssembly>
Index: src/gnuwin32/front-ends/Rcmd.exe.manifest
===================================================================
--- src/gnuwin32/front-ends/Rcmd.exe.manifest	(revision 78739)
+++ src/gnuwin32/front-ends/Rcmd.exe.manifest	(working copy)
@@ -6,6 +6,11 @@
     name="Rcmd.exe"
     type="win32"
 />
+<application>
+  <windowsSettings>
+    <activeCodePage xmlns="http://schemas.microsoft.com/SMI/2019/WindowsSettings">UTF-8</activeCodePage>
+  </windowsSettings>
+</application>
 <description>R utility</description>
 <ms_asmv2:trustInfo xmlns:ms_asmv2="urn:schemas-microsoft-com:asm.v2">
    <ms_asmv2:security>
Index: src/gnuwin32/front-ends/Rcmd64.exe.manifest
===================================================================
--- src/gnuwin32/front-ends/Rcmd64.exe.manifest	(revision 78739)
+++ src/gnuwin32/front-ends/Rcmd64.exe.manifest	(working copy)
@@ -6,6 +6,11 @@
     name="Rcmd.exe"
     type="win32"
 />
+<application>
+  <windowsSettings>
+    <activeCodePage xmlns="http://schemas.microsoft.com/SMI/2019/WindowsSettings">UTF-8</activeCodePage>
+  </windowsSettings>
+</application>
 <description>R utility</description>
 <ms_asmv2:trustInfo xmlns:ms_asmv2="urn:schemas-microsoft-com:asm.v2">
    <ms_asmv2:security>
Index: src/gnuwin32/front-ends/Rscript.exe.manifest
===================================================================
--- src/gnuwin32/front-ends/Rscript.exe.manifest	(revision 78739)
+++ src/gnuwin32/front-ends/Rscript.exe.manifest	(working copy)
@@ -6,6 +6,11 @@
     name="Rscript.exe"
     type="win32"
 />
+<application>
+  <windowsSettings>
+    <activeCodePage xmlns="http://schemas.microsoft.com/SMI/2019/WindowsSettings">UTF-8</activeCodePage>
+  </windowsSettings>
+</application>
 <description>R utility</description>
 <dependency>
     <dependentAssembly>
Index: src/gnuwin32/front-ends/Rscript64.exe.manifest
===================================================================
--- src/gnuwin32/front-ends/Rscript64.exe.manifest	(revision 78739)
+++ src/gnuwin32/front-ends/Rscript64.exe.manifest	(working copy)
@@ -6,6 +6,11 @@
     name="Rscript.exe"
     type="win32"
 />
+<application>
+  <windowsSettings>
+    <activeCodePage xmlns="http://schemas.microsoft.com/SMI/2019/WindowsSettings">UTF-8</activeCodePage>
+  </windowsSettings>
+</application>
 <description>R utility</description>
 <dependency>
     <dependentAssembly>
Index: src/gnuwin32/front-ends/Rterm32.manifest
===================================================================
--- src/gnuwin32/front-ends/Rterm32.manifest	(revision 78739)
+++ src/gnuwin32/front-ends/Rterm32.manifest	(working copy)
@@ -6,6 +6,11 @@
     name="Rterm.exe"
     type="win32"
 />
+<application>
+  <windowsSettings>
+    <activeCodePage xmlns="http://schemas.microsoft.com/SMI/2019/WindowsSettings">UTF-8</activeCodePage>
+  </windowsSettings>
+</application>
 <description>R terminal</description>
 <dependency>
     <dependentAssembly>
Index: src/gnuwin32/front-ends/Rterm64.manifest
===================================================================
--- src/gnuwin32/front-ends/Rterm64.manifest	(revision 78739)
+++ src/gnuwin32/front-ends/Rterm64.manifest	(working copy)
@@ -6,6 +6,11 @@
     name="Rterm.exe"
     type="win32"
 />
+<application>
+  <windowsSettings>
+    <activeCodePage xmlns="http://schemas.microsoft.com/SMI/2019/WindowsSettings">UTF-8</activeCodePage>
+  </windowsSettings>
+</application>
 <description>R terminal</description>
 <dependency>
     <dependentAssembly>
Index: src/gnuwin32/installer/JRins.R
===================================================================
--- src/gnuwin32/installer/JRins.R	(revision 78739)
+++ src/gnuwin32/installer/JRins.R	(working copy)
@@ -37,10 +37,14 @@
     con <- file("R.iss", "w")
     cat("[Setup]\n", file = con)
 
-    if (have64bit) {
+    if (have64bit && have32bit) {
         regfile <- "reg3264.iss"
         types <- "types3264.iss"
         cat("ArchitecturesInstallIn64BitMode=x64\n", file = con)
+    } else if (have64bit) { # 64-bit only
+        regfile <- "reg64.iss"
+        types <- "types64.iss"
+        cat("ArchitecturesInstallIn64BitMode=x64\n", file = con)
     } else { # 32-bit only
         regfile <- "reg.iss"
         types <- "types32.iss"
@@ -76,11 +80,6 @@
     writeLines(lines, con)
 
     lines <- readLines(types)
-    if(have64bit && !have32bit) {
-        lines <- lines[-c(3,4,10)]
-        lines <- gsub("user(32)* ", "", lines)
-        lines <- gsub("compact ", "", lines)
-    }
     writeLines(lines, con)
 
     lines <- readLines("code.iss")
@@ -99,7 +98,7 @@
 	dir <- sub("\\\\$", "", dir)
 
 	component <- if (grepl("^Tcl/(bin|lib)64", f)) "x64"
-	else if (have64bit &&
+	else if (have64bit && have32bit &&
                  (grepl("^Tcl/bin", f) ||
                   grepl("^Tcl/lib/(dde1.3|reg1.2|Tktable)", f))) "i386"
 	else if (grepl("/i386/", f)) "i386"
@@ -109,6 +108,7 @@
 	else "main"
 
         if (component == "x64" && !have64bit) next
+        if (component == "i386" && !have32bit) next
         
         # Skip the /bin front ends, they are installed below
         if (grepl("bin/R.exe$", f)) next
Index: src/gnuwin32/installer/reg64.iss
===================================================================
--- src/gnuwin32/installer/reg64.iss	(nonexistent)
+++ src/gnuwin32/installer/reg64.iss	(working copy)
@@ -0,0 +1,36 @@
+[Icons]
+Name: "{group}\R @RVER@"; Filename: "{app}\bin\x64\Rgui.exe"; WorkingDir: "{app}"; Parameters: "--cd-to-userdocs"
+Name: "{commondesktop}\R @RVER@"; Filename: "{app}\bin\x64\Rgui.exe"; MinVersion: 0,5.0; Tasks: desktopicon; WorkingDir: "{app}"; Parameters: "--cd-to-userdocs"
+Name: "{userappdata}\Microsoft\Internet Explorer\Quick Launch\R @RVER@"; Filename: "{app}\bin\x64\Rgui.exe"; Tasks: quicklaunchicon; WorkingDir: "{app}"; Parameters: "--cd-to-userdocs"
+
+[Registry] 
+Root: HKLM; Subkey: "Software\@Producer@"; Flags: uninsdeletekeyifempty; Tasks: recordversion; Check: IsAdmin
+Root: HKLM; Subkey: "Software\@Producer@\R"; Flags: uninsdeletekeyifempty; Tasks: recordversion; Check: IsAdmin
+Root: HKLM; Subkey: "Software\@Producer@\R"; Flags: uninsdeletevalue; ValueType: string; ValueName: "InstallPath"; ValueData: "{app}"; Tasks: recordversion; Check: IsAdmin
+Root: HKLM; Subkey: "Software\@Producer@\R"; Flags: uninsdeletevalue; ValueType: string; ValueName: "Current Version"; ValueData: "@RVER@"; Tasks: recordversion; Check: IsAdmin
+Root: HKLM; Subkey: "Software\@Producer@\R\@RVER@"; Flags: uninsdeletekey; Tasks: recordversion; Check: IsAdmin
+Root: HKLM; Subkey: "Software\@Producer@\R\@RVER@"; ValueType: string; ValueName: "InstallPath"; ValueData: "{app}"; Tasks: recordversion; Check: IsAdmin
+
+Root: HKLM; Subkey: "Software\@Producer@\R64"; Flags: uninsdeletekeyifempty; Tasks: recordversion; Check: IsAdmin
+Root: HKLM; Subkey: "Software\@Producer@\R64"; Flags: uninsdeletevalue; ValueType: string; ValueName: "InstallPath"; ValueData: "{app}"; Tasks: recordversion; Check: IsAdmin
+Root: HKLM; Subkey: "Software\@Producer@\R64"; Flags: uninsdeletevalue; ValueType: string; ValueName: "Current Version"; ValueData: "@RVER@"; Tasks: recordversion; Check: IsAdmin
+Root: HKLM; Subkey: "Software\@Producer@\R64\@RVER@"; Flags: uninsdeletekey; Tasks: recordversion; Check: IsAdmin
+Root: HKLM; Subkey: "Software\@Producer@\R64\@RVER@"; ValueType: string; ValueName: "InstallPath"; ValueData: "{app}"; Tasks: recordversion; Check: IsAdmin
+
+Root: HKCU; Subkey: "Software\@Producer@"; Flags: uninsdeletekeyifempty; Tasks: recordversion; Check: NonAdmin
+Root: HKCU; Subkey: "Software\@Producer@\R"; Flags: uninsdeletekeyifempty; Tasks: recordversion; Check: NonAdmin
+Root: HKCU; Subkey: "Software\@Producer@\R"; Flags: uninsdeletevalue; ValueType: string; ValueName: "InstallPath"; ValueData: "{app}"; Tasks: recordversion; Check: NonAdmin
+Root: HKCU; Subkey: "Software\@Producer@\R"; Flags: uninsdeletevalue; ValueType: string; ValueName: "Current Version"; ValueData: "@RVER@"; Tasks: recordversion; Check: NonAdmin
+Root: HKCU; Subkey: "Software\@Producer@\R\@RVER@"; Flags: uninsdeletekey; Tasks: recordversion; Check: NonAdmin
+Root: HKCU; Subkey: "Software\@Producer@\R\@RVER@"; ValueType: string; ValueName: "InstallPath"; ValueData: "{app}"; Tasks: recordversion; Check: NonAdmin
+
+Root: HKCU; Subkey: "Software\@Producer@\R64"; Flags: uninsdeletekeyifempty; Tasks: recordversion; Check: NonAdmin
+Root: HKCU; Subkey: "Software\@Producer@\R64"; Flags: uninsdeletevalue; ValueType: string; ValueName: "InstallPath"; ValueData: "{app}"; Tasks: recordversion; Check: NonAdmin
+Root: HKCU; Subkey: "Software\@Producer@\R64"; Flags: uninsdeletevalue; ValueType: string; ValueName: "Current Version"; ValueData: "@RVER@"; Tasks: recordversion; Check: NonAdmin
+Root: HKCU; Subkey: "Software\@Producer@\R64\@RVER@"; Flags: uninsdeletekey; Tasks: recordversion; Check: NonAdmin
+Root: HKCU; Subkey: "Software\@Producer@\R64\@RVER@"; ValueType: string; ValueName: "InstallPath"; ValueData: "{app}"; Tasks: recordversion; Check: NonAdmin
+
+Root: HKCR; Subkey: ".RData"; ValueType: string; ValueName: ""; ValueData: "RWorkspace"; Flags: uninsdeletevalue; Tasks: associate; Check: IsAdmin
+Root: HKCR; Subkey: "RWorkspace"; ValueType: string; ValueName: ""; ValueData: "R Workspace"; Flags: uninsdeletekey; Tasks: associate; Check: IsAdmin
+Root: HKCR; Subkey: "RWorkspace\DefaultIcon"; ValueType: string; ValueName: ""; ValueData: "{app}\bin\x64\RGui.exe,0"; Tasks: associate; Check: IsAdmin 
+Root: HKCR; Subkey: "RWorkspace\shell\open\command"; ValueType: string; ValueName: ""; ValueData: """{app}\bin\x64\RGui.exe"" --workspace=""%1"""; Tasks: associate; Check: IsAdmin
Index: src/gnuwin32/installer/types64.iss
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/x-wine-extension-ini

Property changes on: src/gnuwin32/installer/types64.iss
___________________________________________________________________
Added: svn:mime-type
## -0,0 +1 ##
+application/x-wine-extension-ini
\ No newline at end of property
Index: src/library/grDevices/src/Makefile.win
===================================================================
--- src/library/grDevices/src/Makefile.win	(revision 78739)
+++ src/library/grDevices/src/Makefile.win	(working copy)
@@ -35,7 +35,7 @@
 
 winbitmap-CPPFLAGS = -DHAVE_PNG -DHAVE_JPEG -DHAVE_TIFF -I"$(EXT_LIBS)"
 
-PKG_LIBS = -L"$(EXT_LIBS)"/lib$(R_ARCH) -lRgraphapp -lpng -ltiff -ljpeg -lz
+PKG_LIBS = -L"$(EXT_LIBS)"/lib$(R_ARCH) -lRgraphapp -lpng -ltiff -ljpeg -lzstd -lz -lwebp -llzma
 
 
 all: makeMakedeps shlib
Index: src/library/utils/R/packages2.R
===================================================================
--- src/library/utils/R/packages2.R	(revision 78739)
+++ src/library/utils/R/packages2.R	(working copy)
@@ -826,6 +826,9 @@
             }
             if(keep_outputs)
                 file.copy(paste0(update[, 1L], ".out"), outdir)
+            file.copy(Sys.glob(paste0(update[, 1L], "*.zip")), outdir)
+            file.copy(Sys.glob(paste0(update[, 1L], "*.tgz")), outdir)
+            file.copy(Sys.glob(paste0(update[, 1L], "*.tar.gz")), outdir)
             setwd(cwd); on.exit()
             unlink(tmpd2, recursive = TRUE)
         } else {
Index: src/library/utils/R/zzz.R
===================================================================
--- src/library/utils/R/zzz.R	(revision 78739)
+++ src/library/utils/R/zzz.R	(working copy)
@@ -38,7 +38,9 @@
         if(.Platform$OS.type == "windows") {
             list(unzip = "internal",
                  editor = if(length(grep("Rgui", commandArgs(), TRUE))) "internal" else "notepad",
-                 repos = c(CRAN = "@CRAN@"),
+                 repos = c(CRAN = "https://www.r-project.org/nosvn/winutf8/demo/CRAN",
+                           BIOC = "https://www.r-project.org/nosvn/winutf8/demo/BIOC"),
+                 pkgType= "win.binary",
                  askYesNo = if (.Platform$GUI == "Rgui") askYesNoWinDialog
                  )
         } else
