diff options
| author | Ulf Hermann <[email protected]> | 2017-02-23 17:22:41 +0100 |
|---|---|---|
| committer | Ulf Hermann <[email protected]> | 2017-04-27 15:56:33 +0000 |
| commit | 121d248c1da7f2130a2edde6d158f116c89ed407 (patch) | |
| tree | ad7a348a88db648da6e2df366d89fcb7b7436a1c /libgnu/unistd--.h | |
| parent | f10810fff6fda147f9c07fea0e1b33a7c4d79ad1 (diff) | |
Add gnulib modules to replace missing libc functionality
This enables us to build a fully featured elfutils package on systems
with reduced C libraries, such as windows. All the modules are built
into libgnu.a, which is then linked into all binaries if
--enable-gnulib is given on the configure line.
Change-Id: I743fd22172bc85d9f10dcc3dad8eb921f462b554
Reviewed-by: Christian Kandeler <[email protected]>
Diffstat (limited to 'libgnu/unistd--.h')
| -rw-r--r-- | libgnu/unistd--.h | 32 |
1 files changed, 32 insertions, 0 deletions
diff --git a/libgnu/unistd--.h b/libgnu/unistd--.h new file mode 100644 index 00000000..dd1f068b --- /dev/null +++ b/libgnu/unistd--.h @@ -0,0 +1,32 @@ +/* Like unistd.h, but redefine some names to avoid glitches. + + Copyright (C) 2005, 2009-2017 Free Software Foundation, Inc. + + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see <http://www.gnu.org/licenses/>. */ + +/* Written by Paul Eggert. */ + +#include <unistd.h> +#include "unistd-safer.h" + +#undef dup +#define dup dup_safer + +#undef pipe +#define pipe pipe_safer + +#if GNULIB_PIPE2_SAFER +# undef pipe2 +# define pipe2 pipe2_safer +#endif |
