Well, the image seems to be very outdated in terms of the actual status of MSYS2. This made a lot of workarounds necessary in the past couple of month. Maybe you could consider upgrading the image with a new snapshot of an actual MSYS2 environment
Visual Studio 2019 image has been just updated. This script is used to install MSYS on the image. Image as baked on July 26th. I'd say MSYS there is quite "recent". If you can spot what's missing we could update the script by the next image update.
The script looks ok except that update of pacman-mirrors is commented out.
However from what I see on the logs and console It seems not to have worked. could you provide the console output from the script to see what will be generated
We are not collecting pacman logs during msys installation. However, you can use the same script and call it during your build - it will remove existing C:\msys64 folder and start over - you'll be able to observe the installation. Also, feel free to modify script for logs collection.
I did run the script in my project.
it worked fine and it delivered an actual build.
I inserted a pacman -Q command in the chain as well and it does not deliver the same or at least mostly similar results befor or after the script. So it seems this has not been run for the 29 July update of the Visual Studio 2019 update (it isn't mentioned an MSYS2 upgrade for this update in the changelog neither)