csv-parser icon indicating copy to clipboard operation
csv-parser copied to clipboard

Windows 10 mutex

Open chegrane opened this issue 4 years ago • 2 comments

Using Windows 10 Clion (Cmake) with: CMAKE_CXX_STANDARD 17 and cmake_minimum_required(VERSION 3.15).

At the compile time : several error related to mutex:

  1. error: 'mutex' in namespace 'std' does not name a type std::mutex _lock; (csv-parser\include\internal\basic_csv_parser.hpp:177:18)

  2. note: 'std::mutex' is defined in header ''; did you forget to '#include '? #include "csv_row.hpp" (csv-parser\include\internal\basic_csv_parser.hpp:23:1:)

... etc.

Other errors related to : std::condition_variable and unlock

Note: I tested the same code on Linux Ubuntu 16.04 and it works very well. so the problem is with windows.

chegrane avatar Feb 18 '21 13:02 chegrane

Sounds like a missing #include as the compiler indicates. I'll take a look.

vincentlaucsb avatar May 24 '21 07:05 vincentlaucsb

If you're using MinGW with win32 threads, it just can't work. Use MinGW with posix threads.

SpaceIm avatar Jul 31 '21 00:07 SpaceIm