From 881e0dcc3891cc7b51e7dd5e9f1e9ebae89f289f Mon Sep 17 00:00:00 2001 From: Shelley Vohr Date: Tue, 11 Nov 2025 12:16:49 +0100 Subject: [PATCH] unix: remove deprecated errno constants Various errno constants were deprecated by POSIX. libc++ added deprecation markers on these constants. This change removes the usage of these constants to fix a compilation failure due to mappings of those constants. See: https://github.com/llvm/llvm-project/pull/80542 --- include/uv.h | 1 - include/uv/errno.h | 12 ------------ 2 files changed, 13 deletions(-) diff --git a/include/uv.h b/include/uv.h index d1a77c749..53f5a73dd 100644 --- a/include/uv.h +++ b/include/uv.h @@ -156,7 +156,6 @@ struct uv__queue { XX(EFTYPE, "inappropriate file type or format") \ XX(EILSEQ, "illegal byte sequence") \ XX(ESOCKTNOSUPPORT, "socket type not supported") \ - XX(ENODATA, "no data available") \ XX(EUNATCH, "protocol driver not attached") \ XX(ENOEXEC, "exec format error") \ diff --git a/include/uv/errno.h b/include/uv/errno.h index ac00778cf..f0c4d6dfc 100644 --- a/include/uv/errno.h +++ b/include/uv/errno.h @@ -456,18 +456,6 @@ # define UV__ESOCKTNOSUPPORT (-4025) #endif -/* FreeBSD defines ENODATA in /usr/include/c++/v1/errno.h which is only visible - * if C++ is being used. Define it directly to avoid problems when integrating - * libuv in a C++ project. - */ -#if defined(ENODATA) && !defined(_WIN32) -# define UV__ENODATA UV__ERR(ENODATA) -#elif defined(__FreeBSD__) -# define UV__ENODATA (-9919) -#else -# define UV__ENODATA (-4024) -#endif - #if defined(EUNATCH) && !defined(_WIN32) # define UV__EUNATCH UV__ERR(EUNATCH) #else