On 6/1/2018 6:10 AM, Corinna Vinschen wrote:
On May 30 16:28, Ken Brown wrote:
The attached patch fixes the second problem reported in
https://cygwin.com/ml/cygwin/2018-05/msg00316.html, though I'm not sure it's
the right fix.
Ken
From 4940baac08cd9339d771d9db90a880c61610ae4c Mon Sep 17 00:00:00 2001
From: Ken Brown <kbr...@cornell.edu>
Date: Wed, 30 May 2018 16:19:01 -0400
Subject: [PATCH] Declare the pthread_rwlock_* functions if __cplusplus >=
201402L
Some of these functions are used in the <shared_mutex> C++ header.
---
winsup/cygwin/include/pthread.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/winsup/cygwin/include/pthread.h b/winsup/cygwin/include/pthread.h
index 3dfc2bc80..fed616532 100644
--- a/winsup/cygwin/include/pthread.h
+++ b/winsup/cygwin/include/pthread.h
@@ -187,7 +187,7 @@ int pthread_spin_unlock (pthread_spinlock_t *);
#endif
/* RW Locks */
-#if __XSI_VISIBLE >= 500 || __POSIX_VISIBLE >= 200112
+#if __XSI_VISIBLE >= 500 || __POSIX_VISIBLE >= 200112 || __cplusplus >= 201402L
int pthread_rwlock_destroy (pthread_rwlock_t *rwlock);
int pthread_rwlock_init (pthread_rwlock_t *rwlock, const pthread_rwlockattr_t
*attr);
int pthread_rwlock_rdlock (pthread_rwlock_t *rwlock);
--
2.17.0
Pushed. Any text for winsup/cygwin/release/2.10.1, perhaps?
Attached.
Ken
From 661edafedeb09d6ead1d3249763dc3fc6d3de40f Mon Sep 17 00:00:00 2001
From: Ken Brown <kbr...@cornell.edu>
Date: Fri, 1 Jun 2018 08:31:43 -0400
Subject: [PATCH] Cygwin: Add pthread_rwlock_* fix to release notes
---
winsup/cygwin/release/2.10.1 | 3 +++
1 file changed, 3 insertions(+)
diff --git a/winsup/cygwin/release/2.10.1 b/winsup/cygwin/release/2.10.1
index c133124ae..42d9d1110 100644
--- a/winsup/cygwin/release/2.10.1
+++ b/winsup/cygwin/release/2.10.1
@@ -29,3 +29,6 @@ Bug Fixes
- Fix a stack alignment problem which may lead to spurious crashes after
fork.
Addresses: https://cygwin.com/ml/cygwin-patches/2018-q2/msg00016.html
+
+- Fix a g++ compilation problem with -std=c++14 or -std=c++17.
+ Addresses: https://cygwin.com/ml/cygwin/2018-05/msg00316.html
--
2.17.0