diff -Nru orig/xml2/src/Makevars.win patched/xml2/src/Makevars.win
--- orig/xml2/src/Makevars.win	2020-03-09 20:39:17.000000000 +0100
+++ patched/xml2/src/Makevars.win	2020-07-02 18:06:50.255556400 +0200
@@ -1,16 +1,9 @@
-VERSION=2.9.8
-RWINLIB=../windows/libxml2-$(VERSION)
-PKG_CPPFLAGS=-I../inst/include -I$(RWINLIB)/include/libxml2 \
-	-DLIBXML_STATIC
+PKG_LIBS=-lxml2 -llzma -liconv -lz -lws2_32
+PKG_CPPFLAGS=-I../inst/include -I$(LOCAL_SOFT)/include/libxml2 -DLIBXML_STATIC
 
-PKG_LIBS=-L$(RWINLIB)/lib${R_ARCH} -lxml2 -llzma -liconv -lz -lws2_32
-
-all: clean winlibs
+all: clean 
 
 clean:
 	rm -f $(OBJECTS) $(SHLIB)
 
-winlibs:
-	"${R_HOME}/bin${R_ARCH_BIN}/Rscript.exe" "../tools/winlibs.R" $(VERSION)
-
 .PHONY: all winlibs clean
diff -Nru orig/xml2/tools/winlibs.R patched/xml2/tools/winlibs.R
--- orig/xml2/tools/winlibs.R	2019-07-24 16:43:56.000000000 +0200
+++ patched/xml2/tools/winlibs.R	1970-01-01 01:00:00.000000000 +0100
@@ -1,9 +0,0 @@
-# Build against static libraries from rwinlib
-VERSION <- commandArgs(TRUE)
-if(!file.exists(sprintf("../windows/libxml2-%s/include/libxml2/libxml/parser.h", VERSION))){
-  if(getRversion() < "3.3.0") setInternet2()
-  download.file(sprintf("https://github.com/rwinlib/libxml2/archive/v%s.zip", VERSION), "lib.zip", quiet = TRUE)
-  dir.create("../windows", showWarnings = FALSE)
-  unzip("lib.zip", exdir = "../windows")
-  unlink("lib.zip")
-}
