diff --git a/Include/pyport.h b/Include/pyport.h index 93250f4eb1d..b3b8b6f09af 100644 --- a/Include/pyport.h +++ b/Include/pyport.h @@ -439,11 +439,6 @@ Please be conservative with adding new ones, document them and enclose them in platform-specific #ifdefs. **************************************************************************/ -#ifdef SOLARIS -/* Unchecked */ -extern int gethostname(char *, int); -#endif - #ifdef HAVE__GETPTY #include /* we need to import mode_t */ extern char * _getpty(int *, int, mode_t, int); diff --git a/Misc/NEWS.d/next/Build/2023-09-02-18-04-15.gh-issue-63760.r8hJ6q.rst b/Misc/NEWS.d/next/Build/2023-09-02-18-04-15.gh-issue-63760.r8hJ6q.rst new file mode 100644 index 00000000000..9a7249e923e --- /dev/null +++ b/Misc/NEWS.d/next/Build/2023-09-02-18-04-15.gh-issue-63760.r8hJ6q.rst @@ -0,0 +1,3 @@ +Fix Solaris build: no longer redefine the ``gethostname()`` function. Solaris +defines the function since 2005. Patch by Victor Stinner, original patch by +Jakub KulĂ­k.