install: Correct libdir for Windows installs.

Platform-detection code from configure copied over to install.sh in
order to special case the lib dir being `bin` on Windows instead of
`lib`.

Short-term fix for #13810.