Fix static builds