cmake: fixed compilation static library on Windows