configure: fix target triplet check for mingw targets