[PATCH] Fix C11 conformance issues
Carlos O'Donell
carlos@redhat.com
Wed Jul 25 14:32:00 GMT 2018
On 07/25/2018 09:43 AM, Adhemerval Zanella wrote:
> Remove conformace assumption of NPTL implementation for ISO C threads
> and revert wrong libcrypt addition on linknamespace-libs-XPG4.
>
> The i686-gnu target now shows two new conformance failures:
>
> FAIL: conform/ISO11/threads.h/conform
> FAIL: conform/ISO11/threads.h/linknamespace
>
> It is expected due missing HTL ISO C threads support and both conformance
> .out files indicates the reason ("#error "HTL does not implement ISO C
> threads").
>
> Checked on i686-linux-gnu and i686-gnu.
>
> * include/threads.h: Move to ...
> * sysdeps/nptl/threads.h: ... here.
> * sysdeps/htl/threads.h: New file.
> * conform/Makefile (linknamespace-libs-ISO11): Use
> static-thread-library instead of linking libpthread.
> (linknamespace-libs-XPG4): Revert wrong libcrypt.a addition.
OK for 2.28.
Reviewed-by: Carlos O'Donell <carlos@redhat.com>
> ---
> ChangeLog | 9 +++++++++
> conform/Makefile | 5 ++---
> sysdeps/htl/threads.h | 1 +
> {include => sysdeps/nptl}/threads.h | 0
> 4 files changed, 12 insertions(+), 3 deletions(-)
> create mode 100644 sysdeps/htl/threads.h
> rename {include => sysdeps/nptl}/threads.h (100%)
>
> diff --git a/conform/Makefile b/conform/Makefile
> index a0ab70e..d430931 100644
> --- a/conform/Makefile
> +++ b/conform/Makefile
> @@ -197,9 +197,8 @@ linknamespace-libs-xsi = $(linknamespace-libs-posix)
> linknamespace-libs-ISO = $(linknamespace-libs-isoc)
> linknamespace-libs-ISO99 = $(linknamespace-libs-isoc)
> linknamespace-libs-ISO11 = $(linknamespace-libs-isoc) \
> - $(common-objpfx)nptl/libpthread.a
> -linknamespace-libs-XPG4 = $(linknamespace-libs-isoc) \
> - $(common-objpfx)crypt/libcrypt.a
> + $(static-thread-library)
OK, uses static-thread-library.
> +linknamespace-libs-XPG4 = $(linknamespace-libs-isoc)
OK, fixes libcrypt issue.
> linknamespace-libs-XPG42 = $(linknamespace-libs-XPG4)
> linknamespace-libs-POSIX = $(linknamespace-libs-thr)
> linknamespace-libs-UNIX98 = $(linknamespace-libs-xsi)
> diff --git a/sysdeps/htl/threads.h b/sysdeps/htl/threads.h
> new file mode 100644
> index 0000000..3c04fbc
> --- /dev/null
> +++ b/sysdeps/htl/threads.h
> @@ -0,0 +1 @@
> +#error "HTL does not implement ISO C threads"
OK.
> diff --git a/include/threads.h b/sysdeps/nptl/threads.h
> similarity index 100%
> rename from include/threads.h
> rename to sysdeps/nptl/threads.h
>
More information about the Libc-alpha
mailing list