fix blackmagic compilation with weird compilers