Re: <SPAM> Can't build opencv : 'recursive_mutex' in namespace 'std' does not name a type
Keith Marshall <[email protected]> Thu, 7 Jan 2021 21:00:59 +0000
| Newsgroups | gmane.comp.gnu.mingw.user |
|---|---|
| Organization | MinGW.org Project |
| Message-ID | <[email protected]> |
This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --===============9146708183751371636== Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="ndfuiJMoXQvMzavhWYThSK8laCMVh5258" This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --ndfuiJMoXQvMzavhWYThSK8laCMVh5258 Content-Type: multipart/mixed; boundary="kj7hYeaPw2jhMormRbUZPFOumftEeyNw2"; protected-headers="v1" From: Keith Marshall <[email protected]> To: [email protected] Message-ID: <57a33402-0ff5-e13c-f084-3ae66ebf78e4-JlWs9+JhQMeJPt80KsDg5Q@public.gmane.org> Subject: Re: <SPAM> [MinGW-Users] Can't build opencv : 'recursive_mutex' in namespace 'std' does not name a type References: <CAKjWZNVMzkL=6K84mrom3kZsXpWJu3KQt4Rj1=5CBQJAJp5+Zw-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org> In-Reply-To: <CAKjWZNVMzkL=6K84mrom3kZsXpWJu3KQt4Rj1=5CBQJAJp5+Zw-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org> --kj7hYeaPw2jhMormRbUZPFOumftEeyNw2 Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: quoted-printable On 26/12/2020 03:50, Roy Qu wrote: > I'm trying to build opencv using mingw gcc 9.2, and i got the following= > message: >=20 > [...snip...] > error: 'recursive_mutex' in namespace 'std' does not name a type > =C2=A0 706 | typedef std::recursive_mutex Mutex; > =C2=A0 =C2=A0 =C2=A0 | =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0= ^~~~~~~~~~~~~~~ > F:/Temp/test/opencv-4.5.1/modules/core/include/opencv2/core/utility.hpp= :63:1: > note: 'std::recursive_mutex' is defined in header '<mutex>'; did you > forget to '#include <mutex>'? Presumably, you have checked that <mutex> has been included? Even if it has been, I believe that std::recursive_mutex is unsupported, when GCC itself has been compiled to use the Win32 threads model, (as ours is). > So what should I do to get it worked? This will not be the answer you are hoping for, but unless you build GCC to use the POSIX threads model, (or find a third-party build elsewhere), you will need to port the application, to substitute a Windows-native alternative for std::recursive_mutex. --=20 Regards, Keith. Public key available from keys.gnupg.net Key fingerprint: C19E C018 1547 DE50 E1D4 8F53 C0AD 36C6 347E 5A3F --kj7hYeaPw2jhMormRbUZPFOumftEeyNw2-- --ndfuiJMoXQvMzavhWYThSK8laCMVh5258 Content-Type: application/pgp-signature; name="OpenPGP_signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="OpenPGP_signature" -----BEGIN PGP SIGNATURE----- wsF5BAABCAAjFiEEwZ7AGBVH3lDh1I9TwK02xjR+Wj8FAl/3dosFAwAAAAAACgkQwK02xjR+Wj9f wA/8D03JIYCZCFN2xVOwt7Nt8kCLM872nlu3S9pBLJjgZ12M5cHm7SnlgswQNsG4eukQpUd4cnWh C8OZKH9pZp2nBUgWENe9txL0c4NhoLsWlzvd5NBB3pfNx9VxZ2XQW5oN931m68IbhpoCwr1MQq9r 24RismfpB1Sv4M8yD7ixdwmSFMrdTVaxRTQHiQu6lML3umctNliRtaFZY/CH8I30Gf2tnpZ8P/Kh w1V6Ci60GOkG/OwOtPvqH1h2WGOKdeXhNZ7V9NzgdF4UukxNyAaTn5ZQ2mHUlFeeyKKiVuDKu2GK ugdCfIJp0mvjC0qMx+/+NcYeW8roIuYCdHK9LPfGHWKqpma9hUDWsflkzSNdeH3q00z75jH3Qcxo l8/KtlZ0tkydv60lnoSy0R7ZeFCeOPfb60GylNutJfREEPadXl2J5H0jOvsrr0RDRPRj+TkygHlX eIycX8AcOA5htHI751inIGGN6gWVwsEkwy4gQMfz3yKjQFVPNm/sZnccB/am/AXXnSbJa4UQQxgE 2Q9daJ6hs35OUXVSAc9J38/WMssF9oFYCum+1xUxwCDYhUsQ7aL8ah14soIHEGMkgVGFBPNZRPzs ygwPdC+3mKUvb+1Tgg4yNz84tfmoN4kbXynbDW5E2kjvj86UUdHCnLdnXRGijZaOstCxfsB5t69U L78= =X8Gc -----END PGP SIGNATURE----- --ndfuiJMoXQvMzavhWYThSK8laCMVh5258-- --===============9146708183751371636== Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: base64 Content-Disposition: inline X19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX18KTWluR1ctVXNl cnMgbWFpbGluZyBsaXN0Ck1pbkdXLVVzZXJzQGxpc3RzLm9zZG4ubWUKClRoaXMgbGlzdCBvYnNl cnZlcyB0aGUgUG9zdGluZyBFdGlxdWV0dGUsIGFzIGRlc2NyaWJlZCBhdCBodHRwczovL21pbmd3 Lm9zZG4uaW8vaW5kZXguaHRtbD9wYWdlPW1haWxpbmcuaHRtbCNsaXN0LWV0aXF1ZXR0ZS4KV2Ug YXNrIHRoYXQgeW91IGJlIHBvbGl0ZSBhbmQgZG8gdGhlIHNhbWUuICBEaXNyZWdhcmQgZm9yIHRo ZSBsaXN0IGV0aXF1ZXR0ZSBtYXkgY2F1c2UgeW91ciBhY2NvdW50IHRvIGJlIG1vZGVyYXRlZC4K Cl9fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fCllvdSBtYXkg Y2hhbmdlIHlvdXIgTWluR1cgQWNjb3VudCBPcHRpb25zIG9yIHVuc3Vic2NyaWJlIGF0OgpodHRw czovL2xpc3RzLm9zZG4ubWUvbWFpbG1hbi9saXN0aW5mby9taW5ndy11c2VycwpBbHNvOiBtYWls dG86bWluZ3ctdXNlcnMtcmVxdWVzdEBsaXN0cy5vc2RuLm1lP3N1YmplY3Q9dW5zdWJzY3JpYmU= --===============9146708183751371636==--