conformtest: clean up POSIX expections for sys/utsname.h, sys/wait.h

Message ID Pine.LNX.4.64.1405162132510.24114@digraph.polyomino.org.uk
State Committed
Headers

Commit Message

Joseph Myers May 16, 2014, 9:34 p.m. UTC
  Continuing the series of patches to clean up conformtest expectations
for "POSIX" (1995/6) based on review of the expectations against the
standard, this patch cleans up expectations for sys/utsname.h and
sys/wait.h.  Tested x86_64; a new XFAIL for sys/wait.h is added.

(This patch is independent of my previous patch
<https://sourceware.org/ml/libc-alpha/2014-05/msg00391.html>.)

2014-05-16  Joseph Myers  <joseph@codesourcery.com>

	* conform/data/sys/utsname.h-data (*_t): Allow.
	* conform/data/sys/wait.h-data [POSIX] (uid_t): Do not define.
	[POSIX] (WEXITED): Do not expect constant.
	[POSIX] (WSTOPPED): Likewise.
	[POSIX] (WNOHANG): Likewise.
	[POSIX] (WNOWAIT): Likewise.
	[POSIX] (siginfo_t): Do not expect type or elements.
	[POSIX] (pid_t): Do not expect type.
	[POSIX] (signal.h): Do not allow header.
	[POSIX] (sys/resource.h): Likewise.
	[POSIX] (si_*): Do not allow pattern.
	[POSIX] (W*): Likewise.
	[POSIX] (P_*): Likewise.
	[POSIX] (BUS_*): Likewise.
	[POSIX] (CLD_*): Likewise.
	[POSIX] (FPE_*): Likewise.
	[POSIX] (ILL_*): Likewise.
	[POSIX] (POLL_*): Likewise.
	[POSIX] (SEGV_*): Likewise.
	[POSIX] (SI_*): Likewise.
	[POSIX] (TRAP_*): Likewise.
	* conform/Makefile (test-xfail-POSIX/sys/wait.h/conform): New
	variable.
  

Comments

Joseph Myers May 22, 2014, 2:44 p.m. UTC | #1
Ping.  This patch 
<https://sourceware.org/ml/libc-alpha/2014-05/msg00455.html> is pending 
review.
  
Joseph Myers May 30, 2014, 9:59 p.m. UTC | #2
Ping^2.  This patch 
<https://sourceware.org/ml/libc-alpha/2014-05/msg00455.html> is still 
pending review.
  
Joseph Myers June 6, 2014, 4:41 p.m. UTC | #3
Ping^3.  This patch 
<https://sourceware.org/ml/libc-alpha/2014-05/msg00455.html> is still 
pending review.
  
Joseph Myers June 13, 2014, 11:30 a.m. UTC | #4
Ping^4.  This patch 
<https://sourceware.org/ml/libc-alpha/2014-05/msg00455.html> is still 
pending review.
  
Joseph Myers June 20, 2014, 11:44 a.m. UTC | #5
Ping^5.  This patch 
<https://sourceware.org/ml/libc-alpha/2014-05/msg00455.html> is still 
pending review.
  
Joseph Myers June 26, 2014, 8:16 p.m. UTC | #6
Ping^6.  This patch 
<https://sourceware.org/ml/libc-alpha/2014-05/msg00455.html> is still 
pending review.
  
Joseph Myers June 30, 2014, 3:15 p.m. UTC | #7
Ping^7 (last ping for this patch for 2.20).  This patch 
<https://sourceware.org/ml/libc-alpha/2014-05/msg00455.html> is still 
pending review.
  
Joseph Myers July 17, 2014, 2:37 p.m. UTC | #8
Ping^8.  This patch 
<https://sourceware.org/ml/libc-alpha/2014-05/msg00455.html> is still 
pending review.
  
Joseph Myers Sept. 8, 2014, 3:36 p.m. UTC | #9
Ping^9.  This patch 
<https://sourceware.org/ml/libc-alpha/2014-05/msg00455.html> is still 
pending review.
  
Joseph Myers Sept. 15, 2014, 5:24 p.m. UTC | #10
Ping^10.  This patch 
<https://sourceware.org/ml/libc-alpha/2014-05/msg00455.html> is still 
pending review.
  
Joseph Myers Sept. 22, 2014, 3:03 p.m. UTC | #11
Ping^11.  This patch 
<https://sourceware.org/ml/libc-alpha/2014-05/msg00455.html> is still 
pending review.
  
Joseph Myers Sept. 29, 2014, 2:51 p.m. UTC | #12
Ping^12.  This patch 
<https://sourceware.org/ml/libc-alpha/2014-05/msg00455.html> is still 
pending review.
  
Joseph Myers Oct. 6, 2014, 10 a.m. UTC | #13
Ping^13.  This patch 
<https://sourceware.org/ml/libc-alpha/2014-05/msg00455.html> is still 
pending review.
  
Joseph Myers Oct. 13, 2014, 11:33 a.m. UTC | #14
Ping^14.  This patch 
<https://sourceware.org/ml/libc-alpha/2014-05/msg00455.html> is still 
pending review.
  
Siddhesh Poyarekar Oct. 14, 2014, 6:59 a.m. UTC | #15
On Fri, May 16, 2014 at 09:34:55PM +0000, Joseph S. Myers wrote:
> Continuing the series of patches to clean up conformtest expectations
> for "POSIX" (1995/6) based on review of the expectations against the
> standard, this patch cleans up expectations for sys/utsname.h and
> sys/wait.h.  Tested x86_64; a new XFAIL for sys/wait.h is added.
> 
> (This patch is independent of my previous patch
> <https://sourceware.org/ml/libc-alpha/2014-05/msg00391.html>.)

I haven't been able to acquire a copy of the standard to verify the
changes, but since there's nothing that seems to pop out as obviously
wrong and you're maintainer for conformtests, I don't mind you
checking this in.  14 pings is a long time to wait due to an outdated
document that is not openly available (for an affordable price).

Siddhesh
  

Patch

diff --git a/conform/Makefile b/conform/Makefile
index e1df914..c360c33 100644
--- a/conform/Makefile
+++ b/conform/Makefile
@@ -189,6 +189,7 @@  test-xfail-XPG4/ucontext.h/conform = yes
 test-xfail-XPG4/unistd.h/conform = yes
 test-xfail-XPG4/utmpx.h/conform = yes
 test-xfail-POSIX/tar.h/conform = yes
+test-xfail-POSIX/sys/wait.h/conform = yes
 test-xfail-UNIX98/arpa/inet.h/conform = yes
 test-xfail-UNIX98/fcntl.h/conform = yes
 test-xfail-UNIX98/langinfo.h/conform = yes
diff --git a/conform/data/sys/utsname.h-data b/conform/data/sys/utsname.h-data
index 3564627..82f7f39 100644
--- a/conform/data/sys/utsname.h-data
+++ b/conform/data/sys/utsname.h-data
@@ -8,4 +8,5 @@  element {struct utsname} char version []
 element {struct utsname} char machine []
 
 function int uname (struct utsname *)
+allow *_t
 #endif
diff --git a/conform/data/sys/wait.h-data b/conform/data/sys/wait.h-data
index 6acdab2..e0787e3 100644
--- a/conform/data/sys/wait.h-data
+++ b/conform/data/sys/wait.h-data
@@ -1,7 +1,6 @@ 
 #if !defined ISO && !defined ISO99 && !defined ISO11
 #ifdef  POSIX
 # define pid_t __pid_t
-# define uid_t __uid_t
 #endif
 
 constant WNOHANG
@@ -17,13 +16,15 @@  macro WIFSTOPPED
 macro WSTOPSIG
 macro WTERMSIG
 
+# ifndef POSIX
 constant WEXITED
 constant WSTOPPED
-# if !defined POSIX && !defined POSIX2008
+#  ifndef POSIX2008
 constant WCONTINUED
-# endif
+#  endif
 constant WNOHANG
 constant WNOWAIT
+# endif
 
 #if !defined POSIX
 type idtype_t
@@ -33,7 +34,6 @@  constant P_PID
 constant P_PGID
 
 type id_t
-#endif
 
 type siginfo_t
 
@@ -46,6 +46,7 @@  element siginfo_t {void*} si_addr
 element siginfo_t int si_status
 element siginfo_t long si_band
 element siginfo_t {union sigval} si_value
+#endif
 
 #if !defined POSIX && !defined XPG3 && !defined XOPEN2K8 && !defined POSIX2008
 type {struct rusage}
@@ -54,7 +55,9 @@  element {struct rusage} {struct timeval} ru_utime
 element {struct rusage} {struct timeval} ru_stime
 #endif
 
+#if !defined POSIX
 type pid_t
+#endif
 
 function pid_t wait (int*)
 #if !defined POSIX && !defined XOPEN2K && !defined XOPEN2K8 && !defined POSIX2008
@@ -65,6 +68,7 @@  function int waitid (idtype_t, id_t, siginfo_t*, int)
 #endif
 function pid_t waitpid (pid_t, int*, int)
 
+#if !defined POSIX
 allow-header signal.h
 allow-header sys/resource.h
 
@@ -79,5 +83,6 @@  allow POLL_
 allow SEGV_
 allow SI_
 allow TRAP_
+#endif
 allow *_t
 #endif