Welcome to Doom9's Forum, THE in-place to be for everyone interested in DVD conversion.

Before you start posting please read the forum rules. By posting to this forum you agree to abide by the rules.


Go Back   Doom9's Forum > Programming and Hacking > Development

Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
Old 23rd December 2018, 16:01   #1  |  Link
Registered User
CoRoNe's Avatar
Join Date: Nov 2005
Posts: 648
"error: 'mutex' in namespace 'std' does not name a type" despite up-to-date toolchain

I'm using 'mingw-w64-build-r25' from https://files.1f0.de/mingw/scripts/ (does anyone know who actually maintains these updated scripts? Hendrik / nevairiel?) to create my own toolchain with GCC 8.2, MinGW-w64 6.0.0 and pthreads 2.9.1.

Today I tried to compile libdmusic, but I got the following error:
[ 11%] Building CXX object CMakeFiles/dmusic.dir/src/DlsPlayer.cpp.obj
In file included from /[...]/libdmusic_git/include/dmusic/DlsPlayer.h:8,
                 from /[...]/libdmusic_git/src/DlsPlayer.cpp:1:
/[...]/libdmusic_git/include/dmusic/PlayingContext.h:74:14: error: 'mutex' in namespace 'std' does not name a type
         std::mutex m_queueMutex;
I've done some searching and read that std::mutex and std::thread are added in C++11, which requires a recent GCC version and most likely the -std=gnu++11 compiler flag as well.
I'm using the latest GCC, but export CXXFLAGS="-std=gnu++11" didn't make any difference. I still get the error.
Now I wonder, is this guy right, despite having the latest GCC? Or is there a flaw in the MinGW-w64 build script that I'm getting this error?
My hobby website
CoRoNe is offline   Reply With Quote

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

All times are GMT +1. The time now is 21:52.

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2019, vBulletin Solutions Inc.