binutils-gdb/libctf
Eli Zaretskii 50500ecfef libctf: compilation failure on MinGW due to missing errno values
This commit fixes a compilation failure in a couple of libctf files
due to the use of EOVERFLOW and ENOTSUP, which are not defined
when compiling on MinGW.

libctf/ChangeLog:

	PR binutils/25155:
	* ctf-create.c (EOVERFLOW): If not defined by system header,
	redirect to ERANGE as a poor man's substitute.
	* ctf-subr.c (ENOTSUP): If not defined, use ENOSYS instead.

This one is how Eli implemented it. I think this implementation
has a weakness in the following sense: If other units in libctf
start using those constants, we'll get the same error again.
Also, I'm wondering whether their use is documented as part of
the official libtcf API or not -- users might be writing code
that tests for these, and if the system doesn't support them,
how would they know what errno code to use in its place. This
argues for a having that information in one of libctf's header
files. I think it would be nice to have those in ctf-decls.h,
but I think we'll need to include <errno.h> in ctf-decls.h if
we decide to define those macros there.

Rather than second-guess what the CTF developers would prefer,
I'm starting by sending Eli's patch, to see what you guys think.

Thanks,
--
Joel
2020-02-01 15:25:19 +04:00
..
ChangeLog libctf: compilation failure on MinGW due to missing errno values 2020-02-01 15:25:19 +04:00
Makefile.am libctf: installable libctf as a shared library 2019-10-03 17:04:56 +01:00
Makefile.in libctf: Regenerate Makefile.in and acinclude.m4 2020-01-05 09:49:33 +04:00
aclocal.m4 libctf: Regenerate Makefile.in and acinclude.m4 2020-01-05 09:49:33 +04:00
config.h.in libctf: Add configure check for asprintf (for MinGW) 2020-01-05 09:54:55 +04:00
configure libctf: Add configure check for asprintf (for MinGW) 2020-01-05 09:54:55 +04:00
configure.ac libctf: Add configure check for asprintf (for MinGW) 2020-01-05 09:54:55 +04:00
ctf-archive.c libctf: avoid the need to ever use ctf_update 2019-10-03 17:04:56 +01:00
ctf-create.c libctf: compilation failure on MinGW due to missing errno values 2020-02-01 15:25:19 +04:00
ctf-decl.c libctf: remove ctf_malloc, ctf_free and ctf_strdup 2019-10-03 17:04:56 +01:00
ctf-decls.h libctf: avoid strndup 2019-06-07 13:46:39 +01:00
ctf-dump.c libctf: make ctf_dump not crash on OOM 2019-10-03 17:04:56 +01:00
ctf-endian.h libctf: make it compile for old glibc 2019-10-03 17:04:55 +01:00
ctf-error.c libctf: handle nonrepresentable types at link time 2019-10-03 17:04:56 +01:00
ctf-hash.c libctf: don't leak hash keys or values on value replacement 2019-10-03 17:04:55 +01:00
ctf-impl.h libctf: make ctf_dump not crash on OOM 2019-10-03 17:04:56 +01:00
ctf-labels.c libctf: fix a number of build problems found on Solaris and NetBSD 2019-05-31 11:10:51 +02:00
ctf-link.c libctf: avoid the need to ever use ctf_update 2019-10-03 17:04:56 +01:00
ctf-lookup.c libctf: avoid the need to ever use ctf_update 2019-10-03 17:04:56 +01:00
ctf-open-bfd.c libctf: actually close bfds we have opened 2019-10-03 17:04:55 +01:00
ctf-open.c libctf: fix tabdamage 2019-10-03 17:04:56 +01:00
ctf-qsort_r.c libctf: look for BSD versus GNU qsort_r signatures 2019-06-04 17:05:08 +01:00
ctf-string.c libctf: remove ctf_malloc, ctf_free and ctf_strdup 2019-10-03 17:04:56 +01:00
ctf-subr.c libctf: compilation failure on MinGW due to missing errno values 2020-02-01 15:25:19 +04:00
ctf-types.c libctf: fix tabdamage 2019-10-03 17:04:56 +01:00
ctf-util.c libctf: make ctf_dump not crash on OOM 2019-10-03 17:04:56 +01:00
elf.h libctf: low-level list manipulation and helper utilities 2019-05-28 17:07:19 +01:00
libctf.ver libctf: installable libctf as a shared library 2019-10-03 17:04:56 +01:00
swap.h libctf: mark swap.h inline functions as static 2019-10-16 11:12:23 -04:00