Blame nptl/pt-system.c

Packit Service 82fcde
/* ABI compatibility for 'system' symbol in libpthread ABI.
Packit Service 82fcde
   Copyright (C) 2002-2018 Free Software Foundation, Inc.
Packit Service 82fcde
   This file is part of the GNU C Library.
Packit Service 82fcde
   Contributed by Ulrich Drepper <drepper@redhat.com>, 2002.
Packit Service 82fcde
Packit Service 82fcde
   The GNU C Library is free software; you can redistribute it and/or
Packit Service 82fcde
   modify it under the terms of the GNU Lesser General Public
Packit Service 82fcde
   License as published by the Free Software Foundation; either
Packit Service 82fcde
   version 2.1 of the License, or (at your option) any later version.
Packit Service 82fcde
Packit Service 82fcde
   The GNU C Library is distributed in the hope that it will be useful,
Packit Service 82fcde
   but WITHOUT ANY WARRANTY; without even the implied warranty of
Packit Service 82fcde
   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
Packit Service 82fcde
   Lesser General Public License for more details.
Packit Service 82fcde
Packit Service 82fcde
   You should have received a copy of the GNU Lesser General Public
Packit Service 82fcde
   License along with the GNU C Library; if not, see
Packit Service 82fcde
   <http://www.gnu.org/licenses/>.  */
Packit Service 82fcde
Packit Service 82fcde
#include <stdlib.h>
Packit Service 82fcde
#include <shlib-compat.h>
Packit Service 82fcde
Packit Service 82fcde
/* libpthread once had its own 'system', though there was no apparent
Packit Service 82fcde
   reason for it.  There is no use in having a separate symbol in
Packit Service 82fcde
   libpthread, but the historical ABI requires it.  For static linking,
Packit Service 82fcde
   there is no need to provide anything here--the libc version will be
Packit Service 82fcde
   linked in.  For shared library ABI compatibility, there must be a
Packit Service 82fcde
   'system' symbol in libpthread.so.
Packit Service 82fcde
Packit Service 82fcde
   With an IFUNC resolver, it would be possible to avoid the indirection,
Packit Service 82fcde
   but the IFUNC resolver might run before the __libc_system symbol has
Packit Service 82fcde
   been relocated, in which case the IFUNC resolver would not be able to
Packit Service 82fcde
   provide the correct address.  */
Packit Service 82fcde
Packit Service 82fcde
#if SHLIB_COMPAT (libpthread, GLIBC_2_0, GLIBC_2_22)
Packit Service 82fcde
Packit Service 82fcde
static int __attribute__ ((used))
Packit Service 82fcde
system_compat (const char *line)
Packit Service 82fcde
{
Packit Service 82fcde
  return __libc_system (line);
Packit Service 82fcde
}
Packit Service 82fcde
strong_alias (system_compat, system_alias)
Packit Service 82fcde
compat_symbol (libpthread, system_alias, system, GLIBC_2_0);
Packit Service 82fcde
Packit Service 82fcde
#endif