The below is as minimal of an example as I can get. It does need to be in separate files as that seems to be what causes the segmentation fault error.
I\'m using Min
I had similar problem. My app crashed on win_lock::lock(), but win_lock::win_lock() constructor was never called!
When added -D_POSIX_THREADS to compiler flags it simply started to work.
I use mingw-w64-i686-7.1.0-posix-dwarf-rt_v5-rev0 on win7