the windres.exe that comes with your mingw cannot handle spaces in strings like "long long" correctly, and thus tries to treat the second "long" incorrectly as a filename.
-DOPENCV_ENABLE_ALLOCATOR_STATS=OFF