While the shebang issue mentioned above was real, the crux of this error message:
Error: package 'xtensor' is not installed for 'arch = i386'
was actually due to the fact that a configure.win script was present (which is fine), which caused CRAN to not build on the i386 architecture by default. To fix this, I learned from this github issue:
that you actually need to specify Biarch: true in your DESCRIPTION file to have it build on i386 when a configure.win file is present. Adding that fixed the real issue.