diff options
author | Yonggang Luo <luoyonggang@gmail.com> | 2022-10-16 00:36:20 +0800 |
---|---|---|
committer | Mark Wielaard <mark@klomp.org> | 2022-10-16 22:34:17 +0200 |
commit | a6b2ec76d51386dd06ab86d46eabbcf5140fe80d (patch) | |
tree | 13ec3814bf55e17fb9352a7c37a7d0ae7abc222d /lib | |
parent | 2a4ce08fafcf76d866ae5f6b394389d8d93aa0cb (diff) | |
download | elfutils-a6b2ec76d51386dd06ab86d46eabbcf5140fe80d.tar.gz |
move platform depended include into system.h of libelf
All of these files either #include <system.h> directly or #include "libelfP.h"
And now "libelfP.h also #include <system.h>, so the platform depended include
can be moved to system.h safely
Signed-off-by: Yonggang Luo <luoyonggang@gmail.com>
Diffstat (limited to 'lib')
-rw-r--r-- | lib/ChangeLog | 10 | ||||
-rw-r--r-- | lib/system.h | 11 |
2 files changed, 17 insertions, 4 deletions
diff --git a/lib/ChangeLog b/lib/ChangeLog index 36c3131f..e4f00a8f 100644 --- a/lib/ChangeLog +++ b/lib/ChangeLog @@ -1,3 +1,13 @@ +2022-10-16 Yonggang Luo <luoyonggang@gmail.com> + + * system.h: Add sys/mman.h as system dependend header. + * common.h: Remove ar.h, byteswap.h and endian.h. + * elf32_checksum.c: Remove endian.h. + * elf32_getphdr.c: Remove unistd.h and system.h. + * elf32_getshdr.c: Remove unistd.h.h and system.h. + * elf32_updatefile.c: Remove unistd.h, sys/mman.h and system.h. + * elf32_updatenull.c: Remove endian.h and system.h. + 2022-08-05 Mark Wielaard <mark@klomp.org> * dynamicsizehash_concurrent.c (resize_helper): Add documentation. diff --git a/lib/system.h b/lib/system.h index d3f42c91..48004df1 100644 --- a/lib/system.h +++ b/lib/system.h @@ -35,14 +35,17 @@ #include <errno.h> #include <stddef.h> #include <stdint.h> -#include <sys/param.h> -#include <endian.h> -#include <byteswap.h> -#include <unistd.h> #include <string.h> #include <stdarg.h> #include <stdlib.h> +/* System dependend headers */ +#include <byteswap.h> +#include <endian.h> +#include <sys/mman.h> +#include <sys/param.h> +#include <unistd.h> + #if defined(HAVE_ERROR_H) #include <error.h> #elif defined(HAVE_ERR_H) |